i386.c warnings cleanup

Ian Lance Taylor ian@cygnus.com
Mon Feb 9 19:49:00 GMT 1998


   Date: Tue, 10 Feb 1998 04:15:43 +0100
   From: Marc Lehmann <pcg@goof.com>

   +extern void error PVPROTO((char *s, ...));
   +extern int atoi PROTO((char *));
   +extern void bcopy PROTO((void *, void *, int n));
   +extern void set_float_handler PROTO((jmp_buf));
   +extern void free PROTO((void *));

It's safest to never declare system functions, but to instead get the
declarations from system header files.  That's because on old systems
you can't predict how the functions will be declared.  For example,
the SunOS <stdlib.h> declares free as returning int.

You should instead simply include the correct header files, and trust
them.

Ian



More information about the Gcc mailing list