1 // { dg-do compile { target c++17 } }
2 // { dg-options "-fconcepts" }
6 requires (T t) { t.f(); }; // { dg-message "in requirements" }
10 requires { typename T::type; }; // { dg-message "in requirements" }
20 // Note that these declarations are private and therefore
21 // cannot satisfy the constraints.
30 f1(s); // { dg-error "no match" }
31 f2(s); // { dg-error "" }
33 // When used in non-SFINAE contexts, make sure that we fail
34 // the constraint check before emitting the access check
35 // failures. The context is being presented consistently
37 static_assert(C1<S>, ""); // { dg-error "failed" }
38 static_assert(C2<S>, ""); // { dg-error "" }