Mail Archives: djgpp-workers/2003/02/10/13:52:33
Hello.
DJ Delorie wrote:
>
> > "__extension__" is just a way of ignoring errors when -pedantic is used.
> >
> > I don't know why we use "__extension__" in <stdint.h>.
>
> So that when users compile their applications with -pedantic, we don't
> cause errors. We have to be very careful about stuff like this in the
> headers, but not in the library sources (since we control the compile
> flags for those).
>
> Headers must work correctly for any set of compile flags.
<Lightbulb above head> Ah, I think I see now. If we support a 64-bit type,
i.e.: long long, then we must define the *int64_*t types in <stdint.h>. But
C89 has no "long long" type, hence -pedantic would cause gcc in C89 mode to
barf if there was no "__extension__".
Bye, Rich =]
--
Richard Dawe [ http://www.phekda.freeserve.co.uk/richdawe/ ]
- Raw text -