Intern Substitutions

(Costs a bit of performance, reduces memory usage on RA by ~10%.)
This commit is contained in:
Florian Diebold 2021-04-08 18:25:18 +02:00
parent a169fa6a83
commit be03db0e3a
8 changed files with 34 additions and 27 deletions

View file

@ -1825,7 +1825,7 @@ impl Type {
Solution::Unique(s) => s
.value
.subst
.interned()
.as_slice(&Interner)
.first()
.map(|ty| self.derived(ty.assert_ty_ref(&Interner).clone())),
Solution::Ambig(_) => None,