[AArch64] Improve scheduling model for X-Gene
[official-gcc.git] / gcc / testsuite / g++.dg / concepts / req11.C
blob2d0c5c005d91582db8cdf393a035f3e074b7b344
1 // { dg-options "-std=c++17 -fconcepts" }
3 // Check that we can evaluate constant requires-expressions
4 // as constant expressions, for the curious case when they
5 // appear within predicate constraints.
7 template<typename... Ts> struct variant { };
9 template<typename T>
10 concept bool Streamable()
12   return requires (T t) { t; };
15 template<typename T>
16 concept bool Range()
18   return requires (T t) { t; };
21 template<class T>
22   requires Streamable<T>() and not Range<T>()
23 void print(const T& x) { }
25 int main()
27   print("hello"); // { dg-error "cannot call" }