Skip to content

Commit

Permalink
Accept LocalDefId as key for check_trait_item_well_formed query
Browse files Browse the repository at this point in the history
  • Loading branch information
marmeladema committed Apr 27, 2020
1 parent d9e5fa1 commit 14119a2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 3 additions & 1 deletion src/librustc_middle/query/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -807,7 +807,9 @@ rustc_queries! {
query check_item_well_formed(key: LocalDefId) -> () {
desc { |tcx| "processing `{}`", tcx.def_path_str(key.to_def_id()) }
}
query check_trait_item_well_formed(_: DefId) -> () {}
query check_trait_item_well_formed(key: LocalDefId) -> () {
desc { |tcx| "processing `{}`", tcx.def_path_str(key.to_def_id()) }
}
query check_impl_item_well_formed(_: DefId) -> () {}
}

Expand Down
4 changes: 2 additions & 2 deletions src/librustc_typeck/check/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -758,8 +758,8 @@ fn check_item_well_formed(tcx: TyCtxt<'_>, def_id: LocalDefId) {
wfcheck::check_item_well_formed(tcx, def_id);
}

fn check_trait_item_well_formed(tcx: TyCtxt<'_>, def_id: DefId) {
wfcheck::check_trait_item(tcx, def_id.expect_local());
fn check_trait_item_well_formed(tcx: TyCtxt<'_>, def_id: LocalDefId) {
wfcheck::check_trait_item(tcx, def_id);
}

fn check_impl_item_well_formed(tcx: TyCtxt<'_>, def_id: DefId) {
Expand Down

0 comments on commit 14119a2

Please sign in to comment.