http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46155

--- Comment #10 from joseph at codesourcery dot com <joseph at codesourcery dot 
com> 2010-10-24 17:50:44 UTC ---
On Sun, 24 Oct 2010, david.kirkby at onetel dot net wrote:

> > > I don't have a copy of the C standard. Is there one publicly available? 
> > > In your
> > > opinion, are IBM wrong to define fprnd_t in /usr/include/float.h? AIX 5.3 
> > > is a
> > > POSIX certified operating system.
> > 
> > http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1256.pdf
> 
> Thank you. Do you happen to have one for the C++ standards too? 

No.

> Solaris 10 was only introduced in 2005, so Solaris 9 is not that old. To my
> knowledge Cygwin does not support C99, though I know the GSL builds on 
> Cygwin. 

I think cygwin does have the fenv.h interfaces.

What is meant by "supporting" C99 is very complicated and it is likely to 
involve (if conscientious) complicated lists of caveats about the state of 
support of optional features, issues of interpretation of the standard, 
and what depends on different parts of the implementation (compiler, 
library, OS).  In this case you just need library interfaces that are easy 
to implement for any OS that has any of the alternative interfaces GSL 
sometimes uses.

> > It appears that GSL has code that uses the C99 interfaces (fp-gnuc99.c).  
> 
> I'm a bit puzzled by that. Perhaps it only uses that when it knows the 
> compiler
> supports C99. 

That would be very silly, given that "supports C99" is a very complicated 
matter not a binary yes/no configure test.  For use of a particular 
library feature it should test for that library feature.  Not for support 
of \uNNNNNNNN extended characters in identifiers or any other random 
compiler feature.  And there's no reason for it to compare about other 
details of compiler Annex F support any more for using the C99 interfaces 
than for any of the other interfaces it uses.

What doesn't make sense to me is that GSL has the C99 interfaces as the 
*last* of a series of alternatives, so always preferring pre-standard 
OS-specific interfaces where both are available.  The sensible thing to do 
would be to prefer standard interfaces where available.

Reply via email to