Fortran: Fix PR 47485.
[gcc.git] / gcc / testsuite / g++.dg / diagnostic / ptrtomem2.C
blobf3b29a07a9904493578bb9591edfd9e3bb222d56
1 // PR c++/85901
2 // { dg-do compile { target c++11 } }
4 template<class> struct A;
6 template<class U>
7 struct A<int U::*> {
8     template<class TT>
9     static auto c(int U::*p, TT o) -> decltype(o.*p); // { dg-message {A<int U::\*>} }
12 struct X {};
14 int x = A<int X::*>::c(); // { dg-error "no matching function for call" }