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: GCC headers and DJGPP port


> From: Geoff Keating <geoffk@cygnus.com>
> Date: 21 Jul 2000 11:33:58 -0700
> 
> Note that:
> - size_t is defined by stdio.h and stddef.h and string.h and wchar.h;
> - NULL is defined by stdio.h and stddef.h and string.h and time.h and wchar.h;
> - wchar_t is defined by stdlib.h and stddef.h and wchar.h;
> 
> so you already have to test if NULL is defined before defining it.

Not if every definition of NULL says the same.  This is allowed by
ANSI/ISO C (AFAIK), and GCC quite rightfully doesn't print any warnings.

As for size_t and wchar_t, we have a private header that defines them,
which is included by all the headers that need those types.  There are
safeguards to prevent multiple typedefs.

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