Remove a call-site to primary_body_of as it is only interested in the body id

This commit is contained in:
Oli Scherer 2024-03-27 11:13:34 +00:00
parent d0eb9c86f1
commit 7786ee3c92

View File

@ -106,7 +106,7 @@ fn has_typeck_results(tcx: TyCtxt<'_>, def_id: DefId) -> bool {
}
if let Some(def_id) = def_id.as_local() {
primary_body_of(tcx.hir_node_by_def_id(def_id)).is_some()
tcx.hir_node_by_def_id(def_id).body_id().is_some()
} else {
false
}