Fix a crash when Core is poisoned (#5838)

There are probably other ways to reproduce this, but this is roughly how
I ran into it.
This commit is contained in:
Jon Ross-Perkins
2025-07-22 22:31:41 +00:00
committed by GitHub
parent c90c6728fd
commit fdd68dcbe6
2 changed files with 27 additions and 1 deletions
+1 -1
View File
@@ -648,7 +648,7 @@ auto ImportNameFromOtherPackage(
const auto* import_scope_entry = LookupNameInImport(
*import_ir.sem_ir, import_scope_id, name_id, identifier);
if (!import_scope_entry) {
if (!import_scope_entry || !import_scope_entry->result.is_found()) {
continue;
}
SemIR::InstId import_scope_inst_id =