1 // { dg-do compile { target c++17 } }
2 // { dg-options "-fconcepts" }
3 
4 template<typename ... T>
5   concept bool C1 = true;
6 
7 template<int ... N>
8   concept bool C2 = true;
9 
10 template<typename T>
11   concept bool C3 = __is_class(T);
12 
13 template<typename ... T>
C4()14   concept bool C4() { return true; }
15 template<int N>
C4()16   concept bool C4() { return true; }
17 
18 template<typename T, typename U = int>
C5()19   concept bool C5() { return __is_class(U); }
20 
f1()21 C1{...A, B} void f1() {}; // { dg-error "no matching|wrong number" }
f2()22 C1{A} void f2() {} // { dg-error "cannot match pack|no matching concept" }
f3()23 C2{A, B} void f3() {}; // { dg-error "cannot match pack|no matching concept" }
f4()24 C3{...A} void f4() {}; // { dg-error "cannot match pack|no matching concept" }
f5()25 C4{A} void f5() {}; // { dg-error "no matching concept" }
f6()26 C5{A, B} void f6() {};
27 
main()28 int main()
29 {
30   // Defaults should not transfer
31   f6<int>(); // { dg-error "no matching" }
32   return 0;
33 }
34