Debian Codegraph @

gcc/testsuite/g++.dg/cpp2a/concepts-class5a.C

raw
1 // PR c++/96830
2 // A valid version of concepts-class5.C.
3 // { dg-do compile { target c++20 } }
4
5 template<class T> concept C = true;
6
7 template<C T> requires true
8 struct A {
9 void f();
10 template<class U> void g();
11
12 struct B;
13 template<class U> struct C;
14
15 static int D;
16 template<class U> static int E;
17 };
18
19 template<C T> requires true
20 void A<T>::f() { }
21
22 template<C T> requires true
23 template<class U>
24 void A<T>::g() { }
25
26 template<C T> requires true
27 struct A<T>::B { };
28
29 template<C T> requires true
30 template<class U>
31 struct A<T>::C { };
32
33 template<C T> requires true
34 int A<T>::D = 0;
35
36 template<C T> requires true
37 template<class U>
38 int A<T>::E = 0;