Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-3]: src/gnu/dist/gcc/libstdc++-v3 Pull up revision 1.2 (requested...
details: https://anonhg.NetBSD.org/src/rev/ff3faf46fccd
branches: netbsd-3
changeset: 575097:ff3faf46fccd
user: tron <tron%NetBSD.org@localhost>
date: Mon Apr 04 18:15:17 2005 +0000
description:
Pull up revision 1.2 (requested by christos in ticket #102):
PR/29832: J.T. Conklin: libstdc++ missing std::wstring support
This wonderful patch together with yesterdays wcsftime addition, makes
us able to use wide strings in c++
diffstat:
gnu/dist/gcc/libstdc++-v3/acinclude.m4 | 18 +++-
gnu/dist/gcc/libstdc++-v3/include/c_std/std_cwchar.h | 78 ++++++++++++++++---
2 files changed, 77 insertions(+), 19 deletions(-)
diffs (181 lines):
diff -r 2ee2e5f7fe1d -r ff3faf46fccd gnu/dist/gcc/libstdc++-v3/acinclude.m4
--- a/gnu/dist/gcc/libstdc++-v3/acinclude.m4 Mon Apr 04 18:11:22 2005 +0000
+++ b/gnu/dist/gcc/libstdc++-v3/acinclude.m4 Mon Apr 04 18:15:17 2005 +0000
@@ -987,13 +987,19 @@
ac_wfuncs=no)
dnl Checks for names injected into std:: by the c_std headers.
- AC_CHECK_FUNCS(btowc wctob fgetwc fgetws fputwc fputws fwide \
- fwprintf fwscanf swprintf swscanf vfwprintf vfwscanf vswprintf vswscanf \
- vwprintf vwscanf wprintf wscanf getwc getwchar mbsinit mbrlen mbrtowc \
- mbsrtowcs wcsrtombs putwc putwchar ungetwc wcrtomb wcstod wcstof wcstol \
+ AC_CHECK_FUNCS([btowc wctob fgetwc fgetws fputwc fputws fwide \
+ getwc getwchar mbsinit mbrlen mbrtowc \
+ mbsrtowcs wcsrtombs putwc putwchar ungetwc wcrtomb wcstod wcstol \
wcstoul wcscpy wcsncpy wcscat wcsncat wcscmp wcscoll wcsncmp wcsxfrm \
- wcscspn wcsspn wcstok wcsftime wcschr wcspbrk wcsrchr wcsstr,, \
- ac_wfuncs=no)
+ wcscspn wcsspn wcstok wcsftime wcschr wcspbrk wcsrchr wcsstr,
+ [],[ac_wfuncs=no])
+
+ dnl Checks for wide character functions that are not required
+ dnl for basic wchar_t support. Don't disable support if they are missing.
+ dnl Injection of these is wrapped with guard macros.
+ AC_CHECK_FUNCS([fwprintf fwscanf swprintf swscanf vfwprintf vfwscanf \
+ vswprintf vswscanf vwprintf vwscanf wcstof wprintf wscanf \
+ iswblank],[],[])
AC_MSG_CHECKING([for ISO C99 wchar_t support])
if test x"$has_weof" = xyes &&
diff -r 2ee2e5f7fe1d -r ff3faf46fccd gnu/dist/gcc/libstdc++-v3/include/c_std/std_cwchar.h
--- a/gnu/dist/gcc/libstdc++-v3/include/c_std/std_cwchar.h Mon Apr 04 18:11:22 2005 +0000
+++ b/gnu/dist/gcc/libstdc++-v3/include/c_std/std_cwchar.h Mon Apr 04 18:15:17 2005 +0000
@@ -78,8 +78,12 @@
#undef fputwc
#undef fputws
#undef fwide
-#undef fwprintf
-#undef fwscanf
+#if _GLIBCXX_HAVE_FWPRINTF
+# undef fwprintf
+#endif
+#if _GLIBCXX_HAVE_FWSCANF
+# undef fwscanf
+#endif
#undef getwc
#undef getwchar
#undef mbrlen
@@ -88,15 +92,31 @@
#undef mbsrtowcs
#undef putwc
#undef putwchar
-#undef swprintf
-#undef swscanf
+#if _GLIBCXX_HAVE_SWPRINTF
+# undef swprintf
+#endif
+#if _GLIBCXX_HAVE_SWSCANF
+# undef swscanf
+#endif
#undef ungetwc
-#undef vfwprintf
-#undef vfwscanf
-#undef vswprintf
-#undef vswscanf
-#undef vwprintf
-#undef vwscanf
+#if _GLIBCXX_HAVE_VFWPRINTF
+# undef vfwprintf
+#endif
+#if _GLIBCXX_HAVE_VFWSCANF
+# undef vfwscanf
+#endif
+#if _GLIBCXX_HAVE_VSWPRINTF
+# undef vswprintf
+#endif
+#if _GLIBCXX_HAVE_VSWSCANF
+# undef vswscanf
+#endif
+#if _GLIBCXX_HAVE_VWPRINTF
+# undef vwprintf
+#endif
+#if _GLIBCXX_HAVE_VWSCANF
+# undef vwscanf
+#endif
#undef wcrtomb
#undef wcscat
#undef wcschr
@@ -115,7 +135,9 @@
#undef wcsspn
#undef wcsstr
#undef wcstod
-#undef wcstof
+#if _GLIBCXX_HAVE_WCSTOF
+# undef wcstof
+#endif
#undef wcstok
#undef wcstol
#undef wcstoul
@@ -126,8 +148,12 @@
#undef wmemcpy
#undef wmemmove
#undef wmemset
-#undef wprintf
-#undef wscanf
+#if _GLIBCXX_HAVE_WPRINTF
+# undef wprintf
+#endif
+#if _GLIBCXX_HAVE_WSCANF
+# undef wscanf
+#endif
#if _GLIBCPP_USE_WCHAR_T
namespace std
@@ -140,8 +166,12 @@
using ::fputwc;
using ::fputws;
using ::fwide;
+#if _GLIBCXX_HAVE_FWPRINTF
using ::fwprintf;
+#endif
+#if _GLIBCXX_HAVE_FWSCANF
using ::fwscanf;
+#endif
using ::getwc;
using ::getwchar;
using ::mbrlen;
@@ -150,15 +180,31 @@
using ::mbsrtowcs;
using ::putwc;
using ::putwchar;
+#if _GLIBCXX_HAVE_SWPRINTF
using ::swprintf;
+#endif
+#if _GLIBCXX_HAVE_SWSCANF
using ::swscanf;
+#endif
using ::ungetwc;
+#if _GLIBCXX_HAVE_VFWPRINTF
using ::vfwprintf;
+#endif
+#if _GLIBCXX_HAVE_VWSCANF
using ::vfwscanf;
+#endif
+#if _GLIBCXX_HAVE_VSWPRINTF
using ::vswprintf;
+#endif
+#if _GLIBCXX_HAVE_VSWSCANF
using ::vswscanf;
+#endif
+#if _GLIBCXX_HAVE_VWPRINTF
using ::vwprintf;
+#endif
+#if _GLIBCXX_HAVE_VWSCANF
using ::vwscanf;
+#endif
using ::wcrtomb;
using ::wcscat;
using ::wcscmp;
@@ -173,7 +219,9 @@
using ::wcsrtombs;
using ::wcsspn;
using ::wcstod;
+#if _GLIBCXX_HAVE_WCSTOF
using ::wcstof;
+#endif
using ::wcstok;
using ::wcstol;
using ::wcstoul;
@@ -183,8 +231,12 @@
using ::wmemcpy;
using ::wmemmove;
using ::wmemset;
+#if _GLIBCXX_HAVE_WPRINTF
using ::wprintf;
+#endif
+#if _GLIBCXX_HAVE_WSCANF
using ::wscanf;
+#endif
using ::wcschr;
Home |
Main Index |
Thread Index |
Old Index