diff options
| author | Matthew Jasper <mjjasper1@gmail.com> | 2024-02-27 11:57:52 +0000 |
|---|---|---|
| committer | Matthew Jasper <mjjasper1@gmail.com> | 2024-04-03 08:50:12 +0000 |
| commit | a277c901d95c5fcbb3dbd6608731eebb9e1a01ce (patch) | |
| tree | 6537e75531ca8f2bb59e7cb6ae3903a6225be89f /compiler/rustc_mir_transform/src/lib.rs | |
| parent | 76cf07d5df52c07c3cd4cfeea1ab32b1cfba71bf (diff) | |
| download | rust-a277c901d95c5fcbb3dbd6608731eebb9e1a01ce.tar.gz rust-a277c901d95c5fcbb3dbd6608731eebb9e1a01ce.zip | |
Remove MIR unsafe check
This also remove safety information from MIR.
Diffstat (limited to 'compiler/rustc_mir_transform/src/lib.rs')
| -rw-r--r-- | compiler/rustc_mir_transform/src/lib.rs | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/compiler/rustc_mir_transform/src/lib.rs b/compiler/rustc_mir_transform/src/lib.rs index a684f9bdff1..e477c068229 100644 --- a/compiler/rustc_mir_transform/src/lib.rs +++ b/compiler/rustc_mir_transform/src/lib.rs @@ -53,7 +53,6 @@ mod add_moves_for_packed_drops; mod add_retag; mod check_const_item_mutation; mod check_packed_ref; -pub mod check_unsafety; mod remove_place_mention; // This pass is public to allow external drivers to perform MIR cleanup mod add_subtyping_projections; @@ -120,7 +119,6 @@ use rustc_mir_dataflow::rustc_peek; rustc_fluent_macro::fluent_messages! { "../messages.ftl" } pub fn provide(providers: &mut Providers) { - check_unsafety::provide(providers); coverage::query::provide(providers); ffi_unwind_calls::provide(providers); shim::provide(providers); @@ -280,11 +278,6 @@ fn mir_const_qualif(tcx: TyCtxt<'_>, def: LocalDefId) -> ConstQualifs { } fn mir_built(tcx: TyCtxt<'_>, def: LocalDefId) -> &Steal<Body<'_>> { - // MIR unsafety check uses the raw mir, so make sure it is run. - if !tcx.sess.opts.unstable_opts.thir_unsafeck { - tcx.ensure_with_value().mir_unsafety_check_result(def); - } - let mut body = tcx.build_mir(def); pass_manager::dump_mir_for_phase_change(tcx, &body); |
