diff options
author | Jonathan Wakely <jwakely@redhat.com> | 2022-11-10 14:04:07 +0000 |
---|---|---|
committer | Jonathan Wakely <jwakely@redhat.com> | 2022-11-11 04:00:58 +0000 |
commit | 56d2222c58be78d5125bd8a1069364f0f4b2baa2 (patch) | |
tree | 6cbce515301eed02ebdd67cbbd871d9e581e1d36 | |
parent | b3ac43a3c05744d62a963d656bed782fc867ad79 (diff) | |
download | gcc-56d2222c58be78d5125bd8a1069364f0f4b2baa2.zip gcc-56d2222c58be78d5125bd8a1069364f0f4b2baa2.tar.gz gcc-56d2222c58be78d5125bd8a1069364f0f4b2baa2.tar.bz2 |
libstdc++: Fix test that uses C++17 variable template in C++14
This test fails if run with -std=gnu++14 because it should be using
is_convertible instead of is_convertible_v.
libstdc++-v3/ChangeLog:
* testsuite/experimental/propagate_const/observers/107525.cc:
Use type trait instead of C++17 variable template.
-rw-r--r-- | libstdc++-v3/testsuite/experimental/propagate_const/observers/107525.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libstdc++-v3/testsuite/experimental/propagate_const/observers/107525.cc b/libstdc++-v3/testsuite/experimental/propagate_const/observers/107525.cc index e7ecff7..37e970c 100644 --- a/libstdc++-v3/testsuite/experimental/propagate_const/observers/107525.cc +++ b/libstdc++-v3/testsuite/experimental/propagate_const/observers/107525.cc @@ -32,10 +32,10 @@ test_const_conversion() operator const int*() const = delete; }; - static_assert(!std::is_convertible_v<const X, const int*>, + static_assert(!std::is_convertible<const X, const int*>::value, "Cannot convert const X to const int*"); // So should not be able to convert const propagate_const<X> to const int*. - static_assert(!std::is_convertible_v<const propagate_const<X>, const int*>, + static_assert(!std::is_convertible<const propagate_const<X>, const int*>::value, "So should not be able to convert const propagate_const<X> to " "const int* (although this is not what LFTSv3 says)"); } |