111
|
1 // { dg-options "-std=c++17 -fconcepts" }
|
|
2
|
|
3 template<typename T>
|
|
4 concept bool C1 = __is_same_as(T, int);
|
|
5
|
|
6 template<int N>
|
|
7 concept bool C2 = N == 0;
|
|
8
|
|
9 template<template<typename> class X>
|
|
10 concept bool C3 = true;
|
|
11
|
|
12 template<typename> struct Foo;
|
|
13
|
|
14 template<C1...> struct S1;
|
|
15 template<C1... Ts> struct S1 { };
|
|
16
|
|
17 template<C2...> struct S2;
|
|
18 template<C2... Ns> struct S2 { };
|
|
19
|
|
20 template<C3...> struct S3;
|
|
21 template<C3... Xs> struct S3 { };
|
|
22
|
|
23 S1<int, int, int> s1; // OK
|
|
24 S1<> s11;
|
|
25 S2<0, 0, 0> s2;
|
|
26 S2<> s22;
|
|
27 S3<Foo, Foo> s3;
|
|
28 S3<> s33;
|