// PR c++/94799 - member template function lookup fails. template struct M { void fn() { } }; M* bar (int); M bar2 (int); template struct X : M { void xfn () { this->template M::fn (); bar((T)1)->template M::fn (); bar2((T)1).template M::fn (); } }; int main () { X x; x.xfn(); }