diff options
author | Muhammad Usman Shahid <codesbyusman@gmail.com> | 2022-07-25 07:22:54 -0400 |
---|---|---|
committer | Aaron Ballman <aaron@aaronballman.com> | 2022-07-25 07:22:54 -0400 |
commit | 76476efd68951907a94def92b2bb6ba6e32ca5b4 (patch) | |
tree | 4e147e6403352f54be8a18bb9fcd12bc208f621d /libcxx | |
parent | 214a760a211606d14b3b2b852bd9d9a21149317e (diff) |
Rewording "static_assert" diagnostics
This patch rewords the static assert diagnostic output. Failing a
_Static_assert in C should not report that static_assert failed. This
changes the wording to be more like GCC and uses "static assertion"
when possible instead of hard coding the name. This also changes some
instances of 'static_assert' to instead be based on the token in the
source code.
Differential Revision: https://reviews.llvm.org/D129048
Diffstat (limited to 'libcxx')
68 files changed, 129 insertions, 129 deletions
diff --git a/libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_add.verify.cpp b/libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_add.verify.cpp index 6c4ac602ce72..ca6f0069a155 100644 --- a/libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_add.verify.cpp +++ b/libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_add.verify.cpp @@ -46,12 +46,12 @@ void pointer_to_incomplete_type() { void function_pointer() { { volatile std::atomic<void (*)(int)> fun; - // expected-error-re@atomic:* {{static_assert failed due to requirement '!is_function<void (int)>::value'{{.*}}Pointer to function isn't allowed}} + // expected-error-re@atomic:* {{{{(static_assert|static assertion)}} failed due to requirement '!is_function<void (int)>::value'{{.*}}Pointer to function isn't allowed}} std::atomic_fetch_add(&fun, 0); } { std::atomic<void (*)(int)> fun; - // expected-error-re@atomic:* {{static_assert failed due to requirement '!is_function<void (int)>::value'{{.*}}Pointer to function isn't allowed}} + // expected-error-re@atomic:* {{{{(static_assert|static assertion)}} failed due to requirement '!is_function<void (int)>::value'{{.*}}Pointer to function isn't allowed}} std::atomic_fetch_add(&fun, 0); } } diff --git a/libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_add_explicit.verify.cpp b/libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_add_explicit.verify.cpp index bb45929a5041..773dbc7fa432 100644 --- a/libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_add_explicit.verify.cpp +++ b/libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_add_explicit.verify.cpp @@ -49,12 +49,12 @@ void pointer_to_incomplete_type() { void function_pointer() { { volatile std::atomic<void (*)(int)> fun; - // expected-error-re@atomic:* {{static_assert failed due to requirement '!is_function<void (int)>::value'{{.*}}Pointer to function isn't allowed}} + // expected-error-re@atomic:* {{{{(static_assert|static assertion)}} failed due to requirement '!is_function<void (int)>::value'{{.*}}Pointer to function isn't allowed}} std::atomic_fetch_add_explicit(&fun, 0, std::memory_order_relaxed); } { std::atomic<void (*)(int)> fun; - // expected-error-re@atomic:* {{static_assert failed due to requirement '!is_function<void (int)>::value'{{.*}}Pointer to function isn't allowed}} + // expected-error-re@atomic:* {{{{(static_assert|static assertion)}} failed due to requirement '!is_function<void (int)>::value'{{.*}}Pointer to function isn't allowed}} std::atomic_fetch_add_explicit(&fun, 0, std::memory_order_relaxed); } } diff --git a/libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_sub.verify.cpp b/libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_sub.verify.cpp index f996110f4977..c2cf156b7f76 100644 --- a/libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_sub.verify.cpp +++ b/libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_sub.verify.cpp @@ -46,12 +46,12 @@ void pointer_to_incomplete_type() { void function_pointer() { { volatile std::atomic<void (*)(int)> fun; - // expected-error-re@atomic:* {{static_assert failed due to requirement '!is_function<void (int)>::value'{{.*}}Pointer to function isn't allowed}} + // expected-error-re@atomic:* {{{{(static_assert|static assertion)}} failed due to requirement '!is_function<void (int)>::value'{{.*}}Pointer to function isn't allowed}} std::atomic_fetch_sub(&fun, 0); } { std::atomic<void (*)(int)> fun; - // expected-error-re@atomic:* {{static_assert failed due to requirement '!is_function<void (int)>::value'{{.*}}Pointer to function isn't allowed}} + // expected-error-re@atomic:* {{{{(static_assert|static assertion)}} failed due to requirement '!is_function<void (int)>::value'{{.*}}Pointer to function isn't allowed}} std::atomic_fetch_sub(&fun, 0); } } diff --git a/libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_sub_explicit.verify.cpp b/libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_sub_explicit.verify.cpp index 97416428433d..73c2b963b4f3 100644 --- a/libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_sub_explicit.verify.cpp +++ b/libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_sub_explicit.verify.cpp @@ -49,12 +49,12 @@ void pointer_to_incomplete_type() { void function_pointer() { { volatile std::atomic<void (*)(int)> fun; - // expected-error-re@atomic:* {{static_assert failed due to requirement '!is_function<void (int)>::value'{{.*}}Pointer to function isn't allowed}} + // expected-error-re@atomic:* {{{{(static_assert|static assertion)}} failed due to requirement '!is_function<void (int)>::value'{{.*}}Pointer to function isn't allowed}} std::atomic_fetch_sub_explicit(&fun, 0, std::memory_order_relaxed); } { std::atomic<void (*)(int)> fun; - // expected-error-re@atomic:* {{static_assert failed due to requirement '!is_function<void (int)>::value'{{.*}}Pointer to function isn't allowed}} + // expected-error-re@atomic:* {{{{(static_assert|static assertion)}} failed due to requirement '!is_function<void (int)>::value'{{.*}}Pointer to function isn't allowed}} std::atomic_fetch_sub_explicit(&fun, 0, std::memory_order_relaxed); } } diff --git a/libcxx/test/libcxx/input.output/file.streams/fstreams/filebuf/traits_mismatch.fail.cpp b/libcxx/test/libcxx/input.output/file.streams/fstreams/filebuf/traits_mismatch.fail.cpp index 1615cc9869e7..0cec4ca35a02 100644 --- a/libcxx/test/libcxx/input.output/file.streams/fstreams/filebuf/traits_mismatch.fail.cpp +++ b/libcxx/test/libcxx/input.output/file.streams/fstreams/filebuf/traits_mismatch.fail.cpp @@ -18,7 +18,7 @@ int main(int, char**) { std::basic_filebuf<char, std::char_traits<wchar_t> > f; -// expected-error-re@streambuf:* {{static_assert failed{{.*}}traits_type::char_type must be the same type as CharT}} +// expected-error-re@streambuf:* {{{{(static_assert|static assertion)}} failed{{.*}}traits_type::char_type must be the same type as CharT}} return 0; } diff --git a/libcxx/test/libcxx/input.output/file.streams/fstreams/traits_mismatch.fail.cpp b/libcxx/test/libcxx/input.output/file.streams/fstreams/traits_mismatch.fail.cpp index b8475f193c85..4ec84bb7c45a 100644 --- a/libcxx/test/libcxx/input.output/file.streams/fstreams/traits_mismatch.fail.cpp +++ b/libcxx/test/libcxx/input.output/file.streams/fstreams/traits_mismatch.fail.cpp @@ -18,8 +18,8 @@ int main(int, char**) { std::basic_fstream<char, std::char_traits<wchar_t> > f; -// expected-error-re@ios:* {{static_assert failed{{.*}}traits_type::char_type must be the same type as CharT}} -// expected-error-re@streambuf:* {{static_assert failed{{.*}}traits_type::char_type must be the same type as CharT}} +// expected-error-re@ios:* {{{{(static_assert|static assertion)}} failed{{.*}}traits_type::char_type must be the same type as CharT}} +// expected-error-re@streambuf:* {{{{(static_assert|static assertion)}} failed{{.*}}traits_type::char_type must be the same type as CharT}} // FIXME: As of commit r324062 Clang incorrectly generates a diagnostic about mismatching // exception specifications for types which are already invalid for one reason or another. diff --git a/libcxx/test/libcxx/input.output/iostream.format/input.streams/traits_mismatch.fail.cpp b/libcxx/test/libcxx/input.output/iostream.format/input.streams/traits_mismatch.fail.cpp index 55998289eb83..009ed31cf9e8 100644 --- a/libcxx/test/libcxx/input.output/iostream.format/input.streams/traits_mismatch.fail.cpp +++ b/libcxx/test/libcxx/input.output/iostream.format/input.streams/traits_mismatch.fail.cpp @@ -25,7 +25,7 @@ struct test_istream int main(int, char**) { -// expected-error-re@ios:* {{static_assert failed{{.*}}traits_type::char_type must be the same type as CharT}} +// expected-error-re@ios:* {{{{(static_assert|static assertion)}} failed{{.*}}traits_type::char_type must be the same type as CharT}} return 0; } diff --git a/libcxx/test/libcxx/input.output/iostream.format/output.streams/traits_mismatch.fail.cpp b/libcxx/test/libcxx/input.output/iostream.format/output.streams/traits_mismatch.fail.cpp index 54878a2c9972..9dba983f748e 100644 --- a/libcxx/test/libcxx/input.output/iostream.format/output.streams/traits_mismatch.fail.cpp +++ b/libcxx/test/libcxx/input.output/iostream.format/output.streams/traits_mismatch.fail.cpp @@ -25,7 +25,7 @@ struct test_ostream int main(int, char**) { -// expected-error-re@ios:* {{static_assert failed{{.*}}traits_type::char_type must be the same type as CharT}} +// expected-error-re@ios:* {{{{(static_assert|static assertion)}} failed{{.*}}traits_type::char_type must be the same type as CharT}} return 0; } diff --git a/libcxx/test/libcxx/input.output/string.streams/traits_mismatch.fail.cpp b/libcxx/test/libcxx/input.output/string.streams/traits_mismatch.fail.cpp index a0df8bb4cd01..37641bcb9413 100644 --- a/libcxx/test/libcxx/input.output/string.streams/traits_mismatch.fail.cpp +++ b/libcxx/test/libcxx/input.output/string.streams/traits_mismatch.fail.cpp @@ -21,8 +21,8 @@ int main(int, char**) { std::basic_stringbuf<char, std::char_traits<wchar_t> > sb; -// expected-error-re@streambuf:* {{static_assert failed{{.*}}traits_type::char_type must be the same type as CharT}} -// expected-error-re@string:* {{static_assert failed{{.*}}traits_type::char_type must be the same type as CharT}} +// expected-error-re@streambuf:* {{{{(static_assert|static assertion)}} failed{{.*}}traits_type::char_type must be the same type as CharT}} +// expected-error-re@string:* {{{{(static_assert|static assertion)}} failed{{.*}}traits_type::char_type must be the same type as CharT}} return 0; } diff --git a/libcxx/test/libcxx/iterators/predef.iterators/reverse.iterators/bad_template_argument.verify.cpp b/libcxx/test/libcxx/iterators/predef.iterators/reverse.iterators/bad_template_argument.verify.cpp index 564831fff4c7..4ccf85ea528e 100644 --- a/libcxx/test/libcxx/iterators/predef.iterators/reverse.iterators/bad_template_argument.verify.cpp +++ b/libcxx/test/libcxx/iterators/predef.iterators/reverse.iterators/bad_template_argument.verify.cpp @@ -18,7 +18,7 @@ int main(int, char**) { using BadIter = std::reverse_iterator<forward_iterator<int*>>; - BadIter i; //expected-error-re@*:* {{static_assert failed{{.*}}reverse_iterator<It> requires It to be a bidirectional iterator.}} + BadIter i; //expected-error-re@*:* {{{{(static_assert|static assertion)}} failed{{.*}}reverse_iterator<It> requires It to be a bidirectional iterator.}} return 0; } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/bad_engine.verify.cpp index 822411415d6e..c2a349a72708 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/bad_engine.verify.cpp @@ -25,6 +25,6 @@ void test(std::bernoulli_distribution dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* 2 {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* 2 {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/bad_engine.verify.cpp index 6680ea80d822..b03f6b4f43b5 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/bad_engine.verify.cpp @@ -25,6 +25,6 @@ void test(std::binomial_distribution<int> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* 2 {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* 2 {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/bad_engine.verify.cpp index 01287f4160bf..4adfda81b666 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/bad_engine.verify.cpp @@ -26,6 +26,6 @@ void test(std::geometric_distribution<int> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* 7 {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* 7 {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/bad_engine.verify.cpp index fec66efe7364..6936d8b24847 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/bad_engine.verify.cpp @@ -26,6 +26,6 @@ void test(std::negative_binomial_distribution<int> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* 7 {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* 7 {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/bad_engine.verify.cpp index 76d50e9eae3a..118e0be11f49 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/bad_engine.verify.cpp @@ -25,6 +25,6 @@ void test(std::cauchy_distribution<double> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* 2 {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* 2 {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/bad_engine.verify.cpp index 7ef4c2869c8b..347a5f289f0a 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/bad_engine.verify.cpp @@ -25,6 +25,6 @@ void test(std::chi_squared_distribution<double> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* 3 {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* 3 {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/bad_engine.verify.cpp index 1f12398093c8..22268d7375f0 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/bad_engine.verify.cpp @@ -26,6 +26,6 @@ void test(std::fisher_f_distribution<double> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* 4 {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* 4 {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/bad_engine.verify.cpp index c78ae61cf016..b168a2ac0a5f 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/bad_engine.verify.cpp @@ -25,6 +25,6 @@ void test(std::lognormal_distribution<double> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* 2 {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* 2 {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/bad_engine.verify.cpp index d865ab150a19..6ccec0b7412c 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/bad_engine.verify.cpp @@ -25,6 +25,6 @@ void test(std::normal_distribution<double> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* 2 {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* 2 {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/bad_engine.verify.cpp index 71bc832581b8..7daef43c0b9c 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/bad_engine.verify.cpp @@ -25,6 +25,6 @@ void test(std::student_t_distribution<double> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* 5 {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* 5 {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/bad_engine.verify.cpp index 9214a83fc755..5f43f802a617 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/bad_engine.verify.cpp @@ -25,6 +25,6 @@ void test(std::exponential_distribution<double> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/bad_engine.verify.cpp index 4b4bdd067300..f6fd32a7d4dc 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/bad_engine.verify.cpp @@ -25,6 +25,6 @@ void test(std::extreme_value_distribution<double> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* 2 {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* 2 {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/bad_engine.verify.cpp index e0552616087d..5ae008322897 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/bad_engine.verify.cpp @@ -25,6 +25,6 @@ void test(std::gamma_distribution<double> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* 3 {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* 3 {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/bad_engine.verify.cpp index 12551fa60b11..67b5a866968a 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/bad_engine.verify.cpp @@ -26,6 +26,6 @@ void test(std::poisson_distribution<int> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* 4 {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* 4 {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/bad_engine.verify.cpp index 8d1f11376c90..0c3ae5c2b246 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/bad_engine.verify.cpp @@ -25,6 +25,6 @@ void test(std::weibull_distribution<double> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/bad_engine.verify.cpp index d4172e770f72..bd5f2b1530b6 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/bad_engine.verify.cpp @@ -25,6 +25,6 @@ void test(std::discrete_distribution<int> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* 2 {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* 2 {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/bad_engine.verify.cpp index 47f1caa34f77..ef65a494e9e5 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/bad_engine.verify.cpp @@ -25,6 +25,6 @@ void test(std::piecewise_constant_distribution<double> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* 2 {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* 2 {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/bad_engine.verify.cpp index 9f0422d45b7e..e733aff79bec 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/bad_engine.verify.cpp @@ -25,6 +25,6 @@ void test(std::piecewise_linear_distribution<double> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* 2 {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* 2 {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/bad_engine.verify.cpp index 5ad27576e980..5b2f44737f35 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/bad_engine.verify.cpp @@ -26,6 +26,6 @@ void test(std::uniform_int_distribution<int> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/bad_engine.verify.cpp b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/bad_engine.verify.cpp index 38f91f9267cd..5c9feba1036e 100644 --- a/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/bad_engine.verify.cpp +++ b/libcxx/test/libcxx/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/bad_engine.verify.cpp @@ -25,6 +25,6 @@ void test(std::uniform_real_distribution<double> dist) G<int> badg; G<unsigned> okg; - dist(badg); //expected-error@*:* {{static_assert failed}} //expected-note {{in instantiation}} + dist(badg); //expected-error-re@*:* {{{{(static_assert|static assertion)}} failed}} //expected-note {{in instantiation}} dist(okg); } diff --git a/libcxx/test/libcxx/utilities/memory/util.smartptr/util.smartptr.shared/function_type_default_deleter.fail.cpp b/libcxx/test/libcxx/utilities/memory/util.smartptr/util.smartptr.shared/function_type_default_deleter.fail.cpp index 44824c3c140c..68ac9e3fc500 100644 --- a/libcxx/test/libcxx/utilities/memory/util.smartptr/util.smartptr.shared/function_type_default_deleter.fail.cpp +++ b/libcxx/test/libcxx/utilities/memory/util.smartptr/util.smartptr.shared/function_type_default_deleter.fail.cpp @@ -45,7 +45,7 @@ int main(int, char**) { SPtr<3> s3(nullptr, Deleter{}); // OK } - // expected-error-re@*:* {{static_assert failed{{.*}}default_delete cannot be instantiated for function types}} + // expected-error-re@*:* {{{{(static_assert|static assertion)}} failed{{.*}}default_delete cannot be instantiated for function types}} std::default_delete<FnType<5>> deleter{}; // expected-note {{requested here}} return 0; diff --git a/libcxx/test/libcxx/utilities/utility/pairs/pairs.pair/pair.tuple_element.fail.cpp b/libcxx/test/libcxx/utilities/utility/pairs/pairs.pair/pair.tuple_element.fail.cpp index 5e7b99b8fa16..40e57df50895 100644 --- a/libcxx/test/libcxx/utilities/utility/pairs/pairs.pair/pair.tuple_element.fail.cpp +++ b/libcxx/test/libcxx/utilities/utility/pairs/pairs.pair/pair.tuple_element.fail.cpp @@ -19,7 +19,7 @@ int main(int, char**) { typedef std::pair<int, double> P; std::tuple_element<2, P>::type foo; // expected-note {{requested here}} - // expected-error-re@*:* {{static_assert failed{{( due to requirement '2U[L]{0,2} < 2')?}}{{.*}}Index out of bounds in std::tuple_element<std::pair<T1, T2>>}} + // expected-error-re@*:* {{{{(static_assert|static assertion)}} failed{{( due to requirement '2U[L]{0,2} < 2')?}}{{.*}}Index out of bounds in std::tuple_element<std::pair<T1, T2>>}} } return 0; diff --git a/libcxx/test/libcxx/utilities/variant/variant.variant/variant.helper/variant_alternative.fail.cpp b/libcxx/test/libcxx/utilities/variant/variant.variant/variant.helper/variant_alternative.fail.cpp index 5473e65d9094..1e8037e0abbf 100644 --- a/libcxx/test/libcxx/utilities/variant/variant.variant/variant.helper/variant_alternative.fail.cpp +++ b/libcxx/test/libcxx/utilities/variant/variant.variant/variant.helper/variant_alternative.fail.cpp @@ -30,7 +30,7 @@ int main(int, char**) { typedef std::variant<int, double> T; std::variant_alternative<2, T>::type foo; // expected-note {{requested here}} - // expected-error-re@variant:* {{static_assert failed{{( due to requirement '2U[L]{0,2} < sizeof...\(_Types\)')?}}{{.*}}Index out of bounds in std::variant_alternative<>}} + // expected-error-re@variant:* {{{{(static_assert|static assertion)}} failed{{( due to requirement '2U[L]{0,2} < sizeof...\(_Types\)')?}}{{.*}}Index out of bounds in std::variant_alternative<>}} } return 0; diff --git a/libcxx/test/std/algorithms/alg.modifying.operations/alg.random.sample/sample.fail.cpp b/libcxx/test/std/algorithms/alg.modifying.operations/alg.random.sample/sample.fail.cpp index 3e21576afc85..992a3e988699 100644 --- a/libcxx/test/std/algorithms/alg.modifying.operations/alg.random.sample/sample.fail.cpp +++ b/libcxx/test/std/algorithms/alg.modifying.operations/alg.random.sample/sample.fail.cpp @@ -33,7 +33,7 @@ template <class PopulationIterator, class SampleIterator> void test() { } int main(int, char**) { - // expected-error-re@*:* {{static_assert failed{{( due to requirement '.*')?}}{{.*}}SampleIterator must meet the requirements of RandomAccessIterator}} + // expected-error-re@*:* {{{{(static_assert|static assertion)}} failed{{( due to requirement '.*')?}}{{.*}}SampleIterator must meet the requirements of RandomAccessIterator}} // expected-error@*:* 2 {{does not provide a subscript operator}} // expected-error@*:* {{invalid operands}} test<cpp17_input_iterator<int *>, cpp17_output_iterator<int *> >(); diff --git a/libcxx/test/std/containers/associative/map/map.cons/deduct.fail.cpp b/libcxx/test/std/containers/associative/map/map.cons/deduct.fail.cpp index ab77167c3741..0c0d21b28bf6 100644 --- a/libcxx/test/std/containers/associative/map/map.cons/deduct.fail.cpp +++ b/libcxx/test/std/containers/associative/map/map.cons/deduct.fail.cpp @@ -63,7 +63,7 @@ int main(int, char**) // refuse to rebind the allocator if Allocator::value_type is not exactly what we expect const P arr[] = { {1,1L}, {2,2L}, {3,3L} }; std::map m(arr, arr + 3, std::allocator<P>()); - // expected-error-re@map:* {{static_assert failed{{( due to requirement '.*')?}}{{.*}}Allocator::value_type must be same type as value_type}} + // expected-error-re@map:* {{{{(static_assert|static assertion)}} failed{{( due to requirement '.*')?}}{{.*}}Allocator::value_type must be same type as value_type}} } { // cannot convert from some arbitrary unrelated type diff --git a/libcxx/test/std/containers/associative/multimap/multimap.cons/deduct.fail.cpp b/libcxx/test/std/containers/associative/multimap/multimap.cons/deduct.fail.cpp index 47d32d7e1f4c..383403399640 100644 --- a/libcxx/test/std/containers/associative/multimap/multimap.cons/deduct.fail.cpp +++ b/libcxx/test/std/containers/associative/multimap/multimap.cons/deduct.fail.cpp @@ -63,7 +63,7 @@ int main(int, char**) // refuse to rebind the allocator if Allocator::value_type is not exactly what we expect const P arr[] = { {1,1L}, {2,2L}, {3,3L} }; std::multimap m(arr, arr + 3, std::allocator<P>()); - // expected-error-re@map:* {{static_assert failed{{( due to requirement '.*')?}}{{.*}}Allocator::value_type must be same type as value_type}} + // expected-error-re@map:* {{{{(static_assert|static assertion)}} failed{{( due to requirement '.*')?}}{{.*}}Allocator::value_type must be same type as value_type}} } { // cannot convert from some arbitrary unrelated type diff --git a/libcxx/test/std/containers/sequences/array/array.fill/fill.fail.cpp b/libcxx/test/std/containers/sequences/array/array.fill/fill.fail.cpp index 9aea551dc653..21ea6f899c3a 100644 --- a/libcxx/test/std/containers/sequences/array/array.fill/fill.fail.cpp +++ b/libcxx/test/std/containers/sequences/array/array.fill/fill.fail.cpp @@ -18,7 +18,7 @@ int main(int, char**) { typedef double T; typedef std::array<const T, 0> C; C c = {}; - // expected-error-re@array:* {{static_assert failed{{.*}}cannot fill zero-sized array of type 'const T'}} + // expected-error-re@array:* {{{{(static_assert|static assertion)}} failed{{.*}}cannot fill zero-sized array of type 'const T'}} c.fill(5.5); // expected-note {{requested here}} } diff --git a/libcxx/test/std/containers/sequences/array/array.swap/swap.fail.cpp b/libcxx/test/std/containers/sequences/array/array.swap/swap.fail.cpp index d7726164d4b2..6b17887a4003 100644 --- a/libcxx/test/std/containers/sequences/array/array.swap/swap.fail.cpp +++ b/libcxx/test/std/containers/sequences/array/array.swap/swap.fail.cpp @@ -19,7 +19,7 @@ int main(int, char**) { typedef std::array<const T, 0> C; C c = {}; C c2 = {}; - // expected-error-re@array:* {{static_assert failed{{.*}}cannot swap zero-sized array of type 'const T'}} + // expected-error-re@array:* {{{{(static_assert|static assertion)}} failed{{.*}}cannot swap zero-sized array of type 'const T'}} c.swap(c2); // expected-note {{requested here}} } diff --git a/libcxx/test/std/containers/sequences/array/array.tuple/get.fail.cpp b/libcxx/test/std/containers/sequences/array/array.tuple/get.fail.cpp index cd74522c92ce..2e1071550a51 100644 --- a/libcxx/test/std/containers/sequences/array/array.tuple/get.fail.cpp +++ b/libcxx/test/std/containers/sequences/array/array.tuple/get.fail.cpp @@ -25,7 +25,7 @@ int main(int, char**) typedef std::array<T, 3> C; C c = {1, 2, 3.5}; std::get<3>(c) = 5.5; // expected-note {{requested here}} - // expected-error-re@array:* {{static_assert failed{{( due to requirement '3U[L]{0,2} < 3U[L]{0,2}')?}}{{.*}}Index out of bounds in std::get<> (std::array)}} + // expected-error-re@array:* {{{{(static_assert|static assertion)}} failed{{( due to requirement '3U[L]{0,2} < 3U[L]{0,2}')?}}{{.*}}Index out of bounds in std::get<> (std::array)}} } return 0; diff --git a/libcxx/test/std/containers/sequences/array/array.tuple/tuple_element.fail.cpp b/libcxx/test/std/containers/sequences/array/array.tuple/tuple_element.fail.cpp index 26360790bf4d..6010c893d699 100644 --- a/libcxx/test/std/containers/sequences/array/array.tuple/tuple_element.fail.cpp +++ b/libcxx/test/std/containers/sequences/array/array.tuple/tuple_element.fail.cpp @@ -19,7 +19,7 @@ int main(int, char**) typedef double T; typedef std::array<T, 3> C; std::tuple_element<3, C> foo; // expected-note {{requested here}} - // expected-error-re@array:* {{static_assert failed{{( due to requirement '3U[L]{0,2} < 3U[L]{0,2}')?}}{{.*}}Index out of bounds in std::tuple_element<> (std::array)}} + // expected-error-re@array:* {{{{(static_assert|static assertion)}} failed{{( due to requirement '3U[L]{0,2} < 3U[L]{0,2}')?}}{{.*}}Index out of bounds in std::tuple_element<> (std::array)}} } return 0; diff --git a/libcxx/test/std/experimental/language.support/support.coroutines/coroutine.handle/coroutine.handle.export/from_address.fail.cpp b/libcxx/test/std/experimental/language.support/support.coroutines/coroutine.handle/coroutine.handle.export/from_address.fail.cpp index 8a9a64ef1b41..d02ae2f3ee16 100644 --- a/libcxx/test/std/experimental/language.support/support.coroutines/coroutine.handle/coroutine.handle.export/from_address.fail.cpp +++ b/libcxx/test/std/experimental/language.support/support.coroutines/coroutine.handle/coroutine.handle.export/from_address.fail.cpp @@ -36,7 +36,7 @@ int main(int, char**) } { using H = coro::coroutine_handle<int>; - // expected-error-re@experimental/coroutine:* 1 {{static_assert failed{{.*}}coroutine_handle<promise_type>::from_address cannot be used with pointers to the coroutine's promise type; use 'from_promise' instead}} + // expected-error-re@experimental/coroutine:* 1 {{{{(static_assert|static assertion)}} failed{{.*}}coroutine_handle<promise_type>::from_address cannot be used with pointers to the coroutine's promise type; use 'from_promise' instead}} H::from_address((const char*)nullptr); // expected-note {{requested here}} // expected-error@experimental/coroutine:* 1 {{coroutine_handle<promise_type>::from_address cannot be called with non-void pointers}} H::from_address((int*)nullptr); // expected-note {{requested here}} diff --git a/libcxx/test/std/language.support/support.dynamic/ptr.launder/launder.types.fail.cpp b/libcxx/test/std/language.support/support.dynamic/ptr.launder/launder.types.fail.cpp index 396053c8d78b..2293c6b1c3b3 100644 --- a/libcxx/test/std/language.support/support.dynamic/ptr.launder/launder.types.fail.cpp +++ b/libcxx/test/std/language.support/support.dynamic/ptr.launder/launder.types.fail.cpp @@ -26,10 +26,10 @@ int main(int, char**) (void) std::launder(( void *) nullptr); (void) std::launder((const void *) nullptr); (void) std::launder(( volatile void *) nullptr); - (void) std::launder((const volatile void *) nullptr); // expected-error-re@new:* 4 {{static_assert failed{{.*}}can't launder cv-void}} + (void) std::launder((const volatile void *) nullptr); // expected-error-re@new:* 4 {{{{(static_assert|static assertion)}} failed{{.*}}can't launder cv-void}} // expected-error@new:* 0-4 {{void pointer argument to '__builtin_launder' is not allowed}} - (void) std::launder(foo); // expected-error-re@new:* 1 {{static_assert failed{{.*}}can't launder functions}} + (void) std::launder(foo); // expected-error-re@new:* 1 {{{{(static_assert|static assertion)}} failed{{.*}}can't launder functions}} // expected-error@new:* 0-1 {{function pointer argument to '__builtin_launder' is not allowed}} return 0; diff --git a/libcxx/test/std/numerics/bit/bit.pow.two/bit_ceil.fail.cpp b/libcxx/test/std/numerics/bit/bit.pow.two/bit_ceil.fail.cpp index ff6f29e8817f..ba586ba92b22 100644 --- a/libcxx/test/std/numerics/bit/bit.pow.two/bit_ceil.fail.cpp +++ b/libcxx/test/std/numerics/bit/bit.pow.two/bit_ceil.fail.cpp @@ -34,19 +34,19 @@ constexpr bool toobig() int main(int, char**) { // Make sure we generate a compile-time error for UB - static_assert(toobig<unsigned char>(), ""); // expected-error {{static_assert expression is not an integral constant expression}} - static_assert(toobig<unsigned short>(), ""); // expected-error {{static_assert expression is not an integral constant expression}} - static_assert(toobig<unsigned>(), ""); // expected-error {{static_assert expression is not an integral constant expression}} - static_assert(toobig<unsigned long>(), ""); // expected-error {{static_assert expression is not an integral constant expression}} - static_assert(toobig<unsigned long long>(), ""); // expected-error {{static_assert expression is not an integral constant expression}} - - static_assert(toobig<uint8_t>(), ""); // expected-error {{static_assert expression is not an integral constant expression}} - static_assert(toobig<uint16_t>(), ""); // expected-error {{static_assert expression is not an integral constant expression}} - static_assert(toobig<uint32_t>(), ""); // expected-error {{static_assert expression is not an integral constant expression}} - static_assert(toobig<uint64_t>(), ""); // expected-error {{static_assert expression is not an integral constant expression}} - static_assert(toobig<size_t>(), ""); // expected-error {{static_assert expression is not an integral constant expression}} - static_assert(toobig<uintmax_t>(), ""); // expected-error {{static_assert expression is not an integral constant expression}} - static_assert(toobig<uintptr_t>(), ""); // expected-error {{static_assert expression is not an integral constant expression}} + static_assert(toobig<unsigned char>(), ""); // expected-error-re {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} + static_assert(toobig<unsigned short>(), ""); // expected-error-re {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} + static_assert(toobig<unsigned>(), ""); // expected-error-re {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} + static_assert(toobig<unsigned long>(), ""); // expected-error-re {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} + static_assert(toobig<unsigned long long>(), ""); // expected-error-re {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} + + static_assert(toobig<uint8_t>(), ""); // expected-error-re {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} + static_assert(toobig<uint16_t>(), ""); // expected-error-re {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} + static_assert(toobig<uint32_t>(), ""); // expected-error-re {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} + static_assert(toobig<uint64_t>(), ""); // expected-error-re {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} + static_assert(toobig<size_t>(), ""); // expected-error-re {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} + static_assert(toobig<uintmax_t>(), ""); // expected-error-re {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} + static_assert(toobig<uintptr_t>(), ""); // expected-error-re {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} return 0; } diff --git a/libcxx/test/std/numerics/numbers/illformed.verify.cpp b/libcxx/test/std/numerics/numbers/illformed.verify.cpp index 85e8f2dcb7cd..213f98cff952 100644 --- a/libcxx/test/std/numerics/numbers/illformed.verify.cpp +++ b/libcxx/test/std/numerics/numbers/illformed.verify.cpp @@ -12,7 +12,7 @@ // Initializing the primary template is ill-formed. int log2e{std::numbers::log2e_v< - int>}; // expected-error-re@numbers:* {{static_assert failed{{.*}}A program that instantiates a primary template of a mathematical constant variable template is ill-formed.}} + int>}; // expected-error-re@numbers:* {{{{(static_assert|static assertion)}} failed{{.*}}A program that instantiates a primary template of a mathematical constant variable template is ill-formed.}} int log10e{std::numbers::log10e_v<int>}; int pi{std::numbers::pi_v<int>}; int inv_pi{std::numbers::inv_pi_v<int>}; diff --git a/libcxx/test/std/numerics/rand/rand.eng/rand.eng.lcong/params.fail.cpp b/libcxx/test/std/numerics/rand/rand.eng/rand.eng.lcong/params.fail.cpp index c8df9927b072..4eebedbe61ca 100644 --- a/libcxx/test/std/numerics/rand/rand.eng/rand.eng.lcong/params.fail.cpp +++ b/libcxx/test/std/numerics/rand/rand.eng/rand.eng.lcong/params.fail.cpp @@ -19,12 +19,12 @@ int main(int, char**) { typedef unsigned long long T; - // expected-error-re@*:* {{static_assert failed due to requirement '1ULL == 0 || 1ULL < 1ULL'{{.*}}linear_congruential_engine invalid parameters}} + // expected-error-re@*:* {{{{(static_assert|static assertion)}} failed due to requirement '1ULL == 0 || 1ULL < 1ULL'{{.*}}linear_congruential_engine invalid parameters}} std::linear_congruential_engine<T, 0, 0, 0> e2; - // expected-error-re@*:* {{static_assert failed due to requirement '1ULL == 0 || 1ULL < 1ULL'{{.*}}linear_congruential_engine invalid parameters}} + // expected-error-re@*:* {{{{(static_assert|static assertion)}} failed due to requirement '1ULL == 0 || 1ULL < 1ULL'{{.*}}linear_congruential_engine invalid parameters}} std::linear_congruential_engine<T, 0, 1, 1> e3; std::linear_congruential_engine<T, 1, 0, 1> e4; - // expected-error-re@*:* {{static_assert failed due to requirement 'is_unsigned<int>::value'{{.*}}_UIntType must be unsigned type}} + // expected-error-re@*:* {{{{(static_assert|static assertion)}} failed due to requirement 'is_unsigned<int>::value'{{.*}}_UIntType must be unsigned type}} std::linear_congruential_engine<int, 0, 0, 0> e5; return 0; diff --git a/libcxx/test/std/strings/basic.string/char.bad.verify.cpp b/libcxx/test/std/strings/basic.string/char.bad.verify.cpp index a3ab207f420a..a93fdc7c8e65 100644 --- a/libcxx/test/std/strings/basic.string/char.bad.verify.cpp +++ b/libcxx/test/std/strings/basic.string/char.bad.verify.cpp @@ -32,20 +32,20 @@ void f() { typedef char C[3]; static_assert(std::is_array<C>::value, ""); std::basic_string<C, test_traits<C> > s; - // expected-error-re@string:* {{static_assert failed{{.*}}Character type of basic_string must not be an array}} + // expected-error-re@string:* {{{{(static_assert|static assertion)}} failed{{.*}}Character type of basic_string must not be an array}} } { // not trivial static_assert(!std::is_trivial<NotTrivial>::value, ""); std::basic_string<NotTrivial, test_traits<NotTrivial> > s; - // expected-error-re@string:* {{static_assert failed{{.*}}Character type of basic_string must be trivial}} + // expected-error-re@string:* {{{{(static_assert|static assertion)}} failed{{.*}}Character type of basic_string must be trivial}} } { // not standard layout static_assert(!std::is_standard_layout<NotStandardLayout>::value, ""); std::basic_string<NotStandardLayout, test_traits<NotStandardLayout> > s; - // expected-error-re@string:* {{static_assert failed{{.*}}Character type of basic_string must be standard-layout}} + // expected-error-re@string:* {{{{(static_assert|static assertion)}} failed{{.*}}Character type of basic_string must be standard-layout}} } } diff --git a/libcxx/test/std/strings/string.view/char.bad.fail.cpp b/libcxx/test/std/strings/string.view/char.bad.fail.cpp index d8b8878b19d7..b1794bc30374 100644 --- a/libcxx/test/std/strings/string.view/char.bad.fail.cpp +++ b/libcxx/test/std/strings/string.view/char.bad.fail.cpp @@ -35,21 +35,21 @@ int main(int, char**) typedef char C[3]; static_assert(std::is_array<C>::value, ""); std::basic_string_view<C, test_traits<C> > sv; -// expected-error-re@string_view:* {{static_assert failed{{.*}}Character type of basic_string_view must not be an array}} +// expected-error-re@string_view:* {{{{(static_assert|static assertion)}} failed{{.*}}Character type of basic_string_view must not be an array}} } { // not trivial static_assert(!std::is_trivial<NotTrivial>::value, ""); std::basic_string_view<NotTrivial, test_traits<NotTrivial> > sv; -// expected-error-re@string_view:* {{static_assert failed{{.*}}Character type of basic_string_view must be trivial}} +// expected-error-re@string_view:* {{{{(static_assert|static assertion)}} failed{{.*}}Character type of basic_string_view must be trivial}} } { // not standard layout static_assert(!std::is_standard_layout<NotStandardLayout>::value, ""); std::basic_string_view<NotStandardLayout, test_traits<NotStandardLayout> > sv; -// expected-error-re@string_view:* {{static_assert failed{{.*}}Character type of basic_string_view must be standard-layout}} +// expected-error-re@string_view:* {{{{(static_assert|static assertion)}} failed{{.*}}Character type of basic_string_view must be standard-layout}} } return 0; diff --git a/libcxx/test/std/time/time.hms/hhmmss.fail.cpp b/libcxx/test/std/time/time.hms/hhmmss.fail.cpp index c9d4788d7ad3..d900abad5c12 100644 --- a/libcxx/test/std/time/time.hms/hhmmss.fail.cpp +++ b/libcxx/test/std/time/time.hms/hhmmss.fail.cpp @@ -21,10 +21,10 @@ struct A {}; int main(int, char**) { - std::chrono::hh_mm_ss<void> h0; // expected-error-re@*:* {{static_assert failed{{.*}}template parameter of hh_mm_ss must be a std::chrono::duration}} - std::chrono::hh_mm_ss<int> h1; // expected-error-re@*:* {{static_assert failed{{.*}}template parameter of hh_mm_ss must be a std::chrono::duration}} - std::chrono::hh_mm_ss<std::string> h2; // expected-error-re@*:* {{static_assert failed{{.*}}template parameter of hh_mm_ss must be a std::chrono::duration}} - std::chrono::hh_mm_ss<A> h3; // expected-error-re@*:* {{static_assert failed{{.*}}template parameter of hh_mm_ss must be a std::chrono::duration}} + std::chrono::hh_mm_ss<void> h0; // expected-error-re@*:* {{{{(static_assert|static assertion)}} failed{{.*}}template parameter of hh_mm_ss must be a std::chrono::duration}} + std::chrono::hh_mm_ss<int> h1; // expected-error-re@*:* {{{{(static_assert|static assertion)}} failed{{.*}}template parameter of hh_mm_ss must be a std::chrono::duration}} + std::chrono::hh_mm_ss<std::string> h2; // expected-error-re@*:* {{{{(static_assert|static assertion)}} failed{{.*}}template parameter of hh_mm_ss must be a std::chrono::duration}} + std::chrono::hh_mm_ss<A> h3; // expected-error-re@*:* {{{{(static_assert|static assertion)}} failed{{.*}}template parameter of hh_mm_ss must be a std::chrono::duration}} return 0; } diff --git a/libcxx/test/std/utilities/any/any.nonmembers/any.cast/any_cast_request_invalid_value_category.fail.cpp b/libcxx/test/std/utilities/any/any.nonmembers/any.cast/any_cast_request_invalid_value_category.fail.cpp index aa56b6d9cf25..2dc8bd2e9517 100644 --- a/libcxx/test/std/utilities/any/any.nonmembers/any.cast/any_cast_request_invalid_value_category.fail.cpp +++ b/libcxx/test/std/utilities/any/any.nonmembers/any.cast/any_cast_request_invalid_value_category.fail.cpp @@ -25,12 +25,12 @@ struct TestType {}; void test_const_lvalue_cast_request_non_const_lvalue() { const std::any a; - // expected-error-re@any:* {{static_assert failed{{.*}}ValueType is required to be a const lvalue reference or a CopyConstructible type}} + // expected-error-re@any:* {{{{(static_assert|static assertion)}} failed{{.*}}ValueType is required to be a const lvalue reference or a CopyConstructible type}} // expected-error@any:* {{drops 'const' qualifier}} std::any_cast<TestType &>(a); // expected-note {{requested here}} const std::any a2(42); - // expected-error-re@any:* {{static_assert failed{{.*}}ValueType is required to be a const lvalue reference or a CopyConstructible type}} + // expected-error-re@any:* {{{{(static_assert|static assertion)}} failed{{.*}}ValueType is required to be a const lvalue reference or a CopyConstructible type}} // expected-error@any:* {{drops 'const' qualifier}} std::any_cast<int&>(a2); // expected-note {{requested here}} } @@ -38,22 +38,22 @@ void test_const_lvalue_cast_request_non_const_lvalue() void test_lvalue_any_cast_request_rvalue() { std::any a; - // expected-error-re@any:* {{static_assert failed{{.*}}ValueType is required to be an lvalue reference or a CopyConstructible type}} + // expected-error-re@any:* {{{{(static_assert|static assertion)}} failed{{.*}}ValueType is required to be an lvalue reference or a CopyConstructible type}} std::any_cast<TestType &&>(a); // expected-note {{requested here}} std::any a2(42); - // expected-error-re@any:* {{static_assert failed{{.*}}ValueType is required to be an lvalue reference or a CopyConstructible type}} + // expected-error-re@any:* {{{{(static_assert|static assertion)}} failed{{.*}}ValueType is required to be an lvalue reference or a CopyConstructible type}} std::any_cast<int&&>(a2); // expected-note {{requested here}} } void test_rvalue_any_cast_request_lvalue() { std::any a; - // expected-error-re@any:* {{static_assert failed{{.*}}ValueType is required to be an rvalue reference or a CopyConstructible type}} + // expected-error-re@any:* {{{{(static_assert|static assertion)}} failed{{.*}}ValueType is required to be an rvalue reference or a CopyConstructible type}} // expected-error@any:* {{non-const lvalue reference to type 'TestType' cannot bind to a temporary}} std::any_cast<TestType &>(std::move(a)); // expected-note {{requested here}} - // expected-error-re@any:* {{static_assert failed{{.*}}ValueType is required to be an rvalue reference or a CopyConstructible type}} + // expected-error-re@any:* {{{{(static_assert|static assertion)}} failed{{.*}}ValueType is required to be an rvalue reference or a CopyConstructible type}} // expected-error@any:* {{non-const lvalue reference to type 'int' cannot bind to a temporary}} std::any_cast<int&>(42); } diff --git a/libcxx/test/std/utilities/any/any.nonmembers/any.cast/const_correctness.verify.cpp b/libcxx/test/std/utilities/any/any.nonmembers/any.cast/const_correctness.verify.cpp index 83fd47d95b51..a066c6af4998 100644 --- a/libcxx/test/std/utilities/any/any.nonmembers/any.cast/const_correctness.verify.cpp +++ b/libcxx/test/std/utilities/any/any.nonmembers/any.cast/const_correctness.verify.cpp @@ -34,16 +34,16 @@ int main(int, char**) { std::any a; - // expected-error-re@any:* {{static_assert failed{{.*}}ValueType is required to be a const lvalue reference or a CopyConstructible type}} + // expected-error-re@any:* {{{{(static_assert|static assertion)}} failed{{.*}}ValueType is required to be a const lvalue reference or a CopyConstructible type}} std::any_cast<TestType &>(static_cast<std::any const&>(a)); // expected-note {{requested here}} - // expected-error-re@any:* {{static_assert failed{{.*}}ValueType is required to be a const lvalue reference or a CopyConstructible type}} + // expected-error-re@any:* {{{{(static_assert|static assertion)}} failed{{.*}}ValueType is required to be a const lvalue reference or a CopyConstructible type}} std::any_cast<TestType &&>(static_cast<std::any const&>(a)); // expected-note {{requested here}} - // expected-error-re@any:* {{static_assert failed{{.*}}ValueType is required to be a const lvalue reference or a CopyConstructible type}} + // expected-error-re@any:* {{{{(static_assert|static assertion)}} failed{{.*}}ValueType is required to be a const lvalue reference or a CopyConstructible type}} std::any_cast<TestType2 &>(static_cast<std::any const&&>(a)); // expected-note {{requested here}} - // expected-error-re@any:* {{static_assert failed{{.*}}ValueType is required to be a const lvalue reference or a CopyConstructible type}} + // expected-error-re@any:* {{{{(static_assert|static assertion)}} failed{{.*}}ValueType is required to be a const lvalue reference or a CopyConstructible type}} std::any_cast<TestType2 &&>(static_cast<std::any const&&>(a)); // expected-note {{requested here}} return 0; diff --git a/libcxx/test/std/utilities/any/any.nonmembers/any.cast/not_copy_constructible.verify.cpp b/libcxx/test/std/utilities/any/any.nonmembers/any.cast/not_copy_constructible.verify.cpp index c3cdfe7f9458..a3b3b3b6734e 100644 --- a/libcxx/test/std/utilities/any/any.nonmembers/any.cast/not_copy_constructible.verify.cpp +++ b/libcxx/test/std/utilities/any/any.nonmembers/any.cast/not_copy_constructible.verify.cpp @@ -48,15 +48,15 @@ struct no_move { int main(int, char**) { std::any a; - // expected-error-re@any:* {{static_assert failed{{.*}}ValueType is required to be an lvalue reference or a CopyConstructible type}} + // expected-error-re@any:* {{{{(static_assert|static assertion)}} failed{{.*}}ValueType is required to be an lvalue reference or a CopyConstructible type}} std::any_cast<no_copy>(static_cast<std::any&>(a)); // expected-note {{requested here}} - // expected-error-re@any:* {{static_assert failed{{.*}}ValueType is required to be a const lvalue reference or a CopyConstructible type}} + // expected-error-re@any:* {{{{(static_assert|static assertion)}} failed{{.*}}ValueType is required to be a const lvalue reference or a CopyConstructible type}} std::any_cast<no_copy>(static_cast<std::any const&>(a)); // expected-note {{requested here}} std::any_cast<no_copy>(static_cast<std::any &&>(a)); // OK - // expected-error-re@any:* {{static_assert failed{{.*}}ValueType is required to be an rvalue reference or a CopyConstructible type}} + // expected-error-re@any:* {{{{(static_assert|static assertion)}} failed{{.*}}ValueType is required to be an rvalue reference or a CopyConstructible type}} std::any_cast<no_move>(static_cast<std::any &&>(a)); return 0; diff --git a/libcxx/test/std/utilities/any/any.nonmembers/any.cast/reference_types.fail.cpp b/libcxx/test/std/utilities/any/any.nonmembers/any.cast/reference_types.fail.cpp index f362dd08645c..4b3ce4d3a23e 100644 --- a/libcxx/test/std/utilities/any/any.nonmembers/any.cast/reference_types.fail.cpp +++ b/libcxx/test/std/utilities/any/any.nonmembers/any.cast/reference_types.fail.cpp @@ -22,30 +22,30 @@ int main(int, char**) { std::any a = 1; - // expected-error-re@any:* 1 {{static_assert failed{{.*}}_ValueType may not be a reference.}} + // expected-error-re@any:* 1 {{{{(static_assert|static assertion)}} failed{{.*}}_ValueType may not be a reference.}} std::any_cast<int &>(&a); // expected-note {{requested here}} - // expected-error-re@any:* 1 {{static_assert failed{{.*}}_ValueType may not be a reference.}} + // expected-error-re@any:* 1 {{{{(static_assert|static assertion)}} failed{{.*}}_ValueType may not be a reference.}} std::any_cast<int &&>(&a); // expected-note {{requested here}} - // expected-error-re@any:* 1 {{static_assert failed{{.*}}_ValueType may not be a reference.}} + // expected-error-re@any:* 1 {{{{(static_assert|static assertion)}} failed{{.*}}_ValueType may not be a reference.}} std::any_cast<int const &>(&a); // expected-note {{requested here}} - // expected-error-re@any:* 1 {{static_assert failed{{.*}}_ValueType may not be a reference.}} + // expected-error-re@any:* 1 {{{{(static_assert|static assertion)}} failed{{.*}}_ValueType may not be a reference.}} std::any_cast<int const&&>(&a); // expected-note {{requested here}} const std::any& a2 = a; - // expected-error-re@any:* 1 {{static_assert failed{{.*}}_ValueType may not be a reference.}} + // expected-error-re@any:* 1 {{{{(static_assert|static assertion)}} failed{{.*}}_ValueType may not be a reference.}} std::any_cast<int &>(&a2); // expected-note {{requested here}} - // expected-error-re@any:* 1 {{static_assert failed{{.*}}_ValueType may not be a reference.}} + // expected-error-re@any:* 1 {{{{(static_assert|static assertion)}} failed{{.*}}_ValueType may not be a reference.}} std::any_cast<int &&>(&a2); // expected-note {{requested here}} - // expected-error-re@any:* 1 {{static_assert failed{{.*}}_ValueType may not be a reference.}} + // expected-error-re@any:* 1 {{{{(static_assert|static assertion)}} failed{{.*}}_ValueType may not be a reference.}} std::any_cast<int const &>(&a2); // expected-note {{requested here}} - // expected-error-re@any:* 1 {{static_assert failed{{.*}}_ValueType may not be a reference.}} + // expected-error-re@any:* 1 {{{{(static_assert|static assertion)}} failed{{.*}}_ValueType may not be a reference.}} std::any_cast<int const &&>(&a2); // expected-note {{requested here}} return 0; diff --git a/libcxx/test/std/utilities/format/format.formatter/format.parse.ctx/check_arg_id.verify.cpp b/libcxx/test/std/utilities/format/format.formatter/format.parse.ctx/check_arg_id.verify.cpp index 5ab74bed2728..74342c7d0fdb 100644 --- a/libcxx/test/std/utilities/format/format.formatter/format.parse.ctx/check_arg_id.verify.cpp +++ b/libcxx/test/std/utilities/format/format.formatter/format.parse.ctx/check_arg_id.verify.cpp @@ -25,7 +25,7 @@ constexpr bool test() { } int main(int, char**) { - // expected-error@+1 {{static_assert expression is not an integral constant expression}} + // expected-error-re@+1 {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} static_assert(test()); return 0; diff --git a/libcxx/test/std/utilities/function.objects/func.bind_front/bind_front.verify.cpp b/libcxx/test/std/utilities/function.objects/func.bind_front/bind_front.verify.cpp index 729045961e1c..f7d24998e09b 100644 --- a/libcxx/test/std/utilities/function.objects/func.bind_front/bind_front.verify.cpp +++ b/libcxx/test/std/utilities/function.objects/func.bind_front/bind_front.verify.cpp @@ -40,7 +40,7 @@ int main(int, char**) const int c = 1; auto p = std::bind_front(pass, c); - static_assert(p() == 1); // expected-error {{static_assert expression is not an integral constant expression}} + static_assert(p() == 1); // expected-error-re {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} auto d = std::bind_front(do_nothing, n); // expected-error {{no matching function for call to 'bind_front'}} diff --git a/libcxx/test/std/utilities/intseq/intseq.make/make_integer_seq.fail.cpp b/libcxx/test/std/utilities/intseq/intseq.make/make_integer_seq.fail.cpp index 1394ff0c9d62..8ba71238a5f4 100644 --- a/libcxx/test/std/utilities/intseq/intseq.make/make_integer_seq.fail.cpp +++ b/libcxx/test/std/utilities/intseq/intseq.make/make_integer_seq.fail.cpp @@ -31,7 +31,7 @@ int main(int, char**) #if TEST_HAS_BUILTIN(__make_integer_seq) && !defined(_LIBCPP_TESTING_FALLBACK_MAKE_INTEGER_SEQUENCE) MakeSeqT i; // expected-error@*:* {{integer sequences must have non-negative sequence length}} #else - MakeSeqT i; // expected-error@*:* {{static_assert failed{{.*}}std::make_integer_sequence must have a non-negative sequence length}} + MakeSeqT i; // expected-error-re@*:* {{{{(static_assert|static assertion)}} failed{{.*}}std::make_integer_sequence must have a non-negative sequence length}} #endif return 0; diff --git a/libcxx/test/std/utilities/memory/default.allocator/allocator.members/allocate.constexpr.size.verify.cpp b/libcxx/test/std/utilities/memory/default.allocator/allocator.members/allocate.constexpr.size.verify.cpp index f12b6808edeb..a083e2d88b97 100644 --- a/libcxx/test/std/utilities/memory/default.allocator/allocator.members/allocate.constexpr.size.verify.cpp +++ b/libcxx/test/std/utilities/memory/default.allocator/allocator.members/allocate.constexpr.size.verify.cpp @@ -34,7 +34,7 @@ constexpr bool test() int main(int, char**) { - static_assert(test<double>()); // expected-error {{static_assert expression is not an integral constant expression}} - LIBCPP_STATIC_ASSERT(test<const double>()); // expected-error {{static_assert expression is not an integral constant expression}} + static_assert(test<double>()); // expected-error-re {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} + LIBCPP_STATIC_ASSERT(test<const double>()); // expected-error-re {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} return 0; } diff --git a/libcxx/test/std/utilities/meta/meta.const.eval/is_constant_evaluated.fail.cpp b/libcxx/test/std/utilities/meta/meta.const.eval/is_constant_evaluated.fail.cpp index 8b995a1784ef..f4865ff36807 100644 --- a/libcxx/test/std/utilities/meta/meta.const.eval/is_constant_evaluated.fail.cpp +++ b/libcxx/test/std/utilities/meta/meta.const.eval/is_constant_evaluated.fail.cpp @@ -22,7 +22,7 @@ int main(int, char**) // expected-error@+1 {{no member named 'is_constant_evaluated' in namespace 'std'}} bool b = std::is_constant_evaluated(); #else - // expected-error@+1 {{static_assert failed}} + // expected-error-re@+1 {{{{(static_assert|static assertion)}} failed}} static_assert(!std::is_constant_evaluated(), ""); // expected-warning@-1 0-1 {{'std::is_constant_evaluated' will always evaluate to 'true' in a manifestly constant-evaluated expression}} #endif diff --git a/libcxx/test/std/utilities/optional/optional.object/optional.object.ctor/ctor.fail.cpp b/libcxx/test/std/utilities/optional/optional.object/optional.object.ctor/ctor.fail.cpp index bb2483ecd2ca..b3230d460232 100644 --- a/libcxx/test/std/utilities/optional/optional.object/optional.object.ctor/ctor.fail.cpp +++ b/libcxx/test/std/utilities/optional/optional.object/optional.object.ctor/ctor.fail.cpp @@ -24,23 +24,23 @@ struct NonDestructible { ~NonDestructible() = delete; }; int main(int, char**) { { - std::optional<char &> o1; // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with a reference type is ill-formed}} - std::optional<NonDestructible> o2; // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with a non-destructible type is ill-formed}} - std::optional<char[20]> o3; // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with an array type is ill-formed}} + std::optional<char &> o1; // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with a reference type is ill-formed}} + std::optional<NonDestructible> o2; // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with a non-destructible type is ill-formed}} + std::optional<char[20]> o3; // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with an array type is ill-formed}} } { - std::optional< std::in_place_t> o1; // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with in_place_t is ill-formed}} - std::optional<const std::in_place_t> o2; // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with in_place_t is ill-formed}} - std::optional< volatile std::in_place_t> o3; // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with in_place_t is ill-formed}} - std::optional<const volatile std::in_place_t> o4; // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with in_place_t is ill-formed}} + std::optional< std::in_place_t> o1; // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with in_place_t is ill-formed}} + std::optional<const std::in_place_t> o2; // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with in_place_t is ill-formed}} + std::optional< volatile std::in_place_t> o3; // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with in_place_t is ill-formed}} + std::optional<const volatile std::in_place_t> o4; // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with in_place_t is ill-formed}} } { - std::optional< std::nullopt_t> o1; // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with nullopt_t is ill-formed}} - std::optional<const std::nullopt_t> o2; // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with nullopt_t is ill-formed}} - std::optional< volatile std::nullopt_t> o3; // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with nullopt_t is ill-formed}} - std::optional<const volatile std::nullopt_t> o4; // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with nullopt_t is ill-formed}} + std::optional< std::nullopt_t> o1; // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with nullopt_t is ill-formed}} + std::optional<const std::nullopt_t> o2; // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with nullopt_t is ill-formed}} + std::optional< volatile std::nullopt_t> o3; // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with nullopt_t is ill-formed}} + std::optional<const volatile std::nullopt_t> o4; // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with nullopt_t is ill-formed}} } return 0; diff --git a/libcxx/test/std/utilities/optional/optional.object/optional.object.ctor/deduct.fail.cpp b/libcxx/test/std/utilities/optional/optional.object/optional.object.ctor/deduct.fail.cpp index 9b28b766be44..cd4c1bebf6b2 100644 --- a/libcxx/test/std/utilities/optional/optional.object/optional.object.ctor/deduct.fail.cpp +++ b/libcxx/test/std/utilities/optional/optional.object/optional.object.ctor/deduct.fail.cpp @@ -30,7 +30,7 @@ int main(int, char**) { // optional(nullopt_t) - std::optional opt(std::nullopt); // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with nullopt_t is ill-formed}} + std::optional opt(std::nullopt); // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with nullopt_t is ill-formed}} } return 0; diff --git a/libcxx/test/std/utilities/optional/optional.object/optional.object.ctor/move.fail.cpp b/libcxx/test/std/utilities/optional/optional.object/optional.object.ctor/move.fail.cpp index e6b48b53b218..4df41120d7e3 100644 --- a/libcxx/test/std/utilities/optional/optional.object/optional.object.ctor/move.fail.cpp +++ b/libcxx/test/std/utilities/optional/optional.object/optional.object.ctor/move.fail.cpp @@ -48,6 +48,6 @@ constexpr bool test() // expected-error {{constexpr function never produces a co int main(int, char**) { static_assert (!std::is_trivially_move_constructible_v<S>, "" ); - static_assert (test(), ""); // expected-error {{static_assert expression is not an integral constant expression}} + static_assert (test(), ""); // expected-error-re {{{{(static_assert|static assertion)}} expression is not an integral constant expression}} return 0; } diff --git a/libcxx/test/std/utilities/optional/optional.object/optional_requires_destructible_object.fail.cpp b/libcxx/test/std/utilities/optional/optional.object/optional_requires_destructible_object.fail.cpp index 3149e5a900db..64e130caf839 100644 --- a/libcxx/test/std/utilities/optional/optional.object/optional_requires_destructible_object.fail.cpp +++ b/libcxx/test/std/utilities/optional/optional.object/optional_requires_destructible_object.fail.cpp @@ -25,22 +25,22 @@ int main(int, char**) { using std::optional; { - // expected-error-re@optional:* 2 {{static_assert failed{{.*}}instantiation of optional with a reference type is ill-formed}} + // expected-error-re@optional:* 2 {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with a reference type is ill-formed}} optional<int&> opt1; optional<int&&> opt2; } { - // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with a non-destructible type is ill-formed}} + // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with a non-destructible type is ill-formed}} optional<X> opt3; } { - // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with a non-object type is undefined behavior}} - // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with a non-destructible type is ill-formed}} + // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with a non-object type is undefined behavior}} + // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with a non-destructible type is ill-formed}} optional<void()> opt4; } { - // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with a non-object type is undefined behavior}} - // expected-error-re@optional:* {{static_assert failed{{.*}}instantiation of optional with a non-destructible type is ill-formed}} + // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with a non-object type is undefined behavior}} + // expected-error-re@optional:* {{{{(static_assert|static assertion)}} failed{{.*}}instantiation of optional with a non-destructible type is ill-formed}} // expected-error@optional:* 1+ {{cannot form a reference to 'void'}} optional<const void> opt4; } diff --git a/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.helper/tuple_element.fail.cpp b/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.helper/tuple_element.fail.cpp index 2599ec033cc7..2c297749f3b0 100644 --- a/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.helper/tuple_element.fail.cpp +++ b/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.helper/tuple_element.fail.cpp @@ -27,7 +27,7 @@ int main(int, char**) using E1 = typename std::tuple_element<1, T &>::type; // expected-error{{undefined template}} using E2 = typename std::tuple_element<3, T>::type; using E3 = typename std::tuple_element<4, T const>::type; - // expected-error@__tuple:* 2 {{static_assert failed}} + // expected-error-re@__tuple:* 2 {{{{(static_assert|static assertion)}} failed}} return 0; diff --git a/libcxx/test/std/utilities/utility/forward/forward.fail.cpp b/libcxx/test/std/utilities/utility/forward/forward.fail.cpp index 44ecddf74482..61a3e1834039 100644 --- a/libcxx/test/std/utilities/utility/forward/forward.fail.cpp +++ b/libcxx/test/std/utilities/utility/forward/forward.fail.cpp @@ -23,7 +23,7 @@ int main(int, char**) { { (void)std::forward<A&>(source()); // expected-note {{requested here}} - // expected-error-re@*:* 1 {{static_assert failed{{.*}}cannot forward an rvalue as an lvalue}} + // expected-error-re@*:* 1 {{{{(static_assert|static assertion)}} failed{{.*}}cannot forward an rvalue as an lvalue}} } { const A ca = A(); diff --git a/libcxx/test/std/utilities/variant/variant.relops/relops_bool_conv.fail.cpp b/libcxx/test/std/utilities/variant/variant.relops/relops_bool_conv.fail.cpp index eaf7e79b971e..ebc6020a484f 100644 --- a/libcxx/test/std/utilities/variant/variant.relops/relops_bool_conv.fail.cpp +++ b/libcxx/test/std/utilities/variant/variant.relops/relops_bool_conv.fail.cpp @@ -75,7 +75,7 @@ int main(int, char**) { using V = std::variant<int, ComparesToMyBoolExplicit>; V v1(42); V v2(101); - // expected-error-re@variant:* 6 {{static_assert failed{{.*}}the relational operator does not return a type which is implicitly convertible to bool}} + // expected-error-re@variant:* 6 {{{{(static_assert|static assertion)}} failed{{.*}}the relational operator does not return a type which is implicitly convertible to bool}} // expected-error@variant:* 6 {{no viable conversion}} (void)(v1 == v2); // expected-note {{here}} (void)(v1 != v2); // expected-note {{here}} diff --git a/libcxx/test/std/utilities/variant/variant.variant/variant_array.fail.cpp b/libcxx/test/std/utilities/variant/variant.variant/variant_array.fail.cpp index 0c531d0e0f84..39e2f9689915 100644 --- a/libcxx/test/std/utilities/variant/variant.variant/variant_array.fail.cpp +++ b/libcxx/test/std/utilities/variant/variant.variant/variant_array.fail.cpp @@ -24,7 +24,7 @@ int main(int, char**) { - // expected-error@variant:* 3 {{static_assert failed}} + // expected-error-re@variant:* 3 {{{{(static_assert|static assertion)}} failed}} std::variant<int, int[]> v; // expected-note {{requested here}} std::variant<int, int[42]> v2; // expected-note {{requested here}} std::variant<int, int[][42]> v3; // expected-note {{requested here}} diff --git a/libcxx/test/std/utilities/variant/variant.variant/variant_empty.fail.cpp b/libcxx/test/std/utilities/variant/variant.variant/variant_empty.fail.cpp index e57a6c8f38ae..863947975ea5 100644 --- a/libcxx/test/std/utilities/variant/variant.variant/variant_empty.fail.cpp +++ b/libcxx/test/std/utilities/variant/variant.variant/variant_empty.fail.cpp @@ -19,7 +19,7 @@ int main(int, char**) { - // expected-error@variant:* 1 {{static_assert failed}} + // expected-error-re@variant:* 1 {{{{(static_assert|static assertion)}} failed}} std::variant<> v; // expected-note {{requested here}} return 0; diff --git a/libcxx/test/std/utilities/variant/variant.variant/variant_reference.fail.cpp b/libcxx/test/std/utilities/variant/variant.variant/variant_reference.fail.cpp index 193db411ec70..84ff882c7a22 100644 --- a/libcxx/test/std/utilities/variant/variant.variant/variant_reference.fail.cpp +++ b/libcxx/test/std/utilities/variant/variant.variant/variant_reference.fail.cpp @@ -19,7 +19,7 @@ int main(int, char**) { - // expected-error@variant:* 3 {{static_assert failed}} + // expected-error-re@variant:* 3 {{{{(static_assert|static assertion)}} failed}} std::variant<int, int&> v; // expected-note {{requested here}} std::variant<int, const int &> v2; // expected-note {{requested here}} std::variant<int, int&&> v3; // expected-note {{requested here}} diff --git a/libcxx/test/std/utilities/variant/variant.variant/variant_void.fail.cpp b/libcxx/test/std/utilities/variant/variant.variant/variant_void.fail.cpp index ae7982069cd3..56c01a236a66 100644 --- a/libcxx/test/std/utilities/variant/variant.variant/variant_void.fail.cpp +++ b/libcxx/test/std/utilities/variant/variant.variant/variant_void.fail.cpp @@ -24,7 +24,7 @@ int main(int, char**) { - // expected-error@variant:* 3 {{static_assert failed}} + // expected-error-re@variant:* 3 {{{{(static_assert|static assertion)}} failed}} std::variant<int, void> v; // expected-note {{requested here}} std::variant<int, const void> v2; // expected-note {{requested here}} std::variant<const volatile void, int> v3; // expected-note {{requested here}} |