Skip to content

Commit 433a5f1

Browse files
committed
avoid converting to DefId from LocalDefId when using query
Signed-off-by: Miguel Guarniz <[email protected]>
1 parent 91223ac commit 433a5f1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/rustc_passes/src/entry.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ fn find_item(id: ItemId, ctxt: &mut EntryContext<'_>) {
9393
}
9494
EntryPointType::MainNamed => (),
9595
EntryPointType::OtherMain => {
96-
ctxt.non_main_fns.push(ctxt.tcx.def_span(id.def_id.to_def_id()));
96+
ctxt.non_main_fns.push(ctxt.tcx.def_span(id.def_id));
9797
}
9898
EntryPointType::MainAttr => {
9999
if ctxt.attr_main_fn.is_none() {

0 commit comments

Comments
 (0)