Move body_owners to tcx.hir().
This commit is contained in:
parent
db9fea508a
commit
abc57f63ad
7 changed files with 18 additions and 25 deletions
|
@ -921,9 +921,7 @@ impl ItemLikeVisitor<'tcx> for CheckItemTypesVisitor<'tcx> {
|
|||
}
|
||||
|
||||
fn typeck_item_bodies(tcx: TyCtxt<'_>, (): ()) {
|
||||
tcx.par_body_owners(|body_owner_def_id| {
|
||||
tcx.ensure().typeck(body_owner_def_id);
|
||||
});
|
||||
tcx.hir().par_body_owners(|body_owner_def_id| tcx.ensure().typeck(body_owner_def_id));
|
||||
}
|
||||
|
||||
fn fatally_break_rust(sess: &Session) {
|
||||
|
|
|
@ -9,7 +9,7 @@ use rustc_span::{Span, Symbol};
|
|||
|
||||
pub fn check_crate(tcx: TyCtxt<'_>) {
|
||||
let mut used_trait_imports = FxHashSet::default();
|
||||
for item_def_id in tcx.body_owners() {
|
||||
for item_def_id in tcx.hir().body_owners() {
|
||||
let imports = tcx.used_trait_imports(item_def_id);
|
||||
debug!("GatherVisitor: item_def_id={:?} with imports {:#?}", item_def_id, imports);
|
||||
used_trait_imports.extend(imports.iter());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue