aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_ty/src/infer/coerce.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/hir_ty/src/infer/coerce.rs')
-rw-r--r--crates/hir_ty/src/infer/coerce.rs6
1 files changed, 4 insertions, 2 deletions
diff --git a/crates/hir_ty/src/infer/coerce.rs b/crates/hir_ty/src/infer/coerce.rs
index 137419264..b1f98c507 100644
--- a/crates/hir_ty/src/infer/coerce.rs
+++ b/crates/hir_ty/src/infer/coerce.rs
@@ -7,7 +7,9 @@
7use chalk_ir::{Mutability, TyVariableKind}; 7use chalk_ir::{Mutability, TyVariableKind};
8use hir_def::lang_item::LangItemTarget; 8use hir_def::lang_item::LangItemTarget;
9 9
10use crate::{autoderef, traits::Solution, Interner, Obligation, Substs, TraitRef, Ty, TyKind}; 10use crate::{
11 autoderef, traits::Solution, Interner, Obligation, Substitution, TraitRef, Ty, TyKind,
12};
11 13
12use super::{InEnvironment, InferenceContext}; 14use super::{InEnvironment, InferenceContext};
13 15
@@ -134,7 +136,7 @@ impl<'a> InferenceContext<'a> {
134 return None; 136 return None;
135 } 137 }
136 138
137 let substs = Substs::build_for_generics(&generic_params) 139 let substs = Substitution::build_for_generics(&generic_params)
138 .push(from_ty.clone()) 140 .push(from_ty.clone())
139 .push(to_ty.clone()) 141 .push(to_ty.clone())
140 .build(); 142 .build();