Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/hir-ty/src/infer/closure.rs')
-rw-r--r--crates/hir-ty/src/infer/closure.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/hir-ty/src/infer/closure.rs b/crates/hir-ty/src/infer/closure.rs
index 2679efca7d..0e55bb8e26 100644
--- a/crates/hir-ty/src/infer/closure.rs
+++ b/crates/hir-ty/src/infer/closure.rs
@@ -78,7 +78,7 @@ impl<'db> InferenceContext<'_, 'db> {
// It's always helpful for inference if we know the kind of
// closure sooner rather than later, so first examine the expected
// type, and see if can glean a closure kind from there.
- let (expected_sig, expected_kind) = match expected.to_option(&mut self.table) {
+ let (expected_sig, expected_kind) = match expected.to_option(&self.table) {
Some(ty) => {
let ty = self.table.try_structurally_resolve_type(closure_expr.into(), ty);
self.deduce_closure_signature(closure_expr, ty, closure_kind)
@@ -97,7 +97,7 @@ impl<'db> InferenceContext<'_, 'db> {
debug!(?bound_sig, ?liberated_sig);
- let parent_args = GenericArgs::identity_for_item(interner, self.generic_def.into());
+ let parent_args = GenericArgs::identity_for_item(interner, self.store_owner.into());
let tupled_upvars_ty = self.table.next_ty_var(closure_expr.into());