[PATCH] Allow more lookup of types in dependent base classes

Reid Kleckner rnk at google.com
Tue Jul 8 13:10:21 PDT 2014


thanks!

================
Comment at: test/SemaTemplate/ms-lookup-template-base-classes.cpp:383
@@ +382,3 @@
+
+namespace lookup_in_function_contexts {
+template <typename T> struct A { typedef T NameFromBase; };
----------------
Richard Smith wrote:
> Do you have any tests here for lookup in late-parsed function bodies? (I expect that'll fail too, and probably shouldn't.)
Hm, as I add these test cases, I'm starting to think we should generalize the lookup recovery like you suggested.  I'll commit this change with more tests and send you a new patch to generalize the check.  I'm a more worried because we need to loop over parent DeclContexts to do correct lookup, which I'm less confident about.

http://reviews.llvm.org/D4237






More information about the cfe-commits mailing list