[Bug libstdc++/11196] parse error before numeric constant <M_PI is defined in C++>
gcc-bugzilla at contacts dot eelis dot net
gcc-bugzilla@gcc.gnu.org
Tue Nov 13 18:42:00 GMT 2007
------- Comment #7 from gcc-bugzilla at contacts dot eelis dot net 2007-11-13 18:42 -------
(In reply to comment #6)
> The bug is that the C++ front end implicitly #defines _GNU_SOURCE.
> [..]
> Could some libstdc++ guru explain why this define is actually needed?
I am no libstdc++ guru, but this:
echo "#include <cstdlib>" | g++ -x c++ -U _GNU_SOURCE -c -
produces:
/usr/include/c++/4.1.2/cstdlib:162: error: âÂÂ::lldiv_tâ has not been
declared
/usr/include/c++/4.1.2/cstdlib:168: error: âÂÂ::_Exitâ has not been
declared
/usr/include/c++/4.1.2/cstdlib:175: error: âÂÂ::llabsâ has not been
declared
/usr/include/c++/4.1.2/cstdlib:177: error: âÂÂlldiv_tâ does not name a type
/usr/include/c++/4.1.2/cstdlib:181: error: âÂÂ::lldivâ has not been
declared
/usr/include/c++/4.1.2/cstdlib:196: error: âÂÂ::strtofâ has not been
declared
/usr/include/c++/4.1.2/cstdlib:197: error: âÂÂ::strtoldâ has not been
declared
/usr/include/c++/4.1.2/cstdlib:203: error: âÂÂ__gnu_cxx::lldiv_tâ has not
been declared
/usr/include/c++/4.1.2/cstdlib:205: error: âÂÂ__gnu_cxx::_Exitâ has not
been declared
/usr/include/c++/4.1.2/cstdlib:208: error: âÂÂ__gnu_cxx::llabsâ has not
been declared
/usr/include/c++/4.1.2/cstdlib:209: error: âÂÂ__gnu_cxx::divâ has not been
declared
/usr/include/c++/4.1.2/cstdlib:210: error: âÂÂ__gnu_cxx::lldivâ has not
been declared
/usr/include/c++/4.1.2/cstdlib:213: error: âÂÂ__gnu_cxx::strtofâ has not
been declared
/usr/include/c++/4.1.2/cstdlib:216: error: âÂÂ__gnu_cxx::strtoldâ has not
been declared
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11196
More information about the Gcc-bugs
mailing list