Rollup merge of #104595 - compiler-errors:poly-existential-predicate, r=lcnr

Add `PolyExistentialPredicate` type alias

Wrapping `ExistentialPredicate`s in a binder is very common, and this alias already exists for the `PolyExistential{TraitRef,Projection}` types.
This commit is contained in:
Matthias Krüger 2022-11-21 14:11:11 +01:00 committed by GitHub
commit 3597ed5a09

View file

@ -687,7 +687,7 @@ fn check_ptr_arg_usage<'tcx>(cx: &LateContext<'tcx>, body: &'tcx Body<'_>, args:
fn matches_preds<'tcx>(
cx: &LateContext<'tcx>,
ty: Ty<'tcx>,
preds: &'tcx [Binder<'tcx, ExistentialPredicate<'tcx>>],
preds: &'tcx [ty::PolyExistentialPredicate<'tcx>],
) -> bool {
let infcx = cx.tcx.infer_ctxt().build();
preds.iter().all(|&p| match cx.tcx.erase_late_bound_regions(p) {