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: Jeff Carter Subject: Re: Warning: Religious naming convention discussion :-) [was: assign help!!] Date: 1997/05/12 Message-ID: <33773A11.41C67EA6@spam.innocon.com>#1/1 X-Deja-AN: 241085064 References: <5kjvcv$evt@news.cis.nctu.edu.tw> <5kn8ko$jcc@top.mitre.org> <1997May7.201035.2439@nosc.mil> <33727EEA.2092@sprintmail.com> <5kuf1j$17vi@uni.library.ucla.edu> <3373666A.31DFF4F5@spam.innocon.com> <3373EAB5.73A0@sprintmail.com> Organization: Innovative Concepts, Inc. Newsgroups: comp.lang.ada Date: 1997-05-12T00:00:00+00:00 List-Id: John G. Volan wrote: ... > (By the way, we can level a similar criticism against the AQ&S guide's > "general" vs. "specific" noun phrase scheme: There are just too many > different adjectives in English that can confer "specificness" to a noun > phrase, and it's a waste of effort having to sort them all out. You > wind up concluding, as I did, that it's better to just settle on one > universal "objectness" marker ("The_") and be done with it. But then > you need to take a step back and ask whether it's more practical to mark > all the _objects_, or all the _types_ instead. My conclusion was that > it's better to mark all the types.) The AQ&S is generally too vague and contradictory to be useful. This is perhaps best demonstrated by the fact that its "complete example" does not conform to its recommended style, and contains errors. ... > type Error_Count_Type is range 0 .. Error_Limit; > ... > Error_Count : Error_Count_Type; -- counts errors flagged so far type Error_Count is range ... Num_Errors : Error_Count; > > versus > > type Error_Ident_Type is range Minimum_Error_Ident .. > Maximum_Error_Ident; > ... > Error_Ident : Error_Ident_Type; -- identifies the last error flagged type Error_Id is ... Last_Error : Error_Id; > > But, as you can see, you're still faced with the problem of generating a > different identifier for the type. Nope. See above. > > IMHO, if you can't justify tacking a suffix onto an object name, then it > really doesn't add any useful information. Appending it onto the type > name just wastes energy and adds confusion. If the only purpose it > serves is to differentiate the type, a universal type marker would have > been a simpler solution. You should never tack type suffixes onto object names. That's adding type information to object identifiers. That should be unnecessary. That's what M$'s horrible Hungarian notation is. Although I claimed in jest to be religious about this, I trust that the jest was obvious. I'm most interested in creating readable code; I don't always stick these suffixes on type names. Note, for example, the type Position in the List example. -- Jeff Carter PGP:1024/440FBE21 Auntie-spam reply to; try ( carter @ innocon . com ) "Now go away, or I shall taunt you a second time." Monty Python & the Holy Grail