This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: i386.c warnings cleanup


   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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]