[Bug libstdc++/1773] __cplusplus defined to 1, should be 199711L

marc.glisse at normalesup dot org gcc-bugzilla@gcc.gnu.org
Sat Jul 30 21:03:00 GMT 2011


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

--- Comment #91 from Marc Glisse <marc.glisse at normalesup dot org> 2011-07-30 21:02:20 UTC ---
solaris also provides the pow(*,int) overloads (see DR550). Should these be
fixincluded out? On the other hand, solaris doesn't provide the cos(int)
overload, so cos(0) fails as ambiguous (like with sunpro) if one includes
math.h and not cmath. Should this be ignored? or the integral overload
fixincluded into math.h? or an extra math.h shipped that is equivalent to cmath
(careful to use #include_next)?

In any case, as already mentioned, we'll have trouble with different versions
of solaris providing different things in their headers. The solution of having
__cplusplus as 199711L except for system headers where it is 1 seems easier.



More information about the Gcc-bugs mailing list