aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_ty/src/lower.rs
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2021-03-05 16:04:49 +0000
committerGitHub <[email protected]>2021-03-05 16:04:49 +0000
commit6c27c55041953327d341f4e7c705e8887fc4dd50 (patch)
treebcc8bcac74fa61c816986b0635defa7c7512660f /crates/hir_ty/src/lower.rs
parent25a43e24c81f7b51234fc4e65e5e36ddbe3d60f1 (diff)
parent50e01d2bc7429d718e0783d75458a6a047ee2b70 (diff)
Merge #7870
7870: Use chalk_ir::AdtId r=Veykril a=Veykril It's a bit unfortunate that we got two AdtId's now(technically 3 with the alias in the chalk module but that one won't allow pattern matching), one from hir_def and one from chalk_ir(hir_ty). But the hir_ty/chalk one doesn't leave hir so it shouldn't be that bad I suppose. Though if I see this right this will happen for almost all IDs. I imagine most of the intermediate changes to using chalk ids will turn out not too nice until the refactor is over. Co-authored-by: Lukas Wirth <[email protected]>
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 1b5843d48..5fe5b8ad1 100644
--- a/crates/hir_ty/src/lower.rs
+++ b/crates/hir_ty/src/lower.rs
@@ -1100,7 +1100,7 @@ fn type_for_enum_variant_constructor(db: &dyn HirDatabase, def: EnumVariantId) -
1100fn type_for_adt(db: &dyn HirDatabase, adt: AdtId) -> Binders<Ty> { 1100fn type_for_adt(db: &dyn HirDatabase, adt: AdtId) -> Binders<Ty> {
1101 let generics = generics(db.upcast(), adt.into()); 1101 let generics = generics(db.upcast(), adt.into());
1102 let substs = Substs::bound_vars(&generics, DebruijnIndex::INNERMOST); 1102 let substs = Substs::bound_vars(&generics, DebruijnIndex::INNERMOST);
1103 Binders::new(substs.len(), Ty::Adt(adt, substs)) 1103 Binders::new(substs.len(), Ty::adt_ty(adt, substs))
1104} 1104}
1105 1105
1106fn type_for_type_alias(db: &dyn HirDatabase, t: TypeAliasId) -> Binders<Ty> { 1106fn type_for_type_alias(db: &dyn HirDatabase, t: TypeAliasId) -> Binders<Ty> {