@@ -45,7 +45,6 @@ use rustc_infer::traits::TraitEngineExt;
45
45
use rustc_middle:: dep_graph:: { DepKind , DepNodeIndex } ;
46
46
use rustc_middle:: mir:: interpret:: ErrorHandled ;
47
47
use rustc_middle:: ty:: abstract_const:: NotConstEvaluatable ;
48
- use rustc_middle:: ty:: fast_reject:: { DeepRejectCtxt , TreatParams } ;
49
48
use rustc_middle:: ty:: fold:: BottomUpFolder ;
50
49
use rustc_middle:: ty:: relate:: TypeRelation ;
51
50
use rustc_middle:: ty:: SubstsRef ;
@@ -2533,21 +2532,6 @@ impl<'tcx> SelectionContext<'_, 'tcx> {
2533
2532
Ok ( Normalized { value : impl_substs, obligations : nested_obligations } )
2534
2533
}
2535
2534
2536
- fn fast_reject_trait_refs (
2537
- & mut self ,
2538
- obligation : & TraitObligation < ' tcx > ,
2539
- impl_trait_ref : & ty:: TraitRef < ' tcx > ,
2540
- ) -> bool {
2541
- // We can avoid creating type variables and doing the full
2542
- // substitution if we find that any of the input types, when
2543
- // simplified, do not match.
2544
- let drcx = DeepRejectCtxt { treat_obligation_params : TreatParams :: ForLookup } ;
2545
- !drcx. substs_refs_may_unify (
2546
- obligation. predicate . skip_binder ( ) . trait_ref . substs ,
2547
- impl_trait_ref. substs ,
2548
- )
2549
- }
2550
-
2551
2535
/// Normalize `where_clause_trait_ref` and try to match it against
2552
2536
/// `obligation`. If successful, return any predicates that
2553
2537
/// result from the normalization.
0 commit comments