Allow LocalDefId as the argument to def_path_str

This commit is contained in:
Oli Scherer 2023-02-16 09:25:11 +00:00
parent e18d1f8d2e
commit 1ce80e210d
18 changed files with 68 additions and 54 deletions

View file

@ -364,7 +364,7 @@ impl<'tcx> DepNodeParams<TyCtxt<'tcx>> for HirId {
#[inline(always)]
fn to_debug_str(&self, tcx: TyCtxt<'tcx>) -> String {
let HirId { owner, local_id } = *self;
format!("{}.{}", tcx.def_path_str(owner.to_def_id()), local_id.as_u32())
format!("{}.{}", tcx.def_path_str(owner), local_id.as_u32())
}
#[inline(always)]