Debian Codegraph @

gcc/testsuite/g++.dg/lookup/member5.C

raw
1 // PR c++/69753
2 // { dg-do compile { target c++11 } }
3
4 struct B {
5 template <class> void bfn ();
6 };
7
8 template <class T>
9 constexpr int x(T) { return 42; }
10
11 template <int I>
12 struct C
13 {
14 template <class> void cfn ();
15 };
16
17 template <typename T> struct A {
18 static B fn(int);
19 template <class U> static B ft(U);
20
21 void g()
22 {
23 auto b = this->fn(42);
24 b.bfn<int>();
25
26 auto b2 = this->ft(42);
27 b2.bfn<int>();
28
29 auto c = C<x(42)>();
30 c.cfn<int>();
31 }
32 };