| 1 |
// PR c++/99132 |
| 2 |
// { dg-do compile { target c++11 } } |
| 3 |
|
| 4 |
template <class T> struct A { T c; }; |
| 5 |
template <class T> struct B { |
| 6 |
A<T> d; |
| 7 |
constexpr T operator-> () { return d.c; } |
| 8 |
B (B &&); |
| 9 |
}; |
| 10 |
struct C { |
| 11 |
virtual void foo (); |
| 12 |
void bar (B<C *> h) { h->foo (); } |
| 13 |
}; |