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,2078dddcdcd8d83 X-Google-Attributes: gid103376,public From: Simon Wright Subject: Re: assign help!! Date: 1997/05/10 Message-ID: #1/1 X-Deja-AN: 240476448 X-NNTP-Posting-Host: pogner.demon.co.uk References: <5kjvcv$evt@news.cis.nctu.edu.tw> <5kn8ko$jcc@top.mitre.org> <1997May7.201035.2439@nosc.mil> Organization: At Home Newsgroups: comp.lang.ada Date: 1997-05-10T00:00:00+00:00 List-Id: sampson@nosc.mil (Charles H. Sampson) writes: > This has nothing to do with the original poster's issue, but I > have to disagree with you on this naming convention. I much prefer the > one advocated by Ada Quality and Style: Type names should be general > singular nouns and object names should be specific singular nouns, ex- > cept for predicates as the names for boolean objects. (I don't just > prefer it. I had some influence on its being in AQ&S that way.) The > reason is that your program will be more readable AS AN ENGLISH SEN- > TENCE. For example > > Error_Count : Natural; > > can be read as "Error_Count is a natural number". It could even be read > as "Error_Count: Natural". Notice also, as the rationale to the naming > section of AQ&S says, it's Integer, Boolean, and Character, not Inte- > gers, Booleans, and Characters. Must say I agree with you on this one! A pity that AQ&S isn't consistent, though: see eg Message_Code_Type in 5.4.6, Element_Type in 8.3.3, and many others .. One point on derived (tagged) types; following someone else's posting on various types of Track, I find it helps to use the plural form in the package name and the undecorated singular for the type, eg package Tracks is type Track is abstract tagged private; .. package Friendly_Tracks is type Track is new Tracks.Track with private; .. package Enemy_Tracks is type Track is new Tracks.Track with private; .. Just my 2p.