comp.lang.ada
 help / color / mirror / Atom feed
From: Robert A Duff <bobduff@shell01.TheWorld.com>
Subject: Re: Case dependence and coding standards
Date: 03 Jun 2003 13:31:55 -0400
Date: 2003-06-03T13:31:55-04:00	[thread overview]
Message-ID: <wccr86bjcdw.fsf@shell01.TheWorld.com> (raw)
In-Reply-To: 035odv8mfiksmqo69q0250qp141oebtdro@4ax.com

Fionn mac Cuimhaill <invisible@hiding.from.spam> writes:

> With regards to the thread about case dependence - no, no, a thousand
> times no! Keep Ada the way it is. I *would* like to see a fairly
> simple way of getting the compiler to enforce coding standards.

GNAT has a switch that requires a reference to a declaration to
case-match the declaration.  That seems like a good idea, and is much
simpler than the "dictionary" idea you outlined.

Furthermore, there is no advantage to having some folks use upper case
for reserved words.  The standard advises lower case, and if you do
differently, you make the code harder to read for folks used to the
standard convention.

>...I
> frequently annoy myself  by  writing something like Put_line when I
> intended to to write Put_Line.

GNAT would complain about this (under the switch).

It would be nicer to have a compiler that simply corrected such errors
in the source file, instead of complaining about them.  The goal is to
make consistent/readable code, not to punish programmers who are too
lazy to hit the shift key.

- Bob



  reply	other threads:[~2003-06-03 17:31 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-06-03  5:05 Case dependence and coding standards Fionn mac Cuimhaill
2003-06-03 17:31 ` Robert A Duff [this message]
2003-06-03 17:46   ` Vinzent Hoefler
2003-06-03 19:04     ` Robert A Duff
2003-06-03 23:37       ` Randy Brukardt
2003-06-04  2:39         ` Wesley Groleau
2003-06-04 13:28           ` Georg Bauhaus
2003-06-04 15:44             ` Preben Randhol
2003-06-04 22:32             ` Wesley Groleau
2003-06-05 12:01               ` Georg Bauhaus
2003-06-05 15:36                 ` Preben Randhol
2003-06-05 17:41                   ` Wesley Groleau
2003-06-05 17:47                     ` Preben Randhol
2003-06-05 17:51                       ` Preben Randhol
2003-06-05 18:32                 ` Wesley Groleau
2003-06-06  8:58                   ` Georg Bauhaus
2003-06-07  0:53                     ` Wesley Groleau
2003-06-10 15:05                       ` Georg Bauhaus
2003-06-05 17:32               ` Wesley Groleau
2003-06-05 17:43                 ` Preben Randhol
2003-06-04  8:39       ` Vinzent Hoefler
2003-06-04 16:32         ` Stephen Leake
2003-06-05  1:27           ` Robert I. Eachus
2003-06-05  7:47           ` Vinzent Hoefler
2003-06-05 17:47             ` Stephen Leake
2003-06-05 19:43               ` Wesley Groleau
2003-06-06  9:27               ` Georg Bauhaus
2003-06-06 10:29                 ` Preben Randhol
2003-06-03 19:38   ` Stephen Leake
  -- strict thread matches above, loose matches on Subject: below --
2003-06-04 17:00 Lionel.DRAGHI
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox