From: Eric Fiselier Date: Fri, 14 Dec 2018 20:42:36 +0000 (+0000) Subject: Tolerate Clangs new static_assert messages X-Git-Tag: llvmorg-8.0.0-rc1~2072 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3e5d847fa02f63d0026a6771be613e464530bb6f;p=platform%2Fupstream%2Fllvm.git Tolerate Clangs new static_assert messages llvm-svn: 349189 --- 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 2a92240..2a25780 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 @@ -20,6 +20,6 @@ int main() { typedef std::pair P; std::tuple_element<2, P>::type foo; // expected-note {{requested here}} - // expected-error@utility:* {{static_assert failed "Index out of bounds in std::tuple_element>"}} + // expected-error-re@utility:* {{static_assert failed{{( due to requirement '2UL < 2')?}} "Index out of bounds in std::tuple_element>"}} } } 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 f39a445..2559048 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 @@ -31,6 +31,6 @@ int main() { typedef std::variant T; std::variant_alternative<2, T>::type foo; // expected-note {{requested here}} - // expected-error@variant:* {{static_assert failed "Index out of bounds in std::variant_alternative<>"}} + // expected-error-re@variant:* {{static_assert failed{{( due to requirement '2UL < sizeof...\(_Types\)')?}} "Index out of bounds in std::variant_alternative<>"}} } } 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 d769ad8..3d37d05 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 @@ -34,7 +34,7 @@ template void test() { } int main() { - // expected-error@algorithm:* {{static_assert failed "SampleIterator must meet the requirements of RandomAccessIterator"}} + // expected-error-re@algorithm:* {{static_assert failed{{( due to requirement '.*')?}} "SampleIterator must meet the requirements of RandomAccessIterator"}} // expected-error@algorithm:* 2 {{does not provide a subscript operator}} // expected-error@algorithm:* {{invalid operands}} test, output_iterator >(); 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 45e1d2b..d575b08 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 @@ -31,6 +31,6 @@ int main() typedef std::array C; C c = {1, 2, 3.5}; std::get<3>(c) = 5.5; // expected-note {{requested here}} - // expected-error@array:* {{static_assert failed "Index out of bounds in std::get<> (std::array)"}} + // expected-error-re@array:* {{static_assert failed{{( due to requirement '3UL < 3UL')?}} "Index out of bounds in std::get<> (std::array)"}} } } 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 c9fe695..dd29d12 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 @@ -30,6 +30,6 @@ int main() typedef double T; typedef std::array C; std::tuple_element<3, C> foo; // expected-note {{requested here}} - // expected-error@array:* {{static_assert failed "Index out of bounds in std::tuple_element<> (std::array)"}} + // expected-error-re@array:* {{static_assert failed{{( due to requirement '3UL < 3UL')?}} "Index out of bounds in std::tuple_element<> (std::array)"}} } } diff --git a/libcxx/test/std/containers/views/span.cons/default.fail.cpp b/libcxx/test/std/containers/views/span.cons/default.fail.cpp index e30425c..ef63a6e 100644 --- a/libcxx/test/std/containers/views/span.cons/default.fail.cpp +++ b/libcxx/test/std/containers/views/span.cons/default.fail.cpp @@ -25,7 +25,7 @@ int main () { - std::span s; // expected-error@span:* {{static_assert failed "Can't default construct a statically sized span with size > 0"}} + std::span s; // expected-error-re@span:* {{static_assert failed{{( due to requirement '2L == 0')?}} "Can't default construct a statically sized span with size > 0"}} // TODO: This is what I want: // eXpected-error {{no matching constructor for initialization of 'std::span'}}