From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,21bbcb8deeeab673 X-Google-Attributes: gid103376,public From: dewar@merv.cs.nyu.edu (Robert Dewar) Subject: Re: Ada95 Pretty-Printers/Coding styles Date: 1997/06/26 Message-ID: #1/1 X-Deja-AN: 252749339 References: <33A54D07.4E14@aisf.com> <5orld5$5r8@client2.news.psi.net> Organization: New York University Newsgroups: comp.lang.ada Date: 1997-06-26T00:00:00+00:00 List-Id: Jeff Burns said <<>These rules [style.ads and style.adb] are by no means trivial, >they include things like > >a) specs required for all procedures >b) capitalization in a use of an identifier must match the declaration This is interesting because the second example you give IS trivial, at least for Ada-ASSURED, and not to just monitor this style but to actually automate compliance. >> Rereading this, I am almost certain that you misread b) to be talking about a consistent capitalization style. Which is indeed trivial. This is much more subtle, since it handles visibility and overloading in GNAT: 1. procedure q is 2. procedure Printf (X : String); 3. procedure Printf (X : String) is 4. begin 5. null; 6. end Printf; 7. 8. procedure printf (X : Integer); 9. procedure printf (X : Integer) is 10. begin 11. null; 12. end printf; 13. 14. S : String (1 .. 3); 15. I : Integer; 16. 17. begin 18. Printf (S); 19. printf (S); | >>> (style) bad identifier casing, should be "Printf" 20. Printf (I); | >>> (style) bad identifier casing, should be "printf" 21. printf (I); 22. end q; I chose printf as the name here, because the convention in GNAT when importing functions from C is to use the C capitalization (we do NOT have any consistent 100% enforced rule for capitalization -- we have strict rules, but they are a bit subtle, and beyond the easy reach of a tool). Are you really sure that Ada Assured regards the above as "trivial" And if so, surely enforcing the presence of specs (something that we really *do* want enforced mechanically) is even more trivial no?