Mail Archives: djgpp-workers/2003/02/05/09:17:52
Hello.
Esa A E Peuha wrote:
>
> On Wed, 5 Feb 2003, Eli Zaretskii wrote:
>
> > On Tue, 4 Feb 2003, cvs-richdawe AT delorie DOT com wrote:
>
> > > + #if (defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L) \
> > > + || !defined(__STRICT_ANSI__)
> > > +
> > > + #endif /* (__STDC_VERSION__ >= 199901L) || !__STRICT_ANSI__ */
>
> > Richard, did you try to see whether an old GCC version swallows this
> > successfully? Like compile a program with GCC 2.7.2.x or 2.8? If not,
> > could someone please try that?
>
> I don't see how that would be a problem, but won't this pollute POSIX
> namespace? The older POSIX standard includes all ANSI C89 functions,
> but not all C99 functions (if any; I haven't checked).
Yes, that's true.
> So that #if should also check for strict POSIX compliance, and if it's
> required, what version of POSIX is requested (presumably the newer POSIX
> includes all ANSI C99 functions).
A draft of new POSIX appears to include all the new ANSI C99 things.
> If there are any functions that are both C99 and older POSIX, they need
> yet another section with its own test.
Yes.
I don't have a copy of old POSIX. I have a draft copy of new POSIX. How I can
tell the POSIX standard version? I'm primarily interested in old POSIX here,
since I don't have that. But if anyone has new POSIX, then that would be good
to know too. It looks like it's controlled by _POSIX_C_SOURCE, which obsoletes
_POSIX_SOURCE.
Bye, Rich =]
--
Richard Dawe [ http://www.phekda.freeserve.co.uk/richdawe/ ]
- Raw text -