Mercurial > hg > CbC > CbC_gcc
annotate gcc/testsuite/g++.dg/cpp2a/concepts-template-parm1.C @ 145:1830386684a0
gcc-9.2.0
author | anatofuz |
---|---|
date | Thu, 13 Feb 2020 11:34:05 +0900 |
parents | |
children |
rev | line source |
---|---|
145 | 1 // { dg-do compile { target c++2a } } |
2 | |
3 template<typename T> | |
4 concept Int = __is_same_as(T, int); | |
5 | |
6 // Type template parameters | |
7 template<Int T = int> struct S1 { }; | |
8 template<Int = int> struct S2; | |
9 template<Int T> struct S2 { }; | |
10 | |
11 // Non-type template parameters | |
12 template<Int auto N = 0> struct S3 { }; | |
13 template<Int auto = 0> struct S4; | |
14 template<Int auto N> struct S4 { }; | |
15 | |
16 S1<> s1; | |
17 S2<> s2; | |
18 S3<> s3; | |
19 S4<> s4; |