mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-27 20:42:04 +00:00
Use chalk_ir::ClosureId
This commit is contained in:
parent
be7a31fbd6
commit
2d69eb131f
5 changed files with 17 additions and 23 deletions
|
@ -264,8 +264,9 @@ impl<'a> InferenceContext<'a> {
|
|||
substs: Substs(sig_tys.clone().into()),
|
||||
})
|
||||
.intern(&Interner);
|
||||
let closure_id = self.db.intern_closure((self.owner, tgt_expr)).into();
|
||||
let closure_ty =
|
||||
TyKind::Closure(self.owner, tgt_expr, Substs::single(sig_ty)).intern(&Interner);
|
||||
TyKind::Closure(closure_id, Substs::single(sig_ty)).intern(&Interner);
|
||||
|
||||
// Eagerly try to relate the closure type with the expected
|
||||
// type, otherwise we often won't have enough information to
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue