https://gcc.gnu.org/bugzilla/show_bug.cgi?id=24012

--- Comment #22 from Jonathan Wakely <redi at gcc dot gnu.org> ---
(In reply to Jonathan Wakely from comment #20)
> Also, I assume this is only a problem for -std=c++98 or -std=gnu++98,
> because if the system headers don't declare those functions for C++11 and
> later dialects then that's a bug in those system headers.

That's not true, because we (rather bizarrely) do this:

#if _GLIBCXX_HAVE_WCSTOF
#undef wcstof
#endif

namespace std {
#if _GLIBCXX_HAVE_WCSTOF
using ::wcstof
#endif
}

#if __cplusplus >= 201103L
namespace std {
#if _GLIBCXX_HAVE_WCSTOF
using std::wcstof
#endif
}
#endif

This means we unconditionally try to declare them in namespace std, then for
C++11 redeclare std::wcstof as std:wcstof (???).

Reply via email to