diff gcc/testsuite/g++.dg/concepts/pr67595.C @ 145:1830386684a0

gcc-9.2.0
author anatofuz
date Thu, 13 Feb 2020 11:34:05 +0900
parents 84e7813d76e9
children
line wrap: on
line diff
--- a/gcc/testsuite/g++.dg/concepts/pr67595.C	Thu Oct 25 07:37:49 2018 +0900
+++ b/gcc/testsuite/g++.dg/concepts/pr67595.C	Thu Feb 13 11:34:05 2020 +0900
@@ -1,14 +1,14 @@
-// { dg-do compile { target c++17 } }
+// { dg-do compile { target c++17_only } }
 // { dg-options "-fconcepts" }
 
-template <class X> concept bool allocatable = requires{{new X}->X * };
+template <class X> concept bool allocatable = requires{{new X}->X *; };
 template <class X> concept bool semiregular = allocatable<X>;
-template <class X> concept bool readable = requires{requires semiregular<X>};
-template <class> int weak_input_iterator = requires{{0}->readable};
+template <class X> concept bool readable = requires{requires semiregular<X>;};
+template <class> int weak_input_iterator = requires{{0}->readable;};
 template <class X> bool input_iterator{weak_input_iterator<X>}; // { dg-warning "narrowing conversion" }
 template <class X> bool forward_iterator{input_iterator<X>};
 template <class X> bool bidirectional_iterator{forward_iterator<X>};
 template <class X>
-concept bool random_access_iterator{bidirectional_iterator<X>};
+concept bool random_access_iterator{bidirectional_iterator<X>}; // { dg-error "constant" }
 void fn1(random_access_iterator);
 int main() { fn1(0); }  // { dg-error "" }