From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2181) id 2FFA2385841C; Fri, 11 Nov 2022 05:29:49 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 2FFA2385841C DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1668144589; bh=3V/+Hnj8aqt5EW/S+970fqXbKHeBasnFkQt31zPnMUw=; h=From:To:Subject:Date:From; b=xnVi1GqHQenxBvC9cR6Gk20FG5FjhE7WAuLqiT7IZnaGu4Nn5+E8ycWx1uD8ge2LQ j/137TmuizEjbLJtd2zUYV9h2zKmIJDCe1+tfb35CE//iK5B5hj3GbbDGwFAiiQMHb T8arohL42MjPNy97ZyxWSda4jU8dl6qnwTpKJKMc= MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="utf-8" From: Jonathan Wakely To: gcc-cvs@gcc.gnu.org, libstdc++-cvs@gcc.gnu.org Subject: [gcc r13-3889] libstdc++: Fix test that uses C++17 variable template in C++14 X-Act-Checkin: gcc X-Git-Author: Jonathan Wakely X-Git-Refname: refs/heads/master X-Git-Oldrev: b3ac43a3c05744d62a963d656bed782fc867ad79 X-Git-Newrev: 56d2222c58be78d5125bd8a1069364f0f4b2baa2 Message-Id: <20221111052949.2FFA2385841C@sourceware.org> Date: Fri, 11 Nov 2022 05:29:49 +0000 (GMT) List-Id: https://gcc.gnu.org/g:56d2222c58be78d5125bd8a1069364f0f4b2baa2 commit r13-3889-g56d2222c58be78d5125bd8a1069364f0f4b2baa2 Author: Jonathan Wakely Date: Thu Nov 10 14:04:07 2022 +0000 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. Diff: --- .../testsuite/experimental/propagate_const/observers/107525.cc | 4 ++-- 1 file 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 e7ecff73c1a..37e970c3af4 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, + static_assert(!std::is_convertible::value, "Cannot convert const X to const int*"); // So should not be able to convert const propagate_const to const int*. - static_assert(!std::is_convertible_v, const int*>, + static_assert(!std::is_convertible, const int*>::value, "So should not be able to convert const propagate_const to " "const int* (although this is not what LFTSv3 says)"); }