Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/hir-ty/src/display.rs')
| -rw-r--r-- | crates/hir-ty/src/display.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/hir-ty/src/display.rs b/crates/hir-ty/src/display.rs index 2c6d7c68d1..3bb8be02aa 100644 --- a/crates/hir-ty/src/display.rs +++ b/crates/hir-ty/src/display.rs @@ -47,7 +47,7 @@ use stdx::never; use triomphe::Arc; use crate::{ - CallableDefId, FnAbi, ImplTraitId, MemoryMap, TraitEnvironment, consteval, + CallableDefId, FnAbi, ImplTraitId, InferenceResult, MemoryMap, TraitEnvironment, consteval, db::{HirDatabase, InternedClosure, InternedCoroutine}, generics::generics, layout::Layout, @@ -1398,7 +1398,7 @@ impl<'db> HirDisplay<'db> for Ty<'db> { if let Some(sig) = sig { let sig = sig.skip_binder(); let InternedClosure(def, _) = db.lookup_intern_closure(id); - let infer = db.infer(def); + let infer = InferenceResult::for_body(db, def); let (_, kind) = infer.closure_info(id); match f.closure_style { ClosureStyle::ImplFn => write!(f, "impl {kind:?}(")?, |