comp.lang.ada
 help / color / mirror / Atom feed
From: Vinzent Hoefler <ada.rocks@jlfencey.com>
Subject: Re: Case dependence and coding standards
Date: Wed, 04 Jun 2003 10:39:16 +0200
Date: 2003-06-04T10:39:16+02:00	[thread overview]
Message-ID: <bbkba3$aatu7$1@ID-175126.news.dfncis.de> (raw)
In-Reply-To: wccu1b7yod6.fsf@shell01.TheWorld.com

Robert A Duff wrote:

>Vinzent Hoefler <ada.rocks@jlfencey.com> writes:
>
>> Robert A Duff wrote:
>> 
>> >It would be nicer to have a compiler that simply corrected such errors
>> >in the source file, instead of complaining about them.
>> 
>> Well, I expect a compiler to *read* the source, not actually *write*
>> it.
>
>Sure, that's what we're all used to.  But we expect our editors and
>pretty-printers and CM systems and so forth to modify our source code.

Well, let's say it so: I expect it changes the source in the way I
intended to change the source by hacking on some keys, but never
automatically.

>I like to turn on the GNAT switch that complains when I say "Text_io"
>instead of "Text_IO".

Yes, me too. And then I fix such typos by hand.

>  The latter is more readable, because that's how
>the package was declared.  But I would like even better for it to fix
>it, rather than complain about it.

Well, I wouldn't like it. I would expect that a command like
"pretty-print foobar.adb" to do, but not the compiler. Sometimes
source files that I wish to be compiled aren't even writable.

>> >not to punish programmers who are too
>> >lazy to hit the shift key.
>> 
>> NAK. Lazyness has to be punished. Hard. ;->
>
>On the contrary.  Laziness should be encouraged, in the sense of
>programmers avoiding useless work.

Perhaps we are talking about different kinds of laziness here. :)

>  The only kind of laziness I want
>to inhibit is the kind that causes extra work in the long run
>(e.g. unreadable code).

Yes, but I don't see, how not hitting the shift-key at the appropriate
time to generate readable code isn't laziness. Yeah, I know typos are
the usual suspects, but fixing them automatically would encourage the
coder to never use the shift key, because "the compiler fixes it
anyway". That's laziness and is contrary to my opinion that the code
has to be readable from the very first start.

Its kind of the same problem why quick fixes (aka. dirty hacks) become
standard some months later... ;)


Vinzent.

-- 
Parents strongly cautioned  --  this  posting  is  intended for mature
audiences  over  18.  It  may  contain some material that many parents
would not find suitable for children and may include intense violence,
sexual situations, coarse language and suggestive dialogue.



  parent reply	other threads:[~2003-06-04  8:39 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
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 [this message]
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