diff options
| author | Michael Goulet <michael@errs.io> | 2024-07-24 15:58:34 -0400 |
|---|---|---|
| committer | Michael Goulet <michael@errs.io> | 2024-07-29 11:59:47 -0400 |
| commit | f990239b34d4cc81999d62e3f2271c7c53c72fb7 (patch) | |
| tree | bcd98a66a42777e4bbfaac092cc5ad1393927b35 /compiler/rustc_mir_dataflow/src/rustc_peek.rs | |
| parent | 4db3d12e6f395babed53dee1d209a5c8699a5ae6 (diff) | |
| download | rust-f990239b34d4cc81999d62e3f2271c7c53c72fb7.tar.gz rust-f990239b34d4cc81999d62e3f2271c7c53c72fb7.zip | |
Stop using MoveDataParamEnv for places that don't need a param-env
Diffstat (limited to 'compiler/rustc_mir_dataflow/src/rustc_peek.rs')
| -rw-r--r-- | compiler/rustc_mir_dataflow/src/rustc_peek.rs | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/compiler/rustc_mir_dataflow/src/rustc_peek.rs b/compiler/rustc_mir_dataflow/src/rustc_peek.rs index 23bf35b30ca..0171cc85918 100644 --- a/compiler/rustc_mir_dataflow/src/rustc_peek.rs +++ b/compiler/rustc_mir_dataflow/src/rustc_peek.rs @@ -16,7 +16,7 @@ use crate::impls::{ DefinitelyInitializedPlaces, MaybeInitializedPlaces, MaybeLiveLocals, MaybeUninitializedPlaces, }; use crate::move_paths::{HasMoveData, LookupResult, MoveData, MovePathIndex}; -use crate::{Analysis, JoinSemiLattice, MoveDataParamEnv, ResultsCursor}; +use crate::{Analysis, JoinSemiLattice, ResultsCursor}; pub struct SanityCheck; @@ -46,10 +46,9 @@ impl<'tcx> MirPass<'tcx> for SanityCheck { let param_env = tcx.param_env(def_id); let move_data = MoveData::gather_moves(body, tcx, param_env, |_| true); - let mdpe = MoveDataParamEnv { move_data, param_env }; if has_rustc_mir_with(tcx, def_id, sym::rustc_peek_maybe_init).is_some() { - let flow_inits = MaybeInitializedPlaces::new(tcx, body, &mdpe) + let flow_inits = MaybeInitializedPlaces::new(tcx, body, &move_data) .into_engine(tcx, body) .iterate_to_fixpoint(); @@ -57,7 +56,7 @@ impl<'tcx> MirPass<'tcx> for SanityCheck { } if has_rustc_mir_with(tcx, def_id, sym::rustc_peek_maybe_uninit).is_some() { - let flow_uninits = MaybeUninitializedPlaces::new(tcx, body, &mdpe) + let flow_uninits = MaybeUninitializedPlaces::new(tcx, body, &move_data) .into_engine(tcx, body) .iterate_to_fixpoint(); @@ -65,7 +64,7 @@ impl<'tcx> MirPass<'tcx> for SanityCheck { } if has_rustc_mir_with(tcx, def_id, sym::rustc_peek_definite_init).is_some() { - let flow_def_inits = DefinitelyInitializedPlaces::new(body, &mdpe) + let flow_def_inits = DefinitelyInitializedPlaces::new(body, &move_data) .into_engine(tcx, body) .iterate_to_fixpoint(); |
