aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_ty/src/lower.rs
diff options
context:
space:
mode:
authorJonas Schievink <[email protected]>2021-04-01 18:46:43 +0100
committerJonas Schievink <[email protected]>2021-04-01 18:46:43 +0100
commitb00266b79f0e2c2a5e332b30f7e6aba83b5e6e5a (patch)
treec7e591ec8a1ec6b401a8a7ea00115120a4789db5 /crates/hir_ty/src/lower.rs
parent25201b2dad7b4b0d41494e238ebf643ad7ad8cd6 (diff)
Global TypeRef/TraitRef interning
Diffstat (limited to 'crates/hir_ty/src/lower.rs')
-rw-r--r--crates/hir_ty/src/lower.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/hir_ty/src/lower.rs b/crates/hir_ty/src/lower.rs
index afbfa12d5..a08f694d9 100644
--- a/crates/hir_ty/src/lower.rs
+++ b/crates/hir_ty/src/lower.rs
@@ -1157,7 +1157,7 @@ fn type_for_type_alias(db: &dyn HirDatabase, t: TypeAliasId) -> Binders<Ty> {
1157 Binders::new(0, TyKind::ForeignType(crate::to_foreign_def_id(t)).intern(&Interner)) 1157 Binders::new(0, TyKind::ForeignType(crate::to_foreign_def_id(t)).intern(&Interner))
1158 } else { 1158 } else {
1159 let type_ref = &db.type_alias_data(t).type_ref; 1159 let type_ref = &db.type_alias_data(t).type_ref;
1160 let inner = ctx.lower_ty(type_ref.as_ref().unwrap_or(&TypeRef::Error)); 1160 let inner = ctx.lower_ty(type_ref.as_deref().unwrap_or(&TypeRef::Error));
1161 Binders::new(generics.len(), inner) 1161 Binders::new(generics.len(), inner)
1162 } 1162 }
1163} 1163}