]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
libstdc++: add #pragma diagnostic
authorJason Merrill <jason@redhat.com>
Fri, 22 Dec 2023 18:20:35 +0000 (13:20 -0500)
committerJason Merrill <jason@redhat.com>
Thu, 19 Sep 2024 14:23:16 +0000 (10:23 -0400)
The use of #pragma GCC system_header in libstdc++ has led to bugs going
undetected for a while due to the silencing of compiler warnings that would
have revealed them promptly, and also interferes with warnings about
problematic template instantiations induced by user code.

But removing it, or even compiling with -Wsystem-header, is also problematic
due to warnings about deliberate uses of extensions.

So this patch adds #pragma GCC diagnostic as needed to suppress these
warnings.

The change to acinclude.m4 changes -Wabi to warn only in comparison to ABI
19, to avoid lots of warnings that we now mangle concept requirements, which
are in any case still experimental.  I checked for any other changes against
ABI v15, and found only the <format> lambda mangling, which we can ignore.

This also enables -Wsystem-headers while building the library, so we see any
warnings not silenced by these #pragmas.

libstdc++-v3/ChangeLog:

* include/bits/algorithmfwd.h:
* include/bits/allocator.h:
* include/bits/codecvt.h:
* include/bits/concept_check.h:
* include/bits/cpp_type_traits.h:
* include/bits/hashtable.h:
* include/bits/iterator_concepts.h:
* include/bits/ostream_insert.h:
* include/bits/ranges_base.h:
* include/bits/regex_automaton.h:
* include/bits/std_abs.h:
* include/bits/stl_algo.h:
* include/c_compatibility/fenv.h:
* include/c_compatibility/inttypes.h:
* include/c_compatibility/stdint.h:
* include/ext/concurrence.h:
* include/ext/type_traits.h:
* testsuite/ext/type_traits/add_unsigned_floating_neg.cc:
* testsuite/ext/type_traits/add_unsigned_integer_neg.cc:
* testsuite/ext/type_traits/remove_unsigned_floating_neg.cc:
* testsuite/ext/type_traits/remove_unsigned_integer_neg.cc:
* include/bits/basic_ios.tcc:
* include/bits/basic_string.tcc:
* include/bits/fstream.tcc:
* include/bits/istream.tcc:
* include/bits/locale_classes.tcc:
* include/bits/locale_facets.tcc:
* include/bits/ostream.tcc:
* include/bits/regex_compiler.tcc:
* include/bits/sstream.tcc:
* include/bits/streambuf.tcc:
* configure: Regenerate.
* include/bits/c++config:
* include/c/cassert:
* include/c/cctype:
* include/c/cerrno:
* include/c/cfloat:
* include/c/climits:
* include/c/clocale:
* include/c/cmath:
* include/c/csetjmp:
* include/c/csignal:
* include/c/cstdarg:
* include/c/cstddef:
* include/c/cstdio:
* include/c/cstdlib:
* include/c/cstring:
* include/c/ctime:
* include/c/cwchar:
* include/c/cwctype:
* include/c_global/climits:
* include/c_global/cmath:
* include/c_global/cstddef:
* include/c_global/cstdlib:
* include/decimal/decimal:
* include/ext/rope:
* include/std/any:
* include/std/charconv:
* include/std/complex:
* include/std/coroutine:
* include/std/format:
* include/std/iomanip:
* include/std/limits:
* include/std/numbers:
* include/tr1/functional:
* include/tr1/tuple:
* include/tr1/type_traits:
* libsupc++/compare:
* libsupc++/new: Add #pragma GCC diagnostic to suppress
undesired warnings.
* acinclude.m4: Change -Wabi version from 2 to 19.

gcc/ChangeLog:

* ginclude/stdint-wrap.h: Add #pragma GCC diagnostic to suppress
undesired warnings.
* gsyslimits.h: Likewise.

72 files changed:
gcc/ginclude/stdint-wrap.h
gcc/gsyslimits.h
libstdc++-v3/acinclude.m4
libstdc++-v3/configure
libstdc++-v3/include/bits/algorithmfwd.h
libstdc++-v3/include/bits/allocator.h
libstdc++-v3/include/bits/basic_ios.tcc
libstdc++-v3/include/bits/basic_string.tcc
libstdc++-v3/include/bits/c++config
libstdc++-v3/include/bits/codecvt.h
libstdc++-v3/include/bits/concept_check.h
libstdc++-v3/include/bits/cpp_type_traits.h
libstdc++-v3/include/bits/fstream.tcc
libstdc++-v3/include/bits/hashtable.h
libstdc++-v3/include/bits/istream.tcc
libstdc++-v3/include/bits/iterator_concepts.h
libstdc++-v3/include/bits/locale_classes.tcc
libstdc++-v3/include/bits/locale_facets.tcc
libstdc++-v3/include/bits/ostream.tcc
libstdc++-v3/include/bits/ostream_insert.h
libstdc++-v3/include/bits/ranges_base.h
libstdc++-v3/include/bits/regex_automaton.h
libstdc++-v3/include/bits/regex_compiler.tcc
libstdc++-v3/include/bits/sstream.tcc
libstdc++-v3/include/bits/std_abs.h
libstdc++-v3/include/bits/stl_algo.h
libstdc++-v3/include/bits/streambuf.tcc
libstdc++-v3/include/c/cassert
libstdc++-v3/include/c/cctype
libstdc++-v3/include/c/cerrno
libstdc++-v3/include/c/cfloat
libstdc++-v3/include/c/climits
libstdc++-v3/include/c/clocale
libstdc++-v3/include/c/cmath
libstdc++-v3/include/c/csetjmp
libstdc++-v3/include/c/csignal
libstdc++-v3/include/c/cstdarg
libstdc++-v3/include/c/cstddef
libstdc++-v3/include/c/cstdio
libstdc++-v3/include/c/cstdlib
libstdc++-v3/include/c/cstring
libstdc++-v3/include/c/ctime
libstdc++-v3/include/c/cwchar
libstdc++-v3/include/c/cwctype
libstdc++-v3/include/c_compatibility/fenv.h
libstdc++-v3/include/c_compatibility/inttypes.h
libstdc++-v3/include/c_compatibility/stdint.h
libstdc++-v3/include/c_global/climits
libstdc++-v3/include/c_global/cmath
libstdc++-v3/include/c_global/cstddef
libstdc++-v3/include/c_global/cstdlib
libstdc++-v3/include/decimal/decimal
libstdc++-v3/include/ext/concurrence.h
libstdc++-v3/include/ext/rope
libstdc++-v3/include/ext/type_traits.h
libstdc++-v3/include/std/any
libstdc++-v3/include/std/charconv
libstdc++-v3/include/std/complex
libstdc++-v3/include/std/coroutine
libstdc++-v3/include/std/format
libstdc++-v3/include/std/iomanip
libstdc++-v3/include/std/limits
libstdc++-v3/include/std/numbers
libstdc++-v3/include/tr1/functional
libstdc++-v3/include/tr1/tuple
libstdc++-v3/include/tr1/type_traits
libstdc++-v3/libsupc++/compare
libstdc++-v3/libsupc++/new
libstdc++-v3/testsuite/ext/type_traits/add_unsigned_floating_neg.cc
libstdc++-v3/testsuite/ext/type_traits/add_unsigned_integer_neg.cc
libstdc++-v3/testsuite/ext/type_traits/remove_unsigned_floating_neg.cc
libstdc++-v3/testsuite/ext/type_traits/remove_unsigned_integer_neg.cc

index 83b6f70c83795dca60b1a6355fbc643af81637d1..9d8eb5f786af4d61f1a04a07f9c21fd86f29f137 100644 (file)
@@ -6,7 +6,10 @@
 #  undef __STDC_CONSTANT_MACROS
 #  define __STDC_CONSTANT_MACROS
 # endif
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
 # include_next <stdint.h>
+#pragma GCC diagnostic pop
 #else
 # include "stdint-gcc.h"
 #endif
index a3628025e8a16ffb6670225cf696f0e956f2fab4..82c82e91cde290e23de9ba18130b0f5d44edafba 100644 (file)
@@ -4,5 +4,8 @@
    instead of this text.  */
 
 #define _GCC_NEXT_LIMITS_H             /* tell gcc's limits.h to recurse */
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
 #include_next <limits.h>
+#pragma GCC diagnostic pop
 #undef _GCC_NEXT_LIMITS_H
index e4ed583b3ae3ac5581ee60d0de905ba7b45352a4..768c2991ec29f667cf620996f40217978e2598aa 100644 (file)
@@ -707,7 +707,7 @@ AC_DEFUN([GLIBCXX_EXPORT_FLAGS], [
   # OPTIMIZE_CXXFLAGS = -O3 -fstrict-aliasing -fvtable-gc
   AC_SUBST(OPTIMIZE_CXXFLAGS)
 
-  WARN_FLAGS="-Wall -Wextra -Wwrite-strings -Wcast-qual -Wabi=2"
+  WARN_FLAGS="-Wall -Wextra -Wwrite-strings -Wcast-qual -Wabi=19 -Wsystem-headers"
   AC_SUBST(WARN_FLAGS)
 ])
 
index 005c4a29fd099f3d05edeb9af5e05d69e9036e4d..de05e63de4c5b642dc7eed402f8590420d64cc84 100755 (executable)
@@ -55720,7 +55720,7 @@ $as_echo "$gxx_include_dir" >&6; }
   # OPTIMIZE_CXXFLAGS = -O3 -fstrict-aliasing -fvtable-gc
 
 
-  WARN_FLAGS="-Wall -Wextra -Wwrite-strings -Wcast-qual -Wabi=2"
+  WARN_FLAGS="-Wall -Wextra -Wwrite-strings -Wcast-qual -Wabi=19 -Wsystem-headers"
 
 
 
index 34bf9921f435480805a8ddefb899790466e48bd9..7f1f15970abec1968362026bd0016124824ff4fb 100644 (file)
@@ -39,6 +39,9 @@
 #include <initializer_list>
 #endif
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions"
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -962,6 +965,8 @@ _GLIBCXX_END_NAMESPACE_ALGO
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
+
 #ifdef _GLIBCXX_PARALLEL
 # include <parallel/algorithmfwd.h>
 #endif
index 9e75b37fce7f96be9b148896c1a425334189df40..ebb487a3ffeb2a8f820cd6488f06389400b1873d 100644 (file)
@@ -49,6 +49,9 @@
 #include <type_traits>
 #endif
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions"
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -292,4 +295,5 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
 #endif
index 0197bdf8f6712a59809581e7a527250187890391..1519603f6b5c62bdc52ab87e1703205cd9bed707 100644 (file)
@@ -32,6 +32,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions" // extern template
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -181,4 +184,5 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
 #endif
index e458c1880b2e8aef24ef1445eb81091c67122df0..8a764855698d0223c06e2d9f438d48499c59184a 100644 (file)
@@ -41,6 +41,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions"
+
 #include <bits/cxxabi_forced.h>
 
 namespace std _GLIBCXX_VISIBILITY(default)
@@ -1031,4 +1034,5 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
 #endif
index 54d455be2266a87b2c54684baba952bda4afa6e3..66d03cfd037520fa4929fd57d7d4bf916282f2bd 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wvariadic-macros"
+#pragma GCC diagnostic ignored "-Wc++11-extensions"
+#pragma GCC diagnostic ignored "-Wc++23-extensions" // bf16
+
 // The major release number for the GCC release the C++ library belongs to.
 #define _GLIBCXX_RELEASE
 
@@ -910,4 +915,6 @@ namespace __gnu_cxx
 #endif // __has_include
 #endif // C++17
 
+#pragma GCC diagnostic pop
+
 // End of prewritten config; the settings discovered at configure time follow.
index 41a1d30b11d8758e4c6b8c79ca3cbe4ea7a18ff0..c51cc7d220d3aa5b7f41252098af0b84cae52668 100644 (file)
@@ -41,6 +41,9 @@
 #include <bits/c++config.h>
 #include <bits/locale_classes.h> // locale::facet
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions" // extern template
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -840,4 +843,5 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
 #endif // _CODECVT_H
index 65f662b70bf8e7e2b58af9a88dd18bd81be03c41..6479f2fa919e2a82c420fe6ebd3c52b76b5143b9 100644 (file)
@@ -34,6 +34,9 @@
 
 #include <bits/c++config.h>
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wvariadic-macros"
+
 // All places in libstdc++-v3 where these are used, or /might/ be used, or
 // don't need to be used, or perhaps /should/ be used, are commented with
 // "concept requirements" (and maybe some more text).  So grep like crazy
@@ -78,4 +81,5 @@
 
 #endif // enable/disable
 
+#pragma GCC diagnostic pop
 #endif // _GLIBCXX_CONCEPT_CHECK
index ff74c557245831a75ed32d71d7c680e48da704f9..e3a80e06346efb2d77ddfe9db52894bc48688377 100644 (file)
@@ -40,6 +40,9 @@
 # include <type_traits> // is_same_v, is_integral_v
 #endif
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wlong-long"
+
 //
 // This file provides some compile-time information about various types.
 // These representations were designed, on purpose, to be constant-expressions
@@ -582,4 +585,6 @@ _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace
 } // extern "C++"
 
+#pragma GCC diagnostic pop
+
 #endif //_CPP_TYPE_TRAITS_H
index a5accecd8465ebb294d39c4ece171dcbbebbeff1..7b246ad59d2c44752483cab80b5bc8e76f0a5e58 100644 (file)
@@ -36,6 +36,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions" // extern template
+
 #include <bits/cxxabi_forced.h>
 #include <bits/move.h>   // for swap
 #include <cerrno>
@@ -1094,4 +1097,5 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
 #endif
index 361da2b3b4d4105902875cda85ee35032bd22e6f..b02bddf5635b67f59a6322227fd883408c42d91e 100644 (file)
@@ -40,6 +40,9 @@
 # include <bits/node_handle.h>
 #endif
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions"
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -2758,4 +2761,6 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
+
 #endif // _HASHTABLE_H
index 16423bfbfcb1cdd2fe8362263e536816cec108cb..23a7c84977790b77e2c32ba277139aad74137572 100644 (file)
@@ -36,6 +36,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions" // extern template
+
 #include <bits/cxxabi_forced.h>
 
 namespace std _GLIBCXX_VISIBILITY(default)
@@ -1166,4 +1169,5 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
 #endif
index 642c709fee0c28754c1942395a822720d58312ac..4ac6e6bfbe7a300ea0dd26fd98192171577d9563 100644 (file)
@@ -37,6 +37,9 @@
 #include <bits/ptr_traits.h>   // to_address
 #include <bits/ranges_cmp.h>   // identity, ranges::less
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // __int128
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -1044,5 +1047,6 @@ namespace ranges
 #endif // C++20 library concepts
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
+#pragma GCC diagnostic pop
 #endif // C++20
 #endif // _ITERATOR_CONCEPTS_H
index 1b5f5f2417c83dc5a009c0bfe6a8899ea06b061f..4f3af2461a5d1698d237e13f4a603ed5f3ff3fec 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions" // extern template
+#pragma GCC diagnostic ignored "-Wvariadic-macros"
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -384,4 +388,5 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
 #endif
index cde81bffc08e37697c5b60ed10aa4c1ce1056131..4e9bf6fb8f94c9d502c8ccc8587b6f28915f8ae4 100644 (file)
@@ -32,6 +32,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions" // extern template
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -1433,4 +1436,5 @@ _GLIBCXX_END_NAMESPACE_LDBL
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace
 
+#pragma GCC diagnostic pop
 #endif
index 972de79ea7008ac3f3c5ff14e5fcab2c1468904a..7aeb23ad38d1e39a94a3c60ff2f3519d1d23afec 100644 (file)
@@ -36,6 +36,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions" // extern template
+
 #include <bits/cxxabi_forced.h>
 
 namespace std _GLIBCXX_VISIBILITY(default)
@@ -390,4 +393,5 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
 #endif
index e6857615790a3ed73d863f4da537e8943d79e6ca..d61b4b14f97a21b4be1390a1bfa53bfcab39a0e3 100644 (file)
@@ -36,6 +36,9 @@
 #include <bits/cxxabi_forced.h>
 #include <bits/exception_defines.h>
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions" // extern template
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -131,4 +134,5 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
 #endif /* _OSTREAM_INSERT_H */
index 63eb552b48bb3043fc8c390a5b4a27399edddb9b..0c6a4e83bb246016570e9e654f143809d4a099ec 100644 (file)
@@ -39,6 +39,9 @@
 #include <bits/max_size_type.h>
 #include <bits/version.h>
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // __int128
+
 #ifdef __cpp_lib_concepts
 namespace std _GLIBCXX_VISIBILITY(default)
 {
@@ -1073,5 +1076,6 @@ namespace ranges
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 #endif // library concepts
+#pragma GCC diagnostic pop
 #endif // C++20
 #endif // _GLIBCXX_RANGES_BASE_H
index 574ec90dc3a10d367d97f12374db676a41599a74..03179a0e68763b0f98a74e5bc145b2f6d355139e 100644 (file)
@@ -33,6 +33,9 @@
 #define _GLIBCXX_REGEX_STATE_LIMIT 100000
 #endif
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // anon struct
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -397,4 +400,6 @@ namespace __detail
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
+
 #include <bits/regex_automaton.tcc>
index 3c6cb6649df0ad02025f38ba2c96e3a819cd5f18..9c5a46a47cd08139d3ee60f6e3f59e221af3cd49 100644 (file)
@@ -55,6 +55,9 @@
 // All dummy nodes will be eliminated at the end of compilation.
 */
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++20-extensions" // variadic macro with 0 args
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -621,4 +624,6 @@ namespace __detail
 } // namespace __detail
 
 _GLIBCXX_END_NAMESPACE_VERSION
-} // namespace
+} // namespace std
+
+#pragma GCC diagnostic pop
index 9acf15f399ff1eb863a563ebf7cc386b8aeced34..7eb5561b6309a9bdbdcf0a03bb835cf7b90b331f 100644 (file)
@@ -36,6 +36,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions" // extern template
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -304,4 +307,5 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
 #endif
index 48d44160babae46128ac6b3578dc7536bd84e9f6..d143ec14179da080c076906740a98dd19a3e3e34 100644 (file)
 
 #include <bits/c++config.h>
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+#pragma GCC diagnostic ignored "-Wlong-long"
+
 #define _GLIBCXX_INCLUDE_NEXT_C_HEADERS
 #include_next <stdlib.h>
 #ifdef __CORRECT_ISO_CPP_MATH_H_PROTO
@@ -151,4 +155,6 @@ _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace
 } // extern "C++"
 
+#pragma GCC diagnostic pop
+
 #endif // _GLIBCXX_BITS_STD_ABS_H
index 778a37ac46f4af245dafef06499be1e052112402..a1ef665506d18295661c9725b06bed98b8e0903c 100644 (file)
@@ -72,6 +72,9 @@
 # endif
 #endif
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions" // inline namespace
+
 // See concept_check.h for the __glibcxx_*_requires macros.
 
 namespace std _GLIBCXX_VISIBILITY(default)
@@ -5901,4 +5904,6 @@ _GLIBCXX_END_NAMESPACE_ALGO
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
+
 #endif /* _STL_ALGO_H */
index 3cfee68defc105aedcb68d344b8cbf5349053510..0c28033f4916ab1c991515818d7b777c1f6564cc 100644 (file)
@@ -36,6 +36,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions" // extern template
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -166,4 +169,5 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
 #endif
index 5cd11fff9eceb0af022acf6f0652e6ffa6c014e7..ef6e844a72b71abb9aefd8db5d1edc85791a55fc 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include <bits/c++config.h>
 #include_next <assert.h>
+
+#pragma GCC diagnostic pop
index c6f650394357ebee59dddd171096bb21902ebf1a..a7a59551d86909dce27a802bf2c04d0c0d78da09 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include_next <ctype.h>
 
+#pragma GCC diagnostic pop
+
 #endif
index 9e47b182d25cf3731356a966a921166f0ee2abc8..29bf0b403aad2b14a3d91519953643e46f4b8100 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include <bits/c++config.h>
 #include_next <errno.h>
 
+#pragma GCC diagnostic pop
+
 // Adhere to section 17.4.1.2 clause 5 of ISO 14882:1998
 #ifndef errno
 #define errno errno
index 81d9772ed9f6abee2c47b9f05cf2b95ac8be1871..1f9edada950cecabe71ec3830db4b68e1178be4e 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include <bits/c++config.h>
 #include_next <float.h>
 
+#pragma GCC diagnostic pop
+
 #endif
index 255bed41125946d341323255c783216038ece313..846fe190707a7f610219bae3b9c09b9a61706b93 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include <bits/c++config.h>
 #include_next <limits.h>
 
+#pragma GCC diagnostic pop
+
 #endif
index 4258df1958b6fcb81a451adc349bb764ca802777..62d85ed6609aee1826d11724a7c911813bbaee7a 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include_next <locale.h>
 
+#pragma GCC diagnostic pop
+
 #endif
index 43020eee9d2975d31dd6958b4511f58e792d9234..371ee59986c83565adfb9a29e97bbbe8892b8478 100644 (file)
 
 #include <bits/c++config.h>
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include_next <math.h>
 
+#pragma GCC diagnostic pop
+
 // Get rid of those macros defined in <math.h> in lieu of real functions.
 #undef abs
 #undef div
index 4a5b0334590f377d4b605eba854e2bf2d65ca38e..acf113a0c5a1b0c1f3307c2889f8095279d3c45d 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include_next <setjmp.h>
 
+#pragma GCC diagnostic pop
+
 // Get rid of those macros defined in <setjmp.h> in lieu of real functions.
 #undef longjmp
 
index 040b48368f94127c45397d53430346e8c182e247..c04bb6042f45c912e204e14591a967ec04bd4d0a 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include_next <signal.h>
 
+#pragma GCC diagnostic pop
+
 #endif
index 5d97e043da843ceb9fb5fb507f24cb3fd581e560..7648662680c0ba2148035688d543b8588d4bd22e 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #undef __need___va_list
 #include_next <stdarg.h>
 
+#pragma GCC diagnostic pop
+
 #endif
index 4fd889a1dffc6cb01254354a071f5c8badb01cf1..e1435b94556b58f48edca4042328e85ecab0820a 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #define __need_size_t
 #define __need_ptrdiff_t
 #define __need_NULL
 #define __need_offsetof
 #include_next <stddef.h>
 
+#pragma GCC diagnostic pop
+
 #endif
index 01293054d501ce2cc63a194c164ddd8d79ae5408..99aead4ef9c8bb786504729f01306e5733841125 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include_next <stdio.h>
 
+#pragma GCC diagnostic pop
+
 // Get rid of those macros defined in <stdio.h> in lieu of real functions.
 #undef clearerr
 #undef fclose
index f5707f8a8ce49ac761afabe51611626be22ee4ba..75e6382c01b2cd76c64f6df76d8e2cbc0d01efa8 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include_next <stdlib.h>
 
+#pragma GCC diagnostic pop
+
 #endif
index 0082080fcab0767089486818d3e915a4c6d1ed68..05d75182a7acdc9f4027b1c7830e557de7205c79 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include_next <string.h>
 
+#pragma GCC diagnostic pop
+
 #endif
index 5476ff7da399d61970afacea954d11489ba9e881..73e2a7a016714ab22dae67aef95e21d24f48da7d 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include_next <time.h>
 
+#pragma GCC diagnostic pop
+
 #endif
index 7a62eb74abbfe0ebe54b2afc2da1a620d88ad034..921de2677507783bfc9e8fe37effdc6c0a637bd4 100644 (file)
 #include <cstddef>
 #include <ctime>
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #if _GLIBCXX_HAVE_WCHAR_H
 #include_next <wchar.h>
 #endif
 
+#pragma GCC diagnostic pop
+
 // Need to do a bit of trickery here with mbstate_t as char_traits
 // assumes it is in wchar.h, regardless of wchar_t specializations.
 #ifndef _GLIBCXX_HAVE_MBSTATE_T
index 011ceadbb1b4e376ae1c8f66bc131a681fc41269..0d2f55d9d6d0c78123033fda2c907bdce08512d3 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include <bits/c++config.h>
 
 #if _GLIBCXX_HAVE_WCTYPE_H
 #include_next <wctype.h>
 #endif
 
+#pragma GCC diagnostic pop
+
 #endif
index 6800814bca5a1a44c62794ac948a4709671e642c..a587e7308af93d76c31012a2300ce4b1677755ca 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include <bits/c++config.h>
 #if _GLIBCXX_HAVE_FENV_H
 # include_next <fenv.h>
 #endif
 
+#pragma GCC diagnostic pop
+
 #if __cplusplus >= 201103L
 
 #if _GLIBCXX_USE_C99_FENV
index bc63119097cb143c560e1add12ade51b51bb5e56..5a428ce0bd75f9da0db18294f1033f4cc7d4607b 100644 (file)
@@ -31,6 +31,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include <bits/c++config.h>
 
 #if __cplusplus >= 201103L
@@ -88,4 +91,6 @@ namespace std
 
 #endif // C++11
 
+#pragma GCC diagnostic pop
+
 #endif // _GLIBCXX_INTTYPES_H
index 0b6a8c166270f2b6085e6763051628578bab0a47..2d892e7ceb20d43ab9c4bf28112608acfb2e18a6 100644 (file)
@@ -31,6 +31,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
+
 #include <bits/c++config.h>
 
 #if __cplusplus >= 201103L
@@ -107,4 +110,6 @@ namespace std
 
 #endif // C++11
 
+#pragma GCC diagnostic pop
+
 #endif // _GLIBCXX_STDINT_H
index 7e374ef0c793d386462c668efb65d204f235864b..c85fc283ae6bd509e6514c41f0904c5bea037b1b 100644 (file)
@@ -44,6 +44,9 @@
 #ifndef _GLIBCXX_CLIMITS
 #define _GLIBCXX_CLIMITS 1
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wlong-long"
+
 #ifndef LLONG_MIN
 #define LLONG_MIN (-__LONG_LONG_MAX__ - 1)
 #endif
@@ -56,4 +59,6 @@
 #define ULLONG_MAX (__LONG_LONG_MAX__ * 2ULL + 1)
 #endif
 
+#pragma GCC diagnostic pop
+
 #endif
index dd0174f1987f693d936658dfb4c4688eb7f21344..4958dfd2ff167233656545d8caaac07bdc64e935 100644 (file)
 #include <bits/c++config.h>
 #include <bits/cpp_type_traits.h>
 #include <ext/type_traits.h>
+
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
 #define _GLIBCXX_INCLUDE_NEXT_C_HEADERS
 #include_next <math.h>
 #undef _GLIBCXX_INCLUDE_NEXT_C_HEADERS
+#pragma GCC diagnostic pop
+
 #include <bits/std_abs.h>
 
 #ifndef _GLIBCXX_CMATH
index b25a6b3eec90b54900b745e8fc140204d7974e55..f49f56ae37296b7fa89d3f9d2baea971c0815359 100644 (file)
@@ -52,6 +52,9 @@
 #define __glibcxx_want_byte
 #include <bits/version.h>
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // __int128
+
 extern "C++"
 {
 #if __cplusplus >= 201103L
@@ -189,4 +192,6 @@ _GLIBCXX_END_NAMESPACE_VERSION
 #endif // __cpp_lib_byte
 } // extern "C++"
 
+#pragma GCC diagnostic pop
+
 #endif // _GLIBCXX_CSTDDEF
index 69e7a39eb44e948a64def5c5a090f617c3f36b16..72baff2499150a6f3e1bffca580896fa57d63063 100644 (file)
@@ -75,9 +75,13 @@ namespace std
 
 // Need to ensure this finds the C library's <stdlib.h> not a libstdc++
 // wrapper that might already be installed later in the include search path.
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // include_next
 #define _GLIBCXX_INCLUDE_NEXT_C_HEADERS
 #include_next <stdlib.h>
 #undef _GLIBCXX_INCLUDE_NEXT_C_HEADERS
+#pragma GCC diagnostic pop
+
 #include <bits/std_abs.h>
 
 // Get rid of those macros defined in <stdlib.h> in lieu of real functions.
index d20e012f9c5250b485e96f0c8b45a2ec8d5aa585..a64ddde4756d758436c086901be5d3c77c6064dc 100644 (file)
@@ -33,6 +33,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // DF suffix
+
 #include <bits/c++config.h>
 
 #ifndef _GLIBCXX_USE_DECIMAL_FLOAT
@@ -491,4 +494,5 @@ _GLIBCXX_END_NAMESPACE_VERSION
 
 #include <decimal/decimal.h>
 
+#pragma GCC diagnostic pop
 #endif /* _GLIBCXX_DECIMAL */
index 7629c1b1129f8fb6b4ee68f6fdde149cc3d19087..8188c1366b0b97f81e2c328f9bf8cfa0852a44d0 100644 (file)
@@ -37,6 +37,9 @@
 #include <bits/cpp_type_traits.h>
 #include <ext/type_traits.h>
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions"
+
 namespace __gnu_cxx _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -312,4 +315,6 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace
 
+#pragma GCC diagnostic pop
+
 #endif
index b5ebb1322742a388756f11fc7fd290fd5af8fe5f..19199e82806796feed558f41cc1a70754dee201c 100644 (file)
 
 #include <ext/memory> // For uninitialized_copy_n
 
+// Ignore warnings about default member initializers.
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions"
+
 namespace __gnu_cxx _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -3009,6 +3013,8 @@ namespace tr1
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
+
 # include <ext/ropeimpl.h>
 
 #endif
index 75d7edf85b871a8b5182ccf240b0f9e730852607..165e1b43da00b391010fd883c109c494eb092b2e 100644 (file)
@@ -34,6 +34,9 @@
 #include <bits/c++config.h>
 #include <bits/cpp_type_traits.h>
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wlong-long"
+
 extern "C++" {
 
 namespace __gnu_cxx _GLIBCXX_VISIBILITY(default)
@@ -270,4 +273,6 @@ _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace
 } // extern "C++"
 
+#pragma GCC diagnostic pop
+
 #endif 
index 9ae29aab99fa93b2dd1bd385e0b9812b809508ca..d24260eaacea4e566f6fbc352c90ef63b82acb4b 100644 (file)
@@ -42,6 +42,9 @@
 #include <type_traits>
 #include <bits/utility.h> // in_place_type_t
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations" // aligned_storage
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -661,5 +664,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
+
 #endif // __cpp_lib_any
 #endif // _GLIBCXX_ANY
index 00c4f206922a552be124dad17423b484dc82f620..de671393b88ec82b0d3f8be4662891393090265e 100644 (file)
@@ -31,6 +31,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // __int128
+
 #include <bits/requires_hosted.h> // for error codes
 
 // As an extension we support <charconv> in C++14, but this header should not
@@ -932,4 +935,5 @@ namespace __detail
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 #endif // C++14
+#pragma GCC diagnostic pop
 #endif // _GLIBCXX_CHARCONV
index be810b6d05d25e0ea3bba8b8f1a41f836c329c8e..c688d0cb7284aacf03362ba04af10dcc33b5064f 100644 (file)
@@ -38,6 +38,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions" // extern template
+
 #include <bits/c++config.h>
 #include <bits/cpp_type_traits.h>
 #include <ext/type_traits.h>
@@ -2650,4 +2653,5 @@ _GLIBCXX_END_NAMESPACE_VERSION
 #pragma clang diagnostic pop
 #endif
 
+#pragma GCC diagnostic pop
 #endif  /* _GLIBCXX_COMPLEX */
index ccd016b255eba351dde9758d9f0257cf473466c1..30b4d33711e597b12f3491b867a02d05d9fb5c28 100644 (file)
@@ -31,6 +31,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++17-extensions"
+
 #define __glibcxx_want_coroutine
 #include <bits/version.h>
 
@@ -358,4 +361,5 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 
 #endif // __cpp_lib_coroutine
 
+#pragma GCC diagnostic pop
 #endif // _GLIBCXX_COROUTINE
index e963d7f79b33e5ad770f0da145e6f4066c116f50..4c5377aabec6ec48ff10909da7f9fdd943fba05e 100644 (file)
 # include <cctype>
 #endif
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // __int128
+#pragma GCC diagnostic ignored "-Wc++23-extensions" // bf16
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -1674,6 +1678,10 @@ namespace __format
 
              do
                {
+                 // Mangling of this lambda, and thus resize_and_overwrite
+                 // instantiated with it, was fixed in ABI 18 (G++ 13).  Since
+                 // <format> was new in G++ 13, and is experimental, that
+                 // isn't a problem.
                  auto __overwrite = [&__to_chars, &__res] (char* __p, size_t __n)
                  {
                    __res = __to_chars(__p + 1, __p + __n - 1);
@@ -4737,4 +4745,5 @@ namespace __format
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 #endif // __cpp_lib_format
+#pragma GCC diagnostic pop
 #endif // _GLIBCXX_FORMAT
index fdf80fc8b5087ab6913d8883a1f3f29c86ee85a2..9d8ecea5d65aa3f14a721b4070eeecb48a26bb27 100644 (file)
@@ -35,6 +35,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions"
+
 #include <bits/requires_hosted.h> // iostreams
 
 #include <bits/c++config.h>
@@ -543,4 +546,5 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace
 
+#pragma GCC diagnostic pop
 #endif /* _GLIBCXX_IOMANIP */
index 4b0698e4713471ff553fc7443119f8b71b005190..b0ab57c1ad71907189f8b20decc0ccb3ae93f760 100644 (file)
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // Q suffix
+#pragma GCC diagnostic ignored "-Wlong-long"
+#pragma GCC diagnostic ignored "-Wc++23-extensions"
+
 #include <bits/c++config.h>
 
 //
@@ -2229,4 +2234,5 @@ _GLIBCXX_END_NAMESPACE_VERSION
 #undef __glibcxx_digits10
 #undef __glibcxx_max_digits10
 
+#pragma GCC diagnostic pop
 #endif // _GLIBCXX_NUMERIC_LIMITS
index 9836afac645191d2b389b560765cc519efce00f0..f04000f1dd90d7a875b88713403d2c114a18ca33 100644 (file)
@@ -38,6 +38,9 @@
 
 #include <type_traits>
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // Q extension
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -232,5 +235,7 @@ __glibcxx_numbers (__float128, Q);
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std
 
+#pragma GCC diagnostic pop
+
 #endif // __cpp_lib_math_constants
 #endif // _GLIBCXX_NUMBERS
index 5fc808623a7f24621c0c4f89bbeed2b89956e8da..f2cd42bed4ef7e2db4a2e0308d952e6af5cc0afa 100644 (file)
 #include <ext/type_traits.h>
 #include <bits/move.h> // for std::__addressof
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wvolatile" // volatile parm/return
+#pragma GCC diagnostic ignored "-Wc++11-extensions"
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
 _GLIBCXX_BEGIN_NAMESPACE_VERSION
@@ -2282,4 +2286,5 @@ namespace tr1
 _GLIBCXX_END_NAMESPACE_VERSION
 }
 
+#pragma GCC diagnostic pop
 #endif // _GLIBCXX_TR1_FUNCTIONAL
index be26d283f8c2531e7fd8af07f15f2f4340d795b8..40e2d0915141577db08735f17e5365d05862f5be 100644 (file)
@@ -34,6 +34,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions"
+
 #include <bits/requires_hosted.h> // TR1
 
 #include <utility>
@@ -425,4 +428,5 @@ namespace tr1
 _GLIBCXX_END_NAMESPACE_VERSION
 }
 
+#pragma GCC diagnostic pop
 #endif // _GLIBCXX_TR1_TUPLE
index f5714b0032cc8015840a90a002911da62bc9dd27..62b30e7d658c3f7f7063d3bf4ecc2b7b42cc56cb 100644 (file)
@@ -31,6 +31,9 @@
 
 #pragma GCC system_header
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions"
+
 #include <bits/requires_hosted.h> // TR1
 
 #include <bits/c++config.h>
@@ -684,4 +687,5 @@ namespace tr1
 _GLIBCXX_END_NAMESPACE_VERSION
 }
 
+#pragma GCC diagnostic pop
 #endif // _GLIBCXX_TR1_TYPE_TRAITS
index 63ad6b5c23e95c7e5c1ba7457382092b0b41830e..ac8ffdb6c5ab4f58292dd8f38eaf54f7112d996d 100644 (file)
 
 #include <concepts>
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wpedantic" // __int128
+#pragma GCC diagnostic ignored "-Wzero-as-null-pointer-constant"
+
 namespace std _GLIBCXX_VISIBILITY(default)
 {
   // [cmp.categories], comparison category types
@@ -1258,6 +1262,8 @@ namespace std _GLIBCXX_VISIBILITY(default)
 #endif // __cpp_lib_three_way_comparison >= 201907L
 } // namespace std
 
+#pragma GCC diagnostic pop
+
 #endif // C++20
 
 #endif // _COMPARE
index af5c7690bb999a9773bcc75b8898bec13e196119..b530bd1100dfeffa3afed12299f2acf2e99b27f3 100644 (file)
@@ -46,6 +46,9 @@
 #define __glibcxx_want_constexpr_new
 #include <bits/version.h>
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wc++11-extensions" // scoped enum
+
 #pragma GCC visibility push(default)
 
 extern "C++" {
@@ -239,5 +242,6 @@ namespace std
 }
 
 #pragma GCC visibility pop
+#pragma GCC diagnostic pop
 
 #endif
index 261fe84b0aebbc564b2f9915f40a0f3e28f50ad5..458748af28aa620cf7946b90eaed9bfa213c0e04 100644 (file)
@@ -35,4 +35,4 @@ int main()
 }
 
 // { dg-error "required from" "" { target *-*-* } 28 }
-// { dg-error "no type" "" { target *-*-* } 71 } 
+// { dg-error "no type" "" { target *-*-* } 74 }
index f592478dd97184369eef566a43a25942ec08873f..c1dde44e11888d75f366b8a1f33dd7a9279a1281 100644 (file)
@@ -36,5 +36,5 @@ int main()
 }
 
 // { dg-error "invalid use of incomplete" "" { target *-*-* } 28 } 
-// { dg-error "declaration of" "" { target *-*-* } 100 }
 // { dg-error "declaration of" "" { target *-*-* } 103 }
+// { dg-error "declaration of" "" { target *-*-* } 106 }
index 42078e556f63ddc0ed2e5b34e44c962b5eb921f5..5f77c1a652a340dd546ac184b5c9e01c93aac768 100644 (file)
@@ -35,4 +35,4 @@ int main()
 }
 
 // { dg-error "required from" "" { target *-*-* } 28 }
-// { dg-error "no type" "" { target *-*-* } 114 }
+// { dg-error "no type" "" { target *-*-* } 117 }
index f017aecdb8a6d31bad85f543dea7b0951d56c49c..7f5a304c5264476f4cec11dea35734ed88f1fd6c 100644 (file)
@@ -36,5 +36,5 @@ int main()
 }
 
 // { dg-error "invalid use of incomplete" "" { target *-*-* } 28 } 
-// { dg-error "declaration of" "" { target *-*-* } 143 }
 // { dg-error "declaration of" "" { target *-*-* } 146 }
+// { dg-error "declaration of" "" { target *-*-* } 149 }