Remove extra negative_impl_exists check

This commit is contained in:
Santiago Pastorino 2022-02-02 14:32:21 -03:00
parent b321742c6c
commit 4e83924595
No known key found for this signature in database
GPG Key ID: 8131A24E0C79EFAF

View File

@ -279,9 +279,7 @@ fn implicit_negative<'cx, 'tcx>(
predicate: p,
})
.chain(obligations)
.find(|o| {
loose_check(selcx, o) || tcx.features().negative_impls && negative_impl_exists(selcx, o)
});
.find(|o| loose_check(selcx, o));
// FIXME: the call to `selcx.predicate_may_hold_fatal` above should be ported
// to the canonical trait query form, `infcx.predicate_may_hold`, once
// the new system supports intercrate mode (which coherence needs).