diff options
Diffstat (limited to 'crates/ra_hir_ty/src/traits.rs')
-rw-r--r-- | crates/ra_hir_ty/src/traits.rs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/crates/ra_hir_ty/src/traits.rs b/crates/ra_hir_ty/src/traits.rs index 6e1c8e42a..a1ca33c98 100644 --- a/crates/ra_hir_ty/src/traits.rs +++ b/crates/ra_hir_ty/src/traits.rs | |||
@@ -24,8 +24,8 @@ const CHALK_SOLVER_MAX_SIZE: usize = 10; | |||
24 | const CHALK_SOLVER_FUEL: i32 = 100; | 24 | const CHALK_SOLVER_FUEL: i32 = 100; |
25 | 25 | ||
26 | #[derive(Debug, Copy, Clone)] | 26 | #[derive(Debug, Copy, Clone)] |
27 | struct ChalkContext<'a, DB> { | 27 | struct ChalkContext<'a> { |
28 | db: &'a DB, | 28 | db: &'a dyn HirDatabase, |
29 | krate: CrateId, | 29 | krate: CrateId, |
30 | } | 30 | } |
31 | 31 | ||
@@ -37,7 +37,7 @@ fn create_chalk_solver() -> chalk_solve::Solver<Interner> { | |||
37 | 37 | ||
38 | /// Collects impls for the given trait in the whole dependency tree of `krate`. | 38 | /// Collects impls for the given trait in the whole dependency tree of `krate`. |
39 | pub(crate) fn impls_for_trait_query( | 39 | pub(crate) fn impls_for_trait_query( |
40 | db: &impl HirDatabase, | 40 | db: &dyn HirDatabase, |
41 | krate: CrateId, | 41 | krate: CrateId, |
42 | trait_: TraitId, | 42 | trait_: TraitId, |
43 | ) -> Arc<[ImplId]> { | 43 | ) -> Arc<[ImplId]> { |
@@ -136,7 +136,7 @@ impl TypeWalk for ProjectionPredicate { | |||
136 | 136 | ||
137 | /// Solve a trait goal using Chalk. | 137 | /// Solve a trait goal using Chalk. |
138 | pub(crate) fn trait_solve_query( | 138 | pub(crate) fn trait_solve_query( |
139 | db: &impl HirDatabase, | 139 | db: &dyn HirDatabase, |
140 | krate: CrateId, | 140 | krate: CrateId, |
141 | goal: Canonical<InEnvironment<Obligation>>, | 141 | goal: Canonical<InEnvironment<Obligation>>, |
142 | ) -> Option<Solution> { | 142 | ) -> Option<Solution> { |
@@ -163,7 +163,7 @@ pub(crate) fn trait_solve_query( | |||
163 | } | 163 | } |
164 | 164 | ||
165 | fn solve( | 165 | fn solve( |
166 | db: &impl HirDatabase, | 166 | db: &dyn HirDatabase, |
167 | krate: CrateId, | 167 | krate: CrateId, |
168 | goal: &chalk_ir::UCanonical<chalk_ir::InEnvironment<chalk_ir::Goal<Interner>>>, | 168 | goal: &chalk_ir::UCanonical<chalk_ir::InEnvironment<chalk_ir::Goal<Interner>>>, |
169 | ) -> Option<chalk_solve::Solution<Interner>> { | 169 | ) -> Option<chalk_solve::Solution<Interner>> { |
@@ -188,7 +188,7 @@ fn solve( | |||
188 | } | 188 | } |
189 | 189 | ||
190 | fn solution_from_chalk( | 190 | fn solution_from_chalk( |
191 | db: &impl HirDatabase, | 191 | db: &dyn HirDatabase, |
192 | solution: chalk_solve::Solution<Interner>, | 192 | solution: chalk_solve::Solution<Interner>, |
193 | ) -> Solution { | 193 | ) -> Solution { |
194 | let convert_subst = |subst: chalk_ir::Canonical<chalk_ir::Substitution<Interner>>| { | 194 | let convert_subst = |subst: chalk_ir::Canonical<chalk_ir::Substitution<Interner>>| { |