aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_ty/src/infer/path.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/hir_ty/src/infer/path.rs')
-rw-r--r--crates/hir_ty/src/infer/path.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/hir_ty/src/infer/path.rs b/crates/hir_ty/src/infer/path.rs
index 717738789..b96391776 100644
--- a/crates/hir_ty/src/infer/path.rs
+++ b/crates/hir_ty/src/infer/path.rs
@@ -97,12 +97,12 @@ impl<'a> InferenceContext<'a> {
97 97
98 let ty = self.db.value_ty(typable); 98 let ty = self.db.value_ty(typable);
99 // self_subst is just for the parent 99 // self_subst is just for the parent
100 let parent_substs = self_subst.unwrap_or_else(Substitution::empty); 100 let parent_substs = self_subst.unwrap_or_else(|| Substitution::empty(&Interner));
101 let ctx = crate::lower::TyLoweringContext::new(self.db, &self.resolver); 101 let ctx = crate::lower::TyLoweringContext::new(self.db, &self.resolver);
102 let substs = ctx.substs_from_path(path, typable, true); 102 let substs = ctx.substs_from_path(path, typable, true);
103 let full_substs = Substitution::builder(substs.len()) 103 let full_substs = Substitution::builder(substs.len(&Interner))
104 .use_parent_substs(&parent_substs) 104 .use_parent_substs(&parent_substs)
105 .fill(substs.0[parent_substs.len()..].iter().cloned()) 105 .fill(substs.interned(&Interner)[parent_substs.len(&Interner)..].iter().cloned())
106 .build(); 106 .build();
107 let ty = ty.subst(&full_substs); 107 let ty = ty.subst(&full_substs);
108 Some(ty) 108 Some(ty)