aboutsummaryrefslogtreecommitdiff
path: root/crates/hir
diff options
context:
space:
mode:
authorFlorian Diebold <[email protected]>2021-04-03 21:18:02 +0100
committerFlorian Diebold <[email protected]>2021-04-04 12:16:38 +0100
commit5d2b488aeb17410aec3b89eac69038c51f332448 (patch)
tree30ef50eb5dc4e8c572c6bec969ce96b3ed2f3e68 /crates/hir
parent77333a571ffb401a6765bbc80dea082ad08238d9 (diff)
Replace remaining uses of Substitution::build_for_def
Diffstat (limited to 'crates/hir')
-rw-r--r--crates/hir/src/lib.rs5
1 files changed, 2 insertions, 3 deletions
diff --git a/crates/hir/src/lib.rs b/crates/hir/src/lib.rs
index 15f46f720..42ae53c66 100644
--- a/crates/hir/src/lib.rs
+++ b/crates/hir/src/lib.rs
@@ -1702,10 +1702,9 @@ impl Type {
1702 fn from_def( 1702 fn from_def(
1703 db: &dyn HirDatabase, 1703 db: &dyn HirDatabase,
1704 krate: CrateId, 1704 krate: CrateId,
1705 def: impl HasResolver + Into<TyDefId> + Into<GenericDefId>, 1705 def: impl HasResolver + Into<TyDefId>,
1706 ) -> Type { 1706 ) -> Type {
1707 let substs = Substitution::build_for_def(db, def).fill_with_unknown().build(); 1707 let ty = TyBuilder::def_ty(db, def.into()).fill_with_unknown().build();
1708 let ty = db.ty(def.into()).subst(&substs);
1709 Type::new(db, krate, def, ty) 1708 Type::new(db, krate, def, ty)
1710 } 1709 }
1711 1710