1 // RUN: %clang_cc1 -std=c++20 -verify -fsyntax-only %s
5 concept C1
= true; // #C1
12 concept C2
= true; // #C2
14 auto V2
= true; // #V2
19 concept C3
= true; // #C3
21 auto V3
= true; // #V3
22 template <template <typename T
> typename C
>
23 constexpr bool test
= true;
25 static_assert(test
<a::C1
>); // expected-error {{too few template arguments for concept 'C1'}} \
26 // expected-note@#C1 {{here}}
27 static_assert(test
<a::b::C2
>); // expected-error {{too few template arguments for concept 'C2'}} \
28 // expected-note@#C2 {{here}}
29 static_assert(test
<C3
>); // expected-error {{too few template arguments for concept 'C3'}} \
30 // expected-note@#C3 {{here}}
32 static_assert(test
<a::V1
>); // expected-error {{use of variable template 'V1' requires template arguments}} \
33 // expected-note@#V1 {{here}}
34 static_assert(test
<a::b::V2
>); // expected-error {{use of variable template 'V2' requires template arguments}} \
35 // expected-note@#V2 {{here}}
36 static_assert(test
<V3
>); // expected-error {{use of variable template 'V3' requires template arguments}} \
37 // expected-note@#V3 {{here}}
41 C3 t1
= 0; // expected-error {{expected 'auto' or 'decltype(auto)' after concept name}}
42 a::C1 t2
= 0; // expected-error {{expected 'auto' or 'decltype(auto)' after concept name}}
43 a::b::C2 t3
= 0; // expected-error {{expected 'auto' or 'decltype(auto)' after concept name}}