Skip to content

Commit 14119a2

Browse files
committed
Accept LocalDefId as key for check_trait_item_well_formed query
1 parent d9e5fa1 commit 14119a2

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

src/librustc_middle/query/mod.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -807,7 +807,9 @@ rustc_queries! {
807807
query check_item_well_formed(key: LocalDefId) -> () {
808808
desc { |tcx| "processing `{}`", tcx.def_path_str(key.to_def_id()) }
809809
}
810-
query check_trait_item_well_formed(_: DefId) -> () {}
810+
query check_trait_item_well_formed(key: LocalDefId) -> () {
811+
desc { |tcx| "processing `{}`", tcx.def_path_str(key.to_def_id()) }
812+
}
811813
query check_impl_item_well_formed(_: DefId) -> () {}
812814
}
813815

src/librustc_typeck/check/mod.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -758,8 +758,8 @@ fn check_item_well_formed(tcx: TyCtxt<'_>, def_id: LocalDefId) {
758758
wfcheck::check_item_well_formed(tcx, def_id);
759759
}
760760

761-
fn check_trait_item_well_formed(tcx: TyCtxt<'_>, def_id: DefId) {
762-
wfcheck::check_trait_item(tcx, def_id.expect_local());
761+
fn check_trait_item_well_formed(tcx: TyCtxt<'_>, def_id: LocalDefId) {
762+
wfcheck::check_trait_item(tcx, def_id);
763763
}
764764

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

0 commit comments

Comments
 (0)