rsmith accepted this revision. rsmith added a comment. This revision is now accepted and ready to land.
LGTM ================ Comment at: lib/Sema/TreeTransform.h:9131 @@ -9130,2 +9130,3 @@ // it's a normal declaration name. - if (!Old->hasExplicitTemplateArgs() && !TemplateKWLoc.isValid()) + if (!Old->hasExplicitTemplateArgs() && !TemplateKWLoc.isValid()) { + // If an UnresolvedLookupExpr resolved to an instance member, that's an ---------------- Please also add a test for the case with explicit template arguments, something like: struct X { template<typename> void f(); template<typename T, typename T::type = 0> static void f(); template<typename T> void g() { (void)f<T>; } }; void h(X x) { x.g<int>(); } ... should do the trick. (This already seems to work.) ================ Comment at: test/SemaCXX/using-decl-1.cpp:340-349 @@ +339,12 @@ + static void m_fn1() { + // expected-error@+1 {{invalid use of member 'field' in static member function}} + (void)field; + // expected-error@+1 {{invalid use of member 'field' in static member function}} + (void)&field; + // expected-error@+1 {{call to non-static member function without an object argument}} + (void)method; + // expected-error@+1 {{call to non-static member function without an object argument}} + (void)&method; + // expected-error@+1 {{call to non-static member function without an object argument}} + method(); + } ---------------- Please also add tests that we don't reject the corresponding address-of-member cases. http://reviews.llvm.org/D6700 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits