]> git.ipfire.org Git - thirdparty/gcc.git/commit - libstdc++-v3/include/bits/stl_algobase.h
libstdc++: Use __extension__ instead of diagnostic pragmas
authorJonathan Wakely <jwakely@redhat.com>
Fri, 16 Jul 2021 12:23:06 +0000 (13:23 +0100)
committerJonathan Wakely <jwakely@redhat.com>
Fri, 16 Jul 2021 14:03:03 +0000 (15:03 +0100)
commit42167831ab1f3cd61f02a22dfb0e87333073c5ca
treeaeba22d77559b26fcbf0fd397936a428c4f021b0
parent1af937eb6246ad7f63ebff03590e9eede33aca81
libstdc++: Use __extension__ instead of diagnostic pragmas

This reverts c1676651b6c417e8f2b276a28199d76943834277 and uses the
__extension__ keyword to prevent pedantic warnings instead of diagnostic
pragmas.

This also adds the __extension__ keyword in <limits> and <bits/random.h>
where there are some more warnings that I missed in the previous commit.

Signed-off-by: Jonathan Wakely <jwakely@redhat.com>
libstdc++-v3/ChangeLog:

* include/bits/cpp_type_traits.h (__INT_N): Use __extension__
instead of diagnostic pragmas.
* include/bits/functional_hash.h: Likewise.
* include/bits/iterator_concepts.h (__is_signed_int128)
(__is_unsigned_int128): Likewise.
* include/bits/max_size_type.h (__max_size_type): Likewise.
(numeric_limits<__max_size_type>): Likewise.
* include/bits/std_abs.h (abs): Likewise.
* include/bits/stl_algobase.h (__size_to_integer): Likewise.
* include/bits/uniform_int_dist.h (uniform_int_distribution):
Likewise.
* include/ext/numeric_traits.h (_GLIBCXX_INT_N_TRAITS):
Likewise.
* include/std/type_traits (__is_integral_helper<INT_N>)
(__is_signed_integer, __is_unsigned_integer)
(__make_unsigned<INT_N>, __make_signed<INT_N>): Likewise.
* include/std/limits (__INT_N): Add __extension__ keyword.
* include/bits/random.h (_Select_uint_least_t)
(random_device): Likewise.
libstdc++-v3/include/bits/cpp_type_traits.h
libstdc++-v3/include/bits/functional_hash.h
libstdc++-v3/include/bits/iterator_concepts.h
libstdc++-v3/include/bits/max_size_type.h
libstdc++-v3/include/bits/random.h
libstdc++-v3/include/bits/std_abs.h
libstdc++-v3/include/bits/stl_algobase.h
libstdc++-v3/include/bits/uniform_int_dist.h
libstdc++-v3/include/ext/numeric_traits.h
libstdc++-v3/include/std/limits
libstdc++-v3/include/std/type_traits