Revert "Do not need to account for overflow in predicate_can_apply"
This reverts commit cbe9328018
.
This commit is contained in:
parent
c285218f43
commit
4149923ff0
3 changed files with 1 additions and 31 deletions
|
@ -2544,10 +2544,7 @@ impl<'tcx> InferCtxtPrivExt<'tcx> for TypeErrCtxt<'_, 'tcx> {
|
|||
let obligation =
|
||||
Obligation::new(self.tcx, ObligationCause::dummy(), param_env, cleaned_pred);
|
||||
|
||||
// We don't use `InferCtxt::predicate_may_hold` because that
|
||||
// will re-run predicates that overflow locally, which ends up
|
||||
// taking a really long time to compute.
|
||||
self.evaluate_obligation(&obligation).map_or(false, |eval| eval.may_apply())
|
||||
self.predicate_may_hold(&obligation)
|
||||
})
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue