]> gcc.gnu.org Git - gcc.git/commitdiff
libstdc++: Adjust expected errors in tests when compiled as C++20
authorJonathan Wakely <jwakely@redhat.com>
Mon, 10 May 2021 14:10:45 +0000 (15:10 +0100)
committerJonathan Wakely <jwakely@redhat.com>
Tue, 11 May 2021 19:50:07 +0000 (20:50 +0100)
libstdc++-v3/ChangeLog:

* testsuite/20_util/scoped_allocator/69293_neg.cc: Add dg-error
for additional errors in C++20.
* testsuite/20_util/specialized_algorithms/memory_management_tools/destroy_neg.cc:
Likewise.
* testsuite/20_util/uses_allocator/69293_neg.cc: Likewise.
* testsuite/27_io/filesystem/path/io/dr2989.cc: Likewise.

(cherry picked from commit 23972128c83e62011b583f06b32c8501c096b7d8)

libstdc++-v3/testsuite/20_util/scoped_allocator/69293_neg.cc
libstdc++-v3/testsuite/20_util/specialized_algorithms/memory_management_tools/destroy_neg.cc
libstdc++-v3/testsuite/20_util/uses_allocator/69293_neg.cc
libstdc++-v3/testsuite/27_io/filesystem/path/io/dr2989.cc

index 5efd849ff36dfcf55fb79e3ebbc4422b4dcee7b6..fd37374447f9176cfe2c02be5e6b657e0a5bde3b 100644 (file)
@@ -47,6 +47,7 @@ test01()
   auto p = sa.allocate(1);
   sa.construct(p);  // this is required to be ill-formed
   // { dg-error "failed: .* uses_allocator is true" "" { target *-*-* } 0 }
+  // { dg-error "too many initializers for 'X'" "" { target c++2a } 0 }
 }
 
 // Needed because of PR c++/92193
index b17c6a0b90c72363fc05784a8373cc1d057086a8..626f2e1c6ee1a8fcb498c77d6f59e5f2e422d33f 100644 (file)
@@ -48,3 +48,5 @@ test02()
 }
 
 // { dg-error "value type is destructible" "" { target *-*-* } 0 }
+// { dg-error "use of deleted function" "" { target c++20 } 0 }
+// { dg-error "is private within this context" "" { target c++20 } 0 }
index 921ebbc87de398bf847ddde2c30e4596edadb961..2c5a62190e88d7b1588066889c136b583deae2a8 100644 (file)
@@ -45,5 +45,5 @@ test01()
   alloc_type a;
   std::tuple<X> t(std::allocator_arg, a); // this is required to be ill-formed
   // { dg-error "failed: .* uses_allocator is true" "" { target *-*-* } 0 }
-  // { dg-error "no matching function for call" "" { target c++2a } 0 }
+  // { dg-error "too many initializers for 'X'" "" { target c++2a } 0 }
 }
index c5cda77647776f5f6be9c820ee22ef47e14f722d..e858e3508bda1c41a094177cd7aefbd9127791ae 100644 (file)
@@ -33,3 +33,4 @@ void foo(std::iostream& s) {
   s >> p; // { dg-error "no match" }
 }
 // { dg-prune-output "no type .*enable_if" }
+// { dg-prune-output "template constraint failure" }
This page took 0.063816 seconds and 5 git commands to generate.