From: Jonathan Wakely Date: Sun, 15 Nov 2015 11:15:08 +0000 (+0000) Subject: PR libstdc++/68353 fix _GLIBCXX_USE_C99_WCHAR test X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=356510acd94c858b610a9cc4012880f5ba810c44;p=gcc.git PR libstdc++/68353 fix _GLIBCXX_USE_C99_WCHAR test PR libstdc++/68353 * include/bits/basic_string.h: Test value of _GLIBCXX_USE_C99_WCHAR not whether it is defined. * include/ext/vstring.h: Likewise. From-SVN: r230395 --- diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 942e418b185..fcef0355336 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,10 @@ +2015-11-15 Jonathan Wakely + + PR libstdc++/68353 + * include/bits/basic_string.h: Test value of _GLIBCXX_USE_C99_WCHAR + not whether it is defined. + * include/ext/vstring.h: Likewise. + 2015-11-14 Andreas Tobler * acinclude.m4 (GLIBCXX_ENABLE_CLOCALE): Change locale implementation diff --git a/libstdc++-v3/include/bits/basic_string.h b/libstdc++-v3/include/bits/basic_string.h index b3853cd5828..e7f965ec2f9 100644 --- a/libstdc++-v3/include/bits/basic_string.h +++ b/libstdc++-v3/include/bits/basic_string.h @@ -5503,7 +5503,7 @@ _GLIBCXX_BEGIN_NAMESPACE_CXX11 } #endif // _GLIBCXX_USE_C99_STDIO -#if defined(_GLIBCXX_USE_WCHAR_T) && defined(_GLIBCXX_USE_C99_WCHAR) +#if defined(_GLIBCXX_USE_WCHAR_T) && _GLIBCXX_USE_C99_WCHAR inline int stoi(const wstring& __str, size_t* __idx = 0, int __base = 10) { return __gnu_cxx::__stoa(&std::wcstol, "stoi", __str.c_str(), diff --git a/libstdc++-v3/include/ext/vstring.h b/libstdc++-v3/include/ext/vstring.h index 8732bd38891..529e4f3324c 100644 --- a/libstdc++-v3/include/ext/vstring.h +++ b/libstdc++-v3/include/ext/vstring.h @@ -2794,7 +2794,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION } #endif // _GLIBCXX_USE_C99_STDIO -#if defined(_GLIBCXX_USE_WCHAR_T) && defined(_GLIBCXX_USE_C99_WCHAR) +#if defined(_GLIBCXX_USE_WCHAR_T) && _GLIBCXX_USE_C99_WCHAR inline int stoi(const __wvstring& __str, std::size_t* __idx = 0, int __base = 10) { return __gnu_cxx::__stoa(&std::wcstol, "stoi", __str.c_str(),