diff options
author | Laurențiu Nicola <[email protected]> | 2021-04-05 15:38:37 +0100 |
---|---|---|
committer | Laurențiu Nicola <[email protected]> | 2021-04-05 15:38:37 +0100 |
commit | d7546d8c2323adff53c8170c528e82a8131681c5 (patch) | |
tree | 511c31f0b647044294eba7c4394ee3e4ba7b13b6 /crates/hir_ty/src/traits | |
parent | aefcbf275804f558ab18e83bfc8869187713b4ad (diff) |
Pass interner to TraitRef::self_type_parameter
Diffstat (limited to 'crates/hir_ty/src/traits')
-rw-r--r-- | crates/hir_ty/src/traits/chalk/mapping.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/hir_ty/src/traits/chalk/mapping.rs b/crates/hir_ty/src/traits/chalk/mapping.rs index 240f9d456..67e88ebf4 100644 --- a/crates/hir_ty/src/traits/chalk/mapping.rs +++ b/crates/hir_ty/src/traits/chalk/mapping.rs | |||
@@ -539,7 +539,7 @@ pub(super) fn generic_predicate_to_inline_bound( | |||
539 | let self_ty_shifted_in = self_ty.clone().shift_bound_vars(DebruijnIndex::ONE); | 539 | let self_ty_shifted_in = self_ty.clone().shift_bound_vars(DebruijnIndex::ONE); |
540 | match &pred.value { | 540 | match &pred.value { |
541 | WhereClause::Implemented(trait_ref) => { | 541 | WhereClause::Implemented(trait_ref) => { |
542 | if trait_ref.self_type_parameter() != &self_ty_shifted_in { | 542 | if trait_ref.self_type_parameter(&Interner) != &self_ty_shifted_in { |
543 | // we can only convert predicates back to type bounds if they | 543 | // we can only convert predicates back to type bounds if they |
544 | // have the expected self type | 544 | // have the expected self type |
545 | return None; | 545 | return None; |