Skip to content

Commit 4028b09

Browse files
committed
Do not ICE if some foreign expansions were not encoded.
The metadata encoder does not necessarily encode all expansions, only those which are referenced in other metadata fields.
1 parent daf8903 commit 4028b09

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

compiler/rustc_metadata/src/rmeta/decoder.rs

-2
Original file line numberDiff line numberDiff line change
@@ -1646,8 +1646,6 @@ impl<'a, 'tcx> CrateMetadataRef<'a> {
16461646
let i = ExpnIndex::from_u32(i);
16471647
if let Some(hash) = self.root.expn_hashes.get(self, i) {
16481648
map.insert(hash.decode(self), i);
1649-
} else {
1650-
panic!("Missing expn_hash entry for {:?}", i);
16511649
}
16521650
}
16531651
map

0 commit comments

Comments
 (0)