================
@@ -7061,8 +7061,17 @@ NamedDecl *Sema::FindInstantiatedDecl(SourceLocation
Loc, NamedDecl *D,
// anonymous unions in class templates).
}
- if (!ParentDependsOnArgs)
+ if (!ParentDependsOnArgs) {
+ if (CurrentInstantiationScope) {
+ if (llvm::PointerUnion<
+ Decl *, LocalInstantiationScope::DeclArgumentPack *> *Found =
+ CurrentInstantiationScope->getInstantiationOfIfExists(D)) {
+ if (Decl *FD = Found->dyn_cast<Decl *>())
----------------
erichkeane wrote:
it seems to me that this is a problem not with getting the current
instantiation, but with how we determine that 'ParentDependsOnArgs'. I would
imagine that the calculation there is incorrect for the lambdas, not trying to
do a fixup here.
https://github.com/llvm/llvm-project/pull/165098
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits