diff options
author | Paolo Carlini <paolo.carlini@oracle.com> | 2010-06-08 01:46:10 +0000 |
---|---|---|
committer | Paolo Carlini <paolo@gcc.gnu.org> | 2010-06-08 01:46:10 +0000 |
commit | c8061de73f1ec2db31588f1c20693d570d576a20 (patch) | |
tree | ef9373142d6e954982f2fd1f84a6ac933ffe2d79 /libstdc++-v3/include | |
parent | 567d4027a3ca0dc36fd0d828925a34a237ad62db (diff) | |
download | gcc-c8061de73f1ec2db31588f1c20693d570d576a20.tar.gz |
re PR libstdc++/44417 (make check-target-libstdc++-v3 fails due to undefined ptrdiff_t)
2010-06-07 Paolo Carlini <paolo.carlini@oracle.com>
PR libstdc++/44417
* include/c_std/cwctype: Provide a workaround for bug glibc
BZ 9694 affecting glibc 2.9 and older.
* include/c_global/cwctype: Likewise.
* testsuite/util/testsuite_abi.h: Remove temporary workaround.
* testsuite/util/testsuite_allocator.h: Use everywhere std::size_t
and std::ptrdiff_t, don't include <cstddef>.
* testsuite/27_io/basic_ostream/inserters_other/wchar_t/
error_code.cc: Minor tweak, prefer <cwchar> to <wchar.h>.
From-SVN: r160417
Diffstat (limited to 'libstdc++-v3/include')
-rw-r--r-- | libstdc++-v3/include/c_global/cwctype | 8 | ||||
-rw-r--r-- | libstdc++-v3/include/c_std/cwctype | 8 |
2 files changed, 14 insertions, 2 deletions
diff --git a/libstdc++-v3/include/c_global/cwctype b/libstdc++-v3/include/c_global/cwctype index be649a28950..2ac1155aa9b 100644 --- a/libstdc++-v3/include/c_global/cwctype +++ b/libstdc++-v3/include/c_global/cwctype @@ -43,9 +43,15 @@ #include <bits/c++config.h> #if _GLIBCXX_HAVE_WCTYPE_H -#include <wctype.h> + +#if __GLIBC__ == 2 && __GLIBC_MINOR__ < 10 +// Work around glibc BZ 9694 +#include <stddef.h> #endif +#include <wctype.h> +#endif // _GLIBCXX_HAVE_WCTYPE_H + #ifndef _GLIBCXX_CWCTYPE #define _GLIBCXX_CWCTYPE 1 diff --git a/libstdc++-v3/include/c_std/cwctype b/libstdc++-v3/include/c_std/cwctype index 4af425067b9..d6750390a0a 100644 --- a/libstdc++-v3/include/c_std/cwctype +++ b/libstdc++-v3/include/c_std/cwctype @@ -45,9 +45,15 @@ #include <bits/c++config.h> #if _GLIBCXX_HAVE_WCTYPE_H -#include <wctype.h> + +#if __GLIBC__ == 2 && __GLIBC_MINOR__ < 10 +// Work around glibc BZ 9694 +#include <stddef.h> #endif +#include <wctype.h> +#endif // _GLIBCXX_HAVE_WCTYPE_H + // Get rid of those macros defined in <wctype.h> in lieu of real functions. #undef iswalnum #undef iswalpha |