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,2afac1a4161c7f35 X-Google-Attributes: gid103376,public From: dewar@merv.cs.nyu.edu (Robert Dewar) Subject: Re: Distinguishing type names from other identifiers Date: 1998/01/16 Message-ID: #1/1 X-Deja-AN: 316548823 References: <884736089.2104295427@dejanews.com> <69lael$90o@top.mitre.org> <01bd2207$18f3fac0$95fc82c1@xhv46.dial.pipex.com> X-Complaints-To: usenet@news.nyu.edu X-Trace: news.nyu.edu 884945583 16544 (None) 128.122.140.58 Organization: New York University Newsgroups: comp.lang.ada Date: 1998-01-16T00:00:00+00:00 List-Id: Michael says <<> However, when stuff like _TYPE is added at the end of each type by > FIAT of a quality standard, you not only have changed the meaning > of quality from something that works well and is easily fixed to > something that is regimented, but you also have lost the reliability, > lost the maintainability, and lost the desire to read that code. > It is no longer cool code. >> Now here I disagree. If you have programmers (I don't care whether they are maintaining code or building it), and their orientation is that they react to quality standards by deciding that it means they cannot write cool code, and they want to do their own thing, then the one and only preferable solution is to get rid of these programmers. What you refer to as regimentation is something that quality workers in all fields must learn to accept. Yes, I realize that the programming field tends to be full of mavericks who insist on writing neat cool code, but this is a signal weakness of the field, not a strength. In practice I find one of the advantages of Ada is that Ada tends to encourage what you would like to call "regimented" environments, and thus to scare off the "cool neat code" crowd. Whether the rule of adding _Type at the end of type names is a good one is one that should be debated on its merits, but Michael's contribution quoted above seems to suggest that it should be rejected solely on the basis that it is a rule. That is not a legitimate argument. Some quality standards can indeed be absolute. Everyone agrees, or should agree that consistency of code style is an important requirement in any project, and some aspects of coding style can and should be absolute rules (for a look at the absolute rules enforced by the GNAT project, look at the style.adb unit, which is activated by the internal GNAT-project-only switch -gnatg. We require the use of -gnatg in all GNAT code. This switch enforces a number of rules ranging from the trivial (no use of tab characters or trailing blanks in code) to more significant (all subprograms except main programs at the program library level must have separate specifications). Note that I agree that enjoyment plays an important part in any work, and that "desire to read that code" is important. But competent programmers find that following "regimentation" makes code more uniform, and therefore much pleasanter to read. Robert Dewar