// RUN: clang-cc -fsyntax-only -verify %s namespace PR5557 { template struct A { A(); virtual int a(T x); }; template A::A() {} template int A::a(T x) { return *x; // expected-error{{requires pointer operand}} } A x; // expected-note{{instantiation}} template struct X { virtual void f(); }; template<> void X::f() { } }