Skip to content

Commit 7786ee3

Browse files
committed
Remove a call-site to primary_body_of as it is only interested in the body id
1 parent d0eb9c8 commit 7786ee3

File tree

1 file changed

+1
-1
lines changed
  • compiler/rustc_hir_typeck/src

1 file changed

+1
-1
lines changed

compiler/rustc_hir_typeck/src/lib.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ fn has_typeck_results(tcx: TyCtxt<'_>, def_id: DefId) -> bool {
106106
}
107107

108108
if let Some(def_id) = def_id.as_local() {
109-
primary_body_of(tcx.hir_node_by_def_id(def_id)).is_some()
109+
tcx.hir_node_by_def_id(def_id).body_id().is_some()
110110
} else {
111111
false
112112
}

0 commit comments

Comments
 (0)