Subject: Re: C vs. prototypes (was: Problems with gdb under NetBSD 1.0 )
To: None <current-users@NetBSD.org>
From: D'Arcy J.M. Cain <darcy@druid.planix.com>
List: current-users
Date: 12/17/1994 09:13:00
Greg Woods wrote:
: I personally just fall back on Pike's assertion that the lint checking
: tool should check for lint, and the compiler should compile, and never
: the two should meet.

I have never understood this.  One of the things I really like about
gcc with all the warnings on (*) is that the same tool that checks
the code compiles it with no change to the code.  By that I mean
the use of "#ifndef lint" so that lint doesn't actually see parts
of the code.  I also don't like separating the two steps in time.
I know that if my code compiles (I also use -Werror) that it has
also been checked out.

(*) My CFLAGS are similar to der Mouse:

CFLAGS = -O2 -pipe -ansi -Wall -Wshadow -Wpointer-arith -Wcast-qual \
         -Wwrite-strings -Werror -Wstrict-prototypes -Wmissing-prototypes \
         -funsigned-char -Dscanf=DONT_USE_SCANF -Dgets=DONT_USE_GETS

: And true enough, I don't want to completely disown gcc either, as
: without it (or something at least as good) we wouldn't have a portable,
: free, operating system yet.

Amen.  With it being necessary to port to different systems it sure is
nice not to have to port to different compilers as well.

-- 
D'Arcy J.M. Cain (darcy@druid.com)  |
Planix, Inc.                        |   Democracy is three wolves and a
Toronto, Ontario, Canada            |   sheep voting on what's for dinner.
+1 416 424 2871  (DoD#0082) (eNTP)  |