mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 16:31:04 +01:00
Fix crash when referring to a C++ variable whose type's scope has not been imported. (#6743)
This commit is contained in:
@@ -1673,6 +1673,8 @@ static auto AddDependentUnimportedDecls(Context& context,
|
||||
context, type_decl->getASTContext().getTypeDeclType(type_decl),
|
||||
worklist);
|
||||
}
|
||||
} else if (auto* var_decl = dyn_cast<clang::VarDecl>(clang_decl)) {
|
||||
AddDependentUnimportedTypeDecls(context, var_decl->getType(), worklist);
|
||||
}
|
||||
auto* parent = GetParentDecl(clang_decl);
|
||||
if (llvm::isa_and_nonnull<clang::TagDecl, clang::NamespaceDecl,
|
||||
|
||||
Reference in New Issue
Block a user