]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
testsuite: Disable tests for C++23 that depend on std::unexpected
authorJonathan Wakely <jwakely@redhat.com>
Mon, 28 Mar 2022 21:05:01 +0000 (22:05 +0100)
committerJonathan Wakely <jwakely@redhat.com>
Tue, 29 Mar 2022 19:30:43 +0000 (20:30 +0100)
These tests depend on unexpected handlers, which are no longer declared
for C++23 mode. Adjust the target specifier so they don't run.

gcc/testsuite/ChangeLog:

* g++.dg/cpp0x/noexcept06.C: Disable for C++23.

libstdc++-v3/ChangeLog:

* testsuite/18_support/exception/38732.cc: Disable for C++23.
* testsuite/18_support/headers/exception/synopsis.cc: Likewise.
* testsuite/18_support/unexpected_handler.cc: Likewise.

gcc/testsuite/g++.dg/cpp0x/noexcept06.C
libstdc++-v3/testsuite/18_support/exception/38732.cc
libstdc++-v3/testsuite/18_support/headers/exception/synopsis.cc
libstdc++-v3/testsuite/18_support/unexpected_handler.cc

index ea152237d5450a95e96a6c4ac8c7c1765afa12ba..0183ad6d91816cde08f73464cc73d7671eaa9912 100644 (file)
@@ -1,6 +1,6 @@
 // Test that checking of a nothrow specification uses the one on the
 // definition.
-// { dg-do run { target c++11 } }
+// { dg-do run { target { c++11 && { ! c++23 } } } }
 // { dg-options "-Wno-terminate" }
 
 #include <exception>
index 7b68921d0741f90794b6b67ff5b8f62fc21287a4..a3888353a4b43c4fea9537210fc2e9a8ecd3a555 100644 (file)
@@ -15,6 +15,8 @@
 // with this library; see the file COPYING3.  If not see
 // <http://www.gnu.org/licenses/>.
 
+// { dg-do run { target { c++11 && { ! c++23 } } } }
+
 #include <typeinfo>
 #include <exception>
 #include "unwind.h"
index efc0bc64c18a47de5f00aa13a4a17737ca244f1f..ceb7d1f754b8cc037e704ada8f88a4dd18d9ddf9 100644 (file)
@@ -1,4 +1,4 @@
-// { dg-do compile { target c++11 } }
+// { dg-do compile { target { c++11 && { ! c++23 } } } }
 
 // Copyright (C) 2007-2022 Free Software Foundation, Inc.
 //
index efd00abf879081a424b0e316ada6a8aaaccead49..344e7e08294af2e899f814e6d06718493f4c23b4 100644 (file)
@@ -16,7 +16,7 @@
 // <http://www.gnu.org/licenses/>.
 
 // { dg-options "-Wno-deprecated-declarations" }
-// { dg-do run { target c++11 } }
+// { dg-do run { target { c++11 && { ! c++23 } } } }
 
 // D.11 Violating exception-specifications