/* { dg-do compile } */ /* { dg-require-effective-target c++17 } */ struct u { int b; int c; template u(d, e); }; template struct f { u g; }; template class v { typedef f k; k *l[4]; k m; public: v(h, h); void aa(h, i); }; template void v::aa(h, i) { n(&l[1], &m); } template void n(f **o, f *ab) { bool p, r; f q = **o; f *t; h a = q.g; h b = t->g; if (r) ; else goto ac; s: p = a.b || a.c < b.c; if (p) goto s; ac: ab->g = b; b = t->g; goto s; } template class w {}; template class x; template class z; class ad { public: template static void ah(const z &, const z &, x *&); }; template void ad::ah(const z &ai, const z &aj, x *&) { u c(0, 0), d(0, 0), g(aj, ai); v e(c, d); e.aa(g, 0); } template class ak; template void ao(ak ap, ak aq) { x *f; ad::ah(*ap.ar, *aq.ar, f); } template void au(w ap, w aq) { ao(static_cast(ap), static_cast(aq)); } template class z {}; template class ak : public w> { public: z *ar; }; template class av; template void ay(av, av) { aw h, i; au(h, i); } template class av {}; class az { public: typedef av> ba; }; int main() { az::ba j, k; ay(j, k); }