about summary refs log tree commit diff
path: root/include/wchar.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/wchar.h')
-rw-r--r--include/wchar.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/wchar.h b/include/wchar.h
index 617906eb14..bb49d844be 100644
--- a/include/wchar.h
+++ b/include/wchar.h
@@ -1,4 +1,13 @@
 #ifndef _WCHAR_H
+
+/* Workaround PR90731 with GCC 9 when using ldbl redirects in C++.  */
+# include <bits/floatn.h>
+# if defined __cplusplus && __LONG_DOUBLE_USES_FLOAT128 == 1
+#  if __GNUC_PREREQ (9, 0) && !__GNUC_PREREQ (9, 3)
+#   pragma GCC system_header
+#  endif
+# endif
+
 # include <wcsmbs/wchar.h>
 # ifndef _ISOMAC