- From: Daniel W. Connolly <connolly@hal.com>
- Date: Wed, 13 Jul 1994 14:28:33 -0500
- To: hallam@alws.cern.ch
- Cc: Multiple recipients of list <www-lib@www0.cern.ch>, connolly@hal.com
In message <9407131917.AA22698@dxmint.cern.ch>, hallam@alws.cern.ch writes: > >>Not only should we require an ANSI C compiler for development, but we >>should write squeaky-clean ANSI C code, except for modules that need >>POSIX features, in which case we should write squeaky-clean POSIX code. > >I don't like using gcc for development for this very reason.. I get many more >error messages from the DEC-C compiler on VMS... To get gcc to act as a strictly conforming ANSI C compiler, invoke it as: gcc -ansi -pedantic-errors My personal favorite is: gcc -ansi -pedantic-errors -O -g -Wall The combination of -O and -Wall will produce some very interesting warnings: * variable used before initialized * variable not used at all * implicitly declared function (i.e. you forgot <stdio.h> or some such) * pointer abuse Dan
Received on Wednesday, 13 July 1994 21:28:32 UTC