Skip to content

Commit 99c42d2

Browse files
committedApr 3, 2024·
Auto merge of #123322 - matthewjasper:remove-mir-unsafeck, r=lcnr,compiler-errors
Remove MIR unsafe check Now that THIR unsafeck is enabled by default in stable I think we can remove MIR unsafeck entirely. This PR also removes safety information from MIR.
2 parents c7491b9 + a277c90 commit 99c42d2

File tree

194 files changed

+659
-2230
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

194 files changed

+659
-2230
lines changed
 

‎compiler/rustc_interface/src/passes.rs

-3
Original file line numberDiff line numberDiff line change
@@ -748,9 +748,6 @@ fn analysis(tcx: TyCtxt<'_>, (): ()) -> Result<()> {
748748

749749
sess.time("MIR_effect_checking", || {
750750
for def_id in tcx.hir().body_owners() {
751-
if !tcx.sess.opts.unstable_opts.thir_unsafeck {
752-
rustc_mir_transform::check_unsafety::check_unsafety(tcx, def_id);
753-
}
754751
tcx.ensure().has_ffi_unwind_calls(def_id);
755752

756753
// If we need to codegen, ensure that we emit all errors from

‎compiler/rustc_interface/src/tests.rs

-1
Original file line numberDiff line numberDiff line change
@@ -840,7 +840,6 @@ fn test_unstable_options_tracking_hash() {
840840
tracked!(stack_protector, StackProtector::All);
841841
tracked!(teach, true);
842842
tracked!(thinlto, Some(true));
843-
tracked!(thir_unsafeck, false);
844843
tracked!(tiny_const_eval_limit, true);
845844
tracked!(tls_model, Some(TlsModel::GeneralDynamic));
846845
tracked!(translate_remapped_path_to_local_path, false);

0 commit comments

Comments
 (0)
Please sign in to comment.