1
Fork 0

Remove ToPredicate impls that use Binder::dummy

This commit is contained in:
jackh726 2021-09-15 20:54:50 -04:00
parent 2c7bc5e33c
commit be76bdf905
27 changed files with 99 additions and 85 deletions

View file

@ -156,7 +156,8 @@ impl AscribeUserTypeCx<'me, 'tcx> {
self.relate(self_ty, Variance::Invariant, impl_self_ty)?;
self.prove_predicate(
ty::PredicateKind::WellFormed(impl_self_ty.into()).to_predicate(self.tcx()),
ty::Binder::dummy(ty::PredicateKind::WellFormed(impl_self_ty.into()))
.to_predicate(self.tcx()),
span,
);
}
@ -173,7 +174,7 @@ impl AscribeUserTypeCx<'me, 'tcx> {
// type were ill-formed but did not appear in `ty`,
// which...could happen with normalization...
self.prove_predicate(
ty::PredicateKind::WellFormed(ty.into()).to_predicate(self.tcx()),
ty::Binder::dummy(ty::PredicateKind::WellFormed(ty.into())).to_predicate(self.tcx()),
span,
);
Ok(())