1
Fork 0

Assert def_ident_span presence.

This commit is contained in:
Camille GILLOT 2022-04-19 21:25:15 +02:00
parent 06af25e4f1
commit 64b6c32b21

View file

@ -774,7 +774,8 @@ impl<'a, 'tcx> CrateMetadataRef<'a> {
fn opt_item_ident(self, item_index: DefIndex, sess: &Session) -> Option<Ident> {
let name = self.opt_item_name(item_index)?;
let span = self.root.tables.def_ident_span.get(self, item_index)?.decode((self, sess));
let span =
self.root.tables.def_ident_span.get(self, item_index).unwrap().decode((self, sess));
Some(Ident::new(name, span))
}