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

@ -135,7 +135,7 @@ impl<'a, 'tcx> Autoderef<'a, 'tcx> {
let obligation = traits::Obligation::new(
cause.clone(),
self.param_env,
trait_ref.without_const().to_predicate(tcx),
ty::Binder::dummy(trait_ref).without_const().to_predicate(tcx),
);
if !self.infcx.predicate_may_hold(&obligation) {
debug!("overloaded_deref_ty: cannot match obligation");