This patch implements resolution in core DR580, which is included in the C++11 standard. I have also changed variable names to match with LLVM style.
Diff Detail
Event Timeline
lib/Sema/SemaAccess.cpp | ||
---|---|---|
1487 | While you're fixing style, you can probably bump the DC = FN statement onto the next line, as is more common. |
lib/Sema/SemaAccess.cpp | ||
---|---|---|
1490 | This should either be cast<DeclContext> or should not assign to DC if the templated decl is not a DeclContext (that is, if it's an alias template). I think we shouldn't get here for alias templates, so the cast<> is probably the right option; please add some testcases for that. |
I have added a few test cases for alias templates, a function template - to ensure I didn't break it - and extended previous one slightly. I initially had a FIXME for alias templates, but removed it right before I submitted the patch. I can't find a way to access a private variable/field from an alias template context.
While you're fixing style, you can probably bump the DC = FN statement onto the next line, as is more common.