Don't register reads for external items
Presumably, this ICEs when translating an inlined item from another crate. There shouldn't be a need to track dependencies in that case.
This commit is contained in:
parent
dd0505cefc
commit
37d5c06a0d
|
@ -111,7 +111,12 @@ impl<'a, 'tcx> TransItem<'tcx> {
|
||||||
tcx.map.local_def_id(node_id)
|
tcx.map.local_def_id(node_id)
|
||||||
}
|
}
|
||||||
TransItem::Fn(instance) => {
|
TransItem::Fn(instance) => {
|
||||||
instance.def
|
if instance.def.is_local() {
|
||||||
|
instance.def
|
||||||
|
} else {
|
||||||
|
// Translating an inlined item from another crate? Don't track anything.
|
||||||
|
return;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
TransItem::DropGlue(_) => {
|
TransItem::DropGlue(_) => {
|
||||||
// Nothing to track for drop glue
|
// Nothing to track for drop glue
|
||||||
|
|
Loading…
Reference in New Issue