diff options
| author | Niko Matsakis <niko@alum.mit.edu> | 2022-06-23 16:28:46 -0400 |
|---|---|---|
| committer | Niko Matsakis <niko@alum.mit.edu> | 2022-06-23 16:28:46 -0400 |
| commit | 893b919e64b59c04dbd7c88e74ba138ff8e22a64 (patch) | |
| tree | 41d082004e43ccc0793c39fb154cbebb20695688 /compiler/rustc_borrowck/src | |
| parent | b39ba21fcbf262b94bc8b7c20310fc7fb923d53c (diff) | |
| download | rust-893b919e64b59c04dbd7c88e74ba138ff8e22a64.tar.gz rust-893b919e64b59c04dbd7c88e74ba138ff8e22a64.zip | |
remove VerifyBound::IfEq variant
Diffstat (limited to 'compiler/rustc_borrowck/src')
| -rw-r--r-- | compiler/rustc_borrowck/src/region_infer/mod.rs | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/compiler/rustc_borrowck/src/region_infer/mod.rs b/compiler/rustc_borrowck/src/region_infer/mod.rs index 4830eb3f464..56045166060 100644 --- a/compiler/rustc_borrowck/src/region_infer/mod.rs +++ b/compiler/rustc_borrowck/src/region_infer/mod.rs @@ -19,7 +19,6 @@ use rustc_middle::mir::{ }; use rustc_middle::traits::ObligationCause; use rustc_middle::traits::ObligationCauseCode; -use rustc_middle::ty::Region; use rustc_middle::ty::{self, subst::SubstsRef, RegionVid, Ty, TyCtxt, TypeFoldable}; use rustc_span::Span; @@ -1192,10 +1191,6 @@ impl<'tcx> RegionInferenceContext<'tcx> { debug!("eval_verify_bound(lower_bound={:?}, verify_bound={:?})", lower_bound, verify_bound); match verify_bound { - VerifyBound::IfEq(test_ty, verify_bound1) => { - self.eval_if_eq(infcx, generic_ty, lower_bound, *test_ty, *verify_bound1) - } - VerifyBound::IfEqBound(verify_if_eq_b) => { self.eval_if_eq_bound(infcx, param_env, generic_ty, lower_bound, *verify_if_eq_b) } @@ -1234,24 +1229,6 @@ impl<'tcx> RegionInferenceContext<'tcx> { } } - fn eval_if_eq( - &self, - infcx: &InferCtxt<'_, 'tcx>, - generic_ty: Ty<'tcx>, - lower_bound: RegionVid, - test_ty: Ty<'tcx>, - verify_bound: Region<'tcx>, - ) -> bool { - let generic_ty_normalized = self.normalize_to_scc_representatives(infcx.tcx, generic_ty); - let test_ty_normalized = self.normalize_to_scc_representatives(infcx.tcx, test_ty); - if generic_ty_normalized == test_ty_normalized { - let verify_bound_vid = self.to_region_vid(verify_bound); - self.eval_outlives(verify_bound_vid, lower_bound) - } else { - false - } - } - fn eval_if_eq_bound( &self, infcx: &InferCtxt<'_, 'tcx>, |
