]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
libstdc++: more #pragma diagnostic
authorJason Merrill <jason@redhat.com>
Tue, 24 Sep 2024 03:38:34 +0000 (23:38 -0400)
committerJason Merrill <jason@redhat.com>
Wed, 25 Sep 2024 12:20:45 +0000 (08:20 -0400)
The CI saw failures on 17_intro/headers/c++2011/parallel_mode.cc due to
-Wdeprecated-declarations warnings in some parallel/ headers.

libstdc++-v3/ChangeLog:

* include/parallel/base.h: Suppress -Wdeprecated-declarations.
* include/parallel/multiseq_selection.h: Likewise.

libstdc++-v3/include/parallel/base.h
libstdc++-v3/include/parallel/multiseq_selection.h

index 5bc5350e72340d2460f35dcb38420b1794cb27a7..fcbcc1e0b996fed8088c7374299b17436aabcc43 100644 (file)
@@ -166,6 +166,8 @@ namespace __gnu_parallel
       { return !_M_comp(__a, __b) && !_M_comp(__b, __a); }
     };
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations" // *nary_function
 
   /** @brief Similar to std::unary_negate,
    *  but giving the argument types explicitly. */
@@ -297,6 +299,8 @@ namespace __gnu_parallel
     struct _Multiplies<_Tp, _Tp, _Tp>
     : public std::multiplies<_Tp> { };
 
+#pragma GCC diagnostic pop // -Wdeprecated-declarations
+
   /** @brief _Iterator associated with __gnu_parallel::_PseudoSequence.
    *  If features the usual random-access iterator functionality.
    *  @param _Tp Sequence _M_value type.
index f25895adbdd2f1c6d4964c1398c98e85206942b2..22bd97e6432b3016eac39272099899c35f30c9b9 100644 (file)
 
 namespace __gnu_parallel
 {
+
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations" // *nary_function
+
   /** @brief Compare __a pair of types lexicographically, ascending. */
   template<typename _T1, typename _T2, typename _Compare>
     class _Lexicographic
@@ -100,6 +104,8 @@ namespace __gnu_parallel
       }
     };
 
+#pragma GCC diagnostic pop // -Wdeprecated-declarations
+
   /** 
    *  @brief Splits several sorted sequences at a certain global __rank,
    *  resulting in a splitting point for each sequence.