// PR c++/37540 struct A { int g() {return 0;} }; template void f(A a) { __decltype(a.g()) i; } int main() { f(A()); }