Do not run check on foreign items.
This commit is contained in:
parent
7366bdaea2
commit
6dfdeab65a
@ -244,7 +244,7 @@ fn visit_trait_item(&mut self, it: &'tcx TraitItem<'tcx>) {
|
||||
fn visit_foreign_item(&mut self, it: &'tcx hir::ForeignItem<'tcx>) {
|
||||
trace!(?it.owner_id);
|
||||
assert_ne!(it.owner_id.def_id, self.def_id);
|
||||
self.check(it.owner_id.def_id);
|
||||
// No need to call `check`, as we do not run borrowck on foreign items.
|
||||
intravisit::walk_foreign_item(self, it);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user