diff options
| author | Matthias Krüger <matthias.krueger@famsik.de> | 2022-12-20 14:37:32 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-12-20 14:37:32 +0100 |
| commit | c3af456d6da6bb85dbb8e545f7cab831549325a8 (patch) | |
| tree | 2a26ab28984129f3855eeb9680ec3fea1f04722b /compiler/rustc_mir_transform/src | |
| parent | 52fe5a1cc142562c549a54a41147a92e7e23e25f (diff) | |
| parent | 4251289f27949cec69d8aa39d3891a4977fbc856 (diff) | |
| download | rust-c3af456d6da6bb85dbb8e545f7cab831549325a8.tar.gz rust-c3af456d6da6bb85dbb8e545f7cab831549325a8.zip | |
Rollup merge of #105930 - JakobDegen:nal-unsound, r=oli-obk
Disable `NormalizeArrayLen` cc #105929 r? mir-opt
Diffstat (limited to 'compiler/rustc_mir_transform/src')
| -rw-r--r-- | compiler/rustc_mir_transform/src/normalize_array_len.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/compiler/rustc_mir_transform/src/normalize_array_len.rs b/compiler/rustc_mir_transform/src/normalize_array_len.rs index a159e617178..1708b287e56 100644 --- a/compiler/rustc_mir_transform/src/normalize_array_len.rs +++ b/compiler/rustc_mir_transform/src/normalize_array_len.rs @@ -16,7 +16,8 @@ pub struct NormalizeArrayLen; impl<'tcx> MirPass<'tcx> for NormalizeArrayLen { fn is_enabled(&self, sess: &rustc_session::Session) -> bool { - sess.mir_opt_level() >= 4 + // See #105929 + sess.mir_opt_level() >= 4 && sess.opts.unstable_opts.unsound_mir_opts } fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) { |
