Retire is_foreign_item query.
This commit is contained in:
parent
6c64870fa6
commit
37209dcddd
5 changed files with 7 additions and 20 deletions
|
@ -1254,14 +1254,6 @@ impl<'a, 'tcx> CrateMetadataRef<'a> {
|
|||
}
|
||||
}
|
||||
|
||||
fn is_foreign_item(self, id: DefIndex) -> bool {
|
||||
if let Some(parent) = self.def_key(id).parent {
|
||||
matches!(self.def_kind(parent), DefKind::ForeignMod)
|
||||
} else {
|
||||
false
|
||||
}
|
||||
}
|
||||
|
||||
#[inline]
|
||||
fn def_key(self, index: DefIndex) -> DefKey {
|
||||
*self
|
||||
|
|
|
@ -280,7 +280,6 @@ provide! { tcx, def_id, other, cdata,
|
|||
}
|
||||
associated_item => { cdata.get_associated_item(def_id.index, tcx.sess) }
|
||||
inherent_impls => { cdata.get_inherent_implementations_for_type(tcx, def_id.index) }
|
||||
is_foreign_item => { cdata.is_foreign_item(def_id.index) }
|
||||
item_attrs => { tcx.arena.alloc_from_iter(cdata.get_item_attrs(def_id.index, tcx.sess)) }
|
||||
is_mir_available => { cdata.is_item_mir_available(def_id.index) }
|
||||
is_ctfe_mir_available => { cdata.is_ctfe_mir_available(def_id.index) }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue