Skip to content

Commit 823a7ca

Browse files
committed
We should call eq instead of sup as we're relating Ty directly and not Binder<TraitRef>
1 parent 9613bc3 commit 823a7ca

File tree

1 file changed

+1
-3
lines changed
  • compiler/rustc_hir_analysis/src/astconv

1 file changed

+1
-3
lines changed

compiler/rustc_hir_analysis/src/astconv/mod.rs

+1-3
Original file line numberDiff line numberDiff line change
@@ -1637,10 +1637,8 @@ impl<'o, 'tcx> dyn AstConv<'tcx> + 'o {
16371637
let impl_ty = ocx.normalize(&cause, param_env, impl_ty);
16381638

16391639
// Check that the self types can be related.
1640-
// FIXME(inherent_associated_types): Should we use `eq` here? Method probing uses
1641-
// `sup` for this situtation, too. What for? To constrain inference variables?
16421640
if ocx
1643-
.sup(&ObligationCause::dummy(), param_env, impl_ty, self_ty)
1641+
.eq(&ObligationCause::dummy(), param_env, impl_ty, self_ty)
16441642
.is_err()
16451643
{
16461644
return false;

0 commit comments

Comments
 (0)