aboutsummaryrefslogtreecommitdiff
path: root/libstdc++-v3/config.h.in
diff options
context:
space:
mode:
authorJonathan Wakely <jwakely@redhat.com>2023-05-12 21:36:56 +0100
committerJonathan Wakely <jwakely@redhat.com>2023-05-16 09:59:19 +0100
commitac3a5bbc62949aeb061c01360632b3b8f5fafefa (patch)
tree79e07080c84be7208a0edd49e7e04c4361a5299f /libstdc++-v3/config.h.in
parent5baabdb15d0ee24da414f273a5bafd5eca262ede (diff)
downloadgcc-ac3a5bbc62949aeb061c01360632b3b8f5fafefa.zip
gcc-ac3a5bbc62949aeb061c01360632b3b8f5fafefa.tar.gz
gcc-ac3a5bbc62949aeb061c01360632b3b8f5fafefa.tar.bz2
libstdc++: Stop using TR1 macros in <cctype> and <cfenv>
As with the two commits before this, the _GLIBCXX_USE_C99_CTYPE_TR1 and _GLIBCXX_USE_C99_FENV_TR1 macros are misleading when they are also used for <cctype> and <cfenv>, not only for TR1 headers. It is also wrong, because the configure checks for TR1 use -std=c++98 and a target might define the C99 features for C++11 but not for C++98. Add separate configure checks for the <ctype.h> and <fenv.h> features using -std=c++11 for the checks. Use the new macros defined by those checks in the C++11-specific parts of <cctype>, <cfenv>, and <fenv.h>. libstdc++-v3/ChangeLog: * acinclude.m4 (GLIBCXX_USE_C99): Check for isblank in C++11 mode and define _GLIBCXX_USE_C99_CTYPE. Check for <fenv.h> functions in C++11 mode and define _GLIBCXX_USE_C99_FENV. * config.h.in: Regenerate. * configure: Regenerate. * include/c_compatibility/fenv.h: Check _GLIBCXX_USE_C99_FENV instead of _GLIBCXX_USE_C99_FENV_TR1. * include/c_global/cfenv: Likewise. * include/c_global/cctype: Check _GLIBCXX_USE_C99_CTYPE instead of _GLIBCXX_USE_C99_CTYPE_TR1.
Diffstat (limited to 'libstdc++-v3/config.h.in')
-rw-r--r--libstdc++-v3/config.h.in8
1 files changed, 8 insertions, 0 deletions
diff --git a/libstdc++-v3/config.h.in b/libstdc++-v3/config.h.in
index 62be4c7..f91f7eb 100644
--- a/libstdc++-v3/config.h.in
+++ b/libstdc++-v3/config.h.in
@@ -902,10 +902,18 @@
library functions to be present. */
#undef _GLIBCXX_USE_C99_COMPLEX_TR1
+/* Define if C99 functions in <ctype.h> should be imported in <cctype> in
+ namespace std for C++11. */
+#undef _GLIBCXX_USE_C99_CTYPE
+
/* Define if C99 functions in <ctype.h> should be imported in <tr1/cctype> in
namespace std::tr1. */
#undef _GLIBCXX_USE_C99_CTYPE_TR1
+/* Define if C99 functions in <fenv.h> should be imported in <cfenv> in
+ namespace std for C++11. */
+#undef _GLIBCXX_USE_C99_FENV
+
/* Define if C99 functions in <fenv.h> should be imported in <tr1/cfenv> in
namespace std::tr1. */
#undef _GLIBCXX_USE_C99_FENV_TR1