1 // { dg-do compile { target c++11 } } 2 // { dg-options "-O3" } 3 4 void h(); 5 template <typename b> struct k { using d = b; }; 6 template <typename b, template <typename> class> using e = k<b>; 7 template <typename b, template <typename> class f> 8 using g = typename e<b, f>::d; 9 struct l { 10 template <typename i> using ab = typename i::j; 11 }; 12 struct n : l { 13 using j = g<char *, ab>; 14 }; 15 class o { 16 public: 17 long r(); 18 }; 19 char m; s()20char s() { 21 if (m) 22 return '0'; 23 return 'A'; 24 } 25 class t { 26 public: 27 typedef char *ad; 28 ad m_fn2(); 29 }; fn3()30void fn3() { 31 char *a; 32 t b; 33 bool p = false; 34 while (*a) { 35 h(); 36 o c; 37 if (*a) 38 a++; 39 if (c.r()) { 40 n::j q; 41 for (t::ad d = b.m_fn2(), e; d != e; d++) { 42 char f = *q; 43 *d = f + s(); 44 } 45 p = true; 46 } 47 } 48 if (p) 49 throw; 50 } 51