aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_ty/src/infer
diff options
context:
space:
mode:
Diffstat (limited to 'crates/hir_ty/src/infer')
-rw-r--r--crates/hir_ty/src/infer/expr.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/hir_ty/src/infer/expr.rs b/crates/hir_ty/src/infer/expr.rs
index ccaae53e9..d61ef65f2 100644
--- a/crates/hir_ty/src/infer/expr.rs
+++ b/crates/hir_ty/src/infer/expr.rs
@@ -849,7 +849,7 @@ impl<'a> InferenceContext<'a> {
849 self.write_method_resolution(tgt_expr, func); 849 self.write_method_resolution(tgt_expr, func);
850 (ty, self.db.value_ty(func.into()), Some(generics(self.db.upcast(), func.into()))) 850 (ty, self.db.value_ty(func.into()), Some(generics(self.db.upcast(), func.into())))
851 } 851 }
852 None => (receiver_ty, Binders::new(0, self.err_ty()), None), 852 None => (receiver_ty, Binders::empty(&Interner, self.err_ty()), None),
853 }; 853 };
854 let substs = self.substs_for_method_call(def_generics, generic_args, &derefed_receiver_ty); 854 let substs = self.substs_for_method_call(def_generics, generic_args, &derefed_receiver_ty);
855 let method_ty = method_ty.subst(&substs); 855 let method_ty = method_ty.subst(&substs);
@@ -951,7 +951,7 @@ impl<'a> InferenceContext<'a> {
951 for predicate in generic_predicates.iter() { 951 for predicate in generic_predicates.iter() {
952 let (predicate, binders) = 952 let (predicate, binders) =
953 predicate.clone().subst(parameters).into_value_and_skipped_binders(); 953 predicate.clone().subst(parameters).into_value_and_skipped_binders();
954 always!(binders == 0); // quantified where clauses not yet handled 954 always!(binders.len(&Interner) == 0); // quantified where clauses not yet handled
955 self.push_obligation(predicate.cast(&Interner)); 955 self.push_obligation(predicate.cast(&Interner));
956 } 956 }
957 // add obligation for trait implementation, if this is a trait method 957 // add obligation for trait implementation, if this is a trait method