aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_ty/src/builder.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/hir_ty/src/builder.rs')
-rw-r--r--crates/hir_ty/src/builder.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/crates/hir_ty/src/builder.rs b/crates/hir_ty/src/builder.rs
index c5196200c..9b2c6975a 100644
--- a/crates/hir_ty/src/builder.rs
+++ b/crates/hir_ty/src/builder.rs
@@ -139,7 +139,8 @@ impl TyBuilder<hir_def::AdtId> {
139 } else { 139 } else {
140 // each default can depend on the previous parameters 140 // each default can depend on the previous parameters
141 let subst_so_far = Substitution::intern(self.vec.clone()); 141 let subst_so_far = Substitution::intern(self.vec.clone());
142 self.vec.push(default_ty.clone().substitute(&subst_so_far).cast(&Interner)); 142 self.vec
143 .push(default_ty.clone().substitute(&Interner, &subst_so_far).cast(&Interner));
143 } 144 }
144 } 145 }
145 self 146 self
@@ -200,7 +201,7 @@ impl<T: TypeWalk + HasInterner<Interner = Interner>> TyBuilder<Binders<T>> {
200 201
201 pub fn build(self) -> T { 202 pub fn build(self) -> T {
202 let (b, subst) = self.build_internal(); 203 let (b, subst) = self.build_internal();
203 b.substitute(&subst) 204 b.substitute(&Interner, &subst)
204 } 205 }
205} 206}
206 207