/cp
[official-gcc.git] / gcc / testsuite / g++.dg / cpp1y / pr83817.C
blob9a69cbb201ca70106e2391471a070501f4dbf272
1 // PR c++/83817
2 // { dg-do compile { target c++14 } }
4 struct A;
5 struct B { template <typename> using C = A; };
6 struct D : B { struct F { typedef C<char> E; }; };
7 struct G {
8   struct I { I (D, A &); } h;
9   D::F::E &k ();
10   D j;
11   G (G &&) : h (j, k ()) {}
13 struct N { G l; };
14 typedef N (*M)(N &);
15 struct H { const char *o; M s; };
16 N foo (N &);
17 H r { "", [](auto &x) { return foo (x); }};