about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--tests/ui/asm/aarch64/const.rs2
-rw-r--r--tests/ui/asm/bad-arch.rs2
-rw-r--r--tests/ui/asm/bad-arch.stderr (renamed from tests/ui/asm/bad-arch.mirunsafeck.stderr)4
-rw-r--r--tests/ui/asm/bad-arch.thirunsafeck.stderr17
-rw-r--r--tests/ui/asm/bad-template.aarch64.stderr (renamed from tests/ui/asm/bad-template.aarch64_mirunsafeck.stderr)52
-rw-r--r--tests/ui/asm/bad-template.aarch64_thirunsafeck.stderr202
-rw-r--r--tests/ui/asm/bad-template.rs22
-rw-r--r--tests/ui/asm/bad-template.x86_64.stderr (renamed from tests/ui/asm/bad-template.x86_64_mirunsafeck.stderr)52
-rw-r--r--tests/ui/asm/bad-template.x86_64_thirunsafeck.stderr202
-rw-r--r--tests/ui/asm/x86_64/const.rs2
-rw-r--r--tests/ui/async-await/async-await.rs3
-rw-r--r--tests/ui/async-await/async-unsafe-fn-call-in-safe.rs14
-rw-r--r--tests/ui/async-await/async-unsafe-fn-call-in-safe.stderr (renamed from tests/ui/async-await/async-unsafe-fn-call-in-safe.mir.stderr)8
-rw-r--r--tests/ui/async-await/async-unsafe-fn-call-in-safe.thir.stderr35
-rw-r--r--tests/ui/closures/closure_no_cap_coerce_many_unsafe_0.rs3
-rw-r--r--tests/ui/closures/closure_no_cap_coerce_many_unsafe_0.stderr (renamed from tests/ui/closures/closure_no_cap_coerce_many_unsafe_0.mir.stderr)4
-rw-r--r--tests/ui/closures/coerce-unsafe-closure-to-unsafe-fn-ptr.rs3
-rw-r--r--tests/ui/closures/coerce-unsafe-closure-to-unsafe-fn-ptr.stderr (renamed from tests/ui/closures/coerce-unsafe-closure-to-unsafe-fn-ptr.mir.stderr)2
-rw-r--r--tests/ui/closures/coerce-unsafe-closure-to-unsafe-fn-ptr.thir.stderr11
-rw-r--r--tests/ui/closures/thir-unsafeck-issue-85871.rs1
-rw-r--r--tests/ui/command/command-pre-exec.rs2
-rw-r--r--tests/ui/consts/const-extern-fn/const-extern-fn-requires-unsafe.rs9
-rw-r--r--tests/ui/consts/const-extern-fn/const-extern-fn-requires-unsafe.stderr (renamed from tests/ui/closures/closure_no_cap_coerce_many_unsafe_0.thir.stderr)12
-rw-r--r--tests/ui/consts/issue-16538.rs3
-rw-r--r--tests/ui/consts/issue-16538.stderr (renamed from tests/ui/consts/issue-16538.mir.stderr)6
-rw-r--r--tests/ui/consts/issue-16538.thir.stderr29
-rw-r--r--tests/ui/coroutine/issue-45729-unsafe-in-coroutine.rs3
-rw-r--r--tests/ui/coroutine/issue-45729-unsafe-in-coroutine.stderr (renamed from tests/ui/coroutine/issue-45729-unsafe-in-coroutine.mir.stderr)2
-rw-r--r--tests/ui/coroutine/issue-45729-unsafe-in-coroutine.thir.stderr11
-rw-r--r--tests/ui/coroutine/static-mut-reference-across-yield.rs2
-rw-r--r--tests/ui/error-codes/E0133.rs3
-rw-r--r--tests/ui/error-codes/E0133.stderr (renamed from tests/ui/error-codes/E0133.mir.stderr)2
-rw-r--r--tests/ui/error-codes/E0133.thir.stderr11
-rw-r--r--tests/ui/extern/issue-28324.rs3
-rw-r--r--tests/ui/extern/issue-28324.stderr (renamed from tests/ui/extern/issue-28324.mir.stderr)2
-rw-r--r--tests/ui/extern/issue-28324.thir.stderr11
-rw-r--r--tests/ui/inline-const/expr-unsafe-err.rs6
-rw-r--r--tests/ui/inline-const/expr-unsafe-err.stderr (renamed from tests/ui/inline-const/expr-unsafe-err.mir.stderr)0
-rw-r--r--tests/ui/inline-const/expr-unsafe-err.thir.stderr11
-rw-r--r--tests/ui/inline-const/expr-unsafe.rs3
-rw-r--r--tests/ui/inline-const/expr-unsafe.stderr (renamed from tests/ui/inline-const/expr-unsafe.mir.stderr)4
-rw-r--r--tests/ui/inline-const/expr-unsafe.thir.stderr14
-rw-r--r--tests/ui/inline-const/pat-unsafe-err.rs4
-rw-r--r--tests/ui/inline-const/pat-unsafe-err.thir.stderr19
-rw-r--r--tests/ui/inline-const/pat-unsafe.rs4
-rw-r--r--tests/ui/inline-const/pat-unsafe.thir.stderr20
-rw-r--r--tests/ui/intrinsics/issue-28575.rs3
-rw-r--r--tests/ui/intrinsics/issue-28575.stderr (renamed from tests/ui/intrinsics/issue-28575.mir.stderr)2
-rw-r--r--tests/ui/intrinsics/issue-28575.thir.stderr11
-rw-r--r--tests/ui/intrinsics/unchecked_math_unsafe.rs3
-rw-r--r--tests/ui/intrinsics/unchecked_math_unsafe.stderr (renamed from tests/ui/intrinsics/unchecked_math_unsafe.mir.stderr)6
-rw-r--r--tests/ui/intrinsics/unchecked_math_unsafe.thir.stderr27
-rw-r--r--tests/ui/issues/issue-11740.rs2
-rw-r--r--tests/ui/issues/issue-28776.rs3
-rw-r--r--tests/ui/issues/issue-28776.stderr (renamed from tests/ui/issues/issue-28776.mir.stderr)2
-rw-r--r--tests/ui/issues/issue-28776.thir.stderr11
-rw-r--r--tests/ui/issues/issue-39367.rs2
-rw-r--r--tests/ui/issues/issue-48131.mir.stderr20
-rw-r--r--tests/ui/issues/issue-48131.rs3
-rw-r--r--tests/ui/issues/issue-48131.stderr (renamed from tests/ui/issues/issue-48131.thir.stderr)6
-rw-r--r--tests/ui/issues/issue-5844.rs4
-rw-r--r--tests/ui/issues/issue-5844.stderr (renamed from tests/ui/issues/issue-5844.mir.stderr)2
-rw-r--r--tests/ui/issues/issue-5844.thir.stderr11
-rw-r--r--tests/ui/lto/lto-still-runs-thread-dtors.rs2
-rw-r--r--tests/ui/pattern/non-structural-match-types.mir.stderr14
-rw-r--r--tests/ui/pattern/non-structural-match-types.rs2
-rw-r--r--tests/ui/pattern/non-structural-match-types.stderr14
-rw-r--r--tests/ui/pattern/non-structural-match-types.thir.stderr14
-rw-r--r--tests/ui/process/no-stdio.rs2
-rw-r--r--tests/ui/rfcs/rfc-2396-target_feature-11/check-pass.rs2
-rw-r--r--tests/ui/rfcs/rfc-2396-target_feature-11/closures-inherit-target_feature.rs6
-rw-r--r--tests/ui/rfcs/rfc-2396-target_feature-11/fn-ptr.rs2
-rw-r--r--tests/ui/rfcs/rfc-2396-target_feature-11/fn-ptr.stderr23
-rw-r--r--tests/ui/rfcs/rfc-2396-target_feature-11/issue-108655-inline-always-closure.rs2
-rw-r--r--tests/ui/rfcs/rfc-2396-target_feature-11/safe-calls.rs39
-rw-r--r--tests/ui/rfcs/rfc-2396-target_feature-11/safe-calls.stderr115
-rw-r--r--tests/ui/runtime/running-with-no-runtime.rs2
-rw-r--r--tests/ui/simd/intrinsic/generic-comparison-pass.rs2
-rw-r--r--tests/ui/span/lint-unused-unsafe.rs3
-rw-r--r--tests/ui/span/lint-unused-unsafe.stderr (renamed from tests/ui/span/lint-unused-unsafe.mir.stderr)376
-rw-r--r--tests/ui/span/lint-unused-unsafe.thir.stderr1402
-rw-r--r--tests/ui/static/safe-extern-statics-mut.rs2
-rw-r--r--tests/ui/static/safe-extern-statics-mut.stderr (renamed from tests/ui/static/safe-extern-statics-mut.mir.stderr)8
-rw-r--r--tests/ui/static/safe-extern-statics-mut.thir.stderr35
-rw-r--r--tests/ui/static/safe-extern-statics.rs2
-rw-r--r--tests/ui/static/safe-extern-statics.stderr (renamed from tests/ui/static/safe-extern-statics.mir.stderr)8
-rw-r--r--tests/ui/static/safe-extern-statics.thir.stderr35
-rw-r--r--tests/ui/static/static-mut-foreign-requires-unsafe.rs3
-rw-r--r--tests/ui/static/static-mut-foreign-requires-unsafe.stderr (renamed from tests/ui/static/static-mut-foreign-requires-unsafe.mir.stderr)6
-rw-r--r--tests/ui/static/static-mut-foreign-requires-unsafe.thir.stderr27
-rw-r--r--tests/ui/static/static-mut-requires-unsafe.rs3
-rw-r--r--tests/ui/static/static-mut-requires-unsafe.stderr (renamed from tests/ui/static/static-mut-requires-unsafe.mir.stderr)6
-rw-r--r--tests/ui/static/static-mut-requires-unsafe.thir.stderr27
-rw-r--r--tests/ui/statics/issue-14227.rs3
-rw-r--r--tests/ui/statics/issue-14227.stderr (renamed from tests/ui/statics/issue-14227.mir.stderr)2
-rw-r--r--tests/ui/statics/issue-14227.thir.stderr11
-rw-r--r--tests/ui/thread-local/thread-local-static.rs2
-rw-r--r--tests/ui/thread-local/thread-local-static.stderr (renamed from tests/ui/thread-local/thread-local-static.mir.stderr)10
-rw-r--r--tests/ui/thread-local/thread-local-static.thir.stderr44
-rw-r--r--tests/ui/threads-sendsync/issue-43733.rs8
-rw-r--r--tests/ui/threads-sendsync/issue-43733.stderr (renamed from tests/ui/threads-sendsync/issue-43733.mir.stderr)4
-rw-r--r--tests/ui/threads-sendsync/issue-43733.thir.stderr19
-rw-r--r--tests/ui/traits/safety-fn-body.rs3
-rw-r--r--tests/ui/traits/safety-fn-body.stderr (renamed from tests/ui/traits/safety-fn-body.mir.stderr)2
-rw-r--r--tests/ui/traits/safety-fn-body.thir.stderr11
-rw-r--r--tests/ui/union/union-align.rs2
-rw-r--r--tests/ui/union/union-backcomp.rs2
-rw-r--r--tests/ui/union/union-basic.rs2
-rw-r--r--tests/ui/union/union-borrow-move-parent-sibling.rs3
-rw-r--r--tests/ui/union/union-borrow-move-parent-sibling.stderr (renamed from tests/ui/union/union-borrow-move-parent-sibling.mirunsafeck.stderr)14
-rw-r--r--tests/ui/union/union-borrow-move-parent-sibling.thirunsafeck.stderr84
-rw-r--r--tests/ui/union/union-const-codegen.rs2
-rw-r--r--tests/ui/union/union-const-eval-field.rs2
-rw-r--r--tests/ui/union/union-const-eval.rs2
-rw-r--r--tests/ui/union/union-deref.rs3
-rw-r--r--tests/ui/union/union-deref.stderr (renamed from tests/ui/union/union-deref.mirunsafeck.stderr)12
-rw-r--r--tests/ui/union/union-deref.thirunsafeck.stderr56
-rw-r--r--tests/ui/union/union-derive-clone.rs3
-rw-r--r--tests/ui/union/union-derive-clone.stderr (renamed from tests/ui/union/union-derive-clone.mirunsafeck.stderr)6
-rw-r--r--tests/ui/union/union-derive-clone.thirunsafeck.stderr45
-rw-r--r--tests/ui/union/union-derive-eq.rs3
-rw-r--r--tests/ui/union/union-derive-eq.stderr (renamed from tests/ui/union/union-derive-eq.mirunsafeck.stderr)2
-rw-r--r--tests/ui/union/union-derive-eq.thirunsafeck.stderr21
-rw-r--r--tests/ui/union/union-derive-rpass.rs2
-rw-r--r--tests/ui/union/union-drop.rs2
-rw-r--r--tests/ui/union/union-fields-1.mirunsafeck.stderr42
-rw-r--r--tests/ui/union/union-fields-1.rs3
-rw-r--r--tests/ui/union/union-fields-1.stderr (renamed from tests/ui/union/union-fields-1.thirunsafeck.stderr)10
-rw-r--r--tests/ui/union/union-fields-2.rs3
-rw-r--r--tests/ui/union/union-fields-2.stderr (renamed from tests/ui/union/union-fields-2.mirunsafeck.stderr)26
-rw-r--r--tests/ui/union/union-fields-2.thirunsafeck.stderr84
-rw-r--r--tests/ui/union/union-generic-rpass.rs3
-rw-r--r--tests/ui/union/union-generic.rs3
-rw-r--r--tests/ui/union/union-generic.stderr (renamed from tests/ui/union/union-generic.mirunsafeck.stderr)8
-rw-r--r--tests/ui/union/union-generic.thirunsafeck.stderr27
-rw-r--r--tests/ui/union/union-inherent-method.rs2
-rw-r--r--tests/ui/union/union-lint-dead-code.rs3
-rw-r--r--tests/ui/union/union-lint-dead-code.stderr (renamed from tests/ui/union/union-lint-dead-code.mirunsafeck.stderr)4
-rw-r--r--tests/ui/union/union-lint-dead-code.thirunsafeck.stderr17
-rw-r--r--tests/ui/union/union-macro.rs2
-rw-r--r--tests/ui/union/union-manuallydrop-rpass.rs7
-rw-r--r--tests/ui/union/union-move.rs3
-rw-r--r--tests/ui/union/union-move.stderr (renamed from tests/ui/union/union-move.mirunsafeck.stderr)10
-rw-r--r--tests/ui/union/union-move.thirunsafeck.stderr51
-rw-r--r--tests/ui/union/union-nodrop.rs16
-rw-r--r--tests/ui/union/union-nonzero.rs2
-rw-r--r--tests/ui/union/union-overwrite.rs2
-rw-r--r--tests/ui/union/union-packed.rs2
-rw-r--r--tests/ui/union/union-pat-refutability.rs7
-rw-r--r--tests/ui/union/union-suggest-field.rs3
-rw-r--r--tests/ui/union/union-suggest-field.stderr (renamed from tests/ui/union/union-suggest-field.mirunsafeck.stderr)6
-rw-r--r--tests/ui/union/union-suggest-field.thirunsafeck.stderr37
-rw-r--r--tests/ui/union/union-trait-impl.rs2
-rw-r--r--tests/ui/union/union-transmute.rs2
-rw-r--r--tests/ui/union/union-unsafe.rs4
-rw-r--r--tests/ui/union/union-unsafe.stderr (renamed from tests/ui/union/union-unsafe.mir.stderr)20
-rw-r--r--tests/ui/union/union-unsafe.thir.stderr83
-rw-r--r--tests/ui/union/union-unsized.rs3
-rw-r--r--tests/ui/union/union-unsized.stderr (renamed from tests/ui/union/union-unsized.mirunsafeck.stderr)18
-rw-r--r--tests/ui/union/union-unsized.thirunsafeck.stderr64
-rw-r--r--tests/ui/union/union-with-drop-fields.rs3
-rw-r--r--tests/ui/union/union-with-drop-fields.stderr (renamed from tests/ui/union/union-with-drop-fields.mirunsafeck.stderr)6
-rw-r--r--tests/ui/union/union-with-drop-fields.thirunsafeck.stderr39
-rw-r--r--tests/ui/unsafe/access_union_field.rs3
-rw-r--r--tests/ui/unsafe/access_union_field.stderr (renamed from tests/ui/unsafe/access_union_field.mir.stderr)4
-rw-r--r--tests/ui/unsafe/access_union_field.thir.stderr19
-rw-r--r--tests/ui/unsafe/edition-2024-unsafe_op_in_unsafe_fn.rs6
-rw-r--r--tests/ui/unsafe/edition-2024-unsafe_op_in_unsafe_fn.stderr (renamed from tests/ui/unsafe/edition-2024-unsafe_op_in_unsafe_fn.mir.stderr)4
-rw-r--r--tests/ui/unsafe/edition-2024-unsafe_op_in_unsafe_fn.thir.stderr16
-rw-r--r--tests/ui/unsafe/foreign-unsafe-fn-called.rs6
-rw-r--r--tests/ui/unsafe/foreign-unsafe-fn-called.stderr (renamed from tests/ui/unsafe/foreign-unsafe-fn-called.mir.stderr)2
-rw-r--r--tests/ui/unsafe/foreign-unsafe-fn-called.thir.stderr11
-rw-r--r--tests/ui/unsafe/inline_asm.rs2
-rw-r--r--tests/ui/unsafe/inline_asm.stderr (renamed from tests/ui/unsafe/inline_asm.mir.stderr)2
-rw-r--r--tests/ui/unsafe/inline_asm.thir.stderr11
-rw-r--r--tests/ui/unsafe/issue-3080.rs3
-rw-r--r--tests/ui/unsafe/issue-3080.stderr (renamed from tests/ui/unsafe/issue-3080.mir.stderr)2
-rw-r--r--tests/ui/unsafe/issue-3080.thir.stderr11
-rw-r--r--tests/ui/unsafe/issue-45087-unreachable-unsafe.rs2
-rw-r--r--tests/ui/unsafe/issue-45087-unreachable-unsafe.stderr (renamed from tests/ui/unsafe/issue-45087-unreachable-unsafe.mir.stderr)6
-rw-r--r--tests/ui/unsafe/issue-45087-unreachable-unsafe.thir.stderr27
-rw-r--r--tests/ui/unsafe/issue-45107-unnecessary-unsafe-in-closure.rs3
-rw-r--r--tests/ui/unsafe/issue-45107-unnecessary-unsafe-in-closure.stderr (renamed from tests/ui/unsafe/issue-45107-unnecessary-unsafe-in-closure.mir.stderr)8
-rw-r--r--tests/ui/unsafe/issue-45107-unnecessary-unsafe-in-closure.thir.stderr35
-rw-r--r--tests/ui/unsafe/issue-47412.rs3
-rw-r--r--tests/ui/unsafe/issue-47412.stderr (renamed from tests/ui/unsafe/issue-47412.mir.stderr)4
-rw-r--r--tests/ui/unsafe/issue-47412.thir.stderr19
-rw-r--r--tests/ui/unsafe/issue-85435-unsafe-op-in-let-under-unsafe-under-closure.rs2
-rw-r--r--tests/ui/unsafe/issue-87414-query-cycle.rs1
-rw-r--r--tests/ui/unsafe/ranged_ints.rs3
-rw-r--r--tests/ui/unsafe/ranged_ints.stderr (renamed from tests/ui/unsafe/ranged_ints.mir.stderr)2
-rw-r--r--tests/ui/unsafe/ranged_ints.thir.stderr11
-rw-r--r--tests/ui/unsafe/ranged_ints2.rs3
-rw-r--r--tests/ui/unsafe/ranged_ints2.stderr (renamed from tests/ui/unsafe/ranged_ints2.mirunsafeck.stderr)4
-rw-r--r--tests/ui/unsafe/ranged_ints2.thirunsafeck.stderr19
-rw-r--r--tests/ui/unsafe/ranged_ints2_const.rs3
-rw-r--r--tests/ui/unsafe/ranged_ints2_const.stderr (renamed from tests/ui/unsafe/ranged_ints2_const.mirunsafeck.stderr)8
-rw-r--r--tests/ui/unsafe/ranged_ints2_const.thirunsafeck.stderr39
-rw-r--r--tests/ui/unsafe/ranged_ints3.rs3
-rw-r--r--tests/ui/unsafe/ranged_ints3.stderr (renamed from tests/ui/unsafe/ranged_ints3.mirunsafeck.stderr)2
-rw-r--r--tests/ui/unsafe/ranged_ints3.thirunsafeck.stderr11
-rw-r--r--tests/ui/unsafe/ranged_ints3_const.rs3
-rw-r--r--tests/ui/unsafe/ranged_ints3_const.stderr (renamed from tests/ui/unsafe/ranged_ints3_const.mirunsafeck.stderr)6
-rw-r--r--tests/ui/unsafe/ranged_ints3_const.thirunsafeck.stderr30
-rw-r--r--tests/ui/unsafe/ranged_ints3_match.rs3
-rw-r--r--tests/ui/unsafe/ranged_ints3_match.stderr (renamed from tests/ui/unsafe/ranged_ints3_match.mirunsafeck.stderr)4
-rw-r--r--tests/ui/unsafe/ranged_ints3_match.thirunsafeck.stderr19
-rw-r--r--tests/ui/unsafe/ranged_ints4.mirunsafeck.stderr11
-rw-r--r--tests/ui/unsafe/ranged_ints4.rs3
-rw-r--r--tests/ui/unsafe/ranged_ints4.stderr (renamed from tests/ui/unsafe/ranged_ints4.thirunsafeck.stderr)2
-rw-r--r--tests/ui/unsafe/ranged_ints4_const.rs3
-rw-r--r--tests/ui/unsafe/ranged_ints4_const.stderr (renamed from tests/ui/unsafe/ranged_ints4_const.mirunsafeck.stderr)2
-rw-r--r--tests/ui/unsafe/ranged_ints4_const.thirunsafeck.stderr11
-rw-r--r--tests/ui/unsafe/ranged_ints_const.rs3
-rw-r--r--tests/ui/unsafe/ranged_ints_const.stderr (renamed from tests/ui/unsafe/ranged_ints_const.mir.stderr)2
-rw-r--r--tests/ui/unsafe/ranged_ints_const.thir.stderr11
-rw-r--r--tests/ui/unsafe/ranged_ints_macro.rs2
-rw-r--r--tests/ui/unsafe/rfc-2585-unsafe_op_in_unsafe_fn.rs15
-rw-r--r--tests/ui/unsafe/rfc-2585-unsafe_op_in_unsafe_fn.stderr (renamed from tests/ui/unsafe/rfc-2585-unsafe_op_in_unsafe_fn.mir.stderr)32
-rw-r--r--tests/ui/unsafe/rfc-2585-unsafe_op_in_unsafe_fn.thir.stderr112
-rw-r--r--tests/ui/unsafe/union-assignop.rs3
-rw-r--r--tests/ui/unsafe/union-assignop.stderr (renamed from tests/ui/unsafe/union-assignop.mirunsafeck.stderr)12
-rw-r--r--tests/ui/unsafe/union-assignop.thirunsafeck.stderr51
-rw-r--r--tests/ui/unsafe/union-modification.rs3
-rw-r--r--tests/ui/unsafe/union.rs11
-rw-r--r--tests/ui/unsafe/union.stderr (renamed from tests/ui/unsafe/union.mir.stderr)4
-rw-r--r--tests/ui/unsafe/union.thir.stderr38
-rw-r--r--tests/ui/unsafe/union_access_through_block.rs3
-rw-r--r--tests/ui/unsafe/union_destructure.rs6
-rw-r--r--tests/ui/unsafe/union_destructure.stderr (renamed from tests/ui/unsafe/union_destructure.mir.stderr)4
-rw-r--r--tests/ui/unsafe/union_wild_or_wild.rs3
-rw-r--r--tests/ui/unsafe/unsafe-around-compiler-generated-unsafe.mir.stderr20
-rw-r--r--tests/ui/unsafe/unsafe-around-compiler-generated-unsafe.rs2
-rw-r--r--tests/ui/unsafe/unsafe-around-compiler-generated-unsafe.stderr (renamed from tests/ui/unsafe/unsafe-around-compiler-generated-unsafe.thir.stderr)6
-rw-r--r--tests/ui/unsafe/unsafe-assign.rs3
-rw-r--r--tests/ui/unsafe/unsafe-assign.stderr (renamed from tests/ui/unsafe/unsafe-assign.mirunsafeck.stderr)2
-rw-r--r--tests/ui/unsafe/unsafe-assign.thirunsafeck.stderr11
-rw-r--r--tests/ui/unsafe/unsafe-borrow.rs3
-rw-r--r--tests/ui/unsafe/unsafe-borrow.stderr (renamed from tests/ui/unsafe/unsafe-borrow.mirunsafeck.stderr)6
-rw-r--r--tests/ui/unsafe/unsafe-borrow.thirunsafeck.stderr27
-rw-r--r--tests/ui/unsafe/unsafe-const-fn.rs3
-rw-r--r--tests/ui/unsafe/unsafe-const-fn.stderr (renamed from tests/ui/unsafe/unsafe-const-fn.mir.stderr)2
-rw-r--r--tests/ui/unsafe/unsafe-const-fn.thir.stderr11
-rw-r--r--tests/ui/unsafe/unsafe-fn-assign-deref-ptr.rs3
-rw-r--r--tests/ui/unsafe/unsafe-fn-assign-deref-ptr.stderr (renamed from tests/ui/unsafe/unsafe-fn-assign-deref-ptr.mir.stderr)2
-rw-r--r--tests/ui/unsafe/unsafe-fn-assign-deref-ptr.thir.stderr11
-rw-r--r--tests/ui/unsafe/unsafe-fn-called-from-safe.rs6
-rw-r--r--tests/ui/unsafe/unsafe-fn-called-from-safe.stderr (renamed from tests/ui/unsafe/unsafe-fn-called-from-safe.mir.stderr)2
-rw-r--r--tests/ui/unsafe/unsafe-fn-called-from-safe.thir.stderr11
-rw-r--r--tests/ui/unsafe/unsafe-fn-deref-ptr.rs3
-rw-r--r--tests/ui/unsafe/unsafe-fn-deref-ptr.stderr (renamed from tests/ui/unsafe/unsafe-fn-deref-ptr.mir.stderr)8
-rw-r--r--tests/ui/unsafe/unsafe-fn-deref-ptr.thir.stderr35
-rw-r--r--tests/ui/unsafe/unsafe-fn-used-as-value.rs6
-rw-r--r--tests/ui/unsafe/unsafe-fn-used-as-value.stderr (renamed from tests/ui/unsafe/unsafe-fn-used-as-value.mir.stderr)2
-rw-r--r--tests/ui/unsafe/unsafe-fn-used-as-value.thir.stderr11
-rw-r--r--tests/ui/unsafe/unsafe-not-inherited.rs2
-rw-r--r--tests/ui/unsafe/unsafe-not-inherited.stderr (renamed from tests/ui/unsafe/unsafe-not-inherited.mirunsafeck.stderr)4
-rw-r--r--tests/ui/unsafe/unsafe-not-inherited.thirunsafeck.stderr24
-rw-r--r--tests/ui/unsafe/unsafe-unstable-const-fn.rs3
-rw-r--r--tests/ui/unsafe/unsafe-unstable-const-fn.stderr (renamed from tests/ui/unsafe/unsafe-unstable-const-fn.mir.stderr)2
-rw-r--r--tests/ui/unsafe/unsafe-unstable-const-fn.thir.stderr11
-rw-r--r--tests/ui/unsafe/wrapping-unsafe-block-sugg.fixed (renamed from tests/ui/unsafe/wrapping-unsafe-block-sugg.mir.fixed)18
-rw-r--r--tests/ui/unsafe/wrapping-unsafe-block-sugg.rs18
-rw-r--r--tests/ui/unsafe/wrapping-unsafe-block-sugg.stderr (renamed from tests/ui/unsafe/wrapping-unsafe-block-sugg.mir.stderr)26
-rw-r--r--tests/ui/unsafe/wrapping-unsafe-block-sugg.thir.fixed73
-rw-r--r--tests/ui/unsafe/wrapping-unsafe-block-sugg.thir.stderr99
266 files changed, 694 insertions, 4667 deletions
diff --git a/tests/ui/asm/aarch64/const.rs b/tests/ui/asm/aarch64/const.rs
index de299bfdbdf..0b02c99abf6 100644
--- a/tests/ui/asm/aarch64/const.rs
+++ b/tests/ui/asm/aarch64/const.rs
@@ -1,8 +1,6 @@
 // only-aarch64
 // run-pass
 // needs-asm-support
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 #![feature(asm_const)]
 
diff --git a/tests/ui/asm/bad-arch.rs b/tests/ui/asm/bad-arch.rs
index 93309899bf3..3eeb76f3d00 100644
--- a/tests/ui/asm/bad-arch.rs
+++ b/tests/ui/asm/bad-arch.rs
@@ -1,7 +1,5 @@
 // compile-flags: --target sparc-unknown-linux-gnu
 // needs-llvm-components: sparc
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 #![feature(no_core, lang_items, rustc_attrs)]
 #![no_core]
diff --git a/tests/ui/asm/bad-arch.mirunsafeck.stderr b/tests/ui/asm/bad-arch.stderr
index d7af296152f..23aad9908ef 100644
--- a/tests/ui/asm/bad-arch.mirunsafeck.stderr
+++ b/tests/ui/asm/bad-arch.stderr
@@ -1,11 +1,11 @@
 error[E0472]: inline assembly is unsupported on this target
-  --> $DIR/bad-arch.rs:22:9
+  --> $DIR/bad-arch.rs:20:9
    |
 LL |         asm!("");
    |         ^^^^^^^^
 
 error[E0472]: inline assembly is unsupported on this target
-  --> $DIR/bad-arch.rs:27:1
+  --> $DIR/bad-arch.rs:25:1
    |
 LL | global_asm!("");
    | ^^^^^^^^^^^^^^^
diff --git a/tests/ui/asm/bad-arch.thirunsafeck.stderr b/tests/ui/asm/bad-arch.thirunsafeck.stderr
deleted file mode 100644
index d7af296152f..00000000000
--- a/tests/ui/asm/bad-arch.thirunsafeck.stderr
+++ /dev/null
@@ -1,17 +0,0 @@
-error[E0472]: inline assembly is unsupported on this target
-  --> $DIR/bad-arch.rs:22:9
-   |
-LL |         asm!("");
-   |         ^^^^^^^^
-
-error[E0472]: inline assembly is unsupported on this target
-  --> $DIR/bad-arch.rs:27:1
-   |
-LL | global_asm!("");
-   | ^^^^^^^^^^^^^^^
-   |
-   = note: this error originates in the macro `global_asm` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error: aborting due to 2 previous errors
-
-For more information about this error, try `rustc --explain E0472`.
diff --git a/tests/ui/asm/bad-template.aarch64_mirunsafeck.stderr b/tests/ui/asm/bad-template.aarch64.stderr
index b16f9a06c2a..4ffcd2303b7 100644
--- a/tests/ui/asm/bad-template.aarch64_mirunsafeck.stderr
+++ b/tests/ui/asm/bad-template.aarch64.stderr
@@ -1,5 +1,5 @@
 error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:31:15
+  --> $DIR/bad-template.rs:27:15
    |
 LL |         asm!("{}");
    |               ^^ from here
@@ -7,7 +7,7 @@ LL |         asm!("{}");
    = note: no arguments were given
 
 error: invalid reference to argument at index 1
-  --> $DIR/bad-template.rs:33:15
+  --> $DIR/bad-template.rs:29:15
    |
 LL |         asm!("{1}", in(reg) foo);
    |               ^^^ from here
@@ -15,7 +15,7 @@ LL |         asm!("{1}", in(reg) foo);
    = note: there is 1 argument
 
 error: argument never used
-  --> $DIR/bad-template.rs:33:21
+  --> $DIR/bad-template.rs:29:21
    |
 LL |         asm!("{1}", in(reg) foo);
    |                     ^^^^^^^^^^^ argument never used
@@ -23,13 +23,13 @@ LL |         asm!("{1}", in(reg) foo);
    = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {0} */"`
 
 error: there is no argument named `a`
-  --> $DIR/bad-template.rs:36:16
+  --> $DIR/bad-template.rs:32:16
    |
 LL |         asm!("{a}");
    |                ^
 
 error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:38:15
+  --> $DIR/bad-template.rs:34:15
    |
 LL |         asm!("{}", a = in(reg) foo);
    |               ^^   --------------- named argument
@@ -38,13 +38,13 @@ LL |         asm!("{}", a = in(reg) foo);
    |
    = note: no positional arguments were given
 note: named arguments cannot be referenced by position
-  --> $DIR/bad-template.rs:38:20
+  --> $DIR/bad-template.rs:34:20
    |
 LL |         asm!("{}", a = in(reg) foo);
    |                    ^^^^^^^^^^^^^^^
 
 error: named argument never used
-  --> $DIR/bad-template.rs:38:20
+  --> $DIR/bad-template.rs:34:20
    |
 LL |         asm!("{}", a = in(reg) foo);
    |                    ^^^^^^^^^^^^^^^ named argument never used
@@ -52,7 +52,7 @@ LL |         asm!("{}", a = in(reg) foo);
    = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {a} */"`
 
 error: invalid reference to argument at index 1
-  --> $DIR/bad-template.rs:41:15
+  --> $DIR/bad-template.rs:37:15
    |
 LL |         asm!("{1}", a = in(reg) foo);
    |               ^^^ from here
@@ -60,7 +60,7 @@ LL |         asm!("{1}", a = in(reg) foo);
    = note: no positional arguments were given
 
 error: named argument never used
-  --> $DIR/bad-template.rs:41:21
+  --> $DIR/bad-template.rs:37:21
    |
 LL |         asm!("{1}", a = in(reg) foo);
    |                     ^^^^^^^^^^^^^^^ named argument never used
@@ -68,7 +68,7 @@ LL |         asm!("{1}", a = in(reg) foo);
    = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {a} */"`
 
 error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:48:15
+  --> $DIR/bad-template.rs:44:15
    |
 LL |         asm!("{}", in("x0") foo);
    |               ^^   ------------ explicit register argument
@@ -77,24 +77,24 @@ LL |         asm!("{}", in("x0") foo);
    |
    = note: no positional arguments were given
 note: explicit register arguments cannot be used in the asm template
-  --> $DIR/bad-template.rs:48:20
+  --> $DIR/bad-template.rs:44:20
    |
 LL |         asm!("{}", in("x0") foo);
    |                    ^^^^^^^^^^^^
 help: use the register name directly in the assembly code
-  --> $DIR/bad-template.rs:48:20
+  --> $DIR/bad-template.rs:44:20
    |
 LL |         asm!("{}", in("x0") foo);
    |                    ^^^^^^^^^^^^
 
 error: asm template modifier must be a single character
-  --> $DIR/bad-template.rs:50:17
+  --> $DIR/bad-template.rs:46:17
    |
 LL |         asm!("{:foo}", in(reg) foo);
    |                 ^^^
 
 error: multiple unused asm arguments
-  --> $DIR/bad-template.rs:53:18
+  --> $DIR/bad-template.rs:49:18
    |
 LL |         asm!("", in(reg) 0, in(reg) 1);
    |                  ^^^^^^^^^  ^^^^^^^^^ argument never used
@@ -104,7 +104,7 @@ LL |         asm!("", in(reg) 0, in(reg) 1);
    = help: if these arguments are intentionally unused, consider using them in an asm comment: `"/* {0} {1} */"`
 
 error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:59:14
+  --> $DIR/bad-template.rs:55:14
    |
 LL | global_asm!("{}");
    |              ^^ from here
@@ -112,7 +112,7 @@ LL | global_asm!("{}");
    = note: no arguments were given
 
 error: invalid reference to argument at index 1
-  --> $DIR/bad-template.rs:61:14
+  --> $DIR/bad-template.rs:57:14
    |
 LL | global_asm!("{1}", const FOO);
    |              ^^^ from here
@@ -120,7 +120,7 @@ LL | global_asm!("{1}", const FOO);
    = note: there is 1 argument
 
 error: argument never used
-  --> $DIR/bad-template.rs:61:20
+  --> $DIR/bad-template.rs:57:20
    |
 LL | global_asm!("{1}", const FOO);
    |                    ^^^^^^^^^ argument never used
@@ -128,13 +128,13 @@ LL | global_asm!("{1}", const FOO);
    = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {0} */"`
 
 error: there is no argument named `a`
-  --> $DIR/bad-template.rs:64:15
+  --> $DIR/bad-template.rs:60:15
    |
 LL | global_asm!("{a}");
    |               ^
 
 error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:66:14
+  --> $DIR/bad-template.rs:62:14
    |
 LL | global_asm!("{}", a = const FOO);
    |              ^^   ------------- named argument
@@ -143,13 +143,13 @@ LL | global_asm!("{}", a = const FOO);
    |
    = note: no positional arguments were given
 note: named arguments cannot be referenced by position
-  --> $DIR/bad-template.rs:66:19
+  --> $DIR/bad-template.rs:62:19
    |
 LL | global_asm!("{}", a = const FOO);
    |                   ^^^^^^^^^^^^^
 
 error: named argument never used
-  --> $DIR/bad-template.rs:66:19
+  --> $DIR/bad-template.rs:62:19
    |
 LL | global_asm!("{}", a = const FOO);
    |                   ^^^^^^^^^^^^^ named argument never used
@@ -157,7 +157,7 @@ LL | global_asm!("{}", a = const FOO);
    = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {a} */"`
 
 error: invalid reference to argument at index 1
-  --> $DIR/bad-template.rs:69:14
+  --> $DIR/bad-template.rs:65:14
    |
 LL | global_asm!("{1}", a = const FOO);
    |              ^^^ from here
@@ -165,7 +165,7 @@ LL | global_asm!("{1}", a = const FOO);
    = note: no positional arguments were given
 
 error: named argument never used
-  --> $DIR/bad-template.rs:69:20
+  --> $DIR/bad-template.rs:65:20
    |
 LL | global_asm!("{1}", a = const FOO);
    |                    ^^^^^^^^^^^^^ named argument never used
@@ -173,13 +173,13 @@ LL | global_asm!("{1}", a = const FOO);
    = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {a} */"`
 
 error: asm template modifier must be a single character
-  --> $DIR/bad-template.rs:72:16
+  --> $DIR/bad-template.rs:68:16
    |
 LL | global_asm!("{:foo}", const FOO);
    |                ^^^
 
 error: multiple unused asm arguments
-  --> $DIR/bad-template.rs:74:17
+  --> $DIR/bad-template.rs:70:17
    |
 LL | global_asm!("", const FOO, const FOO);
    |                 ^^^^^^^^^  ^^^^^^^^^ argument never used
@@ -189,7 +189,7 @@ LL | global_asm!("", const FOO, const FOO);
    = help: if these arguments are intentionally unused, consider using them in an asm comment: `"/* {0} {1} */"`
 
 warning: formatting may not be suitable for sub-register argument
-  --> $DIR/bad-template.rs:50:15
+  --> $DIR/bad-template.rs:46:15
    |
 LL |         asm!("{:foo}", in(reg) foo);
    |               ^^^^^^           --- for this argument
diff --git a/tests/ui/asm/bad-template.aarch64_thirunsafeck.stderr b/tests/ui/asm/bad-template.aarch64_thirunsafeck.stderr
deleted file mode 100644
index b16f9a06c2a..00000000000
--- a/tests/ui/asm/bad-template.aarch64_thirunsafeck.stderr
+++ /dev/null
@@ -1,202 +0,0 @@
-error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:31:15
-   |
-LL |         asm!("{}");
-   |               ^^ from here
-   |
-   = note: no arguments were given
-
-error: invalid reference to argument at index 1
-  --> $DIR/bad-template.rs:33:15
-   |
-LL |         asm!("{1}", in(reg) foo);
-   |               ^^^ from here
-   |
-   = note: there is 1 argument
-
-error: argument never used
-  --> $DIR/bad-template.rs:33:21
-   |
-LL |         asm!("{1}", in(reg) foo);
-   |                     ^^^^^^^^^^^ argument never used
-   |
-   = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {0} */"`
-
-error: there is no argument named `a`
-  --> $DIR/bad-template.rs:36:16
-   |
-LL |         asm!("{a}");
-   |                ^
-
-error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:38:15
-   |
-LL |         asm!("{}", a = in(reg) foo);
-   |               ^^   --------------- named argument
-   |               |
-   |               from here
-   |
-   = note: no positional arguments were given
-note: named arguments cannot be referenced by position
-  --> $DIR/bad-template.rs:38:20
-   |
-LL |         asm!("{}", a = in(reg) foo);
-   |                    ^^^^^^^^^^^^^^^
-
-error: named argument never used
-  --> $DIR/bad-template.rs:38:20
-   |
-LL |         asm!("{}", a = in(reg) foo);
-   |                    ^^^^^^^^^^^^^^^ named argument never used
-   |
-   = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {a} */"`
-
-error: invalid reference to argument at index 1
-  --> $DIR/bad-template.rs:41:15
-   |
-LL |         asm!("{1}", a = in(reg) foo);
-   |               ^^^ from here
-   |
-   = note: no positional arguments were given
-
-error: named argument never used
-  --> $DIR/bad-template.rs:41:21
-   |
-LL |         asm!("{1}", a = in(reg) foo);
-   |                     ^^^^^^^^^^^^^^^ named argument never used
-   |
-   = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {a} */"`
-
-error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:48:15
-   |
-LL |         asm!("{}", in("x0") foo);
-   |               ^^   ------------ explicit register argument
-   |               |
-   |               from here
-   |
-   = note: no positional arguments were given
-note: explicit register arguments cannot be used in the asm template
-  --> $DIR/bad-template.rs:48:20
-   |
-LL |         asm!("{}", in("x0") foo);
-   |                    ^^^^^^^^^^^^
-help: use the register name directly in the assembly code
-  --> $DIR/bad-template.rs:48:20
-   |
-LL |         asm!("{}", in("x0") foo);
-   |                    ^^^^^^^^^^^^
-
-error: asm template modifier must be a single character
-  --> $DIR/bad-template.rs:50:17
-   |
-LL |         asm!("{:foo}", in(reg) foo);
-   |                 ^^^
-
-error: multiple unused asm arguments
-  --> $DIR/bad-template.rs:53:18
-   |
-LL |         asm!("", in(reg) 0, in(reg) 1);
-   |                  ^^^^^^^^^  ^^^^^^^^^ argument never used
-   |                  |
-   |                  argument never used
-   |
-   = help: if these arguments are intentionally unused, consider using them in an asm comment: `"/* {0} {1} */"`
-
-error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:59:14
-   |
-LL | global_asm!("{}");
-   |              ^^ from here
-   |
-   = note: no arguments were given
-
-error: invalid reference to argument at index 1
-  --> $DIR/bad-template.rs:61:14
-   |
-LL | global_asm!("{1}", const FOO);
-   |              ^^^ from here
-   |
-   = note: there is 1 argument
-
-error: argument never used
-  --> $DIR/bad-template.rs:61:20
-   |
-LL | global_asm!("{1}", const FOO);
-   |                    ^^^^^^^^^ argument never used
-   |
-   = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {0} */"`
-
-error: there is no argument named `a`
-  --> $DIR/bad-template.rs:64:15
-   |
-LL | global_asm!("{a}");
-   |               ^
-
-error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:66:14
-   |
-LL | global_asm!("{}", a = const FOO);
-   |              ^^   ------------- named argument
-   |              |
-   |              from here
-   |
-   = note: no positional arguments were given
-note: named arguments cannot be referenced by position
-  --> $DIR/bad-template.rs:66:19
-   |
-LL | global_asm!("{}", a = const FOO);
-   |                   ^^^^^^^^^^^^^
-
-error: named argument never used
-  --> $DIR/bad-template.rs:66:19
-   |
-LL | global_asm!("{}", a = const FOO);
-   |                   ^^^^^^^^^^^^^ named argument never used
-   |
-   = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {a} */"`
-
-error: invalid reference to argument at index 1
-  --> $DIR/bad-template.rs:69:14
-   |
-LL | global_asm!("{1}", a = const FOO);
-   |              ^^^ from here
-   |
-   = note: no positional arguments were given
-
-error: named argument never used
-  --> $DIR/bad-template.rs:69:20
-   |
-LL | global_asm!("{1}", a = const FOO);
-   |                    ^^^^^^^^^^^^^ named argument never used
-   |
-   = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {a} */"`
-
-error: asm template modifier must be a single character
-  --> $DIR/bad-template.rs:72:16
-   |
-LL | global_asm!("{:foo}", const FOO);
-   |                ^^^
-
-error: multiple unused asm arguments
-  --> $DIR/bad-template.rs:74:17
-   |
-LL | global_asm!("", const FOO, const FOO);
-   |                 ^^^^^^^^^  ^^^^^^^^^ argument never used
-   |                 |
-   |                 argument never used
-   |
-   = help: if these arguments are intentionally unused, consider using them in an asm comment: `"/* {0} {1} */"`
-
-warning: formatting may not be suitable for sub-register argument
-  --> $DIR/bad-template.rs:50:15
-   |
-LL |         asm!("{:foo}", in(reg) foo);
-   |               ^^^^^^           --- for this argument
-   |
-   = help: use `{0:w}` to have the register formatted as `w0`
-   = help: or use `{0:x}` to keep the default formatting of `x0`
-   = note: `#[warn(asm_sub_register)]` on by default
-
-error: aborting due to 21 previous errors; 1 warning emitted
-
diff --git a/tests/ui/asm/bad-template.rs b/tests/ui/asm/bad-template.rs
index 55637174792..a6a233a36ec 100644
--- a/tests/ui/asm/bad-template.rs
+++ b/tests/ui/asm/bad-template.rs
@@ -1,14 +1,10 @@
-// revisions: x86_64_mirunsafeck aarch64_mirunsafeck x86_64_thirunsafeck aarch64_thirunsafeck
+// revisions: x86_64 aarch64
 
-// [x86_64_thirunsafeck] compile-flags: -Z thir-unsafeck --target x86_64-unknown-linux-gnu
-// [aarch64_thirunsafeck] compile-flags: -Z thir-unsafeck --target aarch64-unknown-linux-gnu
-// [x86_64_mirunsafeck] compile-flags: --target x86_64-unknown-linux-gnu
-// [aarch64_mirunsafeck] compile-flags: --target aarch64-unknown-linux-gnu
+// [x86_64] compile-flags: --target x86_64-unknown-linux-gnu
+// [aarch64] compile-flags: --target aarch64-unknown-linux-gnu
 
-// [x86_64_thirunsafeck] needs-llvm-components: x86
-// [x86_64_mirunsafeck] needs-llvm-components: x86
-// [aarch64_thirunsafeck] needs-llvm-components: aarch64
-// [aarch64_mirunsafeck] needs-llvm-components: aarch64
+// [x86_64] needs-llvm-components: x86
+// [aarch64] needs-llvm-components: aarch64
 
 #![feature(no_core, lang_items, rustc_attrs, asm_const)]
 #![no_core]
@@ -41,12 +37,12 @@ fn main() {
         asm!("{1}", a = in(reg) foo);
         //~^ ERROR invalid reference to argument at index 1
         //~^^ ERROR named argument never used
-        #[cfg(any(x86_64_thirunsafeck, x86_64_mirunsafeck))]
+        #[cfg(any(x86_64))]
         asm!("{}", in("eax") foo);
-        //[x86_64_thirunsafeck,x86_64_mirunsafeck]~^ ERROR invalid reference to argument at index 0
-        #[cfg(any(aarch64_thirunsafeck, aarch64_mirunsafeck))]
+        //[x86_64]~^ ERROR invalid reference to argument at index 0
+        #[cfg(any(aarch64))]
         asm!("{}", in("x0") foo);
-        //[aarch64_thirunsafeck,aarch64_mirunsafeck]~^ ERROR invalid reference to argument at index 0
+        //[aarch64]~^ ERROR invalid reference to argument at index 0
         asm!("{:foo}", in(reg) foo);
         //~^ ERROR asm template modifier must be a single character
         //~| WARN formatting may not be suitable for sub-register argument [asm_sub_register]
diff --git a/tests/ui/asm/bad-template.x86_64_mirunsafeck.stderr b/tests/ui/asm/bad-template.x86_64.stderr
index 41ac37c33c2..52a7789b98c 100644
--- a/tests/ui/asm/bad-template.x86_64_mirunsafeck.stderr
+++ b/tests/ui/asm/bad-template.x86_64.stderr
@@ -1,5 +1,5 @@
 error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:31:15
+  --> $DIR/bad-template.rs:27:15
    |
 LL |         asm!("{}");
    |               ^^ from here
@@ -7,7 +7,7 @@ LL |         asm!("{}");
    = note: no arguments were given
 
 error: invalid reference to argument at index 1
-  --> $DIR/bad-template.rs:33:15
+  --> $DIR/bad-template.rs:29:15
    |
 LL |         asm!("{1}", in(reg) foo);
    |               ^^^ from here
@@ -15,7 +15,7 @@ LL |         asm!("{1}", in(reg) foo);
    = note: there is 1 argument
 
 error: argument never used
-  --> $DIR/bad-template.rs:33:21
+  --> $DIR/bad-template.rs:29:21
    |
 LL |         asm!("{1}", in(reg) foo);
    |                     ^^^^^^^^^^^ argument never used
@@ -23,13 +23,13 @@ LL |         asm!("{1}", in(reg) foo);
    = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {0} */"`
 
 error: there is no argument named `a`
-  --> $DIR/bad-template.rs:36:16
+  --> $DIR/bad-template.rs:32:16
    |
 LL |         asm!("{a}");
    |                ^
 
 error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:38:15
+  --> $DIR/bad-template.rs:34:15
    |
 LL |         asm!("{}", a = in(reg) foo);
    |               ^^   --------------- named argument
@@ -38,13 +38,13 @@ LL |         asm!("{}", a = in(reg) foo);
    |
    = note: no positional arguments were given
 note: named arguments cannot be referenced by position
-  --> $DIR/bad-template.rs:38:20
+  --> $DIR/bad-template.rs:34:20
    |
 LL |         asm!("{}", a = in(reg) foo);
    |                    ^^^^^^^^^^^^^^^
 
 error: named argument never used
-  --> $DIR/bad-template.rs:38:20
+  --> $DIR/bad-template.rs:34:20
    |
 LL |         asm!("{}", a = in(reg) foo);
    |                    ^^^^^^^^^^^^^^^ named argument never used
@@ -52,7 +52,7 @@ LL |         asm!("{}", a = in(reg) foo);
    = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {a} */"`
 
 error: invalid reference to argument at index 1
-  --> $DIR/bad-template.rs:41:15
+  --> $DIR/bad-template.rs:37:15
    |
 LL |         asm!("{1}", a = in(reg) foo);
    |               ^^^ from here
@@ -60,7 +60,7 @@ LL |         asm!("{1}", a = in(reg) foo);
    = note: no positional arguments were given
 
 error: named argument never used
-  --> $DIR/bad-template.rs:41:21
+  --> $DIR/bad-template.rs:37:21
    |
 LL |         asm!("{1}", a = in(reg) foo);
    |                     ^^^^^^^^^^^^^^^ named argument never used
@@ -68,7 +68,7 @@ LL |         asm!("{1}", a = in(reg) foo);
    = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {a} */"`
 
 error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:45:15
+  --> $DIR/bad-template.rs:41:15
    |
 LL |         asm!("{}", in("eax") foo);
    |               ^^   ------------- explicit register argument
@@ -77,24 +77,24 @@ LL |         asm!("{}", in("eax") foo);
    |
    = note: no positional arguments were given
 note: explicit register arguments cannot be used in the asm template
-  --> $DIR/bad-template.rs:45:20
+  --> $DIR/bad-template.rs:41:20
    |
 LL |         asm!("{}", in("eax") foo);
    |                    ^^^^^^^^^^^^^
 help: use the register name directly in the assembly code
-  --> $DIR/bad-template.rs:45:20
+  --> $DIR/bad-template.rs:41:20
    |
 LL |         asm!("{}", in("eax") foo);
    |                    ^^^^^^^^^^^^^
 
 error: asm template modifier must be a single character
-  --> $DIR/bad-template.rs:50:17
+  --> $DIR/bad-template.rs:46:17
    |
 LL |         asm!("{:foo}", in(reg) foo);
    |                 ^^^
 
 error: multiple unused asm arguments
-  --> $DIR/bad-template.rs:53:18
+  --> $DIR/bad-template.rs:49:18
    |
 LL |         asm!("", in(reg) 0, in(reg) 1);
    |                  ^^^^^^^^^  ^^^^^^^^^ argument never used
@@ -104,7 +104,7 @@ LL |         asm!("", in(reg) 0, in(reg) 1);
    = help: if these arguments are intentionally unused, consider using them in an asm comment: `"/* {0} {1} */"`
 
 error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:59:14
+  --> $DIR/bad-template.rs:55:14
    |
 LL | global_asm!("{}");
    |              ^^ from here
@@ -112,7 +112,7 @@ LL | global_asm!("{}");
    = note: no arguments were given
 
 error: invalid reference to argument at index 1
-  --> $DIR/bad-template.rs:61:14
+  --> $DIR/bad-template.rs:57:14
    |
 LL | global_asm!("{1}", const FOO);
    |              ^^^ from here
@@ -120,7 +120,7 @@ LL | global_asm!("{1}", const FOO);
    = note: there is 1 argument
 
 error: argument never used
-  --> $DIR/bad-template.rs:61:20
+  --> $DIR/bad-template.rs:57:20
    |
 LL | global_asm!("{1}", const FOO);
    |                    ^^^^^^^^^ argument never used
@@ -128,13 +128,13 @@ LL | global_asm!("{1}", const FOO);
    = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {0} */"`
 
 error: there is no argument named `a`
-  --> $DIR/bad-template.rs:64:15
+  --> $DIR/bad-template.rs:60:15
    |
 LL | global_asm!("{a}");
    |               ^
 
 error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:66:14
+  --> $DIR/bad-template.rs:62:14
    |
 LL | global_asm!("{}", a = const FOO);
    |              ^^   ------------- named argument
@@ -143,13 +143,13 @@ LL | global_asm!("{}", a = const FOO);
    |
    = note: no positional arguments were given
 note: named arguments cannot be referenced by position
-  --> $DIR/bad-template.rs:66:19
+  --> $DIR/bad-template.rs:62:19
    |
 LL | global_asm!("{}", a = const FOO);
    |                   ^^^^^^^^^^^^^
 
 error: named argument never used
-  --> $DIR/bad-template.rs:66:19
+  --> $DIR/bad-template.rs:62:19
    |
 LL | global_asm!("{}", a = const FOO);
    |                   ^^^^^^^^^^^^^ named argument never used
@@ -157,7 +157,7 @@ LL | global_asm!("{}", a = const FOO);
    = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {a} */"`
 
 error: invalid reference to argument at index 1
-  --> $DIR/bad-template.rs:69:14
+  --> $DIR/bad-template.rs:65:14
    |
 LL | global_asm!("{1}", a = const FOO);
    |              ^^^ from here
@@ -165,7 +165,7 @@ LL | global_asm!("{1}", a = const FOO);
    = note: no positional arguments were given
 
 error: named argument never used
-  --> $DIR/bad-template.rs:69:20
+  --> $DIR/bad-template.rs:65:20
    |
 LL | global_asm!("{1}", a = const FOO);
    |                    ^^^^^^^^^^^^^ named argument never used
@@ -173,13 +173,13 @@ LL | global_asm!("{1}", a = const FOO);
    = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {a} */"`
 
 error: asm template modifier must be a single character
-  --> $DIR/bad-template.rs:72:16
+  --> $DIR/bad-template.rs:68:16
    |
 LL | global_asm!("{:foo}", const FOO);
    |                ^^^
 
 error: multiple unused asm arguments
-  --> $DIR/bad-template.rs:74:17
+  --> $DIR/bad-template.rs:70:17
    |
 LL | global_asm!("", const FOO, const FOO);
    |                 ^^^^^^^^^  ^^^^^^^^^ argument never used
@@ -189,7 +189,7 @@ LL | global_asm!("", const FOO, const FOO);
    = help: if these arguments are intentionally unused, consider using them in an asm comment: `"/* {0} {1} */"`
 
 warning: formatting may not be suitable for sub-register argument
-  --> $DIR/bad-template.rs:50:15
+  --> $DIR/bad-template.rs:46:15
    |
 LL |         asm!("{:foo}", in(reg) foo);
    |               ^^^^^^           --- for this argument
diff --git a/tests/ui/asm/bad-template.x86_64_thirunsafeck.stderr b/tests/ui/asm/bad-template.x86_64_thirunsafeck.stderr
deleted file mode 100644
index 41ac37c33c2..00000000000
--- a/tests/ui/asm/bad-template.x86_64_thirunsafeck.stderr
+++ /dev/null
@@ -1,202 +0,0 @@
-error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:31:15
-   |
-LL |         asm!("{}");
-   |               ^^ from here
-   |
-   = note: no arguments were given
-
-error: invalid reference to argument at index 1
-  --> $DIR/bad-template.rs:33:15
-   |
-LL |         asm!("{1}", in(reg) foo);
-   |               ^^^ from here
-   |
-   = note: there is 1 argument
-
-error: argument never used
-  --> $DIR/bad-template.rs:33:21
-   |
-LL |         asm!("{1}", in(reg) foo);
-   |                     ^^^^^^^^^^^ argument never used
-   |
-   = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {0} */"`
-
-error: there is no argument named `a`
-  --> $DIR/bad-template.rs:36:16
-   |
-LL |         asm!("{a}");
-   |                ^
-
-error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:38:15
-   |
-LL |         asm!("{}", a = in(reg) foo);
-   |               ^^   --------------- named argument
-   |               |
-   |               from here
-   |
-   = note: no positional arguments were given
-note: named arguments cannot be referenced by position
-  --> $DIR/bad-template.rs:38:20
-   |
-LL |         asm!("{}", a = in(reg) foo);
-   |                    ^^^^^^^^^^^^^^^
-
-error: named argument never used
-  --> $DIR/bad-template.rs:38:20
-   |
-LL |         asm!("{}", a = in(reg) foo);
-   |                    ^^^^^^^^^^^^^^^ named argument never used
-   |
-   = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {a} */"`
-
-error: invalid reference to argument at index 1
-  --> $DIR/bad-template.rs:41:15
-   |
-LL |         asm!("{1}", a = in(reg) foo);
-   |               ^^^ from here
-   |
-   = note: no positional arguments were given
-
-error: named argument never used
-  --> $DIR/bad-template.rs:41:21
-   |
-LL |         asm!("{1}", a = in(reg) foo);
-   |                     ^^^^^^^^^^^^^^^ named argument never used
-   |
-   = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {a} */"`
-
-error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:45:15
-   |
-LL |         asm!("{}", in("eax") foo);
-   |               ^^   ------------- explicit register argument
-   |               |
-   |               from here
-   |
-   = note: no positional arguments were given
-note: explicit register arguments cannot be used in the asm template
-  --> $DIR/bad-template.rs:45:20
-   |
-LL |         asm!("{}", in("eax") foo);
-   |                    ^^^^^^^^^^^^^
-help: use the register name directly in the assembly code
-  --> $DIR/bad-template.rs:45:20
-   |
-LL |         asm!("{}", in("eax") foo);
-   |                    ^^^^^^^^^^^^^
-
-error: asm template modifier must be a single character
-  --> $DIR/bad-template.rs:50:17
-   |
-LL |         asm!("{:foo}", in(reg) foo);
-   |                 ^^^
-
-error: multiple unused asm arguments
-  --> $DIR/bad-template.rs:53:18
-   |
-LL |         asm!("", in(reg) 0, in(reg) 1);
-   |                  ^^^^^^^^^  ^^^^^^^^^ argument never used
-   |                  |
-   |                  argument never used
-   |
-   = help: if these arguments are intentionally unused, consider using them in an asm comment: `"/* {0} {1} */"`
-
-error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:59:14
-   |
-LL | global_asm!("{}");
-   |              ^^ from here
-   |
-   = note: no arguments were given
-
-error: invalid reference to argument at index 1
-  --> $DIR/bad-template.rs:61:14
-   |
-LL | global_asm!("{1}", const FOO);
-   |              ^^^ from here
-   |
-   = note: there is 1 argument
-
-error: argument never used
-  --> $DIR/bad-template.rs:61:20
-   |
-LL | global_asm!("{1}", const FOO);
-   |                    ^^^^^^^^^ argument never used
-   |
-   = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {0} */"`
-
-error: there is no argument named `a`
-  --> $DIR/bad-template.rs:64:15
-   |
-LL | global_asm!("{a}");
-   |               ^
-
-error: invalid reference to argument at index 0
-  --> $DIR/bad-template.rs:66:14
-   |
-LL | global_asm!("{}", a = const FOO);
-   |              ^^   ------------- named argument
-   |              |
-   |              from here
-   |
-   = note: no positional arguments were given
-note: named arguments cannot be referenced by position
-  --> $DIR/bad-template.rs:66:19
-   |
-LL | global_asm!("{}", a = const FOO);
-   |                   ^^^^^^^^^^^^^
-
-error: named argument never used
-  --> $DIR/bad-template.rs:66:19
-   |
-LL | global_asm!("{}", a = const FOO);
-   |                   ^^^^^^^^^^^^^ named argument never used
-   |
-   = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {a} */"`
-
-error: invalid reference to argument at index 1
-  --> $DIR/bad-template.rs:69:14
-   |
-LL | global_asm!("{1}", a = const FOO);
-   |              ^^^ from here
-   |
-   = note: no positional arguments were given
-
-error: named argument never used
-  --> $DIR/bad-template.rs:69:20
-   |
-LL | global_asm!("{1}", a = const FOO);
-   |                    ^^^^^^^^^^^^^ named argument never used
-   |
-   = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {a} */"`
-
-error: asm template modifier must be a single character
-  --> $DIR/bad-template.rs:72:16
-   |
-LL | global_asm!("{:foo}", const FOO);
-   |                ^^^
-
-error: multiple unused asm arguments
-  --> $DIR/bad-template.rs:74:17
-   |
-LL | global_asm!("", const FOO, const FOO);
-   |                 ^^^^^^^^^  ^^^^^^^^^ argument never used
-   |                 |
-   |                 argument never used
-   |
-   = help: if these arguments are intentionally unused, consider using them in an asm comment: `"/* {0} {1} */"`
-
-warning: formatting may not be suitable for sub-register argument
-  --> $DIR/bad-template.rs:50:15
-   |
-LL |         asm!("{:foo}", in(reg) foo);
-   |               ^^^^^^           --- for this argument
-   |
-   = help: use `{0:e}` to have the register formatted as `eax`
-   = help: or use `{0:r}` to keep the default formatting of `rax`
-   = note: `#[warn(asm_sub_register)]` on by default
-
-error: aborting due to 21 previous errors; 1 warning emitted
-
diff --git a/tests/ui/asm/x86_64/const.rs b/tests/ui/asm/x86_64/const.rs
index d523ae021a5..f9a2ab6269f 100644
--- a/tests/ui/asm/x86_64/const.rs
+++ b/tests/ui/asm/x86_64/const.rs
@@ -1,8 +1,6 @@
 // only-x86_64
 // run-pass
 // needs-asm-support
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 #![feature(asm_const)]
 
diff --git a/tests/ui/async-await/async-await.rs b/tests/ui/async-await/async-await.rs
index 9cabf16f8bb..63941a79139 100644
--- a/tests/ui/async-await/async-await.rs
+++ b/tests/ui/async-await/async-await.rs
@@ -1,8 +1,7 @@
 // run-pass
 
-// revisions: default nomiropt thirunsafeck
+// revisions: default nomiropt
 //[nomiropt]compile-flags: -Z mir-opt-level=0
-//[thirunsafeck]compile-flags: -Zthir-unsafeck
 
 #![allow(unused)]
 
diff --git a/tests/ui/async-await/async-unsafe-fn-call-in-safe.rs b/tests/ui/async-await/async-unsafe-fn-call-in-safe.rs
index 14cc0dc614f..f7e9e96bff7 100644
--- a/tests/ui/async-await/async-unsafe-fn-call-in-safe.rs
+++ b/tests/ui/async-await/async-unsafe-fn-call-in-safe.rs
@@ -1,6 +1,4 @@
 // edition:2018
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 
 struct S;
 
@@ -12,18 +10,14 @@ async unsafe fn f() {}
 
 async fn g() {
     S::f();
-    //[mir]~^ ERROR call to unsafe function is unsafe
-    //[thir]~^^ ERROR call to unsafe function `S::f` is unsafe
+    //~^ ERROR call to unsafe function is unsafe
     f();
-    //[mir]~^ ERROR call to unsafe function is unsafe
-    //[thir]~^^ ERROR call to unsafe function `f` is unsafe
+    //~^ ERROR call to unsafe function is unsafe
 }
 
 fn main() {
     S::f();
-    //[mir]~^ ERROR call to unsafe function is unsafe
-    //[thir]~^^ ERROR call to unsafe function `S::f` is unsafe
+    //~^ ERROR call to unsafe function is unsafe
     f();
-    //[mir]~^ ERROR call to unsafe function is unsafe
-    //[thir]~^^ ERROR call to unsafe function `f` is unsafe
+    //~^ ERROR call to unsafe function is unsafe
 }
diff --git a/tests/ui/async-await/async-unsafe-fn-call-in-safe.mir.stderr b/tests/ui/async-await/async-unsafe-fn-call-in-safe.stderr
index f9e5bf675cb..89c496c598d 100644
--- a/tests/ui/async-await/async-unsafe-fn-call-in-safe.mir.stderr
+++ b/tests/ui/async-await/async-unsafe-fn-call-in-safe.stderr
@@ -1,5 +1,5 @@
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/async-unsafe-fn-call-in-safe.rs:14:5
+  --> $DIR/async-unsafe-fn-call-in-safe.rs:12:5
    |
 LL |     S::f();
    |     ^^^^^^ call to unsafe function
@@ -7,7 +7,7 @@ LL |     S::f();
    = note: consult the function's documentation for information on how to avoid undefined behavior
 
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/async-unsafe-fn-call-in-safe.rs:17:5
+  --> $DIR/async-unsafe-fn-call-in-safe.rs:14:5
    |
 LL |     f();
    |     ^^^ call to unsafe function
@@ -15,7 +15,7 @@ LL |     f();
    = note: consult the function's documentation for information on how to avoid undefined behavior
 
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/async-unsafe-fn-call-in-safe.rs:23:5
+  --> $DIR/async-unsafe-fn-call-in-safe.rs:19:5
    |
 LL |     S::f();
    |     ^^^^^^ call to unsafe function
@@ -23,7 +23,7 @@ LL |     S::f();
    = note: consult the function's documentation for information on how to avoid undefined behavior
 
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/async-unsafe-fn-call-in-safe.rs:26:5
+  --> $DIR/async-unsafe-fn-call-in-safe.rs:21:5
    |
 LL |     f();
    |     ^^^ call to unsafe function
diff --git a/tests/ui/async-await/async-unsafe-fn-call-in-safe.thir.stderr b/tests/ui/async-await/async-unsafe-fn-call-in-safe.thir.stderr
deleted file mode 100644
index ba3303fe793..00000000000
--- a/tests/ui/async-await/async-unsafe-fn-call-in-safe.thir.stderr
+++ /dev/null
@@ -1,35 +0,0 @@
-error[E0133]: call to unsafe function `S::f` is unsafe and requires unsafe function or block
-  --> $DIR/async-unsafe-fn-call-in-safe.rs:14:5
-   |
-LL |     S::f();
-   |     ^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error[E0133]: call to unsafe function `f` is unsafe and requires unsafe function or block
-  --> $DIR/async-unsafe-fn-call-in-safe.rs:17:5
-   |
-LL |     f();
-   |     ^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error[E0133]: call to unsafe function `S::f` is unsafe and requires unsafe function or block
-  --> $DIR/async-unsafe-fn-call-in-safe.rs:23:5
-   |
-LL |     S::f();
-   |     ^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error[E0133]: call to unsafe function `f` is unsafe and requires unsafe function or block
-  --> $DIR/async-unsafe-fn-call-in-safe.rs:26:5
-   |
-LL |     f();
-   |     ^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: aborting due to 4 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/closures/closure_no_cap_coerce_many_unsafe_0.rs b/tests/ui/closures/closure_no_cap_coerce_many_unsafe_0.rs
index bdb3eb23c38..76a0f291410 100644
--- a/tests/ui/closures/closure_no_cap_coerce_many_unsafe_0.rs
+++ b/tests/ui/closures/closure_no_cap_coerce_many_unsafe_0.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 // Ensure we get unsafe function after coercion
 unsafe fn add(a: i32, b: i32) -> i32 {
     a + b
diff --git a/tests/ui/closures/closure_no_cap_coerce_many_unsafe_0.mir.stderr b/tests/ui/closures/closure_no_cap_coerce_many_unsafe_0.stderr
index 2f9c7973b5a..190b4792ebc 100644
--- a/tests/ui/closures/closure_no_cap_coerce_many_unsafe_0.mir.stderr
+++ b/tests/ui/closures/closure_no_cap_coerce_many_unsafe_0.stderr
@@ -1,5 +1,5 @@
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/closure_no_cap_coerce_many_unsafe_0.rs:15:23
+  --> $DIR/closure_no_cap_coerce_many_unsafe_0.rs:12:23
    |
 LL |     let result: i32 = foo(5, 5);
    |                       ^^^^^^^^^ call to unsafe function
@@ -7,7 +7,7 @@ LL |     let result: i32 = foo(5, 5);
    = note: consult the function's documentation for information on how to avoid undefined behavior
 
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/closure_no_cap_coerce_many_unsafe_0.rs:24:23
+  --> $DIR/closure_no_cap_coerce_many_unsafe_0.rs:21:23
    |
 LL |     let result: i32 = foo(5, 5);
    |                       ^^^^^^^^^ call to unsafe function
diff --git a/tests/ui/closures/coerce-unsafe-closure-to-unsafe-fn-ptr.rs b/tests/ui/closures/coerce-unsafe-closure-to-unsafe-fn-ptr.rs
index 57358fbdd84..36777693fab 100644
--- a/tests/ui/closures/coerce-unsafe-closure-to-unsafe-fn-ptr.rs
+++ b/tests/ui/closures/coerce-unsafe-closure-to-unsafe-fn-ptr.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 fn main() {
     let _: unsafe fn() = || { ::std::pin::Pin::new_unchecked(&0_u8); };
     //~^ ERROR E0133
diff --git a/tests/ui/closures/coerce-unsafe-closure-to-unsafe-fn-ptr.mir.stderr b/tests/ui/closures/coerce-unsafe-closure-to-unsafe-fn-ptr.stderr
index 57922770310..75c379c88e3 100644
--- a/tests/ui/closures/coerce-unsafe-closure-to-unsafe-fn-ptr.mir.stderr
+++ b/tests/ui/closures/coerce-unsafe-closure-to-unsafe-fn-ptr.stderr
@@ -1,5 +1,5 @@
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/coerce-unsafe-closure-to-unsafe-fn-ptr.rs:5:31
+  --> $DIR/coerce-unsafe-closure-to-unsafe-fn-ptr.rs:2:31
    |
 LL |     let _: unsafe fn() = || { ::std::pin::Pin::new_unchecked(&0_u8); };
    |                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
diff --git a/tests/ui/closures/coerce-unsafe-closure-to-unsafe-fn-ptr.thir.stderr b/tests/ui/closures/coerce-unsafe-closure-to-unsafe-fn-ptr.thir.stderr
deleted file mode 100644
index fb237231d65..00000000000
--- a/tests/ui/closures/coerce-unsafe-closure-to-unsafe-fn-ptr.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: call to unsafe function `Pin::<P>::new_unchecked` is unsafe and requires unsafe function or block
-  --> $DIR/coerce-unsafe-closure-to-unsafe-fn-ptr.rs:5:31
-   |
-LL |     let _: unsafe fn() = || { ::std::pin::Pin::new_unchecked(&0_u8); };
-   |                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/closures/thir-unsafeck-issue-85871.rs b/tests/ui/closures/thir-unsafeck-issue-85871.rs
index aea539b74df..a4a487c4dc2 100644
--- a/tests/ui/closures/thir-unsafeck-issue-85871.rs
+++ b/tests/ui/closures/thir-unsafeck-issue-85871.rs
@@ -1,6 +1,5 @@
 // Tests that no ICE occurs when a closure appears inside a node
 // that does not have a body when compiling with
-// compile-flags: -Zthir-unsafeck=yes
 // check-pass
 
 #![allow(dead_code)]
diff --git a/tests/ui/command/command-pre-exec.rs b/tests/ui/command/command-pre-exec.rs
index d366c5ffbfd..e8a909eecc1 100644
--- a/tests/ui/command/command-pre-exec.rs
+++ b/tests/ui/command/command-pre-exec.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mir thir
-// [thir]compile-flags: -Zthir-unsafeck
 
 #![allow(stable_features)]
 // ignore-windows - this is a unix-specific test
diff --git a/tests/ui/consts/const-extern-fn/const-extern-fn-requires-unsafe.rs b/tests/ui/consts/const-extern-fn/const-extern-fn-requires-unsafe.rs
index 6c4f0a5accf..896d4b376fd 100644
--- a/tests/ui/consts/const-extern-fn/const-extern-fn-requires-unsafe.rs
+++ b/tests/ui/consts/const-extern-fn/const-extern-fn-requires-unsafe.rs
@@ -1,15 +1,10 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 #![feature(const_extern_fn)]
 
 const unsafe extern "C" fn foo() -> usize { 5 }
 
 fn main() {
     let a: [u8; foo()];
-    //[mir]~^ call to unsafe function is unsafe and requires unsafe function or block
-    //[thir]~^^ call to unsafe function `foo` is unsafe and requires unsafe function or block
+    //~^ call to unsafe function is unsafe and requires unsafe function or block
     foo();
-    //[mir]~^ ERROR call to unsafe function is unsafe and requires unsafe function or block
-    //[thir]~^^ ERROR call to unsafe function `foo` is unsafe and requires unsafe function or block
+    //~^ ERROR call to unsafe function is unsafe and requires unsafe function or block
 }
diff --git a/tests/ui/closures/closure_no_cap_coerce_many_unsafe_0.thir.stderr b/tests/ui/consts/const-extern-fn/const-extern-fn-requires-unsafe.stderr
index 2f9c7973b5a..5196b8ee0a2 100644
--- a/tests/ui/closures/closure_no_cap_coerce_many_unsafe_0.thir.stderr
+++ b/tests/ui/consts/const-extern-fn/const-extern-fn-requires-unsafe.stderr
@@ -1,16 +1,16 @@
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/closure_no_cap_coerce_many_unsafe_0.rs:15:23
+  --> $DIR/const-extern-fn-requires-unsafe.rs:8:5
    |
-LL |     let result: i32 = foo(5, 5);
-   |                       ^^^^^^^^^ call to unsafe function
+LL |     foo();
+   |     ^^^^^ call to unsafe function
    |
    = note: consult the function's documentation for information on how to avoid undefined behavior
 
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/closure_no_cap_coerce_many_unsafe_0.rs:24:23
+  --> $DIR/const-extern-fn-requires-unsafe.rs:6:17
    |
-LL |     let result: i32 = foo(5, 5);
-   |                       ^^^^^^^^^ call to unsafe function
+LL |     let a: [u8; foo()];
+   |                 ^^^^^ call to unsafe function
    |
    = note: consult the function's documentation for information on how to avoid undefined behavior
 
diff --git a/tests/ui/consts/issue-16538.rs b/tests/ui/consts/issue-16538.rs
index 270fa301414..31f334fb405 100644
--- a/tests/ui/consts/issue-16538.rs
+++ b/tests/ui/consts/issue-16538.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 mod Y {
     pub type X = usize;
     extern "C" {
diff --git a/tests/ui/consts/issue-16538.mir.stderr b/tests/ui/consts/issue-16538.stderr
index e320df4b7ad..afb344f5e85 100644
--- a/tests/ui/consts/issue-16538.mir.stderr
+++ b/tests/ui/consts/issue-16538.stderr
@@ -1,5 +1,5 @@
 error[E0015]: cannot call non-const fn `Y::foo` in statics
-  --> $DIR/issue-16538.rs:14:23
+  --> $DIR/issue-16538.rs:11:23
    |
 LL | static foo: &Y::X = &*Y::foo(Y::x as *const Y::X);
    |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -8,7 +8,7 @@ LL | static foo: &Y::X = &*Y::foo(Y::x as *const Y::X);
    = note: consider wrapping this expression in `Lazy::new(|| ...)` from the `once_cell` crate: https://crates.io/crates/once_cell
 
 error[E0133]: use of extern static is unsafe and requires unsafe function or block
-  --> $DIR/issue-16538.rs:14:30
+  --> $DIR/issue-16538.rs:11:30
    |
 LL | static foo: &Y::X = &*Y::foo(Y::x as *const Y::X);
    |                              ^^^^ use of extern static
@@ -16,7 +16,7 @@ LL | static foo: &Y::X = &*Y::foo(Y::x as *const Y::X);
    = note: extern statics are not controlled by the Rust type system: invalid data, aliasing violations or data races will cause undefined behavior
 
 error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/issue-16538.rs:14:21
+  --> $DIR/issue-16538.rs:11:21
    |
 LL | static foo: &Y::X = &*Y::foo(Y::x as *const Y::X);
    |                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ dereference of raw pointer
diff --git a/tests/ui/consts/issue-16538.thir.stderr b/tests/ui/consts/issue-16538.thir.stderr
deleted file mode 100644
index 4a862869274..00000000000
--- a/tests/ui/consts/issue-16538.thir.stderr
+++ /dev/null
@@ -1,29 +0,0 @@
-error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/issue-16538.rs:14:22
-   |
-LL | static foo: &Y::X = &*Y::foo(Y::x as *const Y::X);
-   |                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-
-error[E0133]: use of extern static is unsafe and requires unsafe function or block
-  --> $DIR/issue-16538.rs:14:30
-   |
-LL | static foo: &Y::X = &*Y::foo(Y::x as *const Y::X);
-   |                              ^^^^ use of extern static
-   |
-   = note: extern statics are not controlled by the Rust type system: invalid data, aliasing violations or data races will cause undefined behavior
-
-error[E0015]: cannot call non-const fn `Y::foo` in statics
-  --> $DIR/issue-16538.rs:14:23
-   |
-LL | static foo: &Y::X = &*Y::foo(Y::x as *const Y::X);
-   |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = note: calls in statics are limited to constant functions, tuple structs and tuple variants
-   = note: consider wrapping this expression in `Lazy::new(|| ...)` from the `once_cell` crate: https://crates.io/crates/once_cell
-
-error: aborting due to 3 previous errors
-
-Some errors have detailed explanations: E0015, E0133.
-For more information about an error, try `rustc --explain E0015`.
diff --git a/tests/ui/coroutine/issue-45729-unsafe-in-coroutine.rs b/tests/ui/coroutine/issue-45729-unsafe-in-coroutine.rs
index 7961b58597c..dab9c81bc8f 100644
--- a/tests/ui/coroutine/issue-45729-unsafe-in-coroutine.rs
+++ b/tests/ui/coroutine/issue-45729-unsafe-in-coroutine.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 #![feature(coroutines)]
 
 fn main() {
diff --git a/tests/ui/coroutine/issue-45729-unsafe-in-coroutine.mir.stderr b/tests/ui/coroutine/issue-45729-unsafe-in-coroutine.stderr
index 11dc57bcf46..d0f200b8360 100644
--- a/tests/ui/coroutine/issue-45729-unsafe-in-coroutine.mir.stderr
+++ b/tests/ui/coroutine/issue-45729-unsafe-in-coroutine.stderr
@@ -1,5 +1,5 @@
 error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/issue-45729-unsafe-in-coroutine.rs:8:9
+  --> $DIR/issue-45729-unsafe-in-coroutine.rs:5:9
    |
 LL |         *(1 as *mut u32) = 42;
    |         ^^^^^^^^^^^^^^^^^^^^^ dereference of raw pointer
diff --git a/tests/ui/coroutine/issue-45729-unsafe-in-coroutine.thir.stderr b/tests/ui/coroutine/issue-45729-unsafe-in-coroutine.thir.stderr
deleted file mode 100644
index a61689a0df5..00000000000
--- a/tests/ui/coroutine/issue-45729-unsafe-in-coroutine.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/issue-45729-unsafe-in-coroutine.rs:8:9
-   |
-LL |         *(1 as *mut u32) = 42;
-   |         ^^^^^^^^^^^^^^^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/coroutine/static-mut-reference-across-yield.rs b/tests/ui/coroutine/static-mut-reference-across-yield.rs
index 07f810856a7..0ed849e0e7d 100644
--- a/tests/ui/coroutine/static-mut-reference-across-yield.rs
+++ b/tests/ui/coroutine/static-mut-reference-across-yield.rs
@@ -1,6 +1,4 @@
 // build-pass
-// revisions: mir thir
-// [thir]compile-flags: -Zthir-unsafeck
 
 #![feature(coroutines)]
 
diff --git a/tests/ui/error-codes/E0133.rs b/tests/ui/error-codes/E0133.rs
index dee1475ba21..52494ce6078 100644
--- a/tests/ui/error-codes/E0133.rs
+++ b/tests/ui/error-codes/E0133.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 unsafe fn f() { return; }
 
 fn main() {
diff --git a/tests/ui/error-codes/E0133.mir.stderr b/tests/ui/error-codes/E0133.stderr
index f8703ef0633..a1ae6cb7fc9 100644
--- a/tests/ui/error-codes/E0133.mir.stderr
+++ b/tests/ui/error-codes/E0133.stderr
@@ -1,5 +1,5 @@
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/E0133.rs:7:5
+  --> $DIR/E0133.rs:4:5
    |
 LL |     f();
    |     ^^^ call to unsafe function
diff --git a/tests/ui/error-codes/E0133.thir.stderr b/tests/ui/error-codes/E0133.thir.stderr
deleted file mode 100644
index fd4d42bcb8b..00000000000
--- a/tests/ui/error-codes/E0133.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: call to unsafe function `f` is unsafe and requires unsafe function or block
-  --> $DIR/E0133.rs:7:5
-   |
-LL |     f();
-   |     ^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/extern/issue-28324.rs b/tests/ui/extern/issue-28324.rs
index fbe83e325ed..f74726e8166 100644
--- a/tests/ui/extern/issue-28324.rs
+++ b/tests/ui/extern/issue-28324.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 extern "C" {
     static error_message_count: u32;
 }
diff --git a/tests/ui/extern/issue-28324.mir.stderr b/tests/ui/extern/issue-28324.stderr
index 9376ac35e21..be748b47d4d 100644
--- a/tests/ui/extern/issue-28324.mir.stderr
+++ b/tests/ui/extern/issue-28324.stderr
@@ -1,5 +1,5 @@
 error[E0133]: use of extern static is unsafe and requires unsafe function or block
-  --> $DIR/issue-28324.rs:8:24
+  --> $DIR/issue-28324.rs:5:24
    |
 LL | pub static BAZ: u32 = *&error_message_count;
    |                        ^^^^^^^^^^^^^^^^^^^^ use of extern static
diff --git a/tests/ui/extern/issue-28324.thir.stderr b/tests/ui/extern/issue-28324.thir.stderr
deleted file mode 100644
index 8857f379ad1..00000000000
--- a/tests/ui/extern/issue-28324.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: use of extern static is unsafe and requires unsafe function or block
-  --> $DIR/issue-28324.rs:8:25
-   |
-LL | pub static BAZ: u32 = *&error_message_count;
-   |                         ^^^^^^^^^^^^^^^^^^^ use of extern static
-   |
-   = note: extern statics are not controlled by the Rust type system: invalid data, aliasing violations or data races will cause undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/inline-const/expr-unsafe-err.rs b/tests/ui/inline-const/expr-unsafe-err.rs
index adf05d352ea..a05a2945168 100644
--- a/tests/ui/inline-const/expr-unsafe-err.rs
+++ b/tests/ui/inline-const/expr-unsafe-err.rs
@@ -1,7 +1,7 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 #![feature(inline_const)]
-const unsafe fn require_unsafe() -> usize { 1 }
+const unsafe fn require_unsafe() -> usize {
+    1
+}
 
 fn main() {
     const {
diff --git a/tests/ui/inline-const/expr-unsafe-err.mir.stderr b/tests/ui/inline-const/expr-unsafe-err.stderr
index ebd18f89d9c..ebd18f89d9c 100644
--- a/tests/ui/inline-const/expr-unsafe-err.mir.stderr
+++ b/tests/ui/inline-const/expr-unsafe-err.stderr
diff --git a/tests/ui/inline-const/expr-unsafe-err.thir.stderr b/tests/ui/inline-const/expr-unsafe-err.thir.stderr
deleted file mode 100644
index 45f850d1f99..00000000000
--- a/tests/ui/inline-const/expr-unsafe-err.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: call to unsafe function `require_unsafe` is unsafe and requires unsafe function or block
-  --> $DIR/expr-unsafe-err.rs:8:9
-   |
-LL |         require_unsafe();
-   |         ^^^^^^^^^^^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/inline-const/expr-unsafe.rs b/tests/ui/inline-const/expr-unsafe.rs
index d71efd33db1..2370c58a712 100644
--- a/tests/ui/inline-const/expr-unsafe.rs
+++ b/tests/ui/inline-const/expr-unsafe.rs
@@ -1,6 +1,5 @@
 // check-pass
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
+
 #![warn(unused_unsafe)]
 #![feature(inline_const)]
 const unsafe fn require_unsafe() -> usize { 1 }
diff --git a/tests/ui/inline-const/expr-unsafe.mir.stderr b/tests/ui/inline-const/expr-unsafe.stderr
index 1ab6e42fba0..47334aaab83 100644
--- a/tests/ui/inline-const/expr-unsafe.mir.stderr
+++ b/tests/ui/inline-const/expr-unsafe.stderr
@@ -1,11 +1,11 @@
 warning: unnecessary `unsafe` block
-  --> $DIR/expr-unsafe.rs:12:13
+  --> $DIR/expr-unsafe.rs:11:13
    |
 LL |             unsafe {}
    |             ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/expr-unsafe.rs:4:9
+  --> $DIR/expr-unsafe.rs:3:9
    |
 LL | #![warn(unused_unsafe)]
    |         ^^^^^^^^^^^^^
diff --git a/tests/ui/inline-const/expr-unsafe.thir.stderr b/tests/ui/inline-const/expr-unsafe.thir.stderr
deleted file mode 100644
index 1ab6e42fba0..00000000000
--- a/tests/ui/inline-const/expr-unsafe.thir.stderr
+++ /dev/null
@@ -1,14 +0,0 @@
-warning: unnecessary `unsafe` block
-  --> $DIR/expr-unsafe.rs:12:13
-   |
-LL |             unsafe {}
-   |             ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/expr-unsafe.rs:4:9
-   |
-LL | #![warn(unused_unsafe)]
-   |         ^^^^^^^^^^^^^
-
-warning: 1 warning emitted
-
diff --git a/tests/ui/inline-const/pat-unsafe-err.rs b/tests/ui/inline-const/pat-unsafe-err.rs
index 6df281c6d94..0db18dd3260 100644
--- a/tests/ui/inline-const/pat-unsafe-err.rs
+++ b/tests/ui/inline-const/pat-unsafe-err.rs
@@ -1,6 +1,4 @@
-// revisions: mir thir
-// [mir]ignore-test This is currently broken
-// [thir]compile-flags: -Z thir-unsafeck
+// ignore-test This is currently broken
 
 #![allow(incomplete_features)]
 #![feature(inline_const_pat)]
diff --git a/tests/ui/inline-const/pat-unsafe-err.thir.stderr b/tests/ui/inline-const/pat-unsafe-err.thir.stderr
deleted file mode 100644
index 48a2cb4c704..00000000000
--- a/tests/ui/inline-const/pat-unsafe-err.thir.stderr
+++ /dev/null
@@ -1,19 +0,0 @@
-error[E0133]: call to unsafe function `require_unsafe` is unsafe and requires unsafe function or block
-  --> $DIR/pat-unsafe-err.rs:15:13
-   |
-LL |             require_unsafe();
-   |             ^^^^^^^^^^^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error[E0133]: call to unsafe function `require_unsafe` is unsafe and requires unsafe function or block
-  --> $DIR/pat-unsafe-err.rs:22:13
-   |
-LL |             require_unsafe()
-   |             ^^^^^^^^^^^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: aborting due to 2 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/inline-const/pat-unsafe.rs b/tests/ui/inline-const/pat-unsafe.rs
index 36f8632af67..cfef9ad6a56 100644
--- a/tests/ui/inline-const/pat-unsafe.rs
+++ b/tests/ui/inline-const/pat-unsafe.rs
@@ -1,7 +1,5 @@
 // check-pass
-// revisions: mir thir
-// [mir]ignore-test This is currently broken
-// [thir]compile-flags: -Z thir-unsafeck
+// ignore-test This is currently broken
 
 #![allow(incomplete_features)]
 #![warn(unused_unsafe)]
diff --git a/tests/ui/inline-const/pat-unsafe.thir.stderr b/tests/ui/inline-const/pat-unsafe.thir.stderr
deleted file mode 100644
index 0318b3ff2cc..00000000000
--- a/tests/ui/inline-const/pat-unsafe.thir.stderr
+++ /dev/null
@@ -1,20 +0,0 @@
-warning: unnecessary `unsafe` block
-  --> $DIR/pat-unsafe.rs:19:17
-   |
-LL |                 unsafe {}
-   |                 ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/pat-unsafe.rs:7:9
-   |
-LL | #![warn(unused_unsafe)]
-   |         ^^^^^^^^^^^^^
-
-warning: unnecessary `unsafe` block
-  --> $DIR/pat-unsafe.rs:26:17
-   |
-LL |                 unsafe {}
-   |                 ^^^^^^ unnecessary `unsafe` block
-
-warning: 2 warnings emitted
-
diff --git a/tests/ui/intrinsics/issue-28575.rs b/tests/ui/intrinsics/issue-28575.rs
index 410f664f89d..141136d25b2 100644
--- a/tests/ui/intrinsics/issue-28575.rs
+++ b/tests/ui/intrinsics/issue-28575.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 #![feature(intrinsics)]
 
 extern "C" {
diff --git a/tests/ui/intrinsics/issue-28575.mir.stderr b/tests/ui/intrinsics/issue-28575.stderr
index 4b29b4c1b6a..8a7816f231f 100644
--- a/tests/ui/intrinsics/issue-28575.mir.stderr
+++ b/tests/ui/intrinsics/issue-28575.stderr
@@ -1,5 +1,5 @@
 error[E0133]: use of extern static is unsafe and requires unsafe function or block
-  --> $DIR/issue-28575.rs:11:5
+  --> $DIR/issue-28575.rs:8:5
    |
 LL |     FOO()
    |     ^^^ use of extern static
diff --git a/tests/ui/intrinsics/issue-28575.thir.stderr b/tests/ui/intrinsics/issue-28575.thir.stderr
deleted file mode 100644
index 4b29b4c1b6a..00000000000
--- a/tests/ui/intrinsics/issue-28575.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: use of extern static is unsafe and requires unsafe function or block
-  --> $DIR/issue-28575.rs:11:5
-   |
-LL |     FOO()
-   |     ^^^ use of extern static
-   |
-   = note: extern statics are not controlled by the Rust type system: invalid data, aliasing violations or data races will cause undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/intrinsics/unchecked_math_unsafe.rs b/tests/ui/intrinsics/unchecked_math_unsafe.rs
index 98d3a11ad02..a034b45f530 100644
--- a/tests/ui/intrinsics/unchecked_math_unsafe.rs
+++ b/tests/ui/intrinsics/unchecked_math_unsafe.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 #![feature(core_intrinsics)]
 
 fn main() {
diff --git a/tests/ui/intrinsics/unchecked_math_unsafe.mir.stderr b/tests/ui/intrinsics/unchecked_math_unsafe.stderr
index 26b2f9f2713..4066cf8efb8 100644
--- a/tests/ui/intrinsics/unchecked_math_unsafe.mir.stderr
+++ b/tests/ui/intrinsics/unchecked_math_unsafe.stderr
@@ -1,5 +1,5 @@
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/unchecked_math_unsafe.rs:8:15
+  --> $DIR/unchecked_math_unsafe.rs:5:15
    |
 LL |     let add = std::intrinsics::unchecked_add(x, y);
    |               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
@@ -7,7 +7,7 @@ LL |     let add = std::intrinsics::unchecked_add(x, y);
    = note: consult the function's documentation for information on how to avoid undefined behavior
 
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/unchecked_math_unsafe.rs:9:15
+  --> $DIR/unchecked_math_unsafe.rs:6:15
    |
 LL |     let sub = std::intrinsics::unchecked_sub(x, y);
    |               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
@@ -15,7 +15,7 @@ LL |     let sub = std::intrinsics::unchecked_sub(x, y);
    = note: consult the function's documentation for information on how to avoid undefined behavior
 
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/unchecked_math_unsafe.rs:10:15
+  --> $DIR/unchecked_math_unsafe.rs:7:15
    |
 LL |     let mul = std::intrinsics::unchecked_mul(x, y);
    |               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
diff --git a/tests/ui/intrinsics/unchecked_math_unsafe.thir.stderr b/tests/ui/intrinsics/unchecked_math_unsafe.thir.stderr
deleted file mode 100644
index 5c3728ccdf8..00000000000
--- a/tests/ui/intrinsics/unchecked_math_unsafe.thir.stderr
+++ /dev/null
@@ -1,27 +0,0 @@
-error[E0133]: call to unsafe function `unchecked_add` is unsafe and requires unsafe function or block
-  --> $DIR/unchecked_math_unsafe.rs:8:15
-   |
-LL |     let add = std::intrinsics::unchecked_add(x, y);
-   |               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error[E0133]: call to unsafe function `unchecked_sub` is unsafe and requires unsafe function or block
-  --> $DIR/unchecked_math_unsafe.rs:9:15
-   |
-LL |     let sub = std::intrinsics::unchecked_sub(x, y);
-   |               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error[E0133]: call to unsafe function `unchecked_mul` is unsafe and requires unsafe function or block
-  --> $DIR/unchecked_math_unsafe.rs:10:15
-   |
-LL |     let mul = std::intrinsics::unchecked_mul(x, y);
-   |               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: aborting due to 3 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/issues/issue-11740.rs b/tests/ui/issues/issue-11740.rs
index fa80f509b32..c3badfd9b49 100644
--- a/tests/ui/issues/issue-11740.rs
+++ b/tests/ui/issues/issue-11740.rs
@@ -1,6 +1,4 @@
 // check-pass
-// revisions: mir thir
-// [thir]compile-flags: -Zthir-unsafeck
 
 struct Attr {
     name: String,
diff --git a/tests/ui/issues/issue-28776.rs b/tests/ui/issues/issue-28776.rs
index 19df3c4a425..e564ebcd110 100644
--- a/tests/ui/issues/issue-28776.rs
+++ b/tests/ui/issues/issue-28776.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 use std::ptr;
 
 fn main() {
diff --git a/tests/ui/issues/issue-28776.mir.stderr b/tests/ui/issues/issue-28776.stderr
index e7b7ba08268..9f0f10335ab 100644
--- a/tests/ui/issues/issue-28776.mir.stderr
+++ b/tests/ui/issues/issue-28776.stderr
@@ -1,5 +1,5 @@
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/issue-28776.rs:7:5
+  --> $DIR/issue-28776.rs:4:5
    |
 LL |     (&ptr::write)(1 as *mut _, 42);
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
diff --git a/tests/ui/issues/issue-28776.thir.stderr b/tests/ui/issues/issue-28776.thir.stderr
deleted file mode 100644
index 63172b85424..00000000000
--- a/tests/ui/issues/issue-28776.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: call to unsafe function `std::ptr::write` is unsafe and requires unsafe function or block
-  --> $DIR/issue-28776.rs:7:5
-   |
-LL |     (&ptr::write)(1 as *mut _, 42);
-   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/issues/issue-39367.rs b/tests/ui/issues/issue-39367.rs
index e7beb8a0392..039b47ae780 100644
--- a/tests/ui/issues/issue-39367.rs
+++ b/tests/ui/issues/issue-39367.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mir thir
-// [thir]compile-flags: -Zthir-unsafeck
 
 use std::ops::Deref;
 
diff --git a/tests/ui/issues/issue-48131.mir.stderr b/tests/ui/issues/issue-48131.mir.stderr
deleted file mode 100644
index 6817e8830c5..00000000000
--- a/tests/ui/issues/issue-48131.mir.stderr
+++ /dev/null
@@ -1,20 +0,0 @@
-error: unnecessary `unsafe` block
-  --> $DIR/issue-48131.rs:12:9
-   |
-LL |         unsafe { /* unnecessary */ }
-   |         ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/issue-48131.rs:6:9
-   |
-LL | #![deny(unused_unsafe)]
-   |         ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/issue-48131.rs:23:13
-   |
-LL |             unsafe { /* unnecessary */ }
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: aborting due to 2 previous errors
-
diff --git a/tests/ui/issues/issue-48131.rs b/tests/ui/issues/issue-48131.rs
index df98547084d..85664e62ead 100644
--- a/tests/ui/issues/issue-48131.rs
+++ b/tests/ui/issues/issue-48131.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 // This note is annotated because the purpose of the test
 // is to ensure that certain other notes are not generated.
 #![deny(unused_unsafe)] //~ NOTE
diff --git a/tests/ui/issues/issue-48131.thir.stderr b/tests/ui/issues/issue-48131.stderr
index 6817e8830c5..5acc4f16e9f 100644
--- a/tests/ui/issues/issue-48131.thir.stderr
+++ b/tests/ui/issues/issue-48131.stderr
@@ -1,17 +1,17 @@
 error: unnecessary `unsafe` block
-  --> $DIR/issue-48131.rs:12:9
+  --> $DIR/issue-48131.rs:9:9
    |
 LL |         unsafe { /* unnecessary */ }
    |         ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/issue-48131.rs:6:9
+  --> $DIR/issue-48131.rs:3:9
    |
 LL | #![deny(unused_unsafe)]
    |         ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/issue-48131.rs:23:13
+  --> $DIR/issue-48131.rs:20:13
    |
 LL |             unsafe { /* unnecessary */ }
    |             ^^^^^^ unnecessary `unsafe` block
diff --git a/tests/ui/issues/issue-5844.rs b/tests/ui/issues/issue-5844.rs
index 4f90a9c6645..0db1ccf76d9 100644
--- a/tests/ui/issues/issue-5844.rs
+++ b/tests/ui/issues/issue-5844.rs
@@ -1,9 +1,7 @@
 //aux-build:issue-5844-aux.rs
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 
 extern crate issue_5844_aux;
 
-fn main () {
+fn main() {
     issue_5844_aux::rand(); //~ ERROR: requires unsafe
 }
diff --git a/tests/ui/issues/issue-5844.mir.stderr b/tests/ui/issues/issue-5844.stderr
index 4434f5a0ff2..af7bfb03320 100644
--- a/tests/ui/issues/issue-5844.mir.stderr
+++ b/tests/ui/issues/issue-5844.stderr
@@ -1,5 +1,5 @@
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/issue-5844.rs:8:5
+  --> $DIR/issue-5844.rs:6:5
    |
 LL |     issue_5844_aux::rand();
    |     ^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
diff --git a/tests/ui/issues/issue-5844.thir.stderr b/tests/ui/issues/issue-5844.thir.stderr
deleted file mode 100644
index 6074f7d0ed4..00000000000
--- a/tests/ui/issues/issue-5844.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: call to unsafe function `rand` is unsafe and requires unsafe function or block
-  --> $DIR/issue-5844.rs:8:5
-   |
-LL |     issue_5844_aux::rand();
-   |     ^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/lto/lto-still-runs-thread-dtors.rs b/tests/ui/lto/lto-still-runs-thread-dtors.rs
index 1c7368b36e1..635ad783b31 100644
--- a/tests/ui/lto/lto-still-runs-thread-dtors.rs
+++ b/tests/ui/lto/lto-still-runs-thread-dtors.rs
@@ -2,8 +2,6 @@
 // compile-flags: -C lto
 // no-prefer-dynamic
 // ignore-emscripten no threads support
-// revisions: mir thir
-// [thir]compile-flags: -Zthir-unsafeck
 
 use std::thread;
 
diff --git a/tests/ui/pattern/non-structural-match-types.mir.stderr b/tests/ui/pattern/non-structural-match-types.mir.stderr
deleted file mode 100644
index 7a9e5b7e02e..00000000000
--- a/tests/ui/pattern/non-structural-match-types.mir.stderr
+++ /dev/null
@@ -1,14 +0,0 @@
-error: `{closure@$DIR/non-structural-match-types.rs:12:17: 12:19}` cannot be used in patterns
-  --> $DIR/non-structural-match-types.rs:12:9
-   |
-LL |         const { || {} } => {}
-   |         ^^^^^^^^^^^^^^^
-
-error: `{async block@$DIR/non-structural-match-types.rs:15:17: 15:25}` cannot be used in patterns
-  --> $DIR/non-structural-match-types.rs:15:9
-   |
-LL |         const { async {} } => {}
-   |         ^^^^^^^^^^^^^^^^^^
-
-error: aborting due to 2 previous errors
-
diff --git a/tests/ui/pattern/non-structural-match-types.rs b/tests/ui/pattern/non-structural-match-types.rs
index fb7779fa808..b4f19bb8294 100644
--- a/tests/ui/pattern/non-structural-match-types.rs
+++ b/tests/ui/pattern/non-structural-match-types.rs
@@ -1,6 +1,4 @@
 // edition:2021
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 
 #![allow(incomplete_features)]
 #![allow(unreachable_code)]
diff --git a/tests/ui/pattern/non-structural-match-types.stderr b/tests/ui/pattern/non-structural-match-types.stderr
new file mode 100644
index 00000000000..4a6990da56f
--- /dev/null
+++ b/tests/ui/pattern/non-structural-match-types.stderr
@@ -0,0 +1,14 @@
+error: `{closure@$DIR/non-structural-match-types.rs:10:17: 10:19}` cannot be used in patterns
+  --> $DIR/non-structural-match-types.rs:10:9
+   |
+LL |         const { || {} } => {}
+   |         ^^^^^^^^^^^^^^^
+
+error: `{async block@$DIR/non-structural-match-types.rs:13:17: 13:25}` cannot be used in patterns
+  --> $DIR/non-structural-match-types.rs:13:9
+   |
+LL |         const { async {} } => {}
+   |         ^^^^^^^^^^^^^^^^^^
+
+error: aborting due to 2 previous errors
+
diff --git a/tests/ui/pattern/non-structural-match-types.thir.stderr b/tests/ui/pattern/non-structural-match-types.thir.stderr
deleted file mode 100644
index 7a9e5b7e02e..00000000000
--- a/tests/ui/pattern/non-structural-match-types.thir.stderr
+++ /dev/null
@@ -1,14 +0,0 @@
-error: `{closure@$DIR/non-structural-match-types.rs:12:17: 12:19}` cannot be used in patterns
-  --> $DIR/non-structural-match-types.rs:12:9
-   |
-LL |         const { || {} } => {}
-   |         ^^^^^^^^^^^^^^^
-
-error: `{async block@$DIR/non-structural-match-types.rs:15:17: 15:25}` cannot be used in patterns
-  --> $DIR/non-structural-match-types.rs:15:9
-   |
-LL |         const { async {} } => {}
-   |         ^^^^^^^^^^^^^^^^^^
-
-error: aborting due to 2 previous errors
-
diff --git a/tests/ui/process/no-stdio.rs b/tests/ui/process/no-stdio.rs
index 24985386a97..68e6fa838b4 100644
--- a/tests/ui/process/no-stdio.rs
+++ b/tests/ui/process/no-stdio.rs
@@ -2,8 +2,6 @@
 // ignore-android
 // ignore-emscripten no processes
 // ignore-sgx no processes
-// revisions: mir thir
-// [thir]compile-flags: -Zthir-unsafeck
 
 #![feature(rustc_private)]
 
diff --git a/tests/ui/rfcs/rfc-2396-target_feature-11/check-pass.rs b/tests/ui/rfcs/rfc-2396-target_feature-11/check-pass.rs
index e0842bfa4cd..58a2c271ecf 100644
--- a/tests/ui/rfcs/rfc-2396-target_feature-11/check-pass.rs
+++ b/tests/ui/rfcs/rfc-2396-target_feature-11/check-pass.rs
@@ -8,8 +8,6 @@
 
 // check-pass
 // only-x86_64
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 
 #![feature(target_feature_11)]
 
diff --git a/tests/ui/rfcs/rfc-2396-target_feature-11/closures-inherit-target_feature.rs b/tests/ui/rfcs/rfc-2396-target_feature-11/closures-inherit-target_feature.rs
index a59d7c2d784..fefe100ba0e 100644
--- a/tests/ui/rfcs/rfc-2396-target_feature-11/closures-inherit-target_feature.rs
+++ b/tests/ui/rfcs/rfc-2396-target_feature-11/closures-inherit-target_feature.rs
@@ -1,18 +1,16 @@
 // Tests #73631: closures inherit `#[target_feature]` annotations
 
 // check-pass
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 // only-x86_64
 
 #![feature(target_feature_11)]
 
-#[target_feature(enable="avx")]
+#[target_feature(enable = "avx")]
 fn also_use_avx() {
     println!("Hello from AVX")
 }
 
-#[target_feature(enable="avx")]
+#[target_feature(enable = "avx")]
 fn use_avx() -> Box<dyn Fn()> {
     Box::new(|| also_use_avx())
 }
diff --git a/tests/ui/rfcs/rfc-2396-target_feature-11/fn-ptr.rs b/tests/ui/rfcs/rfc-2396-target_feature-11/fn-ptr.rs
index c95d4a08e48..3ecea5c5313 100644
--- a/tests/ui/rfcs/rfc-2396-target_feature-11/fn-ptr.rs
+++ b/tests/ui/rfcs/rfc-2396-target_feature-11/fn-ptr.rs
@@ -1,5 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 // only-x86_64
 
 #![feature(target_feature_11)]
diff --git a/tests/ui/rfcs/rfc-2396-target_feature-11/fn-ptr.stderr b/tests/ui/rfcs/rfc-2396-target_feature-11/fn-ptr.stderr
new file mode 100644
index 00000000000..cc941be5479
--- /dev/null
+++ b/tests/ui/rfcs/rfc-2396-target_feature-11/fn-ptr.stderr
@@ -0,0 +1,23 @@
+error[E0308]: mismatched types
+  --> $DIR/fn-ptr.rs:9:21
+   |
+LL | #[target_feature(enable = "sse2")]
+   | ---------------------------------- `#[target_feature]` added here
+...
+LL |     let foo: fn() = foo;
+   |              ----   ^^^ cannot coerce functions with `#[target_feature]` to safe function pointers
+   |              |
+   |              expected due to this
+   |
+   = note: expected fn pointer `fn()`
+                 found fn item `fn() {foo}`
+   = note: fn items are distinct from fn pointers
+   = note: functions with `#[target_feature]` can only be coerced to `unsafe` function pointers
+help: consider casting to a fn pointer
+   |
+LL |     let foo: fn() = foo as fn();
+   |                     ~~~~~~~~~~~
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0308`.
diff --git a/tests/ui/rfcs/rfc-2396-target_feature-11/issue-108655-inline-always-closure.rs b/tests/ui/rfcs/rfc-2396-target_feature-11/issue-108655-inline-always-closure.rs
index bc886400099..115f00b3f4e 100644
--- a/tests/ui/rfcs/rfc-2396-target_feature-11/issue-108655-inline-always-closure.rs
+++ b/tests/ui/rfcs/rfc-2396-target_feature-11/issue-108655-inline-always-closure.rs
@@ -1,8 +1,6 @@
 // Tests #108655: closures in `#[target_feature]` functions can still be marked #[inline(always)]
 
 // check-pass
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 // only-x86_64
 
 #![feature(target_feature_11)]
diff --git a/tests/ui/rfcs/rfc-2396-target_feature-11/safe-calls.rs b/tests/ui/rfcs/rfc-2396-target_feature-11/safe-calls.rs
index f17dab269bc..b420d14d1e1 100644
--- a/tests/ui/rfcs/rfc-2396-target_feature-11/safe-calls.rs
+++ b/tests/ui/rfcs/rfc-2396-target_feature-11/safe-calls.rs
@@ -1,5 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 // only-x86_64
 
 #![feature(target_feature_11)]
@@ -11,7 +9,6 @@ const fn sse2() {}
 #[target_feature(enable = "fxsr")]
 const fn sse2_and_fxsr() {}
 
-
 #[target_feature(enable = "avx")]
 #[target_feature(enable = "bmi2")]
 fn avx_bmi2() {}
@@ -26,62 +23,50 @@ impl Quux {
 
 fn foo() {
     sse2();
-    //[mir]~^ ERROR call to function with `#[target_feature]` is unsafe
-    //[thir]~^^ ERROR call to function `sse2` with `#[target_feature]` is unsafe
+    //~^ ERROR call to function with `#[target_feature]` is unsafe
     avx_bmi2();
-    //[mir]~^ ERROR call to function with `#[target_feature]` is unsafe
-    //[thir]~^^ ERROR call to function `avx_bmi2` with `#[target_feature]` is unsafe
+    //~^ ERROR call to function with `#[target_feature]` is unsafe
     Quux.avx_bmi2();
-    //[mir]~^ ERROR call to function with `#[target_feature]` is unsafe
-    //[thir]~^^ ERROR call to function `Quux::avx_bmi2` with `#[target_feature]` is unsafe
+    //~^ ERROR call to function with `#[target_feature]` is unsafe
 }
 
 #[target_feature(enable = "sse2")]
 fn bar() {
     avx_bmi2();
-    //[mir]~^ ERROR call to function with `#[target_feature]` is unsafe
-    //[thir]~^^ ERROR call to function `avx_bmi2` with `#[target_feature]` is unsafe
+    //~^ ERROR call to function with `#[target_feature]` is unsafe
     Quux.avx_bmi2();
-    //[mir]~^ ERROR call to function with `#[target_feature]` is unsafe
-    //[thir]~^^ ERROR call to function `Quux::avx_bmi2` with `#[target_feature]` is unsafe
+    //~^ ERROR call to function with `#[target_feature]` is unsafe
 }
 
 #[target_feature(enable = "avx")]
 fn baz() {
     sse2();
-    //[mir]~^ ERROR call to function with `#[target_feature]` is unsafe
-    //[thir]~^^ ERROR call to function `sse2` with `#[target_feature]` is unsafe
+    //~^ ERROR call to function with `#[target_feature]` is unsafe
     avx_bmi2();
-    //[mir]~^ ERROR call to function with `#[target_feature]` is unsafe
-    //[thir]~^^ ERROR call to function `avx_bmi2` with `#[target_feature]` is unsafe
+    //~^ ERROR call to function with `#[target_feature]` is unsafe
     Quux.avx_bmi2();
-    //[mir]~^ ERROR call to function with `#[target_feature]` is unsafe
-    //[thir]~^^ ERROR call to function `Quux::avx_bmi2` with `#[target_feature]` is unsafe
+    //~^ ERROR call to function with `#[target_feature]` is unsafe
 }
 
 #[target_feature(enable = "avx")]
 #[target_feature(enable = "bmi2")]
 fn qux() {
     sse2();
-    //[mir]~^ ERROR call to function with `#[target_feature]` is unsafe
-    //[thir]~^^ ERROR call to function `sse2` with `#[target_feature]` is unsafe
+    //~^ ERROR call to function with `#[target_feature]` is unsafe
 }
 
 const _: () = sse2();
-//[mir]~^ ERROR call to function with `#[target_feature]` is unsafe
-//[thir]~^^ ERROR call to function `sse2` with `#[target_feature]` is unsafe
+//~^ ERROR call to function with `#[target_feature]` is unsafe
 
 const _: () = sse2_and_fxsr();
-//[mir]~^ ERROR call to function with `#[target_feature]` is unsafe
-//[thir]~^^ ERROR call to function `sse2_and_fxsr` with `#[target_feature]` is unsafe
+//~^ ERROR call to function with `#[target_feature]` is unsafe
 
 #[deny(unsafe_op_in_unsafe_fn)]
 #[target_feature(enable = "avx")]
 #[target_feature(enable = "bmi2")]
 unsafe fn needs_unsafe_block() {
     sse2();
-    //[mir]~^ ERROR call to function with `#[target_feature]` is unsafe
-    //[thir]~^^ ERROR call to function `sse2` with `#[target_feature]` is unsafe
+    //~^ ERROR call to function with `#[target_feature]` is unsafe
 }
 
 fn main() {}
diff --git a/tests/ui/rfcs/rfc-2396-target_feature-11/safe-calls.stderr b/tests/ui/rfcs/rfc-2396-target_feature-11/safe-calls.stderr
new file mode 100644
index 00000000000..3897f09b576
--- /dev/null
+++ b/tests/ui/rfcs/rfc-2396-target_feature-11/safe-calls.stderr
@@ -0,0 +1,115 @@
+error[E0133]: call to function with `#[target_feature]` is unsafe and requires unsafe function or block
+  --> $DIR/safe-calls.rs:25:5
+   |
+LL |     sse2();
+   |     ^^^^^^ call to function with `#[target_feature]`
+   |
+   = help: in order for the call to be safe, the context requires the following additional target feature: sse2
+   = note: the sse2 target feature being enabled in the build configuration does not remove the requirement to list it in `#[target_feature]`
+
+error[E0133]: call to function with `#[target_feature]` is unsafe and requires unsafe function or block
+  --> $DIR/safe-calls.rs:27:5
+   |
+LL |     avx_bmi2();
+   |     ^^^^^^^^^^ call to function with `#[target_feature]`
+   |
+   = help: in order for the call to be safe, the context requires the following additional target features: avx and bmi2
+
+error[E0133]: call to function with `#[target_feature]` is unsafe and requires unsafe function or block
+  --> $DIR/safe-calls.rs:29:5
+   |
+LL |     Quux.avx_bmi2();
+   |     ^^^^^^^^^^^^^^^ call to function with `#[target_feature]`
+   |
+   = help: in order for the call to be safe, the context requires the following additional target features: avx and bmi2
+
+error[E0133]: call to function with `#[target_feature]` is unsafe and requires unsafe function or block
+  --> $DIR/safe-calls.rs:35:5
+   |
+LL |     avx_bmi2();
+   |     ^^^^^^^^^^ call to function with `#[target_feature]`
+   |
+   = help: in order for the call to be safe, the context requires the following additional target features: avx and bmi2
+
+error[E0133]: call to function with `#[target_feature]` is unsafe and requires unsafe function or block
+  --> $DIR/safe-calls.rs:37:5
+   |
+LL |     Quux.avx_bmi2();
+   |     ^^^^^^^^^^^^^^^ call to function with `#[target_feature]`
+   |
+   = help: in order for the call to be safe, the context requires the following additional target features: avx and bmi2
+
+error[E0133]: call to function with `#[target_feature]` is unsafe and requires unsafe function or block
+  --> $DIR/safe-calls.rs:43:5
+   |
+LL |     sse2();
+   |     ^^^^^^ call to function with `#[target_feature]`
+   |
+   = help: in order for the call to be safe, the context requires the following additional target feature: sse2
+   = note: the sse2 target feature being enabled in the build configuration does not remove the requirement to list it in `#[target_feature]`
+
+error[E0133]: call to function with `#[target_feature]` is unsafe and requires unsafe function or block
+  --> $DIR/safe-calls.rs:45:5
+   |
+LL |     avx_bmi2();
+   |     ^^^^^^^^^^ call to function with `#[target_feature]`
+   |
+   = help: in order for the call to be safe, the context requires the following additional target feature: bmi2
+
+error[E0133]: call to function with `#[target_feature]` is unsafe and requires unsafe function or block
+  --> $DIR/safe-calls.rs:47:5
+   |
+LL |     Quux.avx_bmi2();
+   |     ^^^^^^^^^^^^^^^ call to function with `#[target_feature]`
+   |
+   = help: in order for the call to be safe, the context requires the following additional target feature: bmi2
+
+error[E0133]: call to function with `#[target_feature]` is unsafe and requires unsafe function or block
+  --> $DIR/safe-calls.rs:54:5
+   |
+LL |     sse2();
+   |     ^^^^^^ call to function with `#[target_feature]`
+   |
+   = help: in order for the call to be safe, the context requires the following additional target feature: sse2
+   = note: the sse2 target feature being enabled in the build configuration does not remove the requirement to list it in `#[target_feature]`
+
+error[E0133]: call to function with `#[target_feature]` is unsafe and requires unsafe function or block
+  --> $DIR/safe-calls.rs:58:15
+   |
+LL | const _: () = sse2();
+   |               ^^^^^^ call to function with `#[target_feature]`
+   |
+   = help: in order for the call to be safe, the context requires the following additional target feature: sse2
+   = note: the sse2 target feature being enabled in the build configuration does not remove the requirement to list it in `#[target_feature]`
+
+error[E0133]: call to function with `#[target_feature]` is unsafe and requires unsafe function or block
+  --> $DIR/safe-calls.rs:61:15
+   |
+LL | const _: () = sse2_and_fxsr();
+   |               ^^^^^^^^^^^^^^^ call to function with `#[target_feature]`
+   |
+   = help: in order for the call to be safe, the context requires the following additional target features: sse2 and fxsr
+   = note: the fxsr and sse2 target features being enabled in the build configuration does not remove the requirement to list them in `#[target_feature]`
+
+error: call to function with `#[target_feature]` is unsafe and requires unsafe block (error E0133)
+  --> $DIR/safe-calls.rs:68:5
+   |
+LL |     sse2();
+   |     ^^^^^^ call to function with `#[target_feature]`
+   |
+   = help: in order for the call to be safe, the context requires the following additional target feature: sse2
+   = note: the sse2 target feature being enabled in the build configuration does not remove the requirement to list it in `#[target_feature]`
+note: an unsafe function restricts its caller, but its body is safe by default
+  --> $DIR/safe-calls.rs:67:1
+   |
+LL | unsafe fn needs_unsafe_block() {
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+note: the lint level is defined here
+  --> $DIR/safe-calls.rs:64:8
+   |
+LL | #[deny(unsafe_op_in_unsafe_fn)]
+   |        ^^^^^^^^^^^^^^^^^^^^^^
+
+error: aborting due to 12 previous errors
+
+For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/runtime/running-with-no-runtime.rs b/tests/ui/runtime/running-with-no-runtime.rs
index c575a6bec8e..c321e86dc18 100644
--- a/tests/ui/runtime/running-with-no-runtime.rs
+++ b/tests/ui/runtime/running-with-no-runtime.rs
@@ -1,8 +1,6 @@
 // run-pass
 // ignore-emscripten spawning processes is not supported
 // ignore-sgx no processes
-// revisions: mir thir
-// [thir]compile-flags: -Zthir-unsafeck
 
 #![feature(start)]
 
diff --git a/tests/ui/simd/intrinsic/generic-comparison-pass.rs b/tests/ui/simd/intrinsic/generic-comparison-pass.rs
index da5c42a1a98..103132c18ae 100644
--- a/tests/ui/simd/intrinsic/generic-comparison-pass.rs
+++ b/tests/ui/simd/intrinsic/generic-comparison-pass.rs
@@ -1,7 +1,5 @@
 // run-pass
 // ignore-emscripten FIXME(#45351) hits an LLVM assert
-// revisions: mir thir
-// [thir]compile-flags: -Zthir-unsafeck
 
 #![feature(repr_simd, platform_intrinsics, concat_idents)]
 #![allow(non_camel_case_types)]
diff --git a/tests/ui/span/lint-unused-unsafe.rs b/tests/ui/span/lint-unused-unsafe.rs
index ca615f64f22..94bdd114007 100644
--- a/tests/ui/span/lint-unused-unsafe.rs
+++ b/tests/ui/span/lint-unused-unsafe.rs
@@ -3,9 +3,6 @@
 
 // edition:2018
 
-// revisions: mir thir
-// [thir]compile-flags: -Zthir-unsafeck
-
 #![allow(dead_code)]
 #![deny(unused_unsafe)]
 
diff --git a/tests/ui/span/lint-unused-unsafe.mir.stderr b/tests/ui/span/lint-unused-unsafe.stderr
index 9e8d3359242..d8bd7cc7475 100644
--- a/tests/ui/span/lint-unused-unsafe.mir.stderr
+++ b/tests/ui/span/lint-unused-unsafe.stderr
@@ -1,77 +1,77 @@
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:22:13
+  --> $DIR/lint-unused-unsafe.rs:19:13
    |
 LL | fn bad1() { unsafe {} }
    |             ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:10:9
+  --> $DIR/lint-unused-unsafe.rs:7:9
    |
 LL | #![deny(unused_unsafe)]
    |         ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:23:13
+  --> $DIR/lint-unused-unsafe.rs:20:13
    |
 LL | fn bad2() { unsafe { bad1() } }
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:24:20
+  --> $DIR/lint-unused-unsafe.rs:21:20
    |
 LL | unsafe fn bad3() { unsafe {} }
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:25:13
+  --> $DIR/lint-unused-unsafe.rs:22:13
    |
 LL | fn bad4() { unsafe { callback(||{}) } }
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:28:5
+  --> $DIR/lint-unused-unsafe.rs:25:5
    |
 LL |     unsafe {
    |     ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:35:5
+  --> $DIR/lint-unused-unsafe.rs:32:5
    |
 LL |     unsafe {
    |     ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:70:9
+  --> $DIR/lint-unused-unsafe.rs:67:9
    |
 LL |         unsafe {
    |         ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:79:9
+  --> $DIR/lint-unused-unsafe.rs:76:9
    |
 LL |         unsafe {
    |         ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:80:13
+  --> $DIR/lint-unused-unsafe.rs:77:13
    |
 LL |             unsafe {}
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:81:13
+  --> $DIR/lint-unused-unsafe.rs:78:13
    |
 LL |             unsafe {}
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:86:9
+  --> $DIR/lint-unused-unsafe.rs:83:9
    |
 LL |         unsafe {
    |         ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:96:13
+  --> $DIR/lint-unused-unsafe.rs:93:13
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -80,7 +80,7 @@ LL |             unsafe { unsf() }
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:97:13
+  --> $DIR/lint-unused-unsafe.rs:94:13
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -89,7 +89,7 @@ LL |             unsafe { unsf() }
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:98:13
+  --> $DIR/lint-unused-unsafe.rs:95:13
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -98,7 +98,7 @@ LL |             unsafe { unsf() }
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:108:17
+  --> $DIR/lint-unused-unsafe.rs:105:17
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -107,13 +107,13 @@ LL |                 unsafe { unsf() }
    |                 ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:106:20
+  --> $DIR/lint-unused-unsafe.rs:103:20
    |
 LL |             #[deny(unused_unsafe)]
    |                    ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:109:17
+  --> $DIR/lint-unused-unsafe.rs:106:17
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -122,7 +122,7 @@ LL |                 unsafe { unsf() }
    |                 ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:110:17
+  --> $DIR/lint-unused-unsafe.rs:107:17
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -131,37 +131,37 @@ LL |                 unsafe { unsf() }
    |                 ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:120:9
+  --> $DIR/lint-unused-unsafe.rs:117:9
    |
 LL |         unsafe {
    |         ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:130:9
+  --> $DIR/lint-unused-unsafe.rs:127:9
    |
 LL |         unsafe {
    |         ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:131:13
+  --> $DIR/lint-unused-unsafe.rs:128:13
    |
 LL |             unsafe {}
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:132:13
+  --> $DIR/lint-unused-unsafe.rs:129:13
    |
 LL |             unsafe {}
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:138:9
+  --> $DIR/lint-unused-unsafe.rs:135:9
    |
 LL |         unsafe {
    |         ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:149:13
+  --> $DIR/lint-unused-unsafe.rs:146:13
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -170,7 +170,7 @@ LL |             unsafe { unsf() }
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:150:13
+  --> $DIR/lint-unused-unsafe.rs:147:13
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -179,7 +179,7 @@ LL |             unsafe { unsf() }
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:151:13
+  --> $DIR/lint-unused-unsafe.rs:148:13
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -188,7 +188,7 @@ LL |             unsafe { unsf() }
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:162:17
+  --> $DIR/lint-unused-unsafe.rs:159:17
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -197,13 +197,13 @@ LL |                 unsafe { unsf() }
    |                 ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:160:20
+  --> $DIR/lint-unused-unsafe.rs:157:20
    |
 LL |             #[deny(unused_unsafe)]
    |                    ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:163:17
+  --> $DIR/lint-unused-unsafe.rs:160:17
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -212,7 +212,7 @@ LL |                 unsafe { unsf() }
    |                 ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:164:17
+  --> $DIR/lint-unused-unsafe.rs:161:17
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -221,37 +221,37 @@ LL |                 unsafe { unsf() }
    |                 ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:174:9
+  --> $DIR/lint-unused-unsafe.rs:171:9
    |
 LL |         unsafe {
    |         ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:184:9
+  --> $DIR/lint-unused-unsafe.rs:181:9
    |
 LL |         unsafe {
    |         ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:185:13
+  --> $DIR/lint-unused-unsafe.rs:182:13
    |
 LL |             unsafe {}
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:186:13
+  --> $DIR/lint-unused-unsafe.rs:183:13
    |
 LL |             unsafe {}
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:192:9
+  --> $DIR/lint-unused-unsafe.rs:189:9
    |
 LL |         unsafe {
    |         ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:203:13
+  --> $DIR/lint-unused-unsafe.rs:200:13
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -260,7 +260,7 @@ LL |             unsafe { unsf() }
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:204:13
+  --> $DIR/lint-unused-unsafe.rs:201:13
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -269,7 +269,7 @@ LL |             unsafe { unsf() }
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:205:13
+  --> $DIR/lint-unused-unsafe.rs:202:13
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -278,7 +278,7 @@ LL |             unsafe { unsf() }
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:216:17
+  --> $DIR/lint-unused-unsafe.rs:213:17
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -287,13 +287,13 @@ LL |                 unsafe { unsf() }
    |                 ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:214:20
+  --> $DIR/lint-unused-unsafe.rs:211:20
    |
 LL |             #[deny(unused_unsafe)]
    |                    ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:217:17
+  --> $DIR/lint-unused-unsafe.rs:214:17
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -302,7 +302,7 @@ LL |                 unsafe { unsf() }
    |                 ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:218:17
+  --> $DIR/lint-unused-unsafe.rs:215:17
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -311,13 +311,13 @@ LL |                 unsafe { unsf() }
    |                 ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:238:9
+  --> $DIR/lint-unused-unsafe.rs:235:9
    |
 LL |         unsafe {
    |         ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:251:13
+  --> $DIR/lint-unused-unsafe.rs:248:13
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -325,7 +325,7 @@ LL |             unsafe {
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:264:13
+  --> $DIR/lint-unused-unsafe.rs:261:13
    |
 LL |         unsafe {
    |         ------ because it's nested under this `unsafe` block
@@ -333,37 +333,37 @@ LL |             unsafe {
    |             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:282:20
+  --> $DIR/lint-unused-unsafe.rs:279:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:291:20
+  --> $DIR/lint-unused-unsafe.rs:288:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:292:24
+  --> $DIR/lint-unused-unsafe.rs:289:24
    |
 LL |             let _ = || unsafe {};
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:293:24
+  --> $DIR/lint-unused-unsafe.rs:290:24
    |
 LL |             let _ = || unsafe {};
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:298:20
+  --> $DIR/lint-unused-unsafe.rs:295:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:308:24
+  --> $DIR/lint-unused-unsafe.rs:305:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -372,7 +372,7 @@ LL |             let _ = || unsafe { unsf() };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:309:24
+  --> $DIR/lint-unused-unsafe.rs:306:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -381,7 +381,7 @@ LL |             let _ = || unsafe { unsf() };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:310:24
+  --> $DIR/lint-unused-unsafe.rs:307:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -390,7 +390,7 @@ LL |             let _ = || unsafe { unsf() };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:320:28
+  --> $DIR/lint-unused-unsafe.rs:317:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -399,13 +399,13 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:318:20
+  --> $DIR/lint-unused-unsafe.rs:315:20
    |
 LL |             #[deny(unused_unsafe)]
    |                    ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:321:28
+  --> $DIR/lint-unused-unsafe.rs:318:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -414,7 +414,7 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:322:28
+  --> $DIR/lint-unused-unsafe.rs:319:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -423,37 +423,37 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:332:20
+  --> $DIR/lint-unused-unsafe.rs:329:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:342:20
+  --> $DIR/lint-unused-unsafe.rs:339:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:343:24
+  --> $DIR/lint-unused-unsafe.rs:340:24
    |
 LL |             let _ = || unsafe {};
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:344:24
+  --> $DIR/lint-unused-unsafe.rs:341:24
    |
 LL |             let _ = || unsafe {};
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:350:20
+  --> $DIR/lint-unused-unsafe.rs:347:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:361:24
+  --> $DIR/lint-unused-unsafe.rs:358:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -462,7 +462,7 @@ LL |             let _ = || unsafe { unsf() };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:362:24
+  --> $DIR/lint-unused-unsafe.rs:359:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -471,7 +471,7 @@ LL |             let _ = || unsafe { unsf() };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:363:24
+  --> $DIR/lint-unused-unsafe.rs:360:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -480,7 +480,7 @@ LL |             let _ = || unsafe { unsf() };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:374:28
+  --> $DIR/lint-unused-unsafe.rs:371:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -489,13 +489,13 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:372:20
+  --> $DIR/lint-unused-unsafe.rs:369:20
    |
 LL |             #[deny(unused_unsafe)]
    |                    ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:375:28
+  --> $DIR/lint-unused-unsafe.rs:372:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -504,7 +504,7 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:376:28
+  --> $DIR/lint-unused-unsafe.rs:373:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -513,37 +513,37 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:386:20
+  --> $DIR/lint-unused-unsafe.rs:383:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:396:20
+  --> $DIR/lint-unused-unsafe.rs:393:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:397:24
+  --> $DIR/lint-unused-unsafe.rs:394:24
    |
 LL |             let _ = || unsafe {};
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:398:24
+  --> $DIR/lint-unused-unsafe.rs:395:24
    |
 LL |             let _ = || unsafe {};
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:404:20
+  --> $DIR/lint-unused-unsafe.rs:401:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:415:24
+  --> $DIR/lint-unused-unsafe.rs:412:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -552,7 +552,7 @@ LL |             let _ = || unsafe { unsf() };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:416:24
+  --> $DIR/lint-unused-unsafe.rs:413:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -561,7 +561,7 @@ LL |             let _ = || unsafe { unsf() };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:417:24
+  --> $DIR/lint-unused-unsafe.rs:414:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -570,7 +570,7 @@ LL |             let _ = || unsafe { unsf() };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:428:28
+  --> $DIR/lint-unused-unsafe.rs:425:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -579,13 +579,13 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:426:20
+  --> $DIR/lint-unused-unsafe.rs:423:20
    |
 LL |             #[deny(unused_unsafe)]
    |                    ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:429:28
+  --> $DIR/lint-unused-unsafe.rs:426:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -594,7 +594,7 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:430:28
+  --> $DIR/lint-unused-unsafe.rs:427:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -603,13 +603,13 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:450:20
+  --> $DIR/lint-unused-unsafe.rs:447:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:463:24
+  --> $DIR/lint-unused-unsafe.rs:460:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -617,7 +617,7 @@ LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:476:24
+  --> $DIR/lint-unused-unsafe.rs:473:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -625,37 +625,37 @@ LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:495:20
+  --> $DIR/lint-unused-unsafe.rs:492:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:504:20
+  --> $DIR/lint-unused-unsafe.rs:501:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:505:24
+  --> $DIR/lint-unused-unsafe.rs:502:24
    |
 LL |             let _ = || unsafe {};
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:506:24
+  --> $DIR/lint-unused-unsafe.rs:503:24
    |
 LL |             let _ = || unsafe {};
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:511:20
+  --> $DIR/lint-unused-unsafe.rs:508:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:521:24
+  --> $DIR/lint-unused-unsafe.rs:518:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -664,7 +664,7 @@ LL |             let _ = || unsafe { let _ = || unsf(); };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:522:24
+  --> $DIR/lint-unused-unsafe.rs:519:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -673,7 +673,7 @@ LL |             let _ = || unsafe { let _ = || unsf(); };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:523:24
+  --> $DIR/lint-unused-unsafe.rs:520:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -682,7 +682,7 @@ LL |             let _ = || unsafe { let _ = || unsf(); };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:533:28
+  --> $DIR/lint-unused-unsafe.rs:530:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -691,13 +691,13 @@ LL |                 let _ = || unsafe { let _ = || unsf(); };
    |                            ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:531:20
+  --> $DIR/lint-unused-unsafe.rs:528:20
    |
 LL |             #[deny(unused_unsafe)]
    |                    ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:534:28
+  --> $DIR/lint-unused-unsafe.rs:531:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -706,7 +706,7 @@ LL |                 let _ = || unsafe { let _ = || unsf(); };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:535:28
+  --> $DIR/lint-unused-unsafe.rs:532:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -715,37 +715,37 @@ LL |                 let _ = || unsafe { let _ = || unsf(); };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:545:20
+  --> $DIR/lint-unused-unsafe.rs:542:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:555:20
+  --> $DIR/lint-unused-unsafe.rs:552:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:556:24
+  --> $DIR/lint-unused-unsafe.rs:553:24
    |
 LL |             let _ = || unsafe {};
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:557:24
+  --> $DIR/lint-unused-unsafe.rs:554:24
    |
 LL |             let _ = || unsafe {};
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:563:20
+  --> $DIR/lint-unused-unsafe.rs:560:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:574:24
+  --> $DIR/lint-unused-unsafe.rs:571:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -754,7 +754,7 @@ LL |             let _ = || unsafe { let _ = || unsf(); };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:575:24
+  --> $DIR/lint-unused-unsafe.rs:572:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -763,7 +763,7 @@ LL |             let _ = || unsafe { let _ = || unsf(); };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:576:24
+  --> $DIR/lint-unused-unsafe.rs:573:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -772,7 +772,7 @@ LL |             let _ = || unsafe { let _ = || unsf(); };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:587:28
+  --> $DIR/lint-unused-unsafe.rs:584:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -781,13 +781,13 @@ LL |                 let _ = || unsafe { let _ = || unsf(); };
    |                            ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:585:20
+  --> $DIR/lint-unused-unsafe.rs:582:20
    |
 LL |             #[deny(unused_unsafe)]
    |                    ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:588:28
+  --> $DIR/lint-unused-unsafe.rs:585:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -796,7 +796,7 @@ LL |                 let _ = || unsafe { let _ = || unsf(); };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:589:28
+  --> $DIR/lint-unused-unsafe.rs:586:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -805,37 +805,37 @@ LL |                 let _ = || unsafe { let _ = || unsf(); };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:599:20
+  --> $DIR/lint-unused-unsafe.rs:596:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:609:20
+  --> $DIR/lint-unused-unsafe.rs:606:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:610:24
+  --> $DIR/lint-unused-unsafe.rs:607:24
    |
 LL |             let _ = || unsafe {};
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:611:24
+  --> $DIR/lint-unused-unsafe.rs:608:24
    |
 LL |             let _ = || unsafe {};
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:617:20
+  --> $DIR/lint-unused-unsafe.rs:614:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:628:24
+  --> $DIR/lint-unused-unsafe.rs:625:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -844,7 +844,7 @@ LL |             let _ = || unsafe { let _ = || unsf(); };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:629:24
+  --> $DIR/lint-unused-unsafe.rs:626:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -853,7 +853,7 @@ LL |             let _ = || unsafe { let _ = || unsf(); };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:630:24
+  --> $DIR/lint-unused-unsafe.rs:627:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -862,7 +862,7 @@ LL |             let _ = || unsafe { let _ = || unsf(); };
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:641:28
+  --> $DIR/lint-unused-unsafe.rs:638:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -871,13 +871,13 @@ LL |                 let _ = || unsafe { let _ = || unsf(); };
    |                            ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:639:20
+  --> $DIR/lint-unused-unsafe.rs:636:20
    |
 LL |             #[deny(unused_unsafe)]
    |                    ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:642:28
+  --> $DIR/lint-unused-unsafe.rs:639:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -886,7 +886,7 @@ LL |                 let _ = || unsafe { let _ = || unsf(); };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:643:28
+  --> $DIR/lint-unused-unsafe.rs:640:28
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -895,13 +895,13 @@ LL |                 let _ = || unsafe { let _ = || unsf(); };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:663:20
+  --> $DIR/lint-unused-unsafe.rs:660:20
    |
 LL |         let _ = || unsafe {
    |                    ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:676:24
+  --> $DIR/lint-unused-unsafe.rs:673:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -909,7 +909,7 @@ LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:689:24
+  --> $DIR/lint-unused-unsafe.rs:686:24
    |
 LL |         let _ = || unsafe {
    |                    ------ because it's nested under this `unsafe` block
@@ -917,37 +917,37 @@ LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:707:24
+  --> $DIR/lint-unused-unsafe.rs:704:24
    |
 LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:717:24
+  --> $DIR/lint-unused-unsafe.rs:714:24
    |
 LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:718:28
+  --> $DIR/lint-unused-unsafe.rs:715:28
    |
 LL |                 let _ = || unsafe {};
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:719:28
+  --> $DIR/lint-unused-unsafe.rs:716:28
    |
 LL |                 let _ = || unsafe {};
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:725:24
+  --> $DIR/lint-unused-unsafe.rs:722:24
    |
 LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:736:28
+  --> $DIR/lint-unused-unsafe.rs:733:28
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -956,7 +956,7 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:737:28
+  --> $DIR/lint-unused-unsafe.rs:734:28
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -965,7 +965,7 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:738:28
+  --> $DIR/lint-unused-unsafe.rs:735:28
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -974,7 +974,7 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:749:32
+  --> $DIR/lint-unused-unsafe.rs:746:32
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -983,13 +983,13 @@ LL |                     let _ = || unsafe { unsf() };
    |                                ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:747:24
+  --> $DIR/lint-unused-unsafe.rs:744:24
    |
 LL |                 #[deny(unused_unsafe)]
    |                        ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:750:32
+  --> $DIR/lint-unused-unsafe.rs:747:32
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -998,7 +998,7 @@ LL |                     let _ = || unsafe { unsf() };
    |                                ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:751:32
+  --> $DIR/lint-unused-unsafe.rs:748:32
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1007,37 +1007,37 @@ LL |                     let _ = || unsafe { unsf() };
    |                                ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:761:24
+  --> $DIR/lint-unused-unsafe.rs:758:24
    |
 LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:771:24
+  --> $DIR/lint-unused-unsafe.rs:768:24
    |
 LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:772:28
+  --> $DIR/lint-unused-unsafe.rs:769:28
    |
 LL |                 let _ = || unsafe {};
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:773:28
+  --> $DIR/lint-unused-unsafe.rs:770:28
    |
 LL |                 let _ = || unsafe {};
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:779:24
+  --> $DIR/lint-unused-unsafe.rs:776:24
    |
 LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:790:28
+  --> $DIR/lint-unused-unsafe.rs:787:28
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1046,7 +1046,7 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:791:28
+  --> $DIR/lint-unused-unsafe.rs:788:28
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1055,7 +1055,7 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:792:28
+  --> $DIR/lint-unused-unsafe.rs:789:28
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1064,7 +1064,7 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:803:32
+  --> $DIR/lint-unused-unsafe.rs:800:32
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1073,13 +1073,13 @@ LL |                     let _ = || unsafe { unsf() };
    |                                ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:801:24
+  --> $DIR/lint-unused-unsafe.rs:798:24
    |
 LL |                 #[deny(unused_unsafe)]
    |                        ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:804:32
+  --> $DIR/lint-unused-unsafe.rs:801:32
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1088,7 +1088,7 @@ LL |                     let _ = || unsafe { unsf() };
    |                                ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:805:32
+  --> $DIR/lint-unused-unsafe.rs:802:32
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1097,13 +1097,13 @@ LL |                     let _ = || unsafe { unsf() };
    |                                ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:825:24
+  --> $DIR/lint-unused-unsafe.rs:822:24
    |
 LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:838:28
+  --> $DIR/lint-unused-unsafe.rs:835:28
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1111,7 +1111,7 @@ LL |                 let _ = || unsafe {
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:851:28
+  --> $DIR/lint-unused-unsafe.rs:848:28
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1119,37 +1119,37 @@ LL |                 let _ = || unsafe {
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:865:24
+  --> $DIR/lint-unused-unsafe.rs:862:24
    |
 LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:875:24
+  --> $DIR/lint-unused-unsafe.rs:872:24
    |
 LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:876:28
+  --> $DIR/lint-unused-unsafe.rs:873:28
    |
 LL |                 let _ = || unsafe {};
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:877:28
+  --> $DIR/lint-unused-unsafe.rs:874:28
    |
 LL |                 let _ = || unsafe {};
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:883:24
+  --> $DIR/lint-unused-unsafe.rs:880:24
    |
 LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:894:28
+  --> $DIR/lint-unused-unsafe.rs:891:28
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1158,7 +1158,7 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:895:28
+  --> $DIR/lint-unused-unsafe.rs:892:28
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1167,7 +1167,7 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:896:28
+  --> $DIR/lint-unused-unsafe.rs:893:28
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1176,7 +1176,7 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:907:32
+  --> $DIR/lint-unused-unsafe.rs:904:32
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1185,13 +1185,13 @@ LL |                     let _ = || unsafe { unsf() };
    |                                ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:905:24
+  --> $DIR/lint-unused-unsafe.rs:902:24
    |
 LL |                 #[deny(unused_unsafe)]
    |                        ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:908:32
+  --> $DIR/lint-unused-unsafe.rs:905:32
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1200,7 +1200,7 @@ LL |                     let _ = || unsafe { unsf() };
    |                                ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:909:32
+  --> $DIR/lint-unused-unsafe.rs:906:32
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1209,37 +1209,37 @@ LL |                     let _ = || unsafe { unsf() };
    |                                ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:919:24
+  --> $DIR/lint-unused-unsafe.rs:916:24
    |
 LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:929:24
+  --> $DIR/lint-unused-unsafe.rs:926:24
    |
 LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:930:28
+  --> $DIR/lint-unused-unsafe.rs:927:28
    |
 LL |                 let _ = || unsafe {};
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:931:28
+  --> $DIR/lint-unused-unsafe.rs:928:28
    |
 LL |                 let _ = || unsafe {};
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:937:24
+  --> $DIR/lint-unused-unsafe.rs:934:24
    |
 LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:948:28
+  --> $DIR/lint-unused-unsafe.rs:945:28
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1248,7 +1248,7 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:949:28
+  --> $DIR/lint-unused-unsafe.rs:946:28
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1257,7 +1257,7 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:950:28
+  --> $DIR/lint-unused-unsafe.rs:947:28
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1266,7 +1266,7 @@ LL |                 let _ = || unsafe { unsf() };
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:961:32
+  --> $DIR/lint-unused-unsafe.rs:958:32
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1275,13 +1275,13 @@ LL |                     let _ = || unsafe { unsf() };
    |                                ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:959:24
+  --> $DIR/lint-unused-unsafe.rs:956:24
    |
 LL |                 #[deny(unused_unsafe)]
    |                        ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:962:32
+  --> $DIR/lint-unused-unsafe.rs:959:32
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1290,7 +1290,7 @@ LL |                     let _ = || unsafe { unsf() };
    |                                ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:963:32
+  --> $DIR/lint-unused-unsafe.rs:960:32
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1299,13 +1299,13 @@ LL |                     let _ = || unsafe { unsf() };
    |                                ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:983:24
+  --> $DIR/lint-unused-unsafe.rs:980:24
    |
 LL |             let _ = || unsafe {
    |                        ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:996:28
+  --> $DIR/lint-unused-unsafe.rs:993:28
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1313,7 +1313,7 @@ LL |                 let _ = || unsafe {
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1009:28
+  --> $DIR/lint-unused-unsafe.rs:1006:28
    |
 LL |             let _ = || unsafe {
    |                        ------ because it's nested under this `unsafe` block
@@ -1321,13 +1321,13 @@ LL |                 let _ = || unsafe {
    |                            ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1055:29
+  --> $DIR/lint-unused-unsafe.rs:1052:29
    |
 LL |             let _ = async { unsafe {
    |                             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1062:33
+  --> $DIR/lint-unused-unsafe.rs:1059:33
    |
 LL |             let _ = async { unsafe {
    |                             ------ because it's nested under this `unsafe` block
@@ -1336,7 +1336,7 @@ LL |                 let _ = async { unsafe { let _ = async { unsf() }; }};
    |                                 ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1063:33
+  --> $DIR/lint-unused-unsafe.rs:1060:33
    |
 LL |             let _ = async { unsafe {
    |                             ------ because it's nested under this `unsafe` block
@@ -1345,7 +1345,7 @@ LL |                 let _ = async { unsafe { let _ = async { unsf() }; }};
    |                                 ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1064:33
+  --> $DIR/lint-unused-unsafe.rs:1061:33
    |
 LL |             let _ = async { unsafe {
    |                             ------ because it's nested under this `unsafe` block
@@ -1354,13 +1354,13 @@ LL |                 let _ = async { unsafe { let _ = async { unsf() }; }};
    |                                 ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1069:29
+  --> $DIR/lint-unused-unsafe.rs:1066:29
    |
 LL |             let _ = async { unsafe {
    |                             ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1076:33
+  --> $DIR/lint-unused-unsafe.rs:1073:33
    |
 LL |             let _ = async { unsafe {
    |                             ------ because it's nested under this `unsafe` block
@@ -1369,7 +1369,7 @@ LL |                 let _ = async { unsafe { let _ = async { unsf() }; }};
    |                                 ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1077:33
+  --> $DIR/lint-unused-unsafe.rs:1074:33
    |
 LL |             let _ = async { unsafe {
    |                             ------ because it's nested under this `unsafe` block
@@ -1378,7 +1378,7 @@ LL |                 let _ = async { unsafe { let _ = async { unsf() }; }};
    |                                 ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1078:33
+  --> $DIR/lint-unused-unsafe.rs:1075:33
    |
 LL |             let _ = async { unsafe {
    |                             ------ because it's nested under this `unsafe` block
@@ -1387,13 +1387,13 @@ LL |                 let _ = async { unsafe { let _ = async { unsf() }; }};
    |                                 ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1088:22
+  --> $DIR/lint-unused-unsafe.rs:1085:22
    |
 LL |         let _x: [(); unsafe { 0 }] = [];
    |                      ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1092:22
+  --> $DIR/lint-unused-unsafe.rs:1089:22
    |
 LL |         let _x: [(); unsafe { unsafe { size() } }] = [];
    |                      ^^^^^^ unnecessary `unsafe` block
diff --git a/tests/ui/span/lint-unused-unsafe.thir.stderr b/tests/ui/span/lint-unused-unsafe.thir.stderr
deleted file mode 100644
index 9e8d3359242..00000000000
--- a/tests/ui/span/lint-unused-unsafe.thir.stderr
+++ /dev/null
@@ -1,1402 +0,0 @@
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:22:13
-   |
-LL | fn bad1() { unsafe {} }
-   |             ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:10:9
-   |
-LL | #![deny(unused_unsafe)]
-   |         ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:23:13
-   |
-LL | fn bad2() { unsafe { bad1() } }
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:24:20
-   |
-LL | unsafe fn bad3() { unsafe {} }
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:25:13
-   |
-LL | fn bad4() { unsafe { callback(||{}) } }
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:28:5
-   |
-LL |     unsafe {
-   |     ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:35:5
-   |
-LL |     unsafe {
-   |     ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:70:9
-   |
-LL |         unsafe {
-   |         ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:79:9
-   |
-LL |         unsafe {
-   |         ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:80:13
-   |
-LL |             unsafe {}
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:81:13
-   |
-LL |             unsafe {}
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:86:9
-   |
-LL |         unsafe {
-   |         ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:96:13
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-LL |             unsf();
-LL |             unsafe { unsf() }
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:97:13
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-...
-LL |             unsafe { unsf() }
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:98:13
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-...
-LL |             unsafe { unsf() }
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:108:17
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-...
-LL |                 unsafe { unsf() }
-   |                 ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:106:20
-   |
-LL |             #[deny(unused_unsafe)]
-   |                    ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:109:17
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-...
-LL |                 unsafe { unsf() }
-   |                 ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:110:17
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-...
-LL |                 unsafe { unsf() }
-   |                 ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:120:9
-   |
-LL |         unsafe {
-   |         ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:130:9
-   |
-LL |         unsafe {
-   |         ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:131:13
-   |
-LL |             unsafe {}
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:132:13
-   |
-LL |             unsafe {}
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:138:9
-   |
-LL |         unsafe {
-   |         ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:149:13
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-LL |             unsf();
-LL |             unsafe { unsf() }
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:150:13
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-...
-LL |             unsafe { unsf() }
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:151:13
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-...
-LL |             unsafe { unsf() }
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:162:17
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-...
-LL |                 unsafe { unsf() }
-   |                 ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:160:20
-   |
-LL |             #[deny(unused_unsafe)]
-   |                    ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:163:17
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-...
-LL |                 unsafe { unsf() }
-   |                 ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:164:17
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-...
-LL |                 unsafe { unsf() }
-   |                 ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:174:9
-   |
-LL |         unsafe {
-   |         ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:184:9
-   |
-LL |         unsafe {
-   |         ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:185:13
-   |
-LL |             unsafe {}
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:186:13
-   |
-LL |             unsafe {}
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:192:9
-   |
-LL |         unsafe {
-   |         ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:203:13
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-LL |             unsf();
-LL |             unsafe { unsf() }
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:204:13
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-...
-LL |             unsafe { unsf() }
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:205:13
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-...
-LL |             unsafe { unsf() }
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:216:17
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-...
-LL |                 unsafe { unsf() }
-   |                 ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:214:20
-   |
-LL |             #[deny(unused_unsafe)]
-   |                    ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:217:17
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-...
-LL |                 unsafe { unsf() }
-   |                 ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:218:17
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-...
-LL |                 unsafe { unsf() }
-   |                 ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:238:9
-   |
-LL |         unsafe {
-   |         ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:251:13
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-LL |             unsafe {
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:264:13
-   |
-LL |         unsafe {
-   |         ------ because it's nested under this `unsafe` block
-LL |             unsafe {
-   |             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:282:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:291:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:292:24
-   |
-LL |             let _ = || unsafe {};
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:293:24
-   |
-LL |             let _ = || unsafe {};
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:298:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:308:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-LL |             unsf();
-LL |             let _ = || unsafe { unsf() };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:309:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |             let _ = || unsafe { unsf() };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:310:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |             let _ = || unsafe { unsf() };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:320:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:318:20
-   |
-LL |             #[deny(unused_unsafe)]
-   |                    ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:321:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:322:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:332:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:342:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:343:24
-   |
-LL |             let _ = || unsafe {};
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:344:24
-   |
-LL |             let _ = || unsafe {};
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:350:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:361:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-LL |             unsf();
-LL |             let _ = || unsafe { unsf() };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:362:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |             let _ = || unsafe { unsf() };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:363:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |             let _ = || unsafe { unsf() };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:374:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:372:20
-   |
-LL |             #[deny(unused_unsafe)]
-   |                    ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:375:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:376:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:386:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:396:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:397:24
-   |
-LL |             let _ = || unsafe {};
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:398:24
-   |
-LL |             let _ = || unsafe {};
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:404:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:415:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-LL |             unsf();
-LL |             let _ = || unsafe { unsf() };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:416:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |             let _ = || unsafe { unsf() };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:417:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |             let _ = || unsafe { unsf() };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:428:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:426:20
-   |
-LL |             #[deny(unused_unsafe)]
-   |                    ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:429:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:430:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:450:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:463:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:476:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:495:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:504:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:505:24
-   |
-LL |             let _ = || unsafe {};
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:506:24
-   |
-LL |             let _ = || unsafe {};
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:511:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:521:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-LL |             let _ = || unsf();
-LL |             let _ = || unsafe { let _ = || unsf(); };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:522:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |             let _ = || unsafe { let _ = || unsf(); };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:523:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |             let _ = || unsafe { let _ = || unsf(); };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:533:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { let _ = || unsf(); };
-   |                            ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:531:20
-   |
-LL |             #[deny(unused_unsafe)]
-   |                    ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:534:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { let _ = || unsf(); };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:535:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { let _ = || unsf(); };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:545:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:555:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:556:24
-   |
-LL |             let _ = || unsafe {};
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:557:24
-   |
-LL |             let _ = || unsafe {};
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:563:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:574:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-LL |             let _ = || unsf();
-LL |             let _ = || unsafe { let _ = || unsf(); };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:575:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |             let _ = || unsafe { let _ = || unsf(); };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:576:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |             let _ = || unsafe { let _ = || unsf(); };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:587:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { let _ = || unsf(); };
-   |                            ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:585:20
-   |
-LL |             #[deny(unused_unsafe)]
-   |                    ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:588:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { let _ = || unsf(); };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:589:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { let _ = || unsf(); };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:599:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:609:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:610:24
-   |
-LL |             let _ = || unsafe {};
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:611:24
-   |
-LL |             let _ = || unsafe {};
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:617:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:628:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-LL |             let _ = || unsf();
-LL |             let _ = || unsafe { let _ = || unsf(); };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:629:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |             let _ = || unsafe { let _ = || unsf(); };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:630:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |             let _ = || unsafe { let _ = || unsf(); };
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:641:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { let _ = || unsf(); };
-   |                            ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:639:20
-   |
-LL |             #[deny(unused_unsafe)]
-   |                    ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:642:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { let _ = || unsf(); };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:643:28
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { let _ = || unsf(); };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:663:20
-   |
-LL |         let _ = || unsafe {
-   |                    ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:676:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:689:24
-   |
-LL |         let _ = || unsafe {
-   |                    ------ because it's nested under this `unsafe` block
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:707:24
-   |
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:717:24
-   |
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:718:28
-   |
-LL |                 let _ = || unsafe {};
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:719:28
-   |
-LL |                 let _ = || unsafe {};
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:725:24
-   |
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:736:28
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-LL |                 unsf();
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:737:28
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:738:28
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:749:32
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                     let _ = || unsafe { unsf() };
-   |                                ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:747:24
-   |
-LL |                 #[deny(unused_unsafe)]
-   |                        ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:750:32
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                     let _ = || unsafe { unsf() };
-   |                                ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:751:32
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                     let _ = || unsafe { unsf() };
-   |                                ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:761:24
-   |
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:771:24
-   |
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:772:28
-   |
-LL |                 let _ = || unsafe {};
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:773:28
-   |
-LL |                 let _ = || unsafe {};
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:779:24
-   |
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:790:28
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-LL |                 unsf();
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:791:28
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:792:28
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:803:32
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                     let _ = || unsafe { unsf() };
-   |                                ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:801:24
-   |
-LL |                 #[deny(unused_unsafe)]
-   |                        ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:804:32
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                     let _ = || unsafe { unsf() };
-   |                                ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:805:32
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                     let _ = || unsafe { unsf() };
-   |                                ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:825:24
-   |
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:838:28
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-LL |                 let _ = || unsafe {
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:851:28
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-LL |                 let _ = || unsafe {
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:865:24
-   |
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:875:24
-   |
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:876:28
-   |
-LL |                 let _ = || unsafe {};
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:877:28
-   |
-LL |                 let _ = || unsafe {};
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:883:24
-   |
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:894:28
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-LL |                 unsf();
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:895:28
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:896:28
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:907:32
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                     let _ = || unsafe { unsf() };
-   |                                ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:905:24
-   |
-LL |                 #[deny(unused_unsafe)]
-   |                        ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:908:32
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                     let _ = || unsafe { unsf() };
-   |                                ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:909:32
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                     let _ = || unsafe { unsf() };
-   |                                ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:919:24
-   |
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:929:24
-   |
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:930:28
-   |
-LL |                 let _ = || unsafe {};
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:931:28
-   |
-LL |                 let _ = || unsafe {};
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:937:24
-   |
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:948:28
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-LL |                 unsf();
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:949:28
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:950:28
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = || unsafe { unsf() };
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:961:32
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                     let _ = || unsafe { unsf() };
-   |                                ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/lint-unused-unsafe.rs:959:24
-   |
-LL |                 #[deny(unused_unsafe)]
-   |                        ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:962:32
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                     let _ = || unsafe { unsf() };
-   |                                ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:963:32
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-...
-LL |                     let _ = || unsafe { unsf() };
-   |                                ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:983:24
-   |
-LL |             let _ = || unsafe {
-   |                        ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:996:28
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-LL |                 let _ = || unsafe {
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1009:28
-   |
-LL |             let _ = || unsafe {
-   |                        ------ because it's nested under this `unsafe` block
-LL |                 let _ = || unsafe {
-   |                            ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1055:29
-   |
-LL |             let _ = async { unsafe {
-   |                             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1062:33
-   |
-LL |             let _ = async { unsafe {
-   |                             ------ because it's nested under this `unsafe` block
-LL |                 let _ = async { unsf() };
-LL |                 let _ = async { unsafe { let _ = async { unsf() }; }};
-   |                                 ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1063:33
-   |
-LL |             let _ = async { unsafe {
-   |                             ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = async { unsafe { let _ = async { unsf() }; }};
-   |                                 ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1064:33
-   |
-LL |             let _ = async { unsafe {
-   |                             ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = async { unsafe { let _ = async { unsf() }; }};
-   |                                 ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1069:29
-   |
-LL |             let _ = async { unsafe {
-   |                             ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1076:33
-   |
-LL |             let _ = async { unsafe {
-   |                             ------ because it's nested under this `unsafe` block
-LL |                 let _ = async { unsf() };
-LL |                 let _ = async { unsafe { let _ = async { unsf() }; }};
-   |                                 ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1077:33
-   |
-LL |             let _ = async { unsafe {
-   |                             ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = async { unsafe { let _ = async { unsf() }; }};
-   |                                 ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1078:33
-   |
-LL |             let _ = async { unsafe {
-   |                             ------ because it's nested under this `unsafe` block
-...
-LL |                 let _ = async { unsafe { let _ = async { unsf() }; }};
-   |                                 ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1088:22
-   |
-LL |         let _x: [(); unsafe { 0 }] = [];
-   |                      ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/lint-unused-unsafe.rs:1092:22
-   |
-LL |         let _x: [(); unsafe { unsafe { size() } }] = [];
-   |                      ^^^^^^ unnecessary `unsafe` block
-
-error: aborting due to 174 previous errors
-
diff --git a/tests/ui/static/safe-extern-statics-mut.rs b/tests/ui/static/safe-extern-statics-mut.rs
index 389a4589a71..324fa443aa5 100644
--- a/tests/ui/static/safe-extern-statics-mut.rs
+++ b/tests/ui/static/safe-extern-statics-mut.rs
@@ -1,6 +1,4 @@
 // aux-build:extern-statics.rs
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 
 extern crate extern_statics;
 use extern_statics::*;
diff --git a/tests/ui/static/safe-extern-statics-mut.mir.stderr b/tests/ui/static/safe-extern-statics-mut.stderr
index cec5f9d9c9f..38803883414 100644
--- a/tests/ui/static/safe-extern-statics-mut.mir.stderr
+++ b/tests/ui/static/safe-extern-statics-mut.stderr
@@ -1,5 +1,5 @@
 error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/safe-extern-statics-mut.rs:13:13
+  --> $DIR/safe-extern-statics-mut.rs:11:13
    |
 LL |     let b = B;
    |             ^ use of mutable static
@@ -7,7 +7,7 @@ LL |     let b = B;
    = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
 
 error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/safe-extern-statics-mut.rs:14:14
+  --> $DIR/safe-extern-statics-mut.rs:12:14
    |
 LL |     let rb = &B;
    |              ^^ use of mutable static
@@ -15,7 +15,7 @@ LL |     let rb = &B;
    = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
 
 error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/safe-extern-statics-mut.rs:15:14
+  --> $DIR/safe-extern-statics-mut.rs:13:14
    |
 LL |     let xb = XB;
    |              ^^ use of mutable static
@@ -23,7 +23,7 @@ LL |     let xb = XB;
    = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
 
 error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/safe-extern-statics-mut.rs:16:15
+  --> $DIR/safe-extern-statics-mut.rs:14:15
    |
 LL |     let xrb = &XB;
    |               ^^^ use of mutable static
diff --git a/tests/ui/static/safe-extern-statics-mut.thir.stderr b/tests/ui/static/safe-extern-statics-mut.thir.stderr
deleted file mode 100644
index 8e6d2805a0b..00000000000
--- a/tests/ui/static/safe-extern-statics-mut.thir.stderr
+++ /dev/null
@@ -1,35 +0,0 @@
-error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/safe-extern-statics-mut.rs:13:13
-   |
-LL |     let b = B;
-   |             ^ use of mutable static
-   |
-   = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
-
-error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/safe-extern-statics-mut.rs:14:15
-   |
-LL |     let rb = &B;
-   |               ^ use of mutable static
-   |
-   = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
-
-error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/safe-extern-statics-mut.rs:15:14
-   |
-LL |     let xb = XB;
-   |              ^^ use of mutable static
-   |
-   = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
-
-error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/safe-extern-statics-mut.rs:16:16
-   |
-LL |     let xrb = &XB;
-   |                ^^ use of mutable static
-   |
-   = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
-
-error: aborting due to 4 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/static/safe-extern-statics.rs b/tests/ui/static/safe-extern-statics.rs
index 0aa90c442ea..6fa4c4aaca5 100644
--- a/tests/ui/static/safe-extern-statics.rs
+++ b/tests/ui/static/safe-extern-statics.rs
@@ -1,6 +1,4 @@
 // aux-build:extern-statics.rs
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 
 extern crate extern_statics;
 use extern_statics::*;
diff --git a/tests/ui/static/safe-extern-statics.mir.stderr b/tests/ui/static/safe-extern-statics.stderr
index 102abd0816f..b42572ea3ee 100644
--- a/tests/ui/static/safe-extern-statics.mir.stderr
+++ b/tests/ui/static/safe-extern-statics.stderr
@@ -1,5 +1,5 @@
 error[E0133]: use of extern static is unsafe and requires unsafe function or block
-  --> $DIR/safe-extern-statics.rs:13:13
+  --> $DIR/safe-extern-statics.rs:11:13
    |
 LL |     let a = A;
    |             ^ use of extern static
@@ -7,7 +7,7 @@ LL |     let a = A;
    = note: extern statics are not controlled by the Rust type system: invalid data, aliasing violations or data races will cause undefined behavior
 
 error[E0133]: use of extern static is unsafe and requires unsafe function or block
-  --> $DIR/safe-extern-statics.rs:14:14
+  --> $DIR/safe-extern-statics.rs:12:14
    |
 LL |     let ra = &A;
    |              ^^ use of extern static
@@ -15,7 +15,7 @@ LL |     let ra = &A;
    = note: extern statics are not controlled by the Rust type system: invalid data, aliasing violations or data races will cause undefined behavior
 
 error[E0133]: use of extern static is unsafe and requires unsafe function or block
-  --> $DIR/safe-extern-statics.rs:15:14
+  --> $DIR/safe-extern-statics.rs:13:14
    |
 LL |     let xa = XA;
    |              ^^ use of extern static
@@ -23,7 +23,7 @@ LL |     let xa = XA;
    = note: extern statics are not controlled by the Rust type system: invalid data, aliasing violations or data races will cause undefined behavior
 
 error[E0133]: use of extern static is unsafe and requires unsafe function or block
-  --> $DIR/safe-extern-statics.rs:16:15
+  --> $DIR/safe-extern-statics.rs:14:15
    |
 LL |     let xra = &XA;
    |               ^^^ use of extern static
diff --git a/tests/ui/static/safe-extern-statics.thir.stderr b/tests/ui/static/safe-extern-statics.thir.stderr
deleted file mode 100644
index 7fd2182c4c6..00000000000
--- a/tests/ui/static/safe-extern-statics.thir.stderr
+++ /dev/null
@@ -1,35 +0,0 @@
-error[E0133]: use of extern static is unsafe and requires unsafe function or block
-  --> $DIR/safe-extern-statics.rs:13:13
-   |
-LL |     let a = A;
-   |             ^ use of extern static
-   |
-   = note: extern statics are not controlled by the Rust type system: invalid data, aliasing violations or data races will cause undefined behavior
-
-error[E0133]: use of extern static is unsafe and requires unsafe function or block
-  --> $DIR/safe-extern-statics.rs:14:15
-   |
-LL |     let ra = &A;
-   |               ^ use of extern static
-   |
-   = note: extern statics are not controlled by the Rust type system: invalid data, aliasing violations or data races will cause undefined behavior
-
-error[E0133]: use of extern static is unsafe and requires unsafe function or block
-  --> $DIR/safe-extern-statics.rs:15:14
-   |
-LL |     let xa = XA;
-   |              ^^ use of extern static
-   |
-   = note: extern statics are not controlled by the Rust type system: invalid data, aliasing violations or data races will cause undefined behavior
-
-error[E0133]: use of extern static is unsafe and requires unsafe function or block
-  --> $DIR/safe-extern-statics.rs:16:16
-   |
-LL |     let xra = &XA;
-   |                ^^ use of extern static
-   |
-   = note: extern statics are not controlled by the Rust type system: invalid data, aliasing violations or data races will cause undefined behavior
-
-error: aborting due to 4 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/static/static-mut-foreign-requires-unsafe.rs b/tests/ui/static/static-mut-foreign-requires-unsafe.rs
index 4f96acb3375..90aa2537a82 100644
--- a/tests/ui/static/static-mut-foreign-requires-unsafe.rs
+++ b/tests/ui/static/static-mut-foreign-requires-unsafe.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 extern "C" {
     static mut a: i32;
 }
diff --git a/tests/ui/static/static-mut-foreign-requires-unsafe.mir.stderr b/tests/ui/static/static-mut-foreign-requires-unsafe.stderr
index a4659bc8712..e7ed0b710b2 100644
--- a/tests/ui/static/static-mut-foreign-requires-unsafe.mir.stderr
+++ b/tests/ui/static/static-mut-foreign-requires-unsafe.stderr
@@ -1,5 +1,5 @@
 error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/static-mut-foreign-requires-unsafe.rs:9:5
+  --> $DIR/static-mut-foreign-requires-unsafe.rs:6:5
    |
 LL |     a += 3;
    |     ^^^^^^ use of mutable static
@@ -7,7 +7,7 @@ LL |     a += 3;
    = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
 
 error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/static-mut-foreign-requires-unsafe.rs:10:5
+  --> $DIR/static-mut-foreign-requires-unsafe.rs:7:5
    |
 LL |     a = 4;
    |     ^^^^^ use of mutable static
@@ -15,7 +15,7 @@ LL |     a = 4;
    = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
 
 error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/static-mut-foreign-requires-unsafe.rs:11:14
+  --> $DIR/static-mut-foreign-requires-unsafe.rs:8:14
    |
 LL |     let _b = a;
    |              ^ use of mutable static
diff --git a/tests/ui/static/static-mut-foreign-requires-unsafe.thir.stderr b/tests/ui/static/static-mut-foreign-requires-unsafe.thir.stderr
deleted file mode 100644
index 2c62d4d8f3b..00000000000
--- a/tests/ui/static/static-mut-foreign-requires-unsafe.thir.stderr
+++ /dev/null
@@ -1,27 +0,0 @@
-error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/static-mut-foreign-requires-unsafe.rs:9:5
-   |
-LL |     a += 3;
-   |     ^ use of mutable static
-   |
-   = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
-
-error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/static-mut-foreign-requires-unsafe.rs:10:5
-   |
-LL |     a = 4;
-   |     ^ use of mutable static
-   |
-   = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
-
-error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/static-mut-foreign-requires-unsafe.rs:11:14
-   |
-LL |     let _b = a;
-   |              ^ use of mutable static
-   |
-   = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
-
-error: aborting due to 3 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/static/static-mut-requires-unsafe.rs b/tests/ui/static/static-mut-requires-unsafe.rs
index ea3ba095007..413b97e431d 100644
--- a/tests/ui/static/static-mut-requires-unsafe.rs
+++ b/tests/ui/static/static-mut-requires-unsafe.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 static mut a: isize = 3;
 
 fn main() {
diff --git a/tests/ui/static/static-mut-requires-unsafe.mir.stderr b/tests/ui/static/static-mut-requires-unsafe.stderr
index 0d4ce056fc2..85e468b333c 100644
--- a/tests/ui/static/static-mut-requires-unsafe.mir.stderr
+++ b/tests/ui/static/static-mut-requires-unsafe.stderr
@@ -1,5 +1,5 @@
 error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/static-mut-requires-unsafe.rs:7:5
+  --> $DIR/static-mut-requires-unsafe.rs:4:5
    |
 LL |     a += 3;
    |     ^^^^^^ use of mutable static
@@ -7,7 +7,7 @@ LL |     a += 3;
    = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
 
 error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/static-mut-requires-unsafe.rs:8:5
+  --> $DIR/static-mut-requires-unsafe.rs:5:5
    |
 LL |     a = 4;
    |     ^^^^^ use of mutable static
@@ -15,7 +15,7 @@ LL |     a = 4;
    = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
 
 error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/static-mut-requires-unsafe.rs:9:14
+  --> $DIR/static-mut-requires-unsafe.rs:6:14
    |
 LL |     let _b = a;
    |              ^ use of mutable static
diff --git a/tests/ui/static/static-mut-requires-unsafe.thir.stderr b/tests/ui/static/static-mut-requires-unsafe.thir.stderr
deleted file mode 100644
index 1a1cf14271a..00000000000
--- a/tests/ui/static/static-mut-requires-unsafe.thir.stderr
+++ /dev/null
@@ -1,27 +0,0 @@
-error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/static-mut-requires-unsafe.rs:7:5
-   |
-LL |     a += 3;
-   |     ^ use of mutable static
-   |
-   = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
-
-error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/static-mut-requires-unsafe.rs:8:5
-   |
-LL |     a = 4;
-   |     ^ use of mutable static
-   |
-   = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
-
-error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/static-mut-requires-unsafe.rs:9:14
-   |
-LL |     let _b = a;
-   |              ^ use of mutable static
-   |
-   = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
-
-error: aborting due to 3 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/statics/issue-14227.rs b/tests/ui/statics/issue-14227.rs
index 5f866ec9061..a1fde14600a 100644
--- a/tests/ui/statics/issue-14227.rs
+++ b/tests/ui/statics/issue-14227.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 extern "C" {
     pub static symbol: u32;
 }
diff --git a/tests/ui/statics/issue-14227.mir.stderr b/tests/ui/statics/issue-14227.stderr
index ab50b97d63f..085d6df9c41 100644
--- a/tests/ui/statics/issue-14227.mir.stderr
+++ b/tests/ui/statics/issue-14227.stderr
@@ -1,5 +1,5 @@
 error[E0133]: use of extern static is unsafe and requires unsafe function or block
-  --> $DIR/issue-14227.rs:7:21
+  --> $DIR/issue-14227.rs:4:21
    |
 LL | static CRASH: u32 = symbol;
    |                     ^^^^^^ use of extern static
diff --git a/tests/ui/statics/issue-14227.thir.stderr b/tests/ui/statics/issue-14227.thir.stderr
deleted file mode 100644
index ab50b97d63f..00000000000
--- a/tests/ui/statics/issue-14227.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: use of extern static is unsafe and requires unsafe function or block
-  --> $DIR/issue-14227.rs:7:21
-   |
-LL | static CRASH: u32 = symbol;
-   |                     ^^^^^^ use of extern static
-   |
-   = note: extern statics are not controlled by the Rust type system: invalid data, aliasing violations or data races will cause undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/thread-local/thread-local-static.rs b/tests/ui/thread-local/thread-local-static.rs
index afaffbb7e9b..e6cd4839dda 100644
--- a/tests/ui/thread-local/thread-local-static.rs
+++ b/tests/ui/thread-local/thread-local-static.rs
@@ -1,6 +1,4 @@
 // edition:2018
-// revisions: mir thir
-//thir: -Zthir-unsafeck
 
 #![feature(thread_local)]
 #![feature(const_swap)]
diff --git a/tests/ui/thread-local/thread-local-static.mir.stderr b/tests/ui/thread-local/thread-local-static.stderr
index 607d7ee902c..f37fd9db36d 100644
--- a/tests/ui/thread-local/thread-local-static.mir.stderr
+++ b/tests/ui/thread-local/thread-local-static.stderr
@@ -1,5 +1,5 @@
 error[E0658]: mutable references are not allowed in constant functions
-  --> $DIR/thread-local-static.rs:10:12
+  --> $DIR/thread-local-static.rs:8:12
    |
 LL | const fn g(x: &mut [u32; 8]) {
    |            ^
@@ -8,13 +8,13 @@ LL | const fn g(x: &mut [u32; 8]) {
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
 
 error[E0625]: thread-local statics cannot be accessed at compile-time
-  --> $DIR/thread-local-static.rs:12:28
+  --> $DIR/thread-local-static.rs:10:28
    |
 LL |     std::mem::swap(x, &mut STATIC_VAR_2)
    |                            ^^^^^^^^^^^^
 
 error[E0013]: constant functions cannot refer to statics
-  --> $DIR/thread-local-static.rs:12:28
+  --> $DIR/thread-local-static.rs:10:28
    |
 LL |     std::mem::swap(x, &mut STATIC_VAR_2)
    |                            ^^^^^^^^^^^^
@@ -22,7 +22,7 @@ LL |     std::mem::swap(x, &mut STATIC_VAR_2)
    = help: consider extracting the value of the `static` to a `const`, and referring to that
 
 error[E0658]: mutable references are not allowed in constant functions
-  --> $DIR/thread-local-static.rs:12:23
+  --> $DIR/thread-local-static.rs:10:23
    |
 LL |     std::mem::swap(x, &mut STATIC_VAR_2)
    |                       ^^^^^^^^^^^^^^^^^
@@ -31,7 +31,7 @@ LL |     std::mem::swap(x, &mut STATIC_VAR_2)
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
 
 error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/thread-local-static.rs:12:23
+  --> $DIR/thread-local-static.rs:10:23
    |
 LL |     std::mem::swap(x, &mut STATIC_VAR_2)
    |                       ^^^^^^^^^^^^^^^^^ use of mutable static
diff --git a/tests/ui/thread-local/thread-local-static.thir.stderr b/tests/ui/thread-local/thread-local-static.thir.stderr
deleted file mode 100644
index 607d7ee902c..00000000000
--- a/tests/ui/thread-local/thread-local-static.thir.stderr
+++ /dev/null
@@ -1,44 +0,0 @@
-error[E0658]: mutable references are not allowed in constant functions
-  --> $DIR/thread-local-static.rs:10:12
-   |
-LL | const fn g(x: &mut [u32; 8]) {
-   |            ^
-   |
-   = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
-   = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
-
-error[E0625]: thread-local statics cannot be accessed at compile-time
-  --> $DIR/thread-local-static.rs:12:28
-   |
-LL |     std::mem::swap(x, &mut STATIC_VAR_2)
-   |                            ^^^^^^^^^^^^
-
-error[E0013]: constant functions cannot refer to statics
-  --> $DIR/thread-local-static.rs:12:28
-   |
-LL |     std::mem::swap(x, &mut STATIC_VAR_2)
-   |                            ^^^^^^^^^^^^
-   |
-   = help: consider extracting the value of the `static` to a `const`, and referring to that
-
-error[E0658]: mutable references are not allowed in constant functions
-  --> $DIR/thread-local-static.rs:12:23
-   |
-LL |     std::mem::swap(x, &mut STATIC_VAR_2)
-   |                       ^^^^^^^^^^^^^^^^^
-   |
-   = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
-   = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
-
-error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/thread-local-static.rs:12:23
-   |
-LL |     std::mem::swap(x, &mut STATIC_VAR_2)
-   |                       ^^^^^^^^^^^^^^^^^ use of mutable static
-   |
-   = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
-
-error: aborting due to 5 previous errors
-
-Some errors have detailed explanations: E0013, E0133, E0625, E0658.
-For more information about an error, try `rustc --explain E0013`.
diff --git a/tests/ui/threads-sendsync/issue-43733.rs b/tests/ui/threads-sendsync/issue-43733.rs
index cac745f1e12..996abb4809a 100644
--- a/tests/ui/threads-sendsync/issue-43733.rs
+++ b/tests/ui/threads-sendsync/issue-43733.rs
@@ -1,6 +1,4 @@
 // ignore-wasm32
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 #![feature(thread_local)]
 #![feature(cfg_target_thread_local, thread_local_internals)]
 
@@ -17,13 +15,11 @@ static __KEY: std::thread::local_impl::Key<Foo> = std::thread::local_impl::Key::
 
 fn __getit(_: Option<&mut Option<RefCell<String>>>) -> std::option::Option<&'static Foo> {
     __KEY.get(Default::default)
-    //[mir]~^ ERROR call to unsafe function is unsafe
-    //[thir]~^^ ERROR call to unsafe function `Key::<T>::get`
+    //~^ ERROR call to unsafe function is unsafe
 }
 
 static FOO: std::thread::LocalKey<Foo> = std::thread::LocalKey::new(__getit);
-//[mir]~^ ERROR call to unsafe function is unsafe
-//[thir]~^^ ERROR call to unsafe function `LocalKey::<T>::new`
+//~^ ERROR call to unsafe function is unsafe
 
 fn main() {
     FOO.with(|foo| println!("{}", foo.borrow()));
diff --git a/tests/ui/threads-sendsync/issue-43733.mir.stderr b/tests/ui/threads-sendsync/issue-43733.stderr
index ff83e16add9..9090fd0a4a6 100644
--- a/tests/ui/threads-sendsync/issue-43733.mir.stderr
+++ b/tests/ui/threads-sendsync/issue-43733.stderr
@@ -1,5 +1,5 @@
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/issue-43733.rs:19:5
+  --> $DIR/issue-43733.rs:17:5
    |
 LL |     __KEY.get(Default::default)
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
@@ -7,7 +7,7 @@ LL |     __KEY.get(Default::default)
    = note: consult the function's documentation for information on how to avoid undefined behavior
 
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/issue-43733.rs:24:42
+  --> $DIR/issue-43733.rs:21:42
    |
 LL | static FOO: std::thread::LocalKey<Foo> = std::thread::LocalKey::new(__getit);
    |                                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
diff --git a/tests/ui/threads-sendsync/issue-43733.thir.stderr b/tests/ui/threads-sendsync/issue-43733.thir.stderr
deleted file mode 100644
index 94ec724044c..00000000000
--- a/tests/ui/threads-sendsync/issue-43733.thir.stderr
+++ /dev/null
@@ -1,19 +0,0 @@
-error[E0133]: call to unsafe function `Key::<T>::get` is unsafe and requires unsafe function or block
-  --> $DIR/issue-43733.rs:19:5
-   |
-LL |     __KEY.get(Default::default)
-   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error[E0133]: call to unsafe function `LocalKey::<T>::new` is unsafe and requires unsafe function or block
-  --> $DIR/issue-43733.rs:24:42
-   |
-LL | static FOO: std::thread::LocalKey<Foo> = std::thread::LocalKey::new(__getit);
-   |                                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: aborting due to 2 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/traits/safety-fn-body.rs b/tests/ui/traits/safety-fn-body.rs
index 2cc4fe1b344..df527747305 100644
--- a/tests/ui/traits/safety-fn-body.rs
+++ b/tests/ui/traits/safety-fn-body.rs
@@ -1,9 +1,6 @@
 // Check that an unsafe impl does not imply that unsafe actions are
 // legal in the methods.
 
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 unsafe trait UnsafeTrait : Sized {
     fn foo(self) { }
 }
diff --git a/tests/ui/traits/safety-fn-body.mir.stderr b/tests/ui/traits/safety-fn-body.stderr
index 9a04f3e7d62..284e73f572d 100644
--- a/tests/ui/traits/safety-fn-body.mir.stderr
+++ b/tests/ui/traits/safety-fn-body.stderr
@@ -1,5 +1,5 @@
 error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/safety-fn-body.rs:14:9
+  --> $DIR/safety-fn-body.rs:11:9
    |
 LL |         *self += 1;
    |         ^^^^^^^^^^ dereference of raw pointer
diff --git a/tests/ui/traits/safety-fn-body.thir.stderr b/tests/ui/traits/safety-fn-body.thir.stderr
deleted file mode 100644
index 5d4626c161e..00000000000
--- a/tests/ui/traits/safety-fn-body.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/safety-fn-body.rs:14:9
-   |
-LL |         *self += 1;
-   |         ^^^^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/union/union-align.rs b/tests/ui/union/union-align.rs
index 6a44f27dbb2..67ab10fef4b 100644
--- a/tests/ui/union/union-align.rs
+++ b/tests/ui/union/union-align.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 #![allow(dead_code)]
 
diff --git a/tests/ui/union/union-backcomp.rs b/tests/ui/union/union-backcomp.rs
index b19eab9f52b..21b9fc50e1d 100644
--- a/tests/ui/union/union-backcomp.rs
+++ b/tests/ui/union/union-backcomp.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 #![allow(path_statements)]
 #![allow(dead_code)]
diff --git a/tests/ui/union/union-basic.rs b/tests/ui/union/union-basic.rs
index dcc552ac75c..1009def7d52 100644
--- a/tests/ui/union/union-basic.rs
+++ b/tests/ui/union/union-basic.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 #![allow(unused_imports)]
 
diff --git a/tests/ui/union/union-borrow-move-parent-sibling.rs b/tests/ui/union/union-borrow-move-parent-sibling.rs
index 83781c5e550..5b0b44232e4 100644
--- a/tests/ui/union/union-borrow-move-parent-sibling.rs
+++ b/tests/ui/union/union-borrow-move-parent-sibling.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 #![allow(unused)]
 
 use std::ops::{Deref, DerefMut};
diff --git a/tests/ui/union/union-borrow-move-parent-sibling.mirunsafeck.stderr b/tests/ui/union/union-borrow-move-parent-sibling.stderr
index 7f931b49a58..c9a440a66cc 100644
--- a/tests/ui/union/union-borrow-move-parent-sibling.mirunsafeck.stderr
+++ b/tests/ui/union/union-borrow-move-parent-sibling.stderr
@@ -1,5 +1,5 @@
 error[E0502]: cannot borrow `u` (via `u.y`) as immutable because it is also borrowed as mutable (via `u.x`)
-  --> $DIR/union-borrow-move-parent-sibling.rs:56:13
+  --> $DIR/union-borrow-move-parent-sibling.rs:53:13
    |
 LL |     let a = &mut (*u.x).0;
    |                    --- mutable borrow occurs here (via `u.x`)
@@ -11,7 +11,7 @@ LL |     use_borrow(a);
    = note: `u.y` is a field of the union `U`, so it overlaps the field `u.x`
 
 error[E0507]: cannot move out of dereference of `ManuallyDrop<((MockVec<u8>, MockVec<u8>), MockVec<u8>)>`
-  --> $DIR/union-borrow-move-parent-sibling.rs:62:13
+  --> $DIR/union-borrow-move-parent-sibling.rs:59:13
    |
 LL |     let a = u.x.0;
    |             ^^^^^ move occurs because value has type `(MockVec<u8>, MockVec<u8>)`, which does not implement the `Copy` trait
@@ -22,7 +22,7 @@ LL |     let a = &u.x.0;
    |             +
 
 error[E0382]: use of moved value: `u`
-  --> $DIR/union-borrow-move-parent-sibling.rs:64:13
+  --> $DIR/union-borrow-move-parent-sibling.rs:61:13
    |
 LL |     let u = U { x: ManuallyDrop::new(((MockVec::new(), MockVec::new()), MockVec::new())) };
    |         - move occurs because `u` has type `U`, which does not implement the `Copy` trait
@@ -33,7 +33,7 @@ LL |     let b = u.y;
    |             ^^^ value used here after move
 
 error[E0502]: cannot borrow `u` (via `u.y`) as immutable because it is also borrowed as mutable (via `u.x`)
-  --> $DIR/union-borrow-move-parent-sibling.rs:70:13
+  --> $DIR/union-borrow-move-parent-sibling.rs:67:13
    |
 LL |     let a = &mut ((*u.x).0).0;
    |                     --- mutable borrow occurs here (via `u.x`)
@@ -45,7 +45,7 @@ LL |     use_borrow(a);
    = note: `u.y` is a field of the union `U`, so it overlaps the field `u.x`
 
 error[E0507]: cannot move out of dereference of `ManuallyDrop<((MockVec<u8>, MockVec<u8>), MockVec<u8>)>`
-  --> $DIR/union-borrow-move-parent-sibling.rs:76:13
+  --> $DIR/union-borrow-move-parent-sibling.rs:73:13
    |
 LL |     let a = (u.x.0).0;
    |             ^^^^^^^^^ move occurs because value has type `MockVec<u8>`, which does not implement the `Copy` trait
@@ -56,7 +56,7 @@ LL |     let a = &(u.x.0).0;
    |             +
 
 error[E0382]: use of moved value: `u`
-  --> $DIR/union-borrow-move-parent-sibling.rs:78:13
+  --> $DIR/union-borrow-move-parent-sibling.rs:75:13
    |
 LL |     let u = U { x: ManuallyDrop::new(((MockVec::new(), MockVec::new()), MockVec::new())) };
    |         - move occurs because `u` has type `U`, which does not implement the `Copy` trait
@@ -67,7 +67,7 @@ LL |     let b = u.y;
    |             ^^^ value used here after move
 
 error[E0502]: cannot borrow `u` (via `u.x`) as immutable because it is also borrowed as mutable (via `u.y`)
-  --> $DIR/union-borrow-move-parent-sibling.rs:84:13
+  --> $DIR/union-borrow-move-parent-sibling.rs:81:13
    |
 LL |     let a = &mut *u.y;
    |                   --- mutable borrow occurs here (via `u.y`)
diff --git a/tests/ui/union/union-borrow-move-parent-sibling.thirunsafeck.stderr b/tests/ui/union/union-borrow-move-parent-sibling.thirunsafeck.stderr
deleted file mode 100644
index 7f931b49a58..00000000000
--- a/tests/ui/union/union-borrow-move-parent-sibling.thirunsafeck.stderr
+++ /dev/null
@@ -1,84 +0,0 @@
-error[E0502]: cannot borrow `u` (via `u.y`) as immutable because it is also borrowed as mutable (via `u.x`)
-  --> $DIR/union-borrow-move-parent-sibling.rs:56:13
-   |
-LL |     let a = &mut (*u.x).0;
-   |                    --- mutable borrow occurs here (via `u.x`)
-LL |     let b = &u.y;
-   |             ^^^^ immutable borrow of `u.y` -- which overlaps with `u.x` -- occurs here
-LL |     use_borrow(a);
-   |                - mutable borrow later used here
-   |
-   = note: `u.y` is a field of the union `U`, so it overlaps the field `u.x`
-
-error[E0507]: cannot move out of dereference of `ManuallyDrop<((MockVec<u8>, MockVec<u8>), MockVec<u8>)>`
-  --> $DIR/union-borrow-move-parent-sibling.rs:62:13
-   |
-LL |     let a = u.x.0;
-   |             ^^^^^ move occurs because value has type `(MockVec<u8>, MockVec<u8>)`, which does not implement the `Copy` trait
-   |
-help: consider borrowing here
-   |
-LL |     let a = &u.x.0;
-   |             +
-
-error[E0382]: use of moved value: `u`
-  --> $DIR/union-borrow-move-parent-sibling.rs:64:13
-   |
-LL |     let u = U { x: ManuallyDrop::new(((MockVec::new(), MockVec::new()), MockVec::new())) };
-   |         - move occurs because `u` has type `U`, which does not implement the `Copy` trait
-LL |     let a = u.x.0;
-LL |     let a = u.x;
-   |             --- value moved here
-LL |     let b = u.y;
-   |             ^^^ value used here after move
-
-error[E0502]: cannot borrow `u` (via `u.y`) as immutable because it is also borrowed as mutable (via `u.x`)
-  --> $DIR/union-borrow-move-parent-sibling.rs:70:13
-   |
-LL |     let a = &mut ((*u.x).0).0;
-   |                     --- mutable borrow occurs here (via `u.x`)
-LL |     let b = &u.y;
-   |             ^^^^ immutable borrow of `u.y` -- which overlaps with `u.x` -- occurs here
-LL |     use_borrow(a);
-   |                - mutable borrow later used here
-   |
-   = note: `u.y` is a field of the union `U`, so it overlaps the field `u.x`
-
-error[E0507]: cannot move out of dereference of `ManuallyDrop<((MockVec<u8>, MockVec<u8>), MockVec<u8>)>`
-  --> $DIR/union-borrow-move-parent-sibling.rs:76:13
-   |
-LL |     let a = (u.x.0).0;
-   |             ^^^^^^^^^ move occurs because value has type `MockVec<u8>`, which does not implement the `Copy` trait
-   |
-help: consider borrowing here
-   |
-LL |     let a = &(u.x.0).0;
-   |             +
-
-error[E0382]: use of moved value: `u`
-  --> $DIR/union-borrow-move-parent-sibling.rs:78:13
-   |
-LL |     let u = U { x: ManuallyDrop::new(((MockVec::new(), MockVec::new()), MockVec::new())) };
-   |         - move occurs because `u` has type `U`, which does not implement the `Copy` trait
-LL |     let a = (u.x.0).0;
-LL |     let a = u.x;
-   |             --- value moved here
-LL |     let b = u.y;
-   |             ^^^ value used here after move
-
-error[E0502]: cannot borrow `u` (via `u.x`) as immutable because it is also borrowed as mutable (via `u.y`)
-  --> $DIR/union-borrow-move-parent-sibling.rs:84:13
-   |
-LL |     let a = &mut *u.y;
-   |                   --- mutable borrow occurs here (via `u.y`)
-LL |     let b = &u.x;
-   |             ^^^^ immutable borrow of `u.x` -- which overlaps with `u.y` -- occurs here
-LL |     use_borrow(a);
-   |                - mutable borrow later used here
-   |
-   = note: `u.x` is a field of the union `U`, so it overlaps the field `u.y`
-
-error: aborting due to 7 previous errors
-
-Some errors have detailed explanations: E0382, E0502, E0507.
-For more information about an error, try `rustc --explain E0382`.
diff --git a/tests/ui/union/union-const-codegen.rs b/tests/ui/union/union-const-codegen.rs
index 32a546cf35f..d5b30559595 100644
--- a/tests/ui/union/union-const-codegen.rs
+++ b/tests/ui/union/union-const-codegen.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 union U {
     a: u64,
diff --git a/tests/ui/union/union-const-eval-field.rs b/tests/ui/union/union-const-eval-field.rs
index ca48785cd9f..15a20899a78 100644
--- a/tests/ui/union/union-const-eval-field.rs
+++ b/tests/ui/union/union-const-eval-field.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 type Field1 = (i32, u32);
 type Field2 = f32;
diff --git a/tests/ui/union/union-const-eval.rs b/tests/ui/union/union-const-eval.rs
index 32ee4a739ea..70a97795b75 100644
--- a/tests/ui/union/union-const-eval.rs
+++ b/tests/ui/union/union-const-eval.rs
@@ -1,6 +1,4 @@
 // check-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 union U {
     a: usize,
diff --git a/tests/ui/union/union-deref.rs b/tests/ui/union/union-deref.rs
index 5aa28d93f96..02f9bf2c413 100644
--- a/tests/ui/union/union-deref.rs
+++ b/tests/ui/union/union-deref.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 //! Test the part of RFC 2514 that is about not applying `DerefMut` coercions
 //! of union fields.
 
diff --git a/tests/ui/union/union-deref.mirunsafeck.stderr b/tests/ui/union/union-deref.stderr
index be5e60ab88a..38fce568ae7 100644
--- a/tests/ui/union/union-deref.mirunsafeck.stderr
+++ b/tests/ui/union/union-deref.stderr
@@ -1,5 +1,5 @@
 error: not automatically applying `DerefMut` on `ManuallyDrop` union field
-  --> $DIR/union-deref.rs:16:14
+  --> $DIR/union-deref.rs:13:14
    |
 LL |     unsafe { u.f.0 = Vec::new() };
    |              ^^^
@@ -8,7 +8,7 @@ LL |     unsafe { u.f.0 = Vec::new() };
    = help: add an explicit `*` if that is desired, or call `ptr::write` to not run the destructor
 
 error: not automatically applying `DerefMut` on `ManuallyDrop` union field
-  --> $DIR/union-deref.rs:18:19
+  --> $DIR/union-deref.rs:15:19
    |
 LL |     unsafe { &mut u.f.0 };
    |                   ^^^
@@ -17,7 +17,7 @@ LL |     unsafe { &mut u.f.0 };
    = help: add an explicit `*` if that is desired, or call `ptr::write` to not run the destructor
 
 error: not automatically applying `DerefMut` on `ManuallyDrop` union field
-  --> $DIR/union-deref.rs:20:14
+  --> $DIR/union-deref.rs:17:14
    |
 LL |     unsafe { u.f.0.push(0) };
    |              ^^^
@@ -26,7 +26,7 @@ LL |     unsafe { u.f.0.push(0) };
    = help: add an explicit `*` if that is desired, or call `ptr::write` to not run the destructor
 
 error: not automatically applying `DerefMut` on `ManuallyDrop` union field
-  --> $DIR/union-deref.rs:24:14
+  --> $DIR/union-deref.rs:21:14
    |
 LL |     unsafe { u.f.0.0 = Vec::new() };
    |              ^^^^^
@@ -35,7 +35,7 @@ LL |     unsafe { u.f.0.0 = Vec::new() };
    = help: add an explicit `*` if that is desired, or call `ptr::write` to not run the destructor
 
 error: not automatically applying `DerefMut` on `ManuallyDrop` union field
-  --> $DIR/union-deref.rs:26:19
+  --> $DIR/union-deref.rs:23:19
    |
 LL |     unsafe { &mut u.f.0.0 };
    |                   ^^^^^
@@ -44,7 +44,7 @@ LL |     unsafe { &mut u.f.0.0 };
    = help: add an explicit `*` if that is desired, or call `ptr::write` to not run the destructor
 
 error: not automatically applying `DerefMut` on `ManuallyDrop` union field
-  --> $DIR/union-deref.rs:28:14
+  --> $DIR/union-deref.rs:25:14
    |
 LL |     unsafe { u.f.0.0.push(0) };
    |              ^^^^^
diff --git a/tests/ui/union/union-deref.thirunsafeck.stderr b/tests/ui/union/union-deref.thirunsafeck.stderr
deleted file mode 100644
index be5e60ab88a..00000000000
--- a/tests/ui/union/union-deref.thirunsafeck.stderr
+++ /dev/null
@@ -1,56 +0,0 @@
-error: not automatically applying `DerefMut` on `ManuallyDrop` union field
-  --> $DIR/union-deref.rs:16:14
-   |
-LL |     unsafe { u.f.0 = Vec::new() };
-   |              ^^^
-   |
-   = help: writing to this reference calls the destructor for the old value
-   = help: add an explicit `*` if that is desired, or call `ptr::write` to not run the destructor
-
-error: not automatically applying `DerefMut` on `ManuallyDrop` union field
-  --> $DIR/union-deref.rs:18:19
-   |
-LL |     unsafe { &mut u.f.0 };
-   |                   ^^^
-   |
-   = help: writing to this reference calls the destructor for the old value
-   = help: add an explicit `*` if that is desired, or call `ptr::write` to not run the destructor
-
-error: not automatically applying `DerefMut` on `ManuallyDrop` union field
-  --> $DIR/union-deref.rs:20:14
-   |
-LL |     unsafe { u.f.0.push(0) };
-   |              ^^^
-   |
-   = help: writing to this reference calls the destructor for the old value
-   = help: add an explicit `*` if that is desired, or call `ptr::write` to not run the destructor
-
-error: not automatically applying `DerefMut` on `ManuallyDrop` union field
-  --> $DIR/union-deref.rs:24:14
-   |
-LL |     unsafe { u.f.0.0 = Vec::new() };
-   |              ^^^^^
-   |
-   = help: writing to this reference calls the destructor for the old value
-   = help: add an explicit `*` if that is desired, or call `ptr::write` to not run the destructor
-
-error: not automatically applying `DerefMut` on `ManuallyDrop` union field
-  --> $DIR/union-deref.rs:26:19
-   |
-LL |     unsafe { &mut u.f.0.0 };
-   |                   ^^^^^
-   |
-   = help: writing to this reference calls the destructor for the old value
-   = help: add an explicit `*` if that is desired, or call `ptr::write` to not run the destructor
-
-error: not automatically applying `DerefMut` on `ManuallyDrop` union field
-  --> $DIR/union-deref.rs:28:14
-   |
-LL |     unsafe { u.f.0.0.push(0) };
-   |              ^^^^^
-   |
-   = help: writing to this reference calls the destructor for the old value
-   = help: add an explicit `*` if that is desired, or call `ptr::write` to not run the destructor
-
-error: aborting due to 6 previous errors
-
diff --git a/tests/ui/union/union-derive-clone.rs b/tests/ui/union/union-derive-clone.rs
index 7aa62146e54..7ab19edb471 100644
--- a/tests/ui/union/union-derive-clone.rs
+++ b/tests/ui/union/union-derive-clone.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 use std::mem::ManuallyDrop;
 
 #[derive(Clone)] //~ ERROR the trait bound `U1: Copy` is not satisfied
diff --git a/tests/ui/union/union-derive-clone.mirunsafeck.stderr b/tests/ui/union/union-derive-clone.stderr
index 4d23d230fa3..39f1e32e6eb 100644
--- a/tests/ui/union/union-derive-clone.mirunsafeck.stderr
+++ b/tests/ui/union/union-derive-clone.stderr
@@ -1,5 +1,5 @@
 error[E0277]: the trait bound `U1: Copy` is not satisfied
-  --> $DIR/union-derive-clone.rs:6:10
+  --> $DIR/union-derive-clone.rs:3:10
    |
 LL | #[derive(Clone)]
    |          ^^^^^ the trait `Copy` is not implemented for `U1`
@@ -14,7 +14,7 @@ LL | union U1 {
    |
 
 error[E0599]: the method `clone` exists for union `U5<CloneNoCopy>`, but its trait bounds were not satisfied
-  --> $DIR/union-derive-clone.rs:38:15
+  --> $DIR/union-derive-clone.rs:35:15
    |
 LL | union U5<T> {
    | -----------
@@ -29,7 +29,7 @@ LL |     let w = u.clone();
    |               ^^^^^ method cannot be called on `U5<CloneNoCopy>` due to unsatisfied trait bounds
    |
 note: trait bound `CloneNoCopy: Copy` was not satisfied
-  --> $DIR/union-derive-clone.rs:28:10
+  --> $DIR/union-derive-clone.rs:25:10
    |
 LL | #[derive(Clone, Copy)]
    |          ^^^^^ unsatisfied trait bound introduced in this `derive` macro
diff --git a/tests/ui/union/union-derive-clone.thirunsafeck.stderr b/tests/ui/union/union-derive-clone.thirunsafeck.stderr
deleted file mode 100644
index 4d23d230fa3..00000000000
--- a/tests/ui/union/union-derive-clone.thirunsafeck.stderr
+++ /dev/null
@@ -1,45 +0,0 @@
-error[E0277]: the trait bound `U1: Copy` is not satisfied
-  --> $DIR/union-derive-clone.rs:6:10
-   |
-LL | #[derive(Clone)]
-   |          ^^^^^ the trait `Copy` is not implemented for `U1`
-   |
-note: required by a bound in `AssertParamIsCopy`
-  --> $SRC_DIR/core/src/clone.rs:LL:COL
-   = note: this error originates in the derive macro `Clone` (in Nightly builds, run with -Z macro-backtrace for more info)
-help: consider annotating `U1` with `#[derive(Copy)]`
-   |
-LL + #[derive(Copy)]
-LL | union U1 {
-   |
-
-error[E0599]: the method `clone` exists for union `U5<CloneNoCopy>`, but its trait bounds were not satisfied
-  --> $DIR/union-derive-clone.rs:38:15
-   |
-LL | union U5<T> {
-   | -----------
-   | |
-   | method `clone` not found for this union
-   | doesn't satisfy `U5<CloneNoCopy>: Clone`
-...
-LL | struct CloneNoCopy;
-   | ------------------ doesn't satisfy `CloneNoCopy: Copy`
-...
-LL |     let w = u.clone();
-   |               ^^^^^ method cannot be called on `U5<CloneNoCopy>` due to unsatisfied trait bounds
-   |
-note: trait bound `CloneNoCopy: Copy` was not satisfied
-  --> $DIR/union-derive-clone.rs:28:10
-   |
-LL | #[derive(Clone, Copy)]
-   |          ^^^^^ unsatisfied trait bound introduced in this `derive` macro
-help: consider annotating `CloneNoCopy` with `#[derive(Clone, Copy)]`
-   |
-LL + #[derive(Clone, Copy)]
-LL | struct CloneNoCopy;
-   |
-
-error: aborting due to 2 previous errors
-
-Some errors have detailed explanations: E0277, E0599.
-For more information about an error, try `rustc --explain E0277`.
diff --git a/tests/ui/union/union-derive-eq.rs b/tests/ui/union/union-derive-eq.rs
index b7e7f343f8a..e689f8c27d7 100644
--- a/tests/ui/union/union-derive-eq.rs
+++ b/tests/ui/union/union-derive-eq.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 #[derive(Eq)] // OK
 union U1 {
     a: u8,
diff --git a/tests/ui/union/union-derive-eq.mirunsafeck.stderr b/tests/ui/union/union-derive-eq.stderr
index 86e7c955d2e..b068edd6d69 100644
--- a/tests/ui/union/union-derive-eq.mirunsafeck.stderr
+++ b/tests/ui/union/union-derive-eq.stderr
@@ -1,5 +1,5 @@
 error[E0277]: the trait bound `PartialEqNotEq: Eq` is not satisfied
-  --> $DIR/union-derive-eq.rs:16:5
+  --> $DIR/union-derive-eq.rs:13:5
    |
 LL | #[derive(Eq)]
    |          -- in this derive macro expansion
diff --git a/tests/ui/union/union-derive-eq.thirunsafeck.stderr b/tests/ui/union/union-derive-eq.thirunsafeck.stderr
deleted file mode 100644
index 86e7c955d2e..00000000000
--- a/tests/ui/union/union-derive-eq.thirunsafeck.stderr
+++ /dev/null
@@ -1,21 +0,0 @@
-error[E0277]: the trait bound `PartialEqNotEq: Eq` is not satisfied
-  --> $DIR/union-derive-eq.rs:16:5
-   |
-LL | #[derive(Eq)]
-   |          -- in this derive macro expansion
-LL | union U2 {
-LL |     a: PartialEqNotEq,
-   |     ^^^^^^^^^^^^^^^^^ the trait `Eq` is not implemented for `PartialEqNotEq`
-   |
-note: required by a bound in `AssertParamIsEq`
-  --> $SRC_DIR/core/src/cmp.rs:LL:COL
-   = note: this error originates in the derive macro `Eq` (in Nightly builds, run with -Z macro-backtrace for more info)
-help: consider annotating `PartialEqNotEq` with `#[derive(Eq)]`
-   |
-LL + #[derive(Eq)]
-LL | struct PartialEqNotEq;
-   |
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/union/union-derive-rpass.rs b/tests/ui/union/union-derive-rpass.rs
index 8276bc635fc..826b9e5a7c6 100644
--- a/tests/ui/union/union-derive-rpass.rs
+++ b/tests/ui/union/union-derive-rpass.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 #![allow(dead_code)]
 #![allow(unused_variables)]
diff --git a/tests/ui/union/union-drop.rs b/tests/ui/union/union-drop.rs
index c3d7d41ca35..41c1e9243f7 100644
--- a/tests/ui/union/union-drop.rs
+++ b/tests/ui/union/union-drop.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 #![allow(dead_code)]
 #![allow(unused_variables)]
diff --git a/tests/ui/union/union-fields-1.mirunsafeck.stderr b/tests/ui/union/union-fields-1.mirunsafeck.stderr
deleted file mode 100644
index 0c9981c69fc..00000000000
--- a/tests/ui/union/union-fields-1.mirunsafeck.stderr
+++ /dev/null
@@ -1,42 +0,0 @@
-error: field `c` is never read
-  --> $DIR/union-fields-1.rs:9:5
-   |
-LL | union U1 {
-   |       -- field in this union
-...
-LL |     c: u8,
-   |     ^
-   |
-note: the lint level is defined here
-  --> $DIR/union-fields-1.rs:4:9
-   |
-LL | #![deny(dead_code)]
-   |         ^^^^^^^^^
-
-error: field `a` is never read
-  --> $DIR/union-fields-1.rs:12:5
-   |
-LL | union U2 {
-   |       -- field in this union
-LL |     a: u8,
-   |     ^
-
-error: field `a` is never read
-  --> $DIR/union-fields-1.rs:16:20
-   |
-LL | union NoDropLike { a: u8 }
-   |       ----------   ^
-   |       |
-   |       field in this union
-
-error: field `c` is never read
-  --> $DIR/union-fields-1.rs:21:5
-   |
-LL | union U {
-   |       - field in this union
-...
-LL |     c: u8,
-   |     ^
-
-error: aborting due to 4 previous errors
-
diff --git a/tests/ui/union/union-fields-1.rs b/tests/ui/union/union-fields-1.rs
index cf2ef4c03d6..8ab34b55da2 100644
--- a/tests/ui/union/union-fields-1.rs
+++ b/tests/ui/union/union-fields-1.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 #![deny(dead_code)]
 
 union U1 {
diff --git a/tests/ui/union/union-fields-1.thirunsafeck.stderr b/tests/ui/union/union-fields-1.stderr
index 0c9981c69fc..bba8aae6024 100644
--- a/tests/ui/union/union-fields-1.thirunsafeck.stderr
+++ b/tests/ui/union/union-fields-1.stderr
@@ -1,5 +1,5 @@
 error: field `c` is never read
-  --> $DIR/union-fields-1.rs:9:5
+  --> $DIR/union-fields-1.rs:6:5
    |
 LL | union U1 {
    |       -- field in this union
@@ -8,13 +8,13 @@ LL |     c: u8,
    |     ^
    |
 note: the lint level is defined here
-  --> $DIR/union-fields-1.rs:4:9
+  --> $DIR/union-fields-1.rs:1:9
    |
 LL | #![deny(dead_code)]
    |         ^^^^^^^^^
 
 error: field `a` is never read
-  --> $DIR/union-fields-1.rs:12:5
+  --> $DIR/union-fields-1.rs:9:5
    |
 LL | union U2 {
    |       -- field in this union
@@ -22,7 +22,7 @@ LL |     a: u8,
    |     ^
 
 error: field `a` is never read
-  --> $DIR/union-fields-1.rs:16:20
+  --> $DIR/union-fields-1.rs:13:20
    |
 LL | union NoDropLike { a: u8 }
    |       ----------   ^
@@ -30,7 +30,7 @@ LL | union NoDropLike { a: u8 }
    |       field in this union
 
 error: field `c` is never read
-  --> $DIR/union-fields-1.rs:21:5
+  --> $DIR/union-fields-1.rs:18:5
    |
 LL | union U {
    |       - field in this union
diff --git a/tests/ui/union/union-fields-2.rs b/tests/ui/union/union-fields-2.rs
index e738b184703..71b204fcdc5 100644
--- a/tests/ui/union/union-fields-2.rs
+++ b/tests/ui/union/union-fields-2.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 union U {
     a: u8,
     b: u16,
diff --git a/tests/ui/union/union-fields-2.mirunsafeck.stderr b/tests/ui/union/union-fields-2.stderr
index 1157f0c2ae7..142186885ca 100644
--- a/tests/ui/union/union-fields-2.mirunsafeck.stderr
+++ b/tests/ui/union/union-fields-2.stderr
@@ -1,17 +1,17 @@
 error[E0784]: union expressions should have exactly one field
-  --> $DIR/union-fields-2.rs:10:13
+  --> $DIR/union-fields-2.rs:7:13
    |
 LL |     let u = U {};
    |             ^
 
 error[E0784]: union expressions should have exactly one field
-  --> $DIR/union-fields-2.rs:12:13
+  --> $DIR/union-fields-2.rs:9:13
    |
 LL |     let u = U { a: 0, b: 1 };
    |             ^
 
 error[E0560]: union `U` has no field named `c`
-  --> $DIR/union-fields-2.rs:13:29
+  --> $DIR/union-fields-2.rs:10:29
    |
 LL |     let u = U { a: 0, b: 1, c: 2 };
    |                             ^ `U` does not have this field
@@ -19,61 +19,61 @@ LL |     let u = U { a: 0, b: 1, c: 2 };
    = note: all struct fields are already assigned
 
 error[E0784]: union expressions should have exactly one field
-  --> $DIR/union-fields-2.rs:13:13
+  --> $DIR/union-fields-2.rs:10:13
    |
 LL |     let u = U { a: 0, b: 1, c: 2 };
    |             ^
 
 error[E0784]: union expressions should have exactly one field
-  --> $DIR/union-fields-2.rs:15:13
+  --> $DIR/union-fields-2.rs:12:13
    |
 LL |     let u = U { ..u };
    |             ^
 
 error[E0436]: functional record update syntax requires a struct
-  --> $DIR/union-fields-2.rs:15:19
+  --> $DIR/union-fields-2.rs:12:19
    |
 LL |     let u = U { ..u };
    |                   ^
 
 error: union patterns should have exactly one field
-  --> $DIR/union-fields-2.rs:18:9
+  --> $DIR/union-fields-2.rs:15:9
    |
 LL |     let U {} = u;
    |         ^^^^
 
 error: union patterns should have exactly one field
-  --> $DIR/union-fields-2.rs:20:9
+  --> $DIR/union-fields-2.rs:17:9
    |
 LL |     let U { a, b } = u;
    |         ^^^^^^^^^^
 
 error: union patterns should have exactly one field
-  --> $DIR/union-fields-2.rs:21:9
+  --> $DIR/union-fields-2.rs:18:9
    |
 LL |     let U { a, b, c } = u;
    |         ^^^^^^^^^^^^^
 
 error[E0026]: union `U` does not have a field named `c`
-  --> $DIR/union-fields-2.rs:21:19
+  --> $DIR/union-fields-2.rs:18:19
    |
 LL |     let U { a, b, c } = u;
    |                   ^ union `U` does not have this field
 
 error: union patterns should have exactly one field
-  --> $DIR/union-fields-2.rs:23:9
+  --> $DIR/union-fields-2.rs:20:9
    |
 LL |     let U { .. } = u;
    |         ^^^^^^^^
 
 error: `..` cannot be used in union patterns
-  --> $DIR/union-fields-2.rs:23:9
+  --> $DIR/union-fields-2.rs:20:9
    |
 LL |     let U { .. } = u;
    |         ^^^^^^^^
 
 error: `..` cannot be used in union patterns
-  --> $DIR/union-fields-2.rs:25:9
+  --> $DIR/union-fields-2.rs:22:9
    |
 LL |     let U { a, .. } = u;
    |         ^^^^^^^^^^^
diff --git a/tests/ui/union/union-fields-2.thirunsafeck.stderr b/tests/ui/union/union-fields-2.thirunsafeck.stderr
deleted file mode 100644
index 1157f0c2ae7..00000000000
--- a/tests/ui/union/union-fields-2.thirunsafeck.stderr
+++ /dev/null
@@ -1,84 +0,0 @@
-error[E0784]: union expressions should have exactly one field
-  --> $DIR/union-fields-2.rs:10:13
-   |
-LL |     let u = U {};
-   |             ^
-
-error[E0784]: union expressions should have exactly one field
-  --> $DIR/union-fields-2.rs:12:13
-   |
-LL |     let u = U { a: 0, b: 1 };
-   |             ^
-
-error[E0560]: union `U` has no field named `c`
-  --> $DIR/union-fields-2.rs:13:29
-   |
-LL |     let u = U { a: 0, b: 1, c: 2 };
-   |                             ^ `U` does not have this field
-   |
-   = note: all struct fields are already assigned
-
-error[E0784]: union expressions should have exactly one field
-  --> $DIR/union-fields-2.rs:13:13
-   |
-LL |     let u = U { a: 0, b: 1, c: 2 };
-   |             ^
-
-error[E0784]: union expressions should have exactly one field
-  --> $DIR/union-fields-2.rs:15:13
-   |
-LL |     let u = U { ..u };
-   |             ^
-
-error[E0436]: functional record update syntax requires a struct
-  --> $DIR/union-fields-2.rs:15:19
-   |
-LL |     let u = U { ..u };
-   |                   ^
-
-error: union patterns should have exactly one field
-  --> $DIR/union-fields-2.rs:18:9
-   |
-LL |     let U {} = u;
-   |         ^^^^
-
-error: union patterns should have exactly one field
-  --> $DIR/union-fields-2.rs:20:9
-   |
-LL |     let U { a, b } = u;
-   |         ^^^^^^^^^^
-
-error: union patterns should have exactly one field
-  --> $DIR/union-fields-2.rs:21:9
-   |
-LL |     let U { a, b, c } = u;
-   |         ^^^^^^^^^^^^^
-
-error[E0026]: union `U` does not have a field named `c`
-  --> $DIR/union-fields-2.rs:21:19
-   |
-LL |     let U { a, b, c } = u;
-   |                   ^ union `U` does not have this field
-
-error: union patterns should have exactly one field
-  --> $DIR/union-fields-2.rs:23:9
-   |
-LL |     let U { .. } = u;
-   |         ^^^^^^^^
-
-error: `..` cannot be used in union patterns
-  --> $DIR/union-fields-2.rs:23:9
-   |
-LL |     let U { .. } = u;
-   |         ^^^^^^^^
-
-error: `..` cannot be used in union patterns
-  --> $DIR/union-fields-2.rs:25:9
-   |
-LL |     let U { a, .. } = u;
-   |         ^^^^^^^^^^^
-
-error: aborting due to 13 previous errors
-
-Some errors have detailed explanations: E0026, E0436, E0560, E0784.
-For more information about an error, try `rustc --explain E0026`.
diff --git a/tests/ui/union/union-generic-rpass.rs b/tests/ui/union/union-generic-rpass.rs
index 25f1f5050f9..69837f31cab 100644
--- a/tests/ui/union/union-generic-rpass.rs
+++ b/tests/ui/union/union-generic-rpass.rs
@@ -1,7 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 #![allow(dead_code)]
 
 use std::mem::ManuallyDrop;
diff --git a/tests/ui/union/union-generic.rs b/tests/ui/union/union-generic.rs
index 3d68ecb87d8..ff877892579 100644
--- a/tests/ui/union/union-generic.rs
+++ b/tests/ui/union/union-generic.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 use std::rc::Rc;
 
 union U<T: Copy> {
diff --git a/tests/ui/union/union-generic.mirunsafeck.stderr b/tests/ui/union/union-generic.stderr
index 037022a91fc..b9d4aee787e 100644
--- a/tests/ui/union/union-generic.mirunsafeck.stderr
+++ b/tests/ui/union/union-generic.stderr
@@ -1,23 +1,23 @@
 error[E0277]: the trait bound `Rc<u32>: Copy` is not satisfied
-  --> $DIR/union-generic.rs:11:13
+  --> $DIR/union-generic.rs:8:13
    |
 LL |     let u = U { a: Rc::new(0u32) };
    |             ^ the trait `Copy` is not implemented for `Rc<u32>`
    |
 note: required by a bound in `U`
-  --> $DIR/union-generic.rs:6:12
+  --> $DIR/union-generic.rs:3:12
    |
 LL | union U<T: Copy> {
    |            ^^^^ required by this bound in `U`
 
 error[E0277]: the trait bound `Rc<u32>: Copy` is not satisfied
-  --> $DIR/union-generic.rs:13:17
+  --> $DIR/union-generic.rs:10:17
    |
 LL |     let u = U::<Rc<u32>> { a: Default::default() };
    |                 ^^^^^^^ the trait `Copy` is not implemented for `Rc<u32>`
    |
 note: required by a bound in `U`
-  --> $DIR/union-generic.rs:6:12
+  --> $DIR/union-generic.rs:3:12
    |
 LL | union U<T: Copy> {
    |            ^^^^ required by this bound in `U`
diff --git a/tests/ui/union/union-generic.thirunsafeck.stderr b/tests/ui/union/union-generic.thirunsafeck.stderr
deleted file mode 100644
index 037022a91fc..00000000000
--- a/tests/ui/union/union-generic.thirunsafeck.stderr
+++ /dev/null
@@ -1,27 +0,0 @@
-error[E0277]: the trait bound `Rc<u32>: Copy` is not satisfied
-  --> $DIR/union-generic.rs:11:13
-   |
-LL |     let u = U { a: Rc::new(0u32) };
-   |             ^ the trait `Copy` is not implemented for `Rc<u32>`
-   |
-note: required by a bound in `U`
-  --> $DIR/union-generic.rs:6:12
-   |
-LL | union U<T: Copy> {
-   |            ^^^^ required by this bound in `U`
-
-error[E0277]: the trait bound `Rc<u32>: Copy` is not satisfied
-  --> $DIR/union-generic.rs:13:17
-   |
-LL |     let u = U::<Rc<u32>> { a: Default::default() };
-   |                 ^^^^^^^ the trait `Copy` is not implemented for `Rc<u32>`
-   |
-note: required by a bound in `U`
-  --> $DIR/union-generic.rs:6:12
-   |
-LL | union U<T: Copy> {
-   |            ^^^^ required by this bound in `U`
-
-error: aborting due to 2 previous errors
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/union/union-inherent-method.rs b/tests/ui/union/union-inherent-method.rs
index b0fd22da73a..2e75cce7b10 100644
--- a/tests/ui/union/union-inherent-method.rs
+++ b/tests/ui/union/union-inherent-method.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 union U {
     a: u8,
diff --git a/tests/ui/union/union-lint-dead-code.rs b/tests/ui/union/union-lint-dead-code.rs
index 65aaf0a1d35..cb2cdd4dba0 100644
--- a/tests/ui/union/union-lint-dead-code.rs
+++ b/tests/ui/union/union-lint-dead-code.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 #![deny(dead_code)]
 
 union Foo {
diff --git a/tests/ui/union/union-lint-dead-code.mirunsafeck.stderr b/tests/ui/union/union-lint-dead-code.stderr
index 8a3677d525d..691a5e19ae6 100644
--- a/tests/ui/union/union-lint-dead-code.mirunsafeck.stderr
+++ b/tests/ui/union/union-lint-dead-code.stderr
@@ -1,5 +1,5 @@
 error: field `b` is never read
-  --> $DIR/union-lint-dead-code.rs:8:5
+  --> $DIR/union-lint-dead-code.rs:5:5
    |
 LL | union Foo {
    |       --- field in this union
@@ -8,7 +8,7 @@ LL |     b: bool,
    |     ^
    |
 note: the lint level is defined here
-  --> $DIR/union-lint-dead-code.rs:4:9
+  --> $DIR/union-lint-dead-code.rs:1:9
    |
 LL | #![deny(dead_code)]
    |         ^^^^^^^^^
diff --git a/tests/ui/union/union-lint-dead-code.thirunsafeck.stderr b/tests/ui/union/union-lint-dead-code.thirunsafeck.stderr
deleted file mode 100644
index 8a3677d525d..00000000000
--- a/tests/ui/union/union-lint-dead-code.thirunsafeck.stderr
+++ /dev/null
@@ -1,17 +0,0 @@
-error: field `b` is never read
-  --> $DIR/union-lint-dead-code.rs:8:5
-   |
-LL | union Foo {
-   |       --- field in this union
-LL |     x: usize,
-LL |     b: bool,
-   |     ^
-   |
-note: the lint level is defined here
-  --> $DIR/union-lint-dead-code.rs:4:9
-   |
-LL | #![deny(dead_code)]
-   |         ^^^^^^^^^
-
-error: aborting due to 1 previous error
-
diff --git a/tests/ui/union/union-macro.rs b/tests/ui/union/union-macro.rs
index 7fd9d8221c6..5ca013a44cd 100644
--- a/tests/ui/union/union-macro.rs
+++ b/tests/ui/union/union-macro.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 #![allow(unused_variables)]
 
diff --git a/tests/ui/union/union-manuallydrop-rpass.rs b/tests/ui/union/union-manuallydrop-rpass.rs
index 826bdf07cef..ba99e7441e6 100644
--- a/tests/ui/union/union-manuallydrop-rpass.rs
+++ b/tests/ui/union/union-manuallydrop-rpass.rs
@@ -1,7 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 #![allow(dead_code)]
 
 use std::mem::needs_drop;
@@ -28,9 +25,9 @@ union UnionOk3<T: Copy> {
     value: T,
 }
 
-trait Foo { }
+trait Foo {}
 
-trait ImpliesCopy : Copy { }
+trait ImpliesCopy: Copy {}
 
 #[allow(dead_code)]
 union UnionOk4<T: ImpliesCopy> {
diff --git a/tests/ui/union/union-move.rs b/tests/ui/union/union-move.rs
index b8b1ac8046a..76220a7d40a 100644
--- a/tests/ui/union/union-move.rs
+++ b/tests/ui/union/union-move.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 //! Test the behavior of moving out of non-`Copy` union fields.
 //! Avoid types that `Drop`, we want to focus on moving.
 
diff --git a/tests/ui/union/union-move.mirunsafeck.stderr b/tests/ui/union/union-move.stderr
index 6381ae874ba..47fb801a50e 100644
--- a/tests/ui/union/union-move.mirunsafeck.stderr
+++ b/tests/ui/union/union-move.stderr
@@ -1,5 +1,5 @@
 error[E0382]: use of moved value: `x`
-  --> $DIR/union-move.rs:29:18
+  --> $DIR/union-move.rs:26:18
    |
 LL | fn test1(x: U1) {
    |          - move occurs because `x` has type `U1`, which does not implement the `Copy` trait
@@ -10,7 +10,7 @@ LL |         move_out(x.f2_nocopy);
    |                  ^^^^^^^^^^^ value used here after move
    |
 note: consider changing this parameter type in function `move_out` to borrow instead if owning the value isn't necessary
-  --> $DIR/union-move.rs:10:19
+  --> $DIR/union-move.rs:7:19
    |
 LL | fn move_out<T>(x: T) {}
    |    --------       ^ this parameter takes ownership of the value
@@ -18,7 +18,7 @@ LL | fn move_out<T>(x: T) {}
    |    in this function
 
 error[E0382]: use of moved value: `x`
-  --> $DIR/union-move.rs:45:18
+  --> $DIR/union-move.rs:42:18
    |
 LL | fn test3(x: U1) {
    |          - move occurs because `x` has type `U1`, which does not implement the `Copy` trait
@@ -29,7 +29,7 @@ LL |         move_out(x.f3_copy);
    |                  ^^^^^^^^^ value used here after move
    |
 note: consider changing this parameter type in function `move_out` to borrow instead if owning the value isn't necessary
-  --> $DIR/union-move.rs:10:19
+  --> $DIR/union-move.rs:7:19
    |
 LL | fn move_out<T>(x: T) {}
    |    --------       ^ this parameter takes ownership of the value
@@ -37,7 +37,7 @@ LL | fn move_out<T>(x: T) {}
    |    in this function
 
 error[E0509]: cannot move out of type `U2`, which implements the `Drop` trait
-  --> $DIR/union-move.rs:52:18
+  --> $DIR/union-move.rs:49:18
    |
 LL |         move_out(x.f1_nocopy);
    |                  ^^^^^^^^^^^
diff --git a/tests/ui/union/union-move.thirunsafeck.stderr b/tests/ui/union/union-move.thirunsafeck.stderr
deleted file mode 100644
index 6381ae874ba..00000000000
--- a/tests/ui/union/union-move.thirunsafeck.stderr
+++ /dev/null
@@ -1,51 +0,0 @@
-error[E0382]: use of moved value: `x`
-  --> $DIR/union-move.rs:29:18
-   |
-LL | fn test1(x: U1) {
-   |          - move occurs because `x` has type `U1`, which does not implement the `Copy` trait
-...
-LL |         move_out(x.f1_nocopy);
-   |                  ----------- value moved here
-LL |         move_out(x.f2_nocopy);
-   |                  ^^^^^^^^^^^ value used here after move
-   |
-note: consider changing this parameter type in function `move_out` to borrow instead if owning the value isn't necessary
-  --> $DIR/union-move.rs:10:19
-   |
-LL | fn move_out<T>(x: T) {}
-   |    --------       ^ this parameter takes ownership of the value
-   |    |
-   |    in this function
-
-error[E0382]: use of moved value: `x`
-  --> $DIR/union-move.rs:45:18
-   |
-LL | fn test3(x: U1) {
-   |          - move occurs because `x` has type `U1`, which does not implement the `Copy` trait
-...
-LL |         move_out(x.f2_nocopy);
-   |                  ----------- value moved here
-LL |         move_out(x.f3_copy);
-   |                  ^^^^^^^^^ value used here after move
-   |
-note: consider changing this parameter type in function `move_out` to borrow instead if owning the value isn't necessary
-  --> $DIR/union-move.rs:10:19
-   |
-LL | fn move_out<T>(x: T) {}
-   |    --------       ^ this parameter takes ownership of the value
-   |    |
-   |    in this function
-
-error[E0509]: cannot move out of type `U2`, which implements the `Drop` trait
-  --> $DIR/union-move.rs:52:18
-   |
-LL |         move_out(x.f1_nocopy);
-   |                  ^^^^^^^^^^^
-   |                  |
-   |                  cannot move out of here
-   |                  move occurs because `x.f1_nocopy` has type `ManuallyDrop<RefCell<i32>>`, which does not implement the `Copy` trait
-
-error: aborting due to 3 previous errors
-
-Some errors have detailed explanations: E0382, E0509.
-For more information about an error, try `rustc --explain E0382`.
diff --git a/tests/ui/union/union-nodrop.rs b/tests/ui/union/union-nodrop.rs
index 6e6b105a73e..7ce17a7c825 100644
--- a/tests/ui/union/union-nodrop.rs
+++ b/tests/ui/union/union-nodrop.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 #![allow(dead_code)]
 
@@ -19,10 +17,14 @@ static X: () = (NoDrop { inner: ManuallyDrop::new(NeedDrop) }, ()).1;
 
 const Y: () = (NoDrop { inner: ManuallyDrop::new(NeedDrop) }, ()).1;
 
-const fn _f() { (NoDrop { inner: ManuallyDrop::new(NeedDrop) }, ()).1 }
+const fn _f() {
+    (NoDrop { inner: ManuallyDrop::new(NeedDrop) }, ()).1
+}
 
 // A union that scrubs the drop glue from its inner type
-union NoDrop<T> { inner: ManuallyDrop<T> }
+union NoDrop<T> {
+    inner: ManuallyDrop<T>,
+}
 
 // Copy currently can't be implemented on drop-containing unions,
 // this may change later
@@ -35,7 +37,7 @@ union NoDrop<T> { inner: ManuallyDrop<T> }
 // // We should be able to implement Copy for things using NoDrop
 // #[derive(Copy, Clone)]
 struct Foo {
-    x: NoDrop<Box<u8>>
+    x: NoDrop<Box<u8>>,
 }
 
 struct Baz {
@@ -43,7 +45,9 @@ struct Baz {
     y: Box<u8>,
 }
 
-union ActuallyDrop<T> { inner: ManuallyDrop<T> }
+union ActuallyDrop<T> {
+    inner: ManuallyDrop<T>,
+}
 
 impl<T> Drop for ActuallyDrop<T> {
     fn drop(&mut self) {}
diff --git a/tests/ui/union/union-nonzero.rs b/tests/ui/union/union-nonzero.rs
index 3f4f7ea1c10..e7ab4ebe323 100644
--- a/tests/ui/union/union-nonzero.rs
+++ b/tests/ui/union/union-nonzero.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 #![allow(dead_code)]
 
diff --git a/tests/ui/union/union-overwrite.rs b/tests/ui/union/union-overwrite.rs
index 0eea14d9de0..399ed9ae458 100644
--- a/tests/ui/union/union-overwrite.rs
+++ b/tests/ui/union/union-overwrite.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 #[repr(C)]
 #[derive(Copy, Clone)]
diff --git a/tests/ui/union/union-packed.rs b/tests/ui/union/union-packed.rs
index 9c6398bf5aa..538c337a773 100644
--- a/tests/ui/union/union-packed.rs
+++ b/tests/ui/union/union-packed.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 #![allow(dead_code)]
 #![allow(non_snake_case)]
diff --git a/tests/ui/union/union-pat-refutability.rs b/tests/ui/union/union-pat-refutability.rs
index d628a200a07..17ac6c6dfa9 100644
--- a/tests/ui/union/union-pat-refutability.rs
+++ b/tests/ui/union/union-pat-refutability.rs
@@ -1,12 +1,13 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 #![allow(dead_code)]
 #![allow(illegal_floating_point_literal_pattern)]
 
 #[repr(u32)]
-enum Tag { I, F }
+enum Tag {
+    I,
+    F,
+}
 
 #[repr(C)]
 union U {
diff --git a/tests/ui/union/union-suggest-field.rs b/tests/ui/union/union-suggest-field.rs
index 601a22a0600..71b93e873c2 100644
--- a/tests/ui/union/union-suggest-field.rs
+++ b/tests/ui/union/union-suggest-field.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 union U {
     principal: u8,
 }
diff --git a/tests/ui/union/union-suggest-field.mirunsafeck.stderr b/tests/ui/union/union-suggest-field.stderr
index efe4987bd02..5c428cf6c89 100644
--- a/tests/ui/union/union-suggest-field.mirunsafeck.stderr
+++ b/tests/ui/union/union-suggest-field.stderr
@@ -1,5 +1,5 @@
 error[E0560]: union `U` has no field named `principle`
-  --> $DIR/union-suggest-field.rs:13:17
+  --> $DIR/union-suggest-field.rs:10:17
    |
 LL |     let u = U { principle: 0 };
    |                 ^^^^^^^^^ unknown field
@@ -10,7 +10,7 @@ LL |     let u = U { principal: 0 };
    |                 ~~~~~~~~~
 
 error[E0609]: no field `principial` on type `U`
-  --> $DIR/union-suggest-field.rs:17:15
+  --> $DIR/union-suggest-field.rs:14:15
    |
 LL |     let w = u.principial;
    |               ^^^^^^^^^^ unknown field
@@ -21,7 +21,7 @@ LL |     let w = u.principal;
    |               ~~~~~~~~~
 
 error[E0615]: attempted to take value of method `calculate` on type `U`
-  --> $DIR/union-suggest-field.rs:21:15
+  --> $DIR/union-suggest-field.rs:18:15
    |
 LL |     let y = u.calculate;
    |               ^^^^^^^^^ method, not a field
diff --git a/tests/ui/union/union-suggest-field.thirunsafeck.stderr b/tests/ui/union/union-suggest-field.thirunsafeck.stderr
deleted file mode 100644
index efe4987bd02..00000000000
--- a/tests/ui/union/union-suggest-field.thirunsafeck.stderr
+++ /dev/null
@@ -1,37 +0,0 @@
-error[E0560]: union `U` has no field named `principle`
-  --> $DIR/union-suggest-field.rs:13:17
-   |
-LL |     let u = U { principle: 0 };
-   |                 ^^^^^^^^^ unknown field
-   |
-help: a field with a similar name exists
-   |
-LL |     let u = U { principal: 0 };
-   |                 ~~~~~~~~~
-
-error[E0609]: no field `principial` on type `U`
-  --> $DIR/union-suggest-field.rs:17:15
-   |
-LL |     let w = u.principial;
-   |               ^^^^^^^^^^ unknown field
-   |
-help: a field with a similar name exists
-   |
-LL |     let w = u.principal;
-   |               ~~~~~~~~~
-
-error[E0615]: attempted to take value of method `calculate` on type `U`
-  --> $DIR/union-suggest-field.rs:21:15
-   |
-LL |     let y = u.calculate;
-   |               ^^^^^^^^^ method, not a field
-   |
-help: use parentheses to call the method
-   |
-LL |     let y = u.calculate();
-   |                        ++
-
-error: aborting due to 3 previous errors
-
-Some errors have detailed explanations: E0560, E0609, E0615.
-For more information about an error, try `rustc --explain E0560`.
diff --git a/tests/ui/union/union-trait-impl.rs b/tests/ui/union/union-trait-impl.rs
index 6134e91f31e..8a7ac817240 100644
--- a/tests/ui/union/union-trait-impl.rs
+++ b/tests/ui/union/union-trait-impl.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 use std::fmt;
 
diff --git a/tests/ui/union/union-transmute.rs b/tests/ui/union/union-transmute.rs
index 1a3b32d55f3..be8062f6276 100644
--- a/tests/ui/union/union-transmute.rs
+++ b/tests/ui/union/union-transmute.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 
 union U {
     a: (u8, u8),
diff --git a/tests/ui/union/union-unsafe.rs b/tests/ui/union/union-unsafe.rs
index d1465486f77..bd3946686be 100644
--- a/tests/ui/union/union-unsafe.rs
+++ b/tests/ui/union/union-unsafe.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 use std::cell::RefCell;
 use std::mem::ManuallyDrop;
 
@@ -35,7 +32,6 @@ fn deref_union_field(mut u: URef) {
 }
 
 fn assign_noncopy_union_field(mut u: URefCell) {
-    // FIXME(thir-unsafeck)
     u.a = (ManuallyDrop::new(RefCell::new(0)), 1); // OK (assignment does not drop)
     u.a.0 = ManuallyDrop::new(RefCell::new(0)); // OK (assignment does not drop)
     u.a.1 = 1; // OK
diff --git a/tests/ui/union/union-unsafe.mir.stderr b/tests/ui/union/union-unsafe.stderr
index 15f059ffa48..4d3408a89af 100644
--- a/tests/ui/union/union-unsafe.mir.stderr
+++ b/tests/ui/union/union-unsafe.stderr
@@ -1,5 +1,5 @@
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:34:5
+  --> $DIR/union-unsafe.rs:31:5
    |
 LL |     *(u.p) = 13;
    |     ^^^^^^^^^^^ access to union field
@@ -7,7 +7,7 @@ LL |     *(u.p) = 13;
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:47:6
+  --> $DIR/union-unsafe.rs:43:6
    |
 LL |     *u3.a = T::default();
    |      ^^^^ access to union field
@@ -15,7 +15,7 @@ LL |     *u3.a = T::default();
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:53:6
+  --> $DIR/union-unsafe.rs:49:6
    |
 LL |     *u3.a = T::default();
    |      ^^^^ access to union field
@@ -23,7 +23,7 @@ LL |     *u3.a = T::default();
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:61:13
+  --> $DIR/union-unsafe.rs:57:13
    |
 LL |     let a = u1.a;
    |             ^^^^ access to union field
@@ -31,7 +31,7 @@ LL |     let a = u1.a;
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:64:14
+  --> $DIR/union-unsafe.rs:60:14
    |
 LL |     let U1 { a } = u1;
    |              ^ access to union field
@@ -39,7 +39,7 @@ LL |     let U1 { a } = u1;
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:65:12
+  --> $DIR/union-unsafe.rs:61:12
    |
 LL |     if let U1 { a: 12 } = u1 {}
    |            ^^^^^^^^^^^^ access to union field
@@ -47,7 +47,7 @@ LL |     if let U1 { a: 12 } = u1 {}
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:66:12
+  --> $DIR/union-unsafe.rs:62:12
    |
 LL |     if let Some(U1 { a: 13 }) = Some(u1) {}
    |            ^^^^^^^^^^^^^^^^^^ access to union field
@@ -55,7 +55,7 @@ LL |     if let Some(U1 { a: 13 }) = Some(u1) {}
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:71:6
+  --> $DIR/union-unsafe.rs:67:6
    |
 LL |     *u2.a = String::from("new");
    |      ^^^^ access to union field
@@ -63,7 +63,7 @@ LL |     *u2.a = String::from("new");
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:75:6
+  --> $DIR/union-unsafe.rs:71:6
    |
 LL |     *u3.a = 1;
    |      ^^^^ access to union field
@@ -71,7 +71,7 @@ LL |     *u3.a = 1;
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:79:6
+  --> $DIR/union-unsafe.rs:75:6
    |
 LL |     *u3.a = String::from("new");
    |      ^^^^ access to union field
diff --git a/tests/ui/union/union-unsafe.thir.stderr b/tests/ui/union/union-unsafe.thir.stderr
deleted file mode 100644
index 9ce835497c5..00000000000
--- a/tests/ui/union/union-unsafe.thir.stderr
+++ /dev/null
@@ -1,83 +0,0 @@
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:34:6
-   |
-LL |     *(u.p) = 13;
-   |      ^^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:47:6
-   |
-LL |     *u3.a = T::default();
-   |      ^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:53:6
-   |
-LL |     *u3.a = T::default();
-   |      ^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:61:13
-   |
-LL |     let a = u1.a;
-   |             ^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:64:14
-   |
-LL |     let U1 { a } = u1;
-   |              ^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:65:20
-   |
-LL |     if let U1 { a: 12 } = u1 {}
-   |                    ^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:66:25
-   |
-LL |     if let Some(U1 { a: 13 }) = Some(u1) {}
-   |                         ^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:71:6
-   |
-LL |     *u2.a = String::from("new");
-   |      ^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:75:6
-   |
-LL |     *u3.a = 1;
-   |      ^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-unsafe.rs:79:6
-   |
-LL |     *u3.a = String::from("new");
-   |      ^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error: aborting due to 10 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/union/union-unsized.rs b/tests/ui/union/union-unsized.rs
index b95b2e414f3..5dd32192ab9 100644
--- a/tests/ui/union/union-unsized.rs
+++ b/tests/ui/union/union-unsized.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 union U {
     a: str,
     //~^ ERROR the size for values of type
diff --git a/tests/ui/union/union-unsized.mirunsafeck.stderr b/tests/ui/union/union-unsized.stderr
index de7e690d80f..3d2e699f630 100644
--- a/tests/ui/union/union-unsized.mirunsafeck.stderr
+++ b/tests/ui/union/union-unsized.stderr
@@ -1,5 +1,5 @@
 error[E0277]: the size for values of type `str` cannot be known at compilation time
-  --> $DIR/union-unsized.rs:5:8
+  --> $DIR/union-unsized.rs:2:8
    |
 LL |     a: str,
    |        ^^^ doesn't have a size known at compile-time
@@ -29,7 +29,7 @@ LL |     a: std::mem::ManuallyDrop<str>,
    |        +++++++++++++++++++++++   +
 
 error[E0277]: the size for values of type `str` cannot be known at compilation time
-  --> $DIR/union-unsized.rs:14:8
+  --> $DIR/union-unsized.rs:11:8
    |
 LL |     b: str,
    |        ^^^ doesn't have a size known at compile-time
@@ -47,7 +47,19 @@ LL |     b: Box<str>,
    |        ++++   +
 
 error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
-  --> $DIR/union-unsized.rs:14:5
+  --> $DIR/union-unsized.rs:2:5
+   |
+LL |     a: str,
+   |     ^^^^^^
+   |
+   = note: union fields must not have drop side-effects, which is currently enforced via either `Copy` or `ManuallyDrop<...>`
+help: wrap the field type in `ManuallyDrop<...>`
+   |
+LL |     a: std::mem::ManuallyDrop<str>,
+   |        +++++++++++++++++++++++   +
+
+error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
+  --> $DIR/union-unsized.rs:11:5
    |
 LL |     b: str,
    |     ^^^^^^
diff --git a/tests/ui/union/union-unsized.thirunsafeck.stderr b/tests/ui/union/union-unsized.thirunsafeck.stderr
deleted file mode 100644
index de7e690d80f..00000000000
--- a/tests/ui/union/union-unsized.thirunsafeck.stderr
+++ /dev/null
@@ -1,64 +0,0 @@
-error[E0277]: the size for values of type `str` cannot be known at compilation time
-  --> $DIR/union-unsized.rs:5:8
-   |
-LL |     a: str,
-   |        ^^^ doesn't have a size known at compile-time
-   |
-   = help: the trait `Sized` is not implemented for `str`
-   = note: no field of a union may have a dynamically sized type
-   = help: change the field's type to have a statically known size
-help: borrowed types always have a statically known size
-   |
-LL |     a: &str,
-   |        +
-help: the `Box` type always has a statically known size and allocates its contents in the heap
-   |
-LL |     a: Box<str>,
-   |        ++++   +
-
-error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
-  --> $DIR/union-unsized.rs:5:5
-   |
-LL |     a: str,
-   |     ^^^^^^
-   |
-   = note: union fields must not have drop side-effects, which is currently enforced via either `Copy` or `ManuallyDrop<...>`
-help: wrap the field type in `ManuallyDrop<...>`
-   |
-LL |     a: std::mem::ManuallyDrop<str>,
-   |        +++++++++++++++++++++++   +
-
-error[E0277]: the size for values of type `str` cannot be known at compilation time
-  --> $DIR/union-unsized.rs:14:8
-   |
-LL |     b: str,
-   |        ^^^ doesn't have a size known at compile-time
-   |
-   = help: the trait `Sized` is not implemented for `str`
-   = note: no field of a union may have a dynamically sized type
-   = help: change the field's type to have a statically known size
-help: borrowed types always have a statically known size
-   |
-LL |     b: &str,
-   |        +
-help: the `Box` type always has a statically known size and allocates its contents in the heap
-   |
-LL |     b: Box<str>,
-   |        ++++   +
-
-error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
-  --> $DIR/union-unsized.rs:14:5
-   |
-LL |     b: str,
-   |     ^^^^^^
-   |
-   = note: union fields must not have drop side-effects, which is currently enforced via either `Copy` or `ManuallyDrop<...>`
-help: wrap the field type in `ManuallyDrop<...>`
-   |
-LL |     b: std::mem::ManuallyDrop<str>,
-   |        +++++++++++++++++++++++   +
-
-error: aborting due to 4 previous errors
-
-Some errors have detailed explanations: E0277, E0740.
-For more information about an error, try `rustc --explain E0277`.
diff --git a/tests/ui/union/union-with-drop-fields.rs b/tests/ui/union/union-with-drop-fields.rs
index 9720830fb1f..ae147e9bd2b 100644
--- a/tests/ui/union/union-with-drop-fields.rs
+++ b/tests/ui/union/union-with-drop-fields.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 #![allow(dead_code)]
 
 union U {
diff --git a/tests/ui/union/union-with-drop-fields.mirunsafeck.stderr b/tests/ui/union/union-with-drop-fields.stderr
index 9861a21cb3d..6328be56540 100644
--- a/tests/ui/union/union-with-drop-fields.mirunsafeck.stderr
+++ b/tests/ui/union/union-with-drop-fields.stderr
@@ -1,5 +1,5 @@
 error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
-  --> $DIR/union-with-drop-fields.rs:11:5
+  --> $DIR/union-with-drop-fields.rs:8:5
    |
 LL |     a: String,
    |     ^^^^^^^^^
@@ -11,7 +11,7 @@ LL |     a: std::mem::ManuallyDrop<String>,
    |        +++++++++++++++++++++++      +
 
 error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
-  --> $DIR/union-with-drop-fields.rs:19:5
+  --> $DIR/union-with-drop-fields.rs:16:5
    |
 LL |     a: S,
    |     ^^^^
@@ -23,7 +23,7 @@ LL |     a: std::mem::ManuallyDrop<S>,
    |        +++++++++++++++++++++++ +
 
 error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
-  --> $DIR/union-with-drop-fields.rs:24:5
+  --> $DIR/union-with-drop-fields.rs:21:5
    |
 LL |     a: T,
    |     ^^^^
diff --git a/tests/ui/union/union-with-drop-fields.thirunsafeck.stderr b/tests/ui/union/union-with-drop-fields.thirunsafeck.stderr
deleted file mode 100644
index 9861a21cb3d..00000000000
--- a/tests/ui/union/union-with-drop-fields.thirunsafeck.stderr
+++ /dev/null
@@ -1,39 +0,0 @@
-error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
-  --> $DIR/union-with-drop-fields.rs:11:5
-   |
-LL |     a: String,
-   |     ^^^^^^^^^
-   |
-   = note: union fields must not have drop side-effects, which is currently enforced via either `Copy` or `ManuallyDrop<...>`
-help: wrap the field type in `ManuallyDrop<...>`
-   |
-LL |     a: std::mem::ManuallyDrop<String>,
-   |        +++++++++++++++++++++++      +
-
-error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
-  --> $DIR/union-with-drop-fields.rs:19:5
-   |
-LL |     a: S,
-   |     ^^^^
-   |
-   = note: union fields must not have drop side-effects, which is currently enforced via either `Copy` or `ManuallyDrop<...>`
-help: wrap the field type in `ManuallyDrop<...>`
-   |
-LL |     a: std::mem::ManuallyDrop<S>,
-   |        +++++++++++++++++++++++ +
-
-error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
-  --> $DIR/union-with-drop-fields.rs:24:5
-   |
-LL |     a: T,
-   |     ^^^^
-   |
-   = note: union fields must not have drop side-effects, which is currently enforced via either `Copy` or `ManuallyDrop<...>`
-help: wrap the field type in `ManuallyDrop<...>`
-   |
-LL |     a: std::mem::ManuallyDrop<T>,
-   |        +++++++++++++++++++++++ +
-
-error: aborting due to 3 previous errors
-
-For more information about this error, try `rustc --explain E0740`.
diff --git a/tests/ui/unsafe/access_union_field.rs b/tests/ui/unsafe/access_union_field.rs
index 5c4e695df58..4183119725e 100644
--- a/tests/ui/unsafe/access_union_field.rs
+++ b/tests/ui/unsafe/access_union_field.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 #![allow(unused_variables)]
 
 union Foo {
diff --git a/tests/ui/unsafe/access_union_field.mir.stderr b/tests/ui/unsafe/access_union_field.stderr
index 98bc4077793..4c46bb44a1d 100644
--- a/tests/ui/unsafe/access_union_field.mir.stderr
+++ b/tests/ui/unsafe/access_union_field.stderr
@@ -1,5 +1,5 @@
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/access_union_field.rs:13:13
+  --> $DIR/access_union_field.rs:10:13
    |
 LL |     let a = foo.bar;
    |             ^^^^^^^ access to union field
@@ -7,7 +7,7 @@ LL |     let a = foo.bar;
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/access_union_field.rs:14:13
+  --> $DIR/access_union_field.rs:11:13
    |
 LL |     let b = foo.baz;
    |             ^^^^^^^ access to union field
diff --git a/tests/ui/unsafe/access_union_field.thir.stderr b/tests/ui/unsafe/access_union_field.thir.stderr
deleted file mode 100644
index 98bc4077793..00000000000
--- a/tests/ui/unsafe/access_union_field.thir.stderr
+++ /dev/null
@@ -1,19 +0,0 @@
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/access_union_field.rs:13:13
-   |
-LL |     let a = foo.bar;
-   |             ^^^^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/access_union_field.rs:14:13
-   |
-LL |     let b = foo.baz;
-   |             ^^^^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error: aborting due to 2 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/edition-2024-unsafe_op_in_unsafe_fn.rs b/tests/ui/unsafe/edition-2024-unsafe_op_in_unsafe_fn.rs
index 1b429955cb0..9e150326f0b 100644
--- a/tests/ui/unsafe/edition-2024-unsafe_op_in_unsafe_fn.rs
+++ b/tests/ui/unsafe/edition-2024-unsafe_op_in_unsafe_fn.rs
@@ -1,9 +1,6 @@
 // edition: 2024
 // compile-flags: -Zunstable-options
 // check-pass
-// revisions: mir thir
-// [thir]compile-flags: -Zthir-unsafeck
-
 #![crate_type = "lib"]
 #![deny(unused_unsafe)]
 
@@ -11,8 +8,7 @@ unsafe fn unsf() {}
 
 unsafe fn foo() {
     unsf();
-    //[mir]~^ WARN call to unsafe function is unsafe and requires unsafe block
-    //[thir]~^^ WARN call to unsafe function `unsf` is unsafe and requires unsafe block
+    //~^ WARN call to unsafe function is unsafe and requires unsafe block
 
     // no unused_unsafe
     unsafe {
diff --git a/tests/ui/unsafe/edition-2024-unsafe_op_in_unsafe_fn.mir.stderr b/tests/ui/unsafe/edition-2024-unsafe_op_in_unsafe_fn.stderr
index ea53bf59d31..9ca10b05090 100644
--- a/tests/ui/unsafe/edition-2024-unsafe_op_in_unsafe_fn.mir.stderr
+++ b/tests/ui/unsafe/edition-2024-unsafe_op_in_unsafe_fn.stderr
@@ -1,12 +1,12 @@
 warning: call to unsafe function is unsafe and requires unsafe block (error E0133)
-  --> $DIR/edition-2024-unsafe_op_in_unsafe_fn.rs:13:5
+  --> $DIR/edition-2024-unsafe_op_in_unsafe_fn.rs:10:5
    |
 LL |     unsf();
    |     ^^^^^^ call to unsafe function
    |
    = note: consult the function's documentation for information on how to avoid undefined behavior
 note: an unsafe function restricts its caller, but its body is safe by default
-  --> $DIR/edition-2024-unsafe_op_in_unsafe_fn.rs:12:1
+  --> $DIR/edition-2024-unsafe_op_in_unsafe_fn.rs:9:1
    |
 LL | unsafe fn foo() {
    | ^^^^^^^^^^^^^^^
diff --git a/tests/ui/unsafe/edition-2024-unsafe_op_in_unsafe_fn.thir.stderr b/tests/ui/unsafe/edition-2024-unsafe_op_in_unsafe_fn.thir.stderr
deleted file mode 100644
index d63843ed2b3..00000000000
--- a/tests/ui/unsafe/edition-2024-unsafe_op_in_unsafe_fn.thir.stderr
+++ /dev/null
@@ -1,16 +0,0 @@
-warning: call to unsafe function `unsf` is unsafe and requires unsafe block (error E0133)
-  --> $DIR/edition-2024-unsafe_op_in_unsafe_fn.rs:13:5
-   |
-LL |     unsf();
-   |     ^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-note: an unsafe function restricts its caller, but its body is safe by default
-  --> $DIR/edition-2024-unsafe_op_in_unsafe_fn.rs:12:1
-   |
-LL | unsafe fn foo() {
-   | ^^^^^^^^^^^^^^^
-   = note: `#[warn(unsafe_op_in_unsafe_fn)]` on by default
-
-warning: 1 warning emitted
-
diff --git a/tests/ui/unsafe/foreign-unsafe-fn-called.rs b/tests/ui/unsafe/foreign-unsafe-fn-called.rs
index 67302ea1bcd..abbe462021e 100644
--- a/tests/ui/unsafe/foreign-unsafe-fn-called.rs
+++ b/tests/ui/unsafe/foreign-unsafe-fn-called.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 mod test {
     extern "C" {
         pub fn free();
@@ -9,6 +6,5 @@ mod test {
 
 fn main() {
     test::free();
-    //[mir]~^ ERROR call to unsafe function is unsafe
-    //[thir]~^^ ERROR call to unsafe function `test::free` is unsafe
+    //~^ ERROR call to unsafe function is unsafe
 }
diff --git a/tests/ui/unsafe/foreign-unsafe-fn-called.mir.stderr b/tests/ui/unsafe/foreign-unsafe-fn-called.stderr
index 5157dbb514b..b55e6130230 100644
--- a/tests/ui/unsafe/foreign-unsafe-fn-called.mir.stderr
+++ b/tests/ui/unsafe/foreign-unsafe-fn-called.stderr
@@ -1,5 +1,5 @@
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/foreign-unsafe-fn-called.rs:11:5
+  --> $DIR/foreign-unsafe-fn-called.rs:8:5
    |
 LL |     test::free();
    |     ^^^^^^^^^^^^ call to unsafe function
diff --git a/tests/ui/unsafe/foreign-unsafe-fn-called.thir.stderr b/tests/ui/unsafe/foreign-unsafe-fn-called.thir.stderr
deleted file mode 100644
index 8c221314cd7..00000000000
--- a/tests/ui/unsafe/foreign-unsafe-fn-called.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: call to unsafe function `test::free` is unsafe and requires unsafe function or block
-  --> $DIR/foreign-unsafe-fn-called.rs:11:5
-   |
-LL |     test::free();
-   |     ^^^^^^^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/inline_asm.rs b/tests/ui/unsafe/inline_asm.rs
index 12c7efe4f50..df45b8640c1 100644
--- a/tests/ui/unsafe/inline_asm.rs
+++ b/tests/ui/unsafe/inline_asm.rs
@@ -1,5 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 // needs-asm-support
 
 use std::arch::asm;
diff --git a/tests/ui/unsafe/inline_asm.mir.stderr b/tests/ui/unsafe/inline_asm.stderr
index e38a9388a78..1e829152a72 100644
--- a/tests/ui/unsafe/inline_asm.mir.stderr
+++ b/tests/ui/unsafe/inline_asm.stderr
@@ -1,5 +1,5 @@
 error[E0133]: use of inline assembly is unsafe and requires unsafe function or block
-  --> $DIR/inline_asm.rs:8:5
+  --> $DIR/inline_asm.rs:6:5
    |
 LL |     asm!("nop");
    |     ^^^^^^^^^^^ use of inline assembly
diff --git a/tests/ui/unsafe/inline_asm.thir.stderr b/tests/ui/unsafe/inline_asm.thir.stderr
deleted file mode 100644
index e38a9388a78..00000000000
--- a/tests/ui/unsafe/inline_asm.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: use of inline assembly is unsafe and requires unsafe function or block
-  --> $DIR/inline_asm.rs:8:5
-   |
-LL |     asm!("nop");
-   |     ^^^^^^^^^^^ use of inline assembly
-   |
-   = note: inline assembly is entirely unchecked and can cause undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/issue-3080.rs b/tests/ui/unsafe/issue-3080.rs
index 2b5269dda8f..883f3bfd24e 100644
--- a/tests/ui/unsafe/issue-3080.rs
+++ b/tests/ui/unsafe/issue-3080.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 struct X(());
 impl X {
     pub unsafe fn with(&self) { }
diff --git a/tests/ui/unsafe/issue-3080.mir.stderr b/tests/ui/unsafe/issue-3080.stderr
index a1ad98d205e..f84ba204639 100644
--- a/tests/ui/unsafe/issue-3080.mir.stderr
+++ b/tests/ui/unsafe/issue-3080.stderr
@@ -1,5 +1,5 @@
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/issue-3080.rs:10:5
+  --> $DIR/issue-3080.rs:7:5
    |
 LL |     X(()).with();
    |     ^^^^^^^^^^^^ call to unsafe function
diff --git a/tests/ui/unsafe/issue-3080.thir.stderr b/tests/ui/unsafe/issue-3080.thir.stderr
deleted file mode 100644
index 1018218b1b0..00000000000
--- a/tests/ui/unsafe/issue-3080.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: call to unsafe function `X::with` is unsafe and requires unsafe function or block
-  --> $DIR/issue-3080.rs:10:5
-   |
-LL |     X(()).with();
-   |     ^^^^^^^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/issue-45087-unreachable-unsafe.rs b/tests/ui/unsafe/issue-45087-unreachable-unsafe.rs
index 3e3da667c0b..7c4bde185fb 100644
--- a/tests/ui/unsafe/issue-45087-unreachable-unsafe.rs
+++ b/tests/ui/unsafe/issue-45087-unreachable-unsafe.rs
@@ -1,6 +1,4 @@
 // Verify that unreachable code undergoes unsafety checks.
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 
 fn main() {
     return;
diff --git a/tests/ui/unsafe/issue-45087-unreachable-unsafe.mir.stderr b/tests/ui/unsafe/issue-45087-unreachable-unsafe.stderr
index e7960960774..cc1e73bb932 100644
--- a/tests/ui/unsafe/issue-45087-unreachable-unsafe.mir.stderr
+++ b/tests/ui/unsafe/issue-45087-unreachable-unsafe.stderr
@@ -1,5 +1,5 @@
 error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/issue-45087-unreachable-unsafe.rs:7:5
+  --> $DIR/issue-45087-unreachable-unsafe.rs:5:5
    |
 LL |     *(1 as *mut u32) = 42;
    |     ^^^^^^^^^^^^^^^^^^^^^ dereference of raw pointer
@@ -7,7 +7,7 @@ LL |     *(1 as *mut u32) = 42;
    = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
 
 error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/issue-45087-unreachable-unsafe.rs:17:5
+  --> $DIR/issue-45087-unreachable-unsafe.rs:15:5
    |
 LL |     *a = 1;
    |     ^^^^^^ dereference of raw pointer
@@ -15,7 +15,7 @@ LL |     *a = 1;
    = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
 
 error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/issue-45087-unreachable-unsafe.rs:29:5
+  --> $DIR/issue-45087-unreachable-unsafe.rs:27:5
    |
 LL |     *b = 1;
    |     ^^^^^^ dereference of raw pointer
diff --git a/tests/ui/unsafe/issue-45087-unreachable-unsafe.thir.stderr b/tests/ui/unsafe/issue-45087-unreachable-unsafe.thir.stderr
deleted file mode 100644
index e81adad4507..00000000000
--- a/tests/ui/unsafe/issue-45087-unreachable-unsafe.thir.stderr
+++ /dev/null
@@ -1,27 +0,0 @@
-error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/issue-45087-unreachable-unsafe.rs:7:5
-   |
-LL |     *(1 as *mut u32) = 42;
-   |     ^^^^^^^^^^^^^^^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-
-error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/issue-45087-unreachable-unsafe.rs:17:5
-   |
-LL |     *a = 1;
-   |     ^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-
-error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/issue-45087-unreachable-unsafe.rs:29:5
-   |
-LL |     *b = 1;
-   |     ^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-
-error: aborting due to 3 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/issue-45107-unnecessary-unsafe-in-closure.rs b/tests/ui/unsafe/issue-45107-unnecessary-unsafe-in-closure.rs
index ac1cfd62a05..de275ff701a 100644
--- a/tests/ui/unsafe/issue-45107-unnecessary-unsafe-in-closure.rs
+++ b/tests/ui/unsafe/issue-45107-unnecessary-unsafe-in-closure.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Zthir-unsafeck
-
 #[deny(unused_unsafe)]
 fn main() {
     let mut v = Vec::<i32>::with_capacity(24);
diff --git a/tests/ui/unsafe/issue-45107-unnecessary-unsafe-in-closure.mir.stderr b/tests/ui/unsafe/issue-45107-unnecessary-unsafe-in-closure.stderr
index 9e9cbcf33ae..321698e7636 100644
--- a/tests/ui/unsafe/issue-45107-unnecessary-unsafe-in-closure.mir.stderr
+++ b/tests/ui/unsafe/issue-45107-unnecessary-unsafe-in-closure.stderr
@@ -1,5 +1,5 @@
 error: unnecessary `unsafe` block
-  --> $DIR/issue-45107-unnecessary-unsafe-in-closure.rs:10:13
+  --> $DIR/issue-45107-unnecessary-unsafe-in-closure.rs:7:13
    |
 LL |     unsafe {
    |     ------ because it's nested under this `unsafe` block
@@ -8,13 +8,13 @@ LL |             unsafe {
    |             ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/issue-45107-unnecessary-unsafe-in-closure.rs:4:8
+  --> $DIR/issue-45107-unnecessary-unsafe-in-closure.rs:1:8
    |
 LL | #[deny(unused_unsafe)]
    |        ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/issue-45107-unnecessary-unsafe-in-closure.rs:12:38
+  --> $DIR/issue-45107-unnecessary-unsafe-in-closure.rs:9:38
    |
 LL |     unsafe {
    |     ------ because it's nested under this `unsafe` block
@@ -23,7 +23,7 @@ LL |                 |w: &mut Vec<u32>| { unsafe {
    |                                      ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/issue-45107-unnecessary-unsafe-in-closure.rs:16:34
+  --> $DIR/issue-45107-unnecessary-unsafe-in-closure.rs:13:34
    |
 LL |     unsafe {
    |     ------ because it's nested under this `unsafe` block
diff --git a/tests/ui/unsafe/issue-45107-unnecessary-unsafe-in-closure.thir.stderr b/tests/ui/unsafe/issue-45107-unnecessary-unsafe-in-closure.thir.stderr
deleted file mode 100644
index 2267da31512..00000000000
--- a/tests/ui/unsafe/issue-45107-unnecessary-unsafe-in-closure.thir.stderr
+++ /dev/null
@@ -1,35 +0,0 @@
-error: unnecessary `unsafe` block
-  --> $DIR/issue-45107-unnecessary-unsafe-in-closure.rs:10:13
-   |
-LL |     unsafe {
-   |     ------ because it's nested under this `unsafe` block
-LL |         let f = |v: &mut Vec<_>| {
-LL |             unsafe {
-   |             ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/issue-45107-unnecessary-unsafe-in-closure.rs:4:8
-   |
-LL | #[deny(unused_unsafe)]
-   |        ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/issue-45107-unnecessary-unsafe-in-closure.rs:12:38
-   |
-LL |             unsafe {
-   |             ------ because it's nested under this `unsafe` block
-LL |                 v.set_len(24);
-LL |                 |w: &mut Vec<u32>| { unsafe {
-   |                                      ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/issue-45107-unnecessary-unsafe-in-closure.rs:16:34
-   |
-LL |     unsafe {
-   |     ------ because it's nested under this `unsafe` block
-...
-LL |             |x: &mut Vec<u32>| { unsafe {
-   |                                  ^^^^^^ unnecessary `unsafe` block
-
-error: aborting due to 3 previous errors
-
diff --git a/tests/ui/unsafe/issue-47412.rs b/tests/ui/unsafe/issue-47412.rs
index df6d6e4222e..2d1ea72280b 100644
--- a/tests/ui/unsafe/issue-47412.rs
+++ b/tests/ui/unsafe/issue-47412.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 #[derive(Copy, Clone)]
 enum Void {}
 
diff --git a/tests/ui/unsafe/issue-47412.mir.stderr b/tests/ui/unsafe/issue-47412.stderr
index 305f482e8c2..aebcbf07463 100644
--- a/tests/ui/unsafe/issue-47412.mir.stderr
+++ b/tests/ui/unsafe/issue-47412.stderr
@@ -1,5 +1,5 @@
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/issue-47412.rs:14:11
+  --> $DIR/issue-47412.rs:11:11
    |
 LL |     match u.void {}
    |           ^^^^^^ access to union field
@@ -7,7 +7,7 @@ LL |     match u.void {}
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/issue-47412.rs:20:11
+  --> $DIR/issue-47412.rs:17:11
    |
 LL |     match *ptr {}
    |           ^^^^ dereference of raw pointer
diff --git a/tests/ui/unsafe/issue-47412.thir.stderr b/tests/ui/unsafe/issue-47412.thir.stderr
deleted file mode 100644
index 305f482e8c2..00000000000
--- a/tests/ui/unsafe/issue-47412.thir.stderr
+++ /dev/null
@@ -1,19 +0,0 @@
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/issue-47412.rs:14:11
-   |
-LL |     match u.void {}
-   |           ^^^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/issue-47412.rs:20:11
-   |
-LL |     match *ptr {}
-   |           ^^^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-
-error: aborting due to 2 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/issue-85435-unsafe-op-in-let-under-unsafe-under-closure.rs b/tests/ui/unsafe/issue-85435-unsafe-op-in-let-under-unsafe-under-closure.rs
index 72f7b674777..b0d738855d7 100644
--- a/tests/ui/unsafe/issue-85435-unsafe-op-in-let-under-unsafe-under-closure.rs
+++ b/tests/ui/unsafe/issue-85435-unsafe-op-in-let-under-unsafe-under-closure.rs
@@ -1,6 +1,4 @@
 // check-pass
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 
 // This is issue #85435. But the real story is reflected in issue #85561, where
 // a bug in the implementation of feature(capture_disjoint_fields) () was
diff --git a/tests/ui/unsafe/issue-87414-query-cycle.rs b/tests/ui/unsafe/issue-87414-query-cycle.rs
index 99e40ba4b4c..a004d739422 100644
--- a/tests/ui/unsafe/issue-87414-query-cycle.rs
+++ b/tests/ui/unsafe/issue-87414-query-cycle.rs
@@ -1,7 +1,6 @@
 // Regression test for #87414.
 
 // check-pass
-// compile-flags: -Zthir-unsafeck
 
 fn bad<T>() -> Box<dyn Iterator<Item = [(); { |x: u32| { x }; 4 }]>> { todo!() }
 
diff --git a/tests/ui/unsafe/ranged_ints.rs b/tests/ui/unsafe/ranged_ints.rs
index 05efe87ba6e..0fa2da917e9 100644
--- a/tests/ui/unsafe/ranged_ints.rs
+++ b/tests/ui/unsafe/ranged_ints.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 #![feature(rustc_attrs)]
 
 #[rustc_layout_scalar_valid_range_start(1)]
diff --git a/tests/ui/unsafe/ranged_ints.mir.stderr b/tests/ui/unsafe/ranged_ints.stderr
index ef00edae05d..b6875e15815 100644
--- a/tests/ui/unsafe/ranged_ints.mir.stderr
+++ b/tests/ui/unsafe/ranged_ints.stderr
@@ -1,5 +1,5 @@
 error[E0133]: initializing type with `rustc_layout_scalar_valid_range` attr is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints.rs:10:14
+  --> $DIR/ranged_ints.rs:7:14
    |
 LL |     let _x = NonZero(0);
    |              ^^^^^^^^^^ initializing type with `rustc_layout_scalar_valid_range` attr
diff --git a/tests/ui/unsafe/ranged_ints.thir.stderr b/tests/ui/unsafe/ranged_ints.thir.stderr
deleted file mode 100644
index ef00edae05d..00000000000
--- a/tests/ui/unsafe/ranged_ints.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: initializing type with `rustc_layout_scalar_valid_range` attr is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints.rs:10:14
-   |
-LL |     let _x = NonZero(0);
-   |              ^^^^^^^^^^ initializing type with `rustc_layout_scalar_valid_range` attr
-   |
-   = note: initializing a layout restricted type's field with a value outside the valid range is undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/ranged_ints2.rs b/tests/ui/unsafe/ranged_ints2.rs
index ad9d598aba2..a3d9f54efe2 100644
--- a/tests/ui/unsafe/ranged_ints2.rs
+++ b/tests/ui/unsafe/ranged_ints2.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 #![feature(rustc_attrs)]
 
 #[rustc_layout_scalar_valid_range_start(1)]
diff --git a/tests/ui/unsafe/ranged_ints2.mirunsafeck.stderr b/tests/ui/unsafe/ranged_ints2.stderr
index dc6bd72f56c..1885e77af7e 100644
--- a/tests/ui/unsafe/ranged_ints2.mirunsafeck.stderr
+++ b/tests/ui/unsafe/ranged_ints2.stderr
@@ -1,5 +1,5 @@
 error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints2.rs:11:13
+  --> $DIR/ranged_ints2.rs:8:13
    |
 LL |     let y = &mut x.0;
    |             ^^^^^^^^ mutation of layout constrained field
@@ -7,7 +7,7 @@ LL |     let y = &mut x.0;
    = note: mutating layout constrained fields cannot statically be checked for valid values
 
 error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints2.rs:12:25
+  --> $DIR/ranged_ints2.rs:9:25
    |
 LL |     if let Some(NonZero(ref mut y)) = Some(x) {}
    |                         ^^^^^^^^^ mutation of layout constrained field
diff --git a/tests/ui/unsafe/ranged_ints2.thirunsafeck.stderr b/tests/ui/unsafe/ranged_ints2.thirunsafeck.stderr
deleted file mode 100644
index dc6bd72f56c..00000000000
--- a/tests/ui/unsafe/ranged_ints2.thirunsafeck.stderr
+++ /dev/null
@@ -1,19 +0,0 @@
-error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints2.rs:11:13
-   |
-LL |     let y = &mut x.0;
-   |             ^^^^^^^^ mutation of layout constrained field
-   |
-   = note: mutating layout constrained fields cannot statically be checked for valid values
-
-error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints2.rs:12:25
-   |
-LL |     if let Some(NonZero(ref mut y)) = Some(x) {}
-   |                         ^^^^^^^^^ mutation of layout constrained field
-   |
-   = note: mutating layout constrained fields cannot statically be checked for valid values
-
-error: aborting due to 2 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/ranged_ints2_const.rs b/tests/ui/unsafe/ranged_ints2_const.rs
index 56f5407bb6e..b7178c2b52b 100644
--- a/tests/ui/unsafe/ranged_ints2_const.rs
+++ b/tests/ui/unsafe/ranged_ints2_const.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 #![feature(rustc_attrs)]
 
 #[rustc_layout_scalar_valid_range_start(1)]
diff --git a/tests/ui/unsafe/ranged_ints2_const.mirunsafeck.stderr b/tests/ui/unsafe/ranged_ints2_const.stderr
index c16550a5800..a0dc950e76d 100644
--- a/tests/ui/unsafe/ranged_ints2_const.mirunsafeck.stderr
+++ b/tests/ui/unsafe/ranged_ints2_const.stderr
@@ -1,5 +1,5 @@
 error[E0658]: mutable references are not allowed in constant functions
-  --> $DIR/ranged_ints2_const.rs:14:13
+  --> $DIR/ranged_ints2_const.rs:11:13
    |
 LL |     let y = &mut x.0;
    |             ^^^^^^^^
@@ -8,7 +8,7 @@ LL |     let y = &mut x.0;
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
 
 error[E0658]: mutable references are not allowed in constant functions
-  --> $DIR/ranged_ints2_const.rs:21:22
+  --> $DIR/ranged_ints2_const.rs:18:22
    |
 LL |     let y = unsafe { &mut x.0 };
    |                      ^^^^^^^^
@@ -17,7 +17,7 @@ LL |     let y = unsafe { &mut x.0 };
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
 
 error[E0658]: mutable references are not allowed in constant functions
-  --> $DIR/ranged_ints2_const.rs:27:22
+  --> $DIR/ranged_ints2_const.rs:24:22
    |
 LL |     unsafe { let y = &mut x.0; }
    |                      ^^^^^^^^
@@ -26,7 +26,7 @@ LL |     unsafe { let y = &mut x.0; }
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
 
 error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints2_const.rs:14:13
+  --> $DIR/ranged_ints2_const.rs:11:13
    |
 LL |     let y = &mut x.0;
    |             ^^^^^^^^ mutation of layout constrained field
diff --git a/tests/ui/unsafe/ranged_ints2_const.thirunsafeck.stderr b/tests/ui/unsafe/ranged_ints2_const.thirunsafeck.stderr
deleted file mode 100644
index b3f139f7213..00000000000
--- a/tests/ui/unsafe/ranged_ints2_const.thirunsafeck.stderr
+++ /dev/null
@@ -1,39 +0,0 @@
-error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints2_const.rs:14:13
-   |
-LL |     let y = &mut x.0;
-   |             ^^^^^^^^ mutation of layout constrained field
-   |
-   = note: mutating layout constrained fields cannot statically be checked for valid values
-
-error[E0658]: mutable references are not allowed in constant functions
-  --> $DIR/ranged_ints2_const.rs:14:13
-   |
-LL |     let y = &mut x.0;
-   |             ^^^^^^^^
-   |
-   = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
-   = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
-
-error[E0658]: mutable references are not allowed in constant functions
-  --> $DIR/ranged_ints2_const.rs:21:22
-   |
-LL |     let y = unsafe { &mut x.0 };
-   |                      ^^^^^^^^
-   |
-   = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
-   = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
-
-error[E0658]: mutable references are not allowed in constant functions
-  --> $DIR/ranged_ints2_const.rs:27:22
-   |
-LL |     unsafe { let y = &mut x.0; }
-   |                      ^^^^^^^^
-   |
-   = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
-   = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
-
-error: aborting due to 4 previous errors
-
-Some errors have detailed explanations: E0133, E0658.
-For more information about an error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/ranged_ints3.rs b/tests/ui/unsafe/ranged_ints3.rs
index 76d4bfe9530..47d67fac678 100644
--- a/tests/ui/unsafe/ranged_ints3.rs
+++ b/tests/ui/unsafe/ranged_ints3.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 #![feature(rustc_attrs)]
 
 use std::cell::Cell;
diff --git a/tests/ui/unsafe/ranged_ints3.mirunsafeck.stderr b/tests/ui/unsafe/ranged_ints3.stderr
index 72bce5de0ae..8dcb99fc16d 100644
--- a/tests/ui/unsafe/ranged_ints3.mirunsafeck.stderr
+++ b/tests/ui/unsafe/ranged_ints3.stderr
@@ -1,5 +1,5 @@
 error[E0133]: borrow of layout constrained field with interior mutability is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints3.rs:13:13
+  --> $DIR/ranged_ints3.rs:10:13
    |
 LL |     let y = &x.0;
    |             ^^^^ borrow of layout constrained field with interior mutability
diff --git a/tests/ui/unsafe/ranged_ints3.thirunsafeck.stderr b/tests/ui/unsafe/ranged_ints3.thirunsafeck.stderr
deleted file mode 100644
index 72bce5de0ae..00000000000
--- a/tests/ui/unsafe/ranged_ints3.thirunsafeck.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: borrow of layout constrained field with interior mutability is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints3.rs:13:13
-   |
-LL |     let y = &x.0;
-   |             ^^^^ borrow of layout constrained field with interior mutability
-   |
-   = note: references to fields of layout constrained fields lose the constraints. Coupled with interior mutability, the field can be changed to invalid values
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/ranged_ints3_const.rs b/tests/ui/unsafe/ranged_ints3_const.rs
index 637198d3604..c069ae7da02 100644
--- a/tests/ui/unsafe/ranged_ints3_const.rs
+++ b/tests/ui/unsafe/ranged_ints3_const.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 #![feature(rustc_attrs)]
 
 use std::cell::Cell;
diff --git a/tests/ui/unsafe/ranged_ints3_const.mirunsafeck.stderr b/tests/ui/unsafe/ranged_ints3_const.stderr
index 62df9333069..215005571f6 100644
--- a/tests/ui/unsafe/ranged_ints3_const.mirunsafeck.stderr
+++ b/tests/ui/unsafe/ranged_ints3_const.stderr
@@ -1,5 +1,5 @@
 error[E0658]: cannot borrow here, since the borrowed element may contain interior mutability
-  --> $DIR/ranged_ints3_const.rs:15:13
+  --> $DIR/ranged_ints3_const.rs:12:13
    |
 LL |     let y = &x.0;
    |             ^^^^
@@ -8,7 +8,7 @@ LL |     let y = &x.0;
    = help: add `#![feature(const_refs_to_cell)]` to the crate attributes to enable
 
 error[E0658]: cannot borrow here, since the borrowed element may contain interior mutability
-  --> $DIR/ranged_ints3_const.rs:22:22
+  --> $DIR/ranged_ints3_const.rs:19:22
    |
 LL |     let y = unsafe { &x.0 };
    |                      ^^^^
@@ -17,7 +17,7 @@ LL |     let y = unsafe { &x.0 };
    = help: add `#![feature(const_refs_to_cell)]` to the crate attributes to enable
 
 error[E0133]: borrow of layout constrained field with interior mutability is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints3_const.rs:15:13
+  --> $DIR/ranged_ints3_const.rs:12:13
    |
 LL |     let y = &x.0;
    |             ^^^^ borrow of layout constrained field with interior mutability
diff --git a/tests/ui/unsafe/ranged_ints3_const.thirunsafeck.stderr b/tests/ui/unsafe/ranged_ints3_const.thirunsafeck.stderr
deleted file mode 100644
index 5dbc563aad2..00000000000
--- a/tests/ui/unsafe/ranged_ints3_const.thirunsafeck.stderr
+++ /dev/null
@@ -1,30 +0,0 @@
-error[E0133]: borrow of layout constrained field with interior mutability is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints3_const.rs:15:13
-   |
-LL |     let y = &x.0;
-   |             ^^^^ borrow of layout constrained field with interior mutability
-   |
-   = note: references to fields of layout constrained fields lose the constraints. Coupled with interior mutability, the field can be changed to invalid values
-
-error[E0658]: cannot borrow here, since the borrowed element may contain interior mutability
-  --> $DIR/ranged_ints3_const.rs:15:13
-   |
-LL |     let y = &x.0;
-   |             ^^^^
-   |
-   = note: see issue #80384 <https://github.com/rust-lang/rust/issues/80384> for more information
-   = help: add `#![feature(const_refs_to_cell)]` to the crate attributes to enable
-
-error[E0658]: cannot borrow here, since the borrowed element may contain interior mutability
-  --> $DIR/ranged_ints3_const.rs:22:22
-   |
-LL |     let y = unsafe { &x.0 };
-   |                      ^^^^
-   |
-   = note: see issue #80384 <https://github.com/rust-lang/rust/issues/80384> for more information
-   = help: add `#![feature(const_refs_to_cell)]` to the crate attributes to enable
-
-error: aborting due to 3 previous errors
-
-Some errors have detailed explanations: E0133, E0658.
-For more information about an error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/ranged_ints3_match.rs b/tests/ui/unsafe/ranged_ints3_match.rs
index d9fcf0bd665..de6be506d56 100644
--- a/tests/ui/unsafe/ranged_ints3_match.rs
+++ b/tests/ui/unsafe/ranged_ints3_match.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 #![feature(rustc_attrs)]
 
 use std::cell::Cell;
diff --git a/tests/ui/unsafe/ranged_ints3_match.mirunsafeck.stderr b/tests/ui/unsafe/ranged_ints3_match.stderr
index 27c06640928..1bdc29d077c 100644
--- a/tests/ui/unsafe/ranged_ints3_match.mirunsafeck.stderr
+++ b/tests/ui/unsafe/ranged_ints3_match.stderr
@@ -1,5 +1,5 @@
 error[E0133]: borrow of layout constrained field with interior mutability is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints3_match.rs:14:17
+  --> $DIR/ranged_ints3_match.rs:11:17
    |
 LL |         NonZero(ref x) => { x }
    |                 ^^^^^ borrow of layout constrained field with interior mutability
@@ -7,7 +7,7 @@ LL |         NonZero(ref x) => { x }
    = note: references to fields of layout constrained fields lose the constraints. Coupled with interior mutability, the field can be changed to invalid values
 
 error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints3_match.rs:20:23
+  --> $DIR/ranged_ints3_match.rs:17:23
    |
 LL |     match y { NonZero(ref mut y) => { y } };
    |                       ^^^^^^^^^ mutation of layout constrained field
diff --git a/tests/ui/unsafe/ranged_ints3_match.thirunsafeck.stderr b/tests/ui/unsafe/ranged_ints3_match.thirunsafeck.stderr
deleted file mode 100644
index 27c06640928..00000000000
--- a/tests/ui/unsafe/ranged_ints3_match.thirunsafeck.stderr
+++ /dev/null
@@ -1,19 +0,0 @@
-error[E0133]: borrow of layout constrained field with interior mutability is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints3_match.rs:14:17
-   |
-LL |         NonZero(ref x) => { x }
-   |                 ^^^^^ borrow of layout constrained field with interior mutability
-   |
-   = note: references to fields of layout constrained fields lose the constraints. Coupled with interior mutability, the field can be changed to invalid values
-
-error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints3_match.rs:20:23
-   |
-LL |     match y { NonZero(ref mut y) => { y } };
-   |                       ^^^^^^^^^ mutation of layout constrained field
-   |
-   = note: mutating layout constrained fields cannot statically be checked for valid values
-
-error: aborting due to 2 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/ranged_ints4.mirunsafeck.stderr b/tests/ui/unsafe/ranged_ints4.mirunsafeck.stderr
deleted file mode 100644
index 4f2f1e42e76..00000000000
--- a/tests/ui/unsafe/ranged_ints4.mirunsafeck.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints4.rs:11:5
-   |
-LL |     x.0 = 0;
-   |     ^^^^^^^ mutation of layout constrained field
-   |
-   = note: mutating layout constrained fields cannot statically be checked for valid values
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/ranged_ints4.rs b/tests/ui/unsafe/ranged_ints4.rs
index fe80af454cb..d8632c48434 100644
--- a/tests/ui/unsafe/ranged_ints4.rs
+++ b/tests/ui/unsafe/ranged_ints4.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 #![feature(rustc_attrs)]
 
 #[rustc_layout_scalar_valid_range_start(1)]
diff --git a/tests/ui/unsafe/ranged_ints4.thirunsafeck.stderr b/tests/ui/unsafe/ranged_ints4.stderr
index 4f2f1e42e76..4a703696b88 100644
--- a/tests/ui/unsafe/ranged_ints4.thirunsafeck.stderr
+++ b/tests/ui/unsafe/ranged_ints4.stderr
@@ -1,5 +1,5 @@
 error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints4.rs:11:5
+  --> $DIR/ranged_ints4.rs:8:5
    |
 LL |     x.0 = 0;
    |     ^^^^^^^ mutation of layout constrained field
diff --git a/tests/ui/unsafe/ranged_ints4_const.rs b/tests/ui/unsafe/ranged_ints4_const.rs
index a43c8be71c4..f09168c3d3f 100644
--- a/tests/ui/unsafe/ranged_ints4_const.rs
+++ b/tests/ui/unsafe/ranged_ints4_const.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 #![feature(rustc_attrs)]
 
 #[rustc_layout_scalar_valid_range_start(1)]
diff --git a/tests/ui/unsafe/ranged_ints4_const.mirunsafeck.stderr b/tests/ui/unsafe/ranged_ints4_const.stderr
index a2a3ae668a2..604ec1167e4 100644
--- a/tests/ui/unsafe/ranged_ints4_const.mirunsafeck.stderr
+++ b/tests/ui/unsafe/ranged_ints4_const.stderr
@@ -1,5 +1,5 @@
 error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints4_const.rs:13:5
+  --> $DIR/ranged_ints4_const.rs:10:5
    |
 LL |     x.0 = 0;
    |     ^^^^^^^ mutation of layout constrained field
diff --git a/tests/ui/unsafe/ranged_ints4_const.thirunsafeck.stderr b/tests/ui/unsafe/ranged_ints4_const.thirunsafeck.stderr
deleted file mode 100644
index a2a3ae668a2..00000000000
--- a/tests/ui/unsafe/ranged_ints4_const.thirunsafeck.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints4_const.rs:13:5
-   |
-LL |     x.0 = 0;
-   |     ^^^^^^^ mutation of layout constrained field
-   |
-   = note: mutating layout constrained fields cannot statically be checked for valid values
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/ranged_ints_const.rs b/tests/ui/unsafe/ranged_ints_const.rs
index 472b0968150..8477772867e 100644
--- a/tests/ui/unsafe/ranged_ints_const.rs
+++ b/tests/ui/unsafe/ranged_ints_const.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 #![feature(rustc_attrs)]
 
 #[rustc_layout_scalar_valid_range_start(1)]
diff --git a/tests/ui/unsafe/ranged_ints_const.mir.stderr b/tests/ui/unsafe/ranged_ints_const.stderr
index 563b9be2672..2b8be290d3a 100644
--- a/tests/ui/unsafe/ranged_ints_const.mir.stderr
+++ b/tests/ui/unsafe/ranged_ints_const.stderr
@@ -1,5 +1,5 @@
 error[E0133]: initializing type with `rustc_layout_scalar_valid_range` attr is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints_const.rs:11:34
+  --> $DIR/ranged_ints_const.rs:8:34
    |
 LL | const fn foo() -> NonZero<u32> { NonZero(0) }
    |                                  ^^^^^^^^^^ initializing type with `rustc_layout_scalar_valid_range` attr
diff --git a/tests/ui/unsafe/ranged_ints_const.thir.stderr b/tests/ui/unsafe/ranged_ints_const.thir.stderr
deleted file mode 100644
index 563b9be2672..00000000000
--- a/tests/ui/unsafe/ranged_ints_const.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: initializing type with `rustc_layout_scalar_valid_range` attr is unsafe and requires unsafe function or block
-  --> $DIR/ranged_ints_const.rs:11:34
-   |
-LL | const fn foo() -> NonZero<u32> { NonZero(0) }
-   |                                  ^^^^^^^^^^ initializing type with `rustc_layout_scalar_valid_range` attr
-   |
-   = note: initializing a layout restricted type's field with a value outside the valid range is undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/ranged_ints_macro.rs b/tests/ui/unsafe/ranged_ints_macro.rs
index 8293d029951..0acc3e0f6b1 100644
--- a/tests/ui/unsafe/ranged_ints_macro.rs
+++ b/tests/ui/unsafe/ranged_ints_macro.rs
@@ -1,6 +1,4 @@
 // build-pass
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 
 #![feature(rustc_attrs)]
 
diff --git a/tests/ui/unsafe/rfc-2585-unsafe_op_in_unsafe_fn.rs b/tests/ui/unsafe/rfc-2585-unsafe_op_in_unsafe_fn.rs
index db1e916a36c..eceac115edd 100644
--- a/tests/ui/unsafe/rfc-2585-unsafe_op_in_unsafe_fn.rs
+++ b/tests/ui/unsafe/rfc-2585-unsafe_op_in_unsafe_fn.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Zthir-unsafeck
-
 #![deny(unsafe_op_in_unsafe_fn)]
 #![deny(unused_unsafe)]
 
@@ -10,8 +7,7 @@ static mut VOID: () = ();
 
 unsafe fn deny_level() {
     unsf();
-    //[mir]~^ ERROR call to unsafe function is unsafe and requires unsafe block
-    //[thir]~^^ ERROR call to unsafe function `unsf` is unsafe and requires unsafe block
+    //~^ ERROR call to unsafe function is unsafe and requires unsafe block
     *PTR;
     //~^ ERROR dereference of raw pointer is unsafe and requires unsafe block
     VOID = ();
@@ -26,8 +22,7 @@ unsafe fn deny_level() {
 #[deny(warnings)]
 unsafe fn warning_level() {
     unsf();
-    //[mir]~^ ERROR call to unsafe function is unsafe and requires unsafe block
-    //[thir]~^^ ERROR call to unsafe function `unsf` is unsafe and requires unsafe block
+    //~^ ERROR call to unsafe function is unsafe and requires unsafe block
     *PTR;
     //~^ ERROR dereference of raw pointer is unsafe and requires unsafe block
     VOID = ();
@@ -74,12 +69,10 @@ unsafe fn nested_allow_level() {
 
 fn main() {
     unsf();
-    //[mir]~^ ERROR call to unsafe function is unsafe and requires unsafe block
-    //[thir]~^^ ERROR call to unsafe function `unsf` is unsafe and requires unsafe block
+    //~^ ERROR call to unsafe function is unsafe and requires unsafe block
     #[allow(unsafe_op_in_unsafe_fn)]
     {
         unsf();
-        //[mir]~^ ERROR call to unsafe function is unsafe and requires unsafe function or block
-        //[thir]~^^ ERROR call to unsafe function `unsf` is unsafe and requires unsafe function or block
+        //~^ ERROR call to unsafe function is unsafe and requires unsafe function or block
     }
 }
diff --git a/tests/ui/unsafe/rfc-2585-unsafe_op_in_unsafe_fn.mir.stderr b/tests/ui/unsafe/rfc-2585-unsafe_op_in_unsafe_fn.stderr
index 0c0826c1cfb..d61d87cd001 100644
--- a/tests/ui/unsafe/rfc-2585-unsafe_op_in_unsafe_fn.mir.stderr
+++ b/tests/ui/unsafe/rfc-2585-unsafe_op_in_unsafe_fn.stderr
@@ -1,23 +1,23 @@
 error: call to unsafe function is unsafe and requires unsafe block (error E0133)
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:12:5
+  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:9:5
    |
 LL |     unsf();
    |     ^^^^^^ call to unsafe function
    |
    = note: consult the function's documentation for information on how to avoid undefined behavior
 note: an unsafe function restricts its caller, but its body is safe by default
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:11:1
+  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:8:1
    |
 LL | unsafe fn deny_level() {
    | ^^^^^^^^^^^^^^^^^^^^^^
 note: the lint level is defined here
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:4:9
+  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:1:9
    |
 LL | #![deny(unsafe_op_in_unsafe_fn)]
    |         ^^^^^^^^^^^^^^^^^^^^^^
 
 error: dereference of raw pointer is unsafe and requires unsafe block (error E0133)
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:15:5
+  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:11:5
    |
 LL |     *PTR;
    |     ^^^^ dereference of raw pointer
@@ -25,7 +25,7 @@ LL |     *PTR;
    = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
 
 error: use of mutable static is unsafe and requires unsafe block (error E0133)
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:17:5
+  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:13:5
    |
 LL |     VOID = ();
    |     ^^^^^^^^^ use of mutable static
@@ -33,38 +33,38 @@ LL |     VOID = ();
    = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
 
 error: unnecessary `unsafe` block
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:20:5
+  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:16:5
    |
 LL |     unsafe {}
    |     ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:5:9
+  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:2:9
    |
 LL | #![deny(unused_unsafe)]
    |         ^^^^^^^^^^^^^
 
 error: call to unsafe function is unsafe and requires unsafe block (error E0133)
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:28:5
+  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:24:5
    |
 LL |     unsf();
    |     ^^^^^^ call to unsafe function
    |
    = note: consult the function's documentation for information on how to avoid undefined behavior
 note: an unsafe function restricts its caller, but its body is safe by default
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:27:1
+  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:23:1
    |
 LL | unsafe fn warning_level() {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^
 note: the lint level is defined here
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:26:8
+  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:22:8
    |
 LL | #[deny(warnings)]
    |        ^^^^^^^^
    = note: `#[deny(unsafe_op_in_unsafe_fn)]` implied by `#[deny(warnings)]`
 
 error: dereference of raw pointer is unsafe and requires unsafe block (error E0133)
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:31:5
+  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:26:5
    |
 LL |     *PTR;
    |     ^^^^ dereference of raw pointer
@@ -72,7 +72,7 @@ LL |     *PTR;
    = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
 
 error: use of mutable static is unsafe and requires unsafe block (error E0133)
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:33:5
+  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:28:5
    |
 LL |     VOID = ();
    |     ^^^^^^^^^ use of mutable static
@@ -80,19 +80,19 @@ LL |     VOID = ();
    = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
 
 error: unnecessary `unsafe` block
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:35:5
+  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:30:5
    |
 LL |     unsafe {}
    |     ^^^^^^ unnecessary `unsafe` block
 
 error: unnecessary `unsafe` block
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:49:5
+  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:44:5
    |
 LL |     unsafe { unsafe { unsf() } }
    |     ^^^^^^ unnecessary `unsafe` block
 
 error[E0133]: call to unsafe function is unsafe and requires unsafe block
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:76:5
+  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:71:5
    |
 LL |     unsf();
    |     ^^^^^^ call to unsafe function
@@ -100,7 +100,7 @@ LL |     unsf();
    = note: consult the function's documentation for information on how to avoid undefined behavior
 
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:81:9
+  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:75:9
    |
 LL |         unsf();
    |         ^^^^^^ call to unsafe function
diff --git a/tests/ui/unsafe/rfc-2585-unsafe_op_in_unsafe_fn.thir.stderr b/tests/ui/unsafe/rfc-2585-unsafe_op_in_unsafe_fn.thir.stderr
deleted file mode 100644
index ad0621a1d04..00000000000
--- a/tests/ui/unsafe/rfc-2585-unsafe_op_in_unsafe_fn.thir.stderr
+++ /dev/null
@@ -1,112 +0,0 @@
-error: call to unsafe function `unsf` is unsafe and requires unsafe block (error E0133)
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:12:5
-   |
-LL |     unsf();
-   |     ^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-note: an unsafe function restricts its caller, but its body is safe by default
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:11:1
-   |
-LL | unsafe fn deny_level() {
-   | ^^^^^^^^^^^^^^^^^^^^^^
-note: the lint level is defined here
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:4:9
-   |
-LL | #![deny(unsafe_op_in_unsafe_fn)]
-   |         ^^^^^^^^^^^^^^^^^^^^^^
-
-error: dereference of raw pointer is unsafe and requires unsafe block (error E0133)
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:15:5
-   |
-LL |     *PTR;
-   |     ^^^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-
-error: use of mutable static is unsafe and requires unsafe block (error E0133)
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:17:5
-   |
-LL |     VOID = ();
-   |     ^^^^ use of mutable static
-   |
-   = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
-
-error: unnecessary `unsafe` block
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:20:5
-   |
-LL |     unsafe {}
-   |     ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:5:9
-   |
-LL | #![deny(unused_unsafe)]
-   |         ^^^^^^^^^^^^^
-
-error: call to unsafe function `unsf` is unsafe and requires unsafe block (error E0133)
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:28:5
-   |
-LL |     unsf();
-   |     ^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-note: an unsafe function restricts its caller, but its body is safe by default
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:27:1
-   |
-LL | unsafe fn warning_level() {
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^
-note: the lint level is defined here
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:26:8
-   |
-LL | #[deny(warnings)]
-   |        ^^^^^^^^
-   = note: `#[deny(unsafe_op_in_unsafe_fn)]` implied by `#[deny(warnings)]`
-
-error: dereference of raw pointer is unsafe and requires unsafe block (error E0133)
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:31:5
-   |
-LL |     *PTR;
-   |     ^^^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-
-error: use of mutable static is unsafe and requires unsafe block (error E0133)
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:33:5
-   |
-LL |     VOID = ();
-   |     ^^^^ use of mutable static
-   |
-   = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
-
-error: unnecessary `unsafe` block
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:35:5
-   |
-LL |     unsafe {}
-   |     ^^^^^^ unnecessary `unsafe` block
-
-error: unnecessary `unsafe` block
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:49:5
-   |
-LL |     unsafe { unsafe { unsf() } }
-   |     ^^^^^^ unnecessary `unsafe` block
-
-error[E0133]: call to unsafe function `unsf` is unsafe and requires unsafe block
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:76:5
-   |
-LL |     unsf();
-   |     ^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error[E0133]: call to unsafe function `unsf` is unsafe and requires unsafe function or block
-  --> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:81:9
-   |
-LL |         unsf();
-   |         ^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: aborting due to 11 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/union-assignop.rs b/tests/ui/unsafe/union-assignop.rs
index 5e667cd10d5..6122aef0565 100644
--- a/tests/ui/unsafe/union-assignop.rs
+++ b/tests/ui/unsafe/union-assignop.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 use std::ops::AddAssign;
 use std::mem::ManuallyDrop;
 
diff --git a/tests/ui/unsafe/union-assignop.mirunsafeck.stderr b/tests/ui/unsafe/union-assignop.stderr
index 0ecd5203dd9..e3a673ee1ff 100644
--- a/tests/ui/unsafe/union-assignop.mirunsafeck.stderr
+++ b/tests/ui/unsafe/union-assignop.stderr
@@ -1,5 +1,5 @@
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-assignop.rs:19:5
+  --> $DIR/union-assignop.rs:16:5
    |
 LL |     foo.a += 5;
    |     ^^^^^^^^^^ access to union field
@@ -7,7 +7,7 @@ LL |     foo.a += 5;
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-assignop.rs:20:6
+  --> $DIR/union-assignop.rs:17:6
    |
 LL |     *foo.b += NonCopy;
    |      ^^^^^ access to union field
@@ -15,7 +15,7 @@ LL |     *foo.b += NonCopy;
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-assignop.rs:21:6
+  --> $DIR/union-assignop.rs:18:6
    |
 LL |     *foo.b = NonCopy;
    |      ^^^^^ access to union field
@@ -23,7 +23,7 @@ LL |     *foo.b = NonCopy;
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-assignop.rs:23:5
+  --> $DIR/union-assignop.rs:20:5
    |
 LL |     foo.a;
    |     ^^^^^ access to union field
@@ -31,7 +31,7 @@ LL |     foo.a;
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-assignop.rs:25:5
+  --> $DIR/union-assignop.rs:22:5
    |
 LL |     foo.b;
    |     ^^^^^ access to union field
@@ -39,7 +39,7 @@ LL |     foo.b;
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-assignop.rs:27:13
+  --> $DIR/union-assignop.rs:24:13
    |
 LL |     foo.b = foo.b;
    |             ^^^^^ access to union field
diff --git a/tests/ui/unsafe/union-assignop.thirunsafeck.stderr b/tests/ui/unsafe/union-assignop.thirunsafeck.stderr
deleted file mode 100644
index 24b357e762b..00000000000
--- a/tests/ui/unsafe/union-assignop.thirunsafeck.stderr
+++ /dev/null
@@ -1,51 +0,0 @@
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-assignop.rs:19:5
-   |
-LL |     foo.a += 5;
-   |     ^^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-assignop.rs:20:6
-   |
-LL |     *foo.b += NonCopy;
-   |      ^^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-assignop.rs:21:6
-   |
-LL |     *foo.b = NonCopy;
-   |      ^^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-assignop.rs:23:5
-   |
-LL |     foo.a;
-   |     ^^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-assignop.rs:25:5
-   |
-LL |     foo.b;
-   |     ^^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union-assignop.rs:27:13
-   |
-LL |     foo.b = foo.b;
-   |             ^^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error: aborting due to 6 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/union-modification.rs b/tests/ui/unsafe/union-modification.rs
index 9a53ef90852..fbcb846be9d 100644
--- a/tests/ui/unsafe/union-modification.rs
+++ b/tests/ui/unsafe/union-modification.rs
@@ -1,7 +1,4 @@
 // run-pass
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 union Foo {
     bar: i8,
     _blah: isize,
diff --git a/tests/ui/unsafe/union.rs b/tests/ui/unsafe/union.rs
index 4338d78eabb..83ec1c3cd6c 100644
--- a/tests/ui/unsafe/union.rs
+++ b/tests/ui/unsafe/union.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 union Foo {
     bar: i8,
     zst: (),
@@ -29,9 +26,9 @@ pub fn main() {
     match foo {
         Foo { bar: _a } => {}, //~ ERROR access to union field is unsafe
     }
-    match foo { //[mir]~ ERROR access to union field is unsafe
+    match foo { //~ ERROR access to union field is unsafe
         Foo {
-            pizza: Pizza { //[thir]~ ERROR access to union field is unsafe
+            pizza: Pizza {
                 topping: Some(PizzaTopping::Cheese) | Some(PizzaTopping::Pineapple) | None
             }
         } => {},
@@ -39,10 +36,10 @@ pub fn main() {
 
     // MIR unsafeck incorrectly thinks that no unsafe block is needed to do these
     match foo {
-        Foo { zst: () } => {}, //[thir]~ ERROR access to union field is unsafe
+        Foo { zst: () } => {},
     }
     match foo {
-        Foo { pizza: Pizza { .. } } => {}, //[thir]~ ERROR access to union field is unsafe
+        Foo { pizza: Pizza { .. } } => {},
     }
 
     // binding to wildcard is okay
diff --git a/tests/ui/unsafe/union.mir.stderr b/tests/ui/unsafe/union.stderr
index 787714cdd2d..fe814462412 100644
--- a/tests/ui/unsafe/union.mir.stderr
+++ b/tests/ui/unsafe/union.stderr
@@ -1,5 +1,5 @@
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union.rs:30:20
+  --> $DIR/union.rs:27:20
    |
 LL |         Foo { bar: _a } => {},
    |                    ^^ access to union field
@@ -7,7 +7,7 @@ LL |         Foo { bar: _a } => {},
    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
 
 error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union.rs:32:11
+  --> $DIR/union.rs:29:11
    |
 LL |     match foo {
    |           ^^^ access to union field
diff --git a/tests/ui/unsafe/union.thir.stderr b/tests/ui/unsafe/union.thir.stderr
deleted file mode 100644
index e1a1bd634de..00000000000
--- a/tests/ui/unsafe/union.thir.stderr
+++ /dev/null
@@ -1,38 +0,0 @@
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union.rs:30:20
-   |
-LL |         Foo { bar: _a } => {},
-   |                    ^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union.rs:34:20
-   |
-LL |               pizza: Pizza {
-   |  ____________________^
-LL | |                 topping: Some(PizzaTopping::Cheese) | Some(PizzaTopping::Pineapple) | None
-LL | |             }
-   | |_____________^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union.rs:42:20
-   |
-LL |         Foo { zst: () } => {},
-   |                    ^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error[E0133]: access to union field is unsafe and requires unsafe function or block
-  --> $DIR/union.rs:45:22
-   |
-LL |         Foo { pizza: Pizza { .. } } => {},
-   |                      ^^^^^^^^^^^^ access to union field
-   |
-   = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
-
-error: aborting due to 4 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/union_access_through_block.rs b/tests/ui/unsafe/union_access_through_block.rs
index e4c0976b826..8b28c33650e 100644
--- a/tests/ui/unsafe/union_access_through_block.rs
+++ b/tests/ui/unsafe/union_access_through_block.rs
@@ -1,7 +1,4 @@
 // check-pass
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 #[derive(Copy, Clone)]
 pub struct Foo { a: bool }
 
diff --git a/tests/ui/unsafe/union_destructure.rs b/tests/ui/unsafe/union_destructure.rs
index 6c88344b5fd..85fd54c8145 100644
--- a/tests/ui/unsafe/union_destructure.rs
+++ b/tests/ui/unsafe/union_destructure.rs
@@ -1,6 +1,4 @@
 // run-pass
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 
 #[derive(Copy, Clone)]
 #[allow(dead_code)]
@@ -32,13 +30,13 @@ fn main() {
     };
 
     let u = Foo { bar: 9 };
-    unsafe { //[mir]~ WARNING unnecessary `unsafe` block
+    unsafe { //~ WARNING unnecessary `unsafe` block
         match u {
             Foo { baz: Pie { .. } } => {},
         };
     }
     let u = Foo { bar: 10 };
-    unsafe { //[mir]~ WARNING unnecessary `unsafe` block
+    unsafe { //~ WARNING unnecessary `unsafe` block
         match u {
             Foo { baz: Pie { slices: _, size: _ } } => {},
         };
diff --git a/tests/ui/unsafe/union_destructure.mir.stderr b/tests/ui/unsafe/union_destructure.stderr
index 818f5ce03b5..431521472e8 100644
--- a/tests/ui/unsafe/union_destructure.mir.stderr
+++ b/tests/ui/unsafe/union_destructure.stderr
@@ -1,5 +1,5 @@
 warning: unnecessary `unsafe` block
-  --> $DIR/union_destructure.rs:35:5
+  --> $DIR/union_destructure.rs:33:5
    |
 LL |     unsafe {
    |     ^^^^^^ unnecessary `unsafe` block
@@ -7,7 +7,7 @@ LL |     unsafe {
    = note: `#[warn(unused_unsafe)]` on by default
 
 warning: unnecessary `unsafe` block
-  --> $DIR/union_destructure.rs:41:5
+  --> $DIR/union_destructure.rs:39:5
    |
 LL |     unsafe {
    |     ^^^^^^ unnecessary `unsafe` block
diff --git a/tests/ui/unsafe/union_wild_or_wild.rs b/tests/ui/unsafe/union_wild_or_wild.rs
index 52a0a7abf27..935de97f255 100644
--- a/tests/ui/unsafe/union_wild_or_wild.rs
+++ b/tests/ui/unsafe/union_wild_or_wild.rs
@@ -1,7 +1,4 @@
 // check-pass
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 union X { a: i8 }
 
 fn main() {
diff --git a/tests/ui/unsafe/unsafe-around-compiler-generated-unsafe.mir.stderr b/tests/ui/unsafe/unsafe-around-compiler-generated-unsafe.mir.stderr
deleted file mode 100644
index 62199e5a2ec..00000000000
--- a/tests/ui/unsafe/unsafe-around-compiler-generated-unsafe.mir.stderr
+++ /dev/null
@@ -1,20 +0,0 @@
-error: unnecessary `unsafe` block
-  --> $DIR/unsafe-around-compiler-generated-unsafe.rs:9:9
-   |
-LL |         unsafe { async {}.await; }
-   |         ^^^^^^ unnecessary `unsafe` block
-   |
-note: the lint level is defined here
-  --> $DIR/unsafe-around-compiler-generated-unsafe.rs:5:9
-   |
-LL | #![deny(unused_unsafe)]
-   |         ^^^^^^^^^^^^^
-
-error: unnecessary `unsafe` block
-  --> $DIR/unsafe-around-compiler-generated-unsafe.rs:13:5
-   |
-LL |     unsafe { println!("foo"); }
-   |     ^^^^^^ unnecessary `unsafe` block
-
-error: aborting due to 2 previous errors
-
diff --git a/tests/ui/unsafe/unsafe-around-compiler-generated-unsafe.rs b/tests/ui/unsafe/unsafe-around-compiler-generated-unsafe.rs
index c1a32764039..e060c58e408 100644
--- a/tests/ui/unsafe/unsafe-around-compiler-generated-unsafe.rs
+++ b/tests/ui/unsafe/unsafe-around-compiler-generated-unsafe.rs
@@ -1,6 +1,4 @@
 // edition:2018
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
 
 #![deny(unused_unsafe)]
 
diff --git a/tests/ui/unsafe/unsafe-around-compiler-generated-unsafe.thir.stderr b/tests/ui/unsafe/unsafe-around-compiler-generated-unsafe.stderr
index 62199e5a2ec..ffadd90c64b 100644
--- a/tests/ui/unsafe/unsafe-around-compiler-generated-unsafe.thir.stderr
+++ b/tests/ui/unsafe/unsafe-around-compiler-generated-unsafe.stderr
@@ -1,17 +1,17 @@
 error: unnecessary `unsafe` block
-  --> $DIR/unsafe-around-compiler-generated-unsafe.rs:9:9
+  --> $DIR/unsafe-around-compiler-generated-unsafe.rs:7:9
    |
 LL |         unsafe { async {}.await; }
    |         ^^^^^^ unnecessary `unsafe` block
    |
 note: the lint level is defined here
-  --> $DIR/unsafe-around-compiler-generated-unsafe.rs:5:9
+  --> $DIR/unsafe-around-compiler-generated-unsafe.rs:3:9
    |
 LL | #![deny(unused_unsafe)]
    |         ^^^^^^^^^^^^^
 
 error: unnecessary `unsafe` block
-  --> $DIR/unsafe-around-compiler-generated-unsafe.rs:13:5
+  --> $DIR/unsafe-around-compiler-generated-unsafe.rs:11:5
    |
 LL |     unsafe { println!("foo"); }
    |     ^^^^^^ unnecessary `unsafe` block
diff --git a/tests/ui/unsafe/unsafe-assign.rs b/tests/ui/unsafe/unsafe-assign.rs
index 15273165b5e..02ce238854d 100644
--- a/tests/ui/unsafe/unsafe-assign.rs
+++ b/tests/ui/unsafe/unsafe-assign.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 #![feature(rustc_attrs)]
 #![allow(unused,dead_code)]
 
diff --git a/tests/ui/unsafe/unsafe-assign.mirunsafeck.stderr b/tests/ui/unsafe/unsafe-assign.stderr
index f8b55e0668d..1fa5d715c2e 100644
--- a/tests/ui/unsafe/unsafe-assign.mirunsafeck.stderr
+++ b/tests/ui/unsafe/unsafe-assign.stderr
@@ -1,5 +1,5 @@
 error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-assign.rs:12:5
+  --> $DIR/unsafe-assign.rs:9:5
    |
 LL |     foo.0.0 = 0;
    |     ^^^^^^^^^^^ mutation of layout constrained field
diff --git a/tests/ui/unsafe/unsafe-assign.thirunsafeck.stderr b/tests/ui/unsafe/unsafe-assign.thirunsafeck.stderr
deleted file mode 100644
index f8b55e0668d..00000000000
--- a/tests/ui/unsafe/unsafe-assign.thirunsafeck.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-assign.rs:12:5
-   |
-LL |     foo.0.0 = 0;
-   |     ^^^^^^^^^^^ mutation of layout constrained field
-   |
-   = note: mutating layout constrained fields cannot statically be checked for valid values
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/unsafe-borrow.rs b/tests/ui/unsafe/unsafe-borrow.rs
index 8dddc70be45..ab0e59489a9 100644
--- a/tests/ui/unsafe/unsafe-borrow.rs
+++ b/tests/ui/unsafe/unsafe-borrow.rs
@@ -1,6 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
-
 #![feature(rustc_attrs)]
 #![allow(unused,dead_code)]
 
diff --git a/tests/ui/unsafe/unsafe-borrow.mirunsafeck.stderr b/tests/ui/unsafe/unsafe-borrow.stderr
index a206722495a..a53b50583ca 100644
--- a/tests/ui/unsafe/unsafe-borrow.mirunsafeck.stderr
+++ b/tests/ui/unsafe/unsafe-borrow.stderr
@@ -1,5 +1,5 @@
 error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-borrow.rs:12:13
+  --> $DIR/unsafe-borrow.rs:9:13
    |
 LL |     let a = &mut foo.0.0;
    |             ^^^^^^^^^^^^ mutation of layout constrained field
@@ -7,7 +7,7 @@ LL |     let a = &mut foo.0.0;
    = note: mutating layout constrained fields cannot statically be checked for valid values
 
 error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-borrow.rs:32:13
+  --> $DIR/unsafe-borrow.rs:29:13
    |
 LL |     let a = &mut foo.0[2];
    |             ^^^^^^^^^^^^^ mutation of layout constrained field
@@ -15,7 +15,7 @@ LL |     let a = &mut foo.0[2];
    = note: mutating layout constrained fields cannot statically be checked for valid values
 
 error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-borrow.rs:51:18
+  --> $DIR/unsafe-borrow.rs:48:18
    |
 LL |         NonZero((a,)) => *a = 0,
    |                  ^ mutation of layout constrained field
diff --git a/tests/ui/unsafe/unsafe-borrow.thirunsafeck.stderr b/tests/ui/unsafe/unsafe-borrow.thirunsafeck.stderr
deleted file mode 100644
index a206722495a..00000000000
--- a/tests/ui/unsafe/unsafe-borrow.thirunsafeck.stderr
+++ /dev/null
@@ -1,27 +0,0 @@
-error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-borrow.rs:12:13
-   |
-LL |     let a = &mut foo.0.0;
-   |             ^^^^^^^^^^^^ mutation of layout constrained field
-   |
-   = note: mutating layout constrained fields cannot statically be checked for valid values
-
-error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-borrow.rs:32:13
-   |
-LL |     let a = &mut foo.0[2];
-   |             ^^^^^^^^^^^^^ mutation of layout constrained field
-   |
-   = note: mutating layout constrained fields cannot statically be checked for valid values
-
-error[E0133]: mutation of layout constrained field is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-borrow.rs:51:18
-   |
-LL |         NonZero((a,)) => *a = 0,
-   |                  ^ mutation of layout constrained field
-   |
-   = note: mutating layout constrained fields cannot statically be checked for valid values
-
-error: aborting due to 3 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/unsafe-const-fn.rs b/tests/ui/unsafe/unsafe-const-fn.rs
index 65e3acf3063..3b4becf17a7 100644
--- a/tests/ui/unsafe/unsafe-const-fn.rs
+++ b/tests/ui/unsafe/unsafe-const-fn.rs
@@ -1,8 +1,5 @@
 // A quick test of 'unsafe const fn' functionality
 
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 const unsafe fn dummy(v: u32) -> u32 {
     !v
 }
diff --git a/tests/ui/unsafe/unsafe-const-fn.mir.stderr b/tests/ui/unsafe/unsafe-const-fn.stderr
index 2450f08664c..8d7f09a1edb 100644
--- a/tests/ui/unsafe/unsafe-const-fn.mir.stderr
+++ b/tests/ui/unsafe/unsafe-const-fn.stderr
@@ -1,5 +1,5 @@
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-const-fn.rs:10:18
+  --> $DIR/unsafe-const-fn.rs:7:18
    |
 LL | const VAL: u32 = dummy(0xFFFF);
    |                  ^^^^^^^^^^^^^ call to unsafe function
diff --git a/tests/ui/unsafe/unsafe-const-fn.thir.stderr b/tests/ui/unsafe/unsafe-const-fn.thir.stderr
deleted file mode 100644
index 199dca9237e..00000000000
--- a/tests/ui/unsafe/unsafe-const-fn.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: call to unsafe function `dummy` is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-const-fn.rs:10:18
-   |
-LL | const VAL: u32 = dummy(0xFFFF);
-   |                  ^^^^^^^^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/unsafe-fn-assign-deref-ptr.rs b/tests/ui/unsafe/unsafe-fn-assign-deref-ptr.rs
index a94e94375ae..91264e790c8 100644
--- a/tests/ui/unsafe/unsafe-fn-assign-deref-ptr.rs
+++ b/tests/ui/unsafe/unsafe-fn-assign-deref-ptr.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 fn f(p: *mut u8) {
     *p = 0; //~ ERROR dereference of raw pointer is unsafe
     return;
diff --git a/tests/ui/unsafe/unsafe-fn-assign-deref-ptr.mir.stderr b/tests/ui/unsafe/unsafe-fn-assign-deref-ptr.stderr
index da3d5f3bd29..d79cbd466c2 100644
--- a/tests/ui/unsafe/unsafe-fn-assign-deref-ptr.mir.stderr
+++ b/tests/ui/unsafe/unsafe-fn-assign-deref-ptr.stderr
@@ -1,5 +1,5 @@
 error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-fn-assign-deref-ptr.rs:5:5
+  --> $DIR/unsafe-fn-assign-deref-ptr.rs:2:5
    |
 LL |     *p = 0;
    |     ^^^^^^ dereference of raw pointer
diff --git a/tests/ui/unsafe/unsafe-fn-assign-deref-ptr.thir.stderr b/tests/ui/unsafe/unsafe-fn-assign-deref-ptr.thir.stderr
deleted file mode 100644
index aa5644782a4..00000000000
--- a/tests/ui/unsafe/unsafe-fn-assign-deref-ptr.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-fn-assign-deref-ptr.rs:5:5
-   |
-LL |     *p = 0;
-   |     ^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/unsafe-fn-called-from-safe.rs b/tests/ui/unsafe/unsafe-fn-called-from-safe.rs
index 55072dcc6c3..1836629958a 100644
--- a/tests/ui/unsafe/unsafe-fn-called-from-safe.rs
+++ b/tests/ui/unsafe/unsafe-fn-called-from-safe.rs
@@ -1,10 +1,6 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 unsafe fn f() { return; }
 
 fn main() {
     f();
-    //[mir]~^ ERROR call to unsafe function is unsafe
-    //[thir]~^^ ERROR call to unsafe function `f` is unsafe
+    //~^ ERROR call to unsafe function is unsafe
 }
diff --git a/tests/ui/unsafe/unsafe-fn-called-from-safe.mir.stderr b/tests/ui/unsafe/unsafe-fn-called-from-safe.stderr
index d3347437075..51aba0ba6d7 100644
--- a/tests/ui/unsafe/unsafe-fn-called-from-safe.mir.stderr
+++ b/tests/ui/unsafe/unsafe-fn-called-from-safe.stderr
@@ -1,5 +1,5 @@
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-fn-called-from-safe.rs:7:5
+  --> $DIR/unsafe-fn-called-from-safe.rs:4:5
    |
 LL |     f();
    |     ^^^ call to unsafe function
diff --git a/tests/ui/unsafe/unsafe-fn-called-from-safe.thir.stderr b/tests/ui/unsafe/unsafe-fn-called-from-safe.thir.stderr
deleted file mode 100644
index 75431666186..00000000000
--- a/tests/ui/unsafe/unsafe-fn-called-from-safe.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: call to unsafe function `f` is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-fn-called-from-safe.rs:7:5
-   |
-LL |     f();
-   |     ^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/unsafe-fn-deref-ptr.rs b/tests/ui/unsafe/unsafe-fn-deref-ptr.rs
index 4b7c6bf6985..a3144824323 100644
--- a/tests/ui/unsafe/unsafe-fn-deref-ptr.rs
+++ b/tests/ui/unsafe/unsafe-fn-deref-ptr.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 fn f(p: *const u8) -> u8 {
     let _ = *p; //~ ERROR dereference of raw pointer is unsafe
     let _: u8 = *p; //~ ERROR dereference of raw pointer is unsafe
diff --git a/tests/ui/unsafe/unsafe-fn-deref-ptr.mir.stderr b/tests/ui/unsafe/unsafe-fn-deref-ptr.stderr
index 7f1e7c8902f..2e68963097e 100644
--- a/tests/ui/unsafe/unsafe-fn-deref-ptr.mir.stderr
+++ b/tests/ui/unsafe/unsafe-fn-deref-ptr.stderr
@@ -1,5 +1,5 @@
 error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-fn-deref-ptr.rs:5:13
+  --> $DIR/unsafe-fn-deref-ptr.rs:2:13
    |
 LL |     let _ = *p;
    |             ^^ dereference of raw pointer
@@ -7,7 +7,7 @@ LL |     let _ = *p;
    = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
 
 error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-fn-deref-ptr.rs:6:17
+  --> $DIR/unsafe-fn-deref-ptr.rs:3:17
    |
 LL |     let _: u8 = *p;
    |                 ^^ dereference of raw pointer
@@ -15,7 +15,7 @@ LL |     let _: u8 = *p;
    = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
 
 error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-fn-deref-ptr.rs:7:9
+  --> $DIR/unsafe-fn-deref-ptr.rs:4:9
    |
 LL |     _ = *p;
    |         ^^ dereference of raw pointer
@@ -23,7 +23,7 @@ LL |     _ = *p;
    = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
 
 error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-fn-deref-ptr.rs:8:12
+  --> $DIR/unsafe-fn-deref-ptr.rs:5:12
    |
 LL |     return *p;
    |            ^^ dereference of raw pointer
diff --git a/tests/ui/unsafe/unsafe-fn-deref-ptr.thir.stderr b/tests/ui/unsafe/unsafe-fn-deref-ptr.thir.stderr
deleted file mode 100644
index 7f1e7c8902f..00000000000
--- a/tests/ui/unsafe/unsafe-fn-deref-ptr.thir.stderr
+++ /dev/null
@@ -1,35 +0,0 @@
-error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-fn-deref-ptr.rs:5:13
-   |
-LL |     let _ = *p;
-   |             ^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-
-error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-fn-deref-ptr.rs:6:17
-   |
-LL |     let _: u8 = *p;
-   |                 ^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-
-error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-fn-deref-ptr.rs:7:9
-   |
-LL |     _ = *p;
-   |         ^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-
-error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-fn-deref-ptr.rs:8:12
-   |
-LL |     return *p;
-   |            ^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-
-error: aborting due to 4 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/unsafe-fn-used-as-value.rs b/tests/ui/unsafe/unsafe-fn-used-as-value.rs
index 9517598c7ce..a47189d265f 100644
--- a/tests/ui/unsafe/unsafe-fn-used-as-value.rs
+++ b/tests/ui/unsafe/unsafe-fn-used-as-value.rs
@@ -1,11 +1,7 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 unsafe fn f() { return; }
 
 fn main() {
     let x = f;
     x();
-    //[mir]~^ ERROR call to unsafe function is unsafe
-    //[thir]~^^ ERROR call to unsafe function `f` is unsafe
+    //~^ ERROR call to unsafe function is unsafe
 }
diff --git a/tests/ui/unsafe/unsafe-fn-used-as-value.mir.stderr b/tests/ui/unsafe/unsafe-fn-used-as-value.stderr
index 01e8e49ecfa..1625de184d2 100644
--- a/tests/ui/unsafe/unsafe-fn-used-as-value.mir.stderr
+++ b/tests/ui/unsafe/unsafe-fn-used-as-value.stderr
@@ -1,5 +1,5 @@
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-fn-used-as-value.rs:8:5
+  --> $DIR/unsafe-fn-used-as-value.rs:5:5
    |
 LL |     x();
    |     ^^^ call to unsafe function
diff --git a/tests/ui/unsafe/unsafe-fn-used-as-value.thir.stderr b/tests/ui/unsafe/unsafe-fn-used-as-value.thir.stderr
deleted file mode 100644
index c38da7226f6..00000000000
--- a/tests/ui/unsafe/unsafe-fn-used-as-value.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: call to unsafe function `f` is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-fn-used-as-value.rs:8:5
-   |
-LL |     x();
-   |     ^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/unsafe-not-inherited.rs b/tests/ui/unsafe/unsafe-not-inherited.rs
index f9d9a595714..6d797caa0f9 100644
--- a/tests/ui/unsafe/unsafe-not-inherited.rs
+++ b/tests/ui/unsafe/unsafe-not-inherited.rs
@@ -1,5 +1,3 @@
-// revisions: mirunsafeck thirunsafeck
-// [thirunsafeck]compile-flags: -Z thir-unsafeck
 #![allow(unused, dead_code)]
 
 static mut FOO: u64 = 0;
diff --git a/tests/ui/unsafe/unsafe-not-inherited.mirunsafeck.stderr b/tests/ui/unsafe/unsafe-not-inherited.stderr
index 5536efbc6f4..3bc5ca5c9d1 100644
--- a/tests/ui/unsafe/unsafe-not-inherited.mirunsafeck.stderr
+++ b/tests/ui/unsafe/unsafe-not-inherited.stderr
@@ -1,5 +1,5 @@
 error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-not-inherited.rs:8:31
+  --> $DIR/unsafe-not-inherited.rs:6:31
    |
 LL |     unsafe {static BAR: u64 = FOO;}
    |     ------                    ^^^ use of mutable static
@@ -9,7 +9,7 @@ LL |     unsafe {static BAR: u64 = FOO;}
    = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
 
 error[E0133]: call to unsafe function is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-not-inherited.rs:20:13
+  --> $DIR/unsafe-not-inherited.rs:18:13
    |
 LL |     unsafe {
    |     ------ items do not inherit unsafety from separate enclosing items
diff --git a/tests/ui/unsafe/unsafe-not-inherited.thirunsafeck.stderr b/tests/ui/unsafe/unsafe-not-inherited.thirunsafeck.stderr
deleted file mode 100644
index 88ea2e6d1fe..00000000000
--- a/tests/ui/unsafe/unsafe-not-inherited.thirunsafeck.stderr
+++ /dev/null
@@ -1,24 +0,0 @@
-error[E0133]: use of mutable static is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-not-inherited.rs:8:31
-   |
-LL |     unsafe {static BAR: u64 = FOO;}
-   |     ------                    ^^^ use of mutable static
-   |     |
-   |     items do not inherit unsafety from separate enclosing items
-   |
-   = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
-
-error[E0133]: call to unsafe function `unsafe_call` is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-not-inherited.rs:20:13
-   |
-LL |     unsafe {
-   |     ------ items do not inherit unsafety from separate enclosing items
-...
-LL |             unsafe_call();
-   |             ^^^^^^^^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: aborting due to 2 previous errors
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/unsafe-unstable-const-fn.rs b/tests/ui/unsafe/unsafe-unstable-const-fn.rs
index 581b15cdfb0..5398721484a 100644
--- a/tests/ui/unsafe/unsafe-unstable-const-fn.rs
+++ b/tests/ui/unsafe/unsafe-unstable-const-fn.rs
@@ -1,6 +1,3 @@
-// revisions: mir thir
-// [thir]compile-flags: -Z thir-unsafeck
-
 #![stable(feature = "foo", since = "1.33.0")]
 #![feature(staged_api)]
 
diff --git a/tests/ui/unsafe/unsafe-unstable-const-fn.mir.stderr b/tests/ui/unsafe/unsafe-unstable-const-fn.stderr
index 79133ab39a0..22a2dcbf119 100644
--- a/tests/ui/unsafe/unsafe-unstable-const-fn.mir.stderr
+++ b/tests/ui/unsafe/unsafe-unstable-const-fn.stderr
@@ -1,5 +1,5 @@
 error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-unstable-const-fn.rs:10:5
+  --> $DIR/unsafe-unstable-const-fn.rs:7:5
    |
 LL |     *a == b
    |     ^^ dereference of raw pointer
diff --git a/tests/ui/unsafe/unsafe-unstable-const-fn.thir.stderr b/tests/ui/unsafe/unsafe-unstable-const-fn.thir.stderr
deleted file mode 100644
index 79133ab39a0..00000000000
--- a/tests/ui/unsafe/unsafe-unstable-const-fn.thir.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
-  --> $DIR/unsafe-unstable-const-fn.rs:10:5
-   |
-LL |     *a == b
-   |     ^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0133`.
diff --git a/tests/ui/unsafe/wrapping-unsafe-block-sugg.mir.fixed b/tests/ui/unsafe/wrapping-unsafe-block-sugg.fixed
index b59029df642..f776cffed59 100644
--- a/tests/ui/unsafe/wrapping-unsafe-block-sugg.mir.fixed
+++ b/tests/ui/unsafe/wrapping-unsafe-block-sugg.fixed
@@ -1,7 +1,5 @@
 // run-rustfix
 // aux-build:external_unsafe_macro.rs
-// revisions: mir thir
-// [thir]compile-flags: -Zthir-unsafeck
 
 #![deny(unsafe_op_in_unsafe_fn)] //~ NOTE
 #![crate_name = "wrapping_unsafe_block_sugg"]
@@ -12,13 +10,11 @@ unsafe fn unsf() {}
 
 pub unsafe fn foo() { unsafe {
     //~^ NOTE an unsafe function restricts its caller, but its body is safe by default
-    unsf(); //[mir]~ ERROR call to unsafe function is unsafe
-     //[thir]~^ ERROR call to unsafe function `unsf` is unsafe
-    //~^^ NOTE
+    unsf(); //~ ERROR call to unsafe function is unsafe
+    //~^ NOTE
     //~| NOTE
-    unsf(); //[mir]~ ERROR call to unsafe function is unsafe
-    //[thir]~^ ERROR call to unsafe function `unsf` is unsafe
-    //~^^ NOTE
+    unsf(); //~ ERROR call to unsafe function is unsafe
+    //~^ NOTE
     //~| NOTE
 }}
 
@@ -44,12 +40,10 @@ pub unsafe fn baz() -> i32 { unsafe {
 }}
 
 macro_rules! unsafe_macro { () => (unsf()) }
-//[mir]~^ ERROR call to unsafe function is unsafe
-//[thir]~^^ ERROR call to unsafe function `unsf` is unsafe
+//~^ ERROR call to unsafe function is unsafe
 //~| NOTE
 //~| NOTE
-//[mir]~| ERROR call to unsafe function is unsafe
-//[thir]~| ERROR call to unsafe function `unsf` is unsafe
+//~| ERROR call to unsafe function is unsafe
 //~| NOTE
 //~| NOTE
 
diff --git a/tests/ui/unsafe/wrapping-unsafe-block-sugg.rs b/tests/ui/unsafe/wrapping-unsafe-block-sugg.rs
index 3629b8a1beb..13ab51ef432 100644
--- a/tests/ui/unsafe/wrapping-unsafe-block-sugg.rs
+++ b/tests/ui/unsafe/wrapping-unsafe-block-sugg.rs
@@ -1,7 +1,5 @@
 // run-rustfix
 // aux-build:external_unsafe_macro.rs
-// revisions: mir thir
-// [thir]compile-flags: -Zthir-unsafeck
 
 #![deny(unsafe_op_in_unsafe_fn)] //~ NOTE
 #![crate_name = "wrapping_unsafe_block_sugg"]
@@ -12,13 +10,11 @@ unsafe fn unsf() {}
 
 pub unsafe fn foo() {
     //~^ NOTE an unsafe function restricts its caller, but its body is safe by default
-    unsf(); //[mir]~ ERROR call to unsafe function is unsafe
-     //[thir]~^ ERROR call to unsafe function `unsf` is unsafe
-    //~^^ NOTE
+    unsf(); //~ ERROR call to unsafe function is unsafe
+    //~^ NOTE
     //~| NOTE
-    unsf(); //[mir]~ ERROR call to unsafe function is unsafe
-    //[thir]~^ ERROR call to unsafe function `unsf` is unsafe
-    //~^^ NOTE
+    unsf(); //~ ERROR call to unsafe function is unsafe
+    //~^ NOTE
     //~| NOTE
 }
 
@@ -44,12 +40,10 @@ pub unsafe fn baz() -> i32 {
 }
 
 macro_rules! unsafe_macro { () => (unsf()) }
-//[mir]~^ ERROR call to unsafe function is unsafe
-//[thir]~^^ ERROR call to unsafe function `unsf` is unsafe
+//~^ ERROR call to unsafe function is unsafe
 //~| NOTE
 //~| NOTE
-//[mir]~| ERROR call to unsafe function is unsafe
-//[thir]~| ERROR call to unsafe function `unsf` is unsafe
+//~| ERROR call to unsafe function is unsafe
 //~| NOTE
 //~| NOTE
 
diff --git a/tests/ui/unsafe/wrapping-unsafe-block-sugg.mir.stderr b/tests/ui/unsafe/wrapping-unsafe-block-sugg.stderr
index 7a1b83c7367..9ae238d5a79 100644
--- a/tests/ui/unsafe/wrapping-unsafe-block-sugg.mir.stderr
+++ b/tests/ui/unsafe/wrapping-unsafe-block-sugg.stderr
@@ -1,23 +1,23 @@
 error: call to unsafe function is unsafe and requires unsafe block (error E0133)
-  --> $DIR/wrapping-unsafe-block-sugg.rs:15:5
+  --> $DIR/wrapping-unsafe-block-sugg.rs:13:5
    |
 LL |     unsf();
    |     ^^^^^^ call to unsafe function
    |
    = note: consult the function's documentation for information on how to avoid undefined behavior
 note: an unsafe function restricts its caller, but its body is safe by default
-  --> $DIR/wrapping-unsafe-block-sugg.rs:13:1
+  --> $DIR/wrapping-unsafe-block-sugg.rs:11:1
    |
 LL | pub unsafe fn foo() {
    | ^^^^^^^^^^^^^^^^^^^
 note: the lint level is defined here
-  --> $DIR/wrapping-unsafe-block-sugg.rs:6:9
+  --> $DIR/wrapping-unsafe-block-sugg.rs:4:9
    |
 LL | #![deny(unsafe_op_in_unsafe_fn)]
    |         ^^^^^^^^^^^^^^^^^^^^^^
 
 error: call to unsafe function is unsafe and requires unsafe block (error E0133)
-  --> $DIR/wrapping-unsafe-block-sugg.rs:19:5
+  --> $DIR/wrapping-unsafe-block-sugg.rs:16:5
    |
 LL |     unsf();
    |     ^^^^^^ call to unsafe function
@@ -25,20 +25,20 @@ LL |     unsf();
    = note: consult the function's documentation for information on how to avoid undefined behavior
 
 error: dereference of raw pointer is unsafe and requires unsafe block (error E0133)
-  --> $DIR/wrapping-unsafe-block-sugg.rs:27:13
+  --> $DIR/wrapping-unsafe-block-sugg.rs:23:13
    |
 LL |     let y = *x;
    |             ^^ dereference of raw pointer
    |
    = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
 note: an unsafe function restricts its caller, but its body is safe by default
-  --> $DIR/wrapping-unsafe-block-sugg.rs:25:1
+  --> $DIR/wrapping-unsafe-block-sugg.rs:21:1
    |
 LL | pub unsafe fn bar(x: *const i32) -> i32 {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: dereference of raw pointer is unsafe and requires unsafe block (error E0133)
-  --> $DIR/wrapping-unsafe-block-sugg.rs:30:9
+  --> $DIR/wrapping-unsafe-block-sugg.rs:26:9
    |
 LL |     y + *x
    |         ^^ dereference of raw pointer
@@ -46,20 +46,20 @@ LL |     y + *x
    = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
 
 error: use of mutable static is unsafe and requires unsafe block (error E0133)
-  --> $DIR/wrapping-unsafe-block-sugg.rs:38:13
+  --> $DIR/wrapping-unsafe-block-sugg.rs:34:13
    |
 LL |     let y = BAZ;
    |             ^^^ use of mutable static
    |
    = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
 note: an unsafe function restricts its caller, but its body is safe by default
-  --> $DIR/wrapping-unsafe-block-sugg.rs:36:1
+  --> $DIR/wrapping-unsafe-block-sugg.rs:32:1
    |
 LL | pub unsafe fn baz() -> i32 {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: use of mutable static is unsafe and requires unsafe block (error E0133)
-  --> $DIR/wrapping-unsafe-block-sugg.rs:41:9
+  --> $DIR/wrapping-unsafe-block-sugg.rs:37:9
    |
 LL |     y + BAZ
    |         ^^^ use of mutable static
@@ -67,7 +67,7 @@ LL |     y + BAZ
    = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
 
 error: call to unsafe function is unsafe and requires unsafe block (error E0133)
-  --> $DIR/wrapping-unsafe-block-sugg.rs:46:36
+  --> $DIR/wrapping-unsafe-block-sugg.rs:42:36
    |
 LL | macro_rules! unsafe_macro { () => (unsf()) }
    |                                    ^^^^^^ call to unsafe function
@@ -77,14 +77,14 @@ LL |     unsafe_macro!();
    |
    = note: consult the function's documentation for information on how to avoid undefined behavior
 note: an unsafe function restricts its caller, but its body is safe by default
-  --> $DIR/wrapping-unsafe-block-sugg.rs:56:1
+  --> $DIR/wrapping-unsafe-block-sugg.rs:50:1
    |
 LL | pub unsafe fn unsafe_in_macro() {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    = note: this error originates in the macro `unsafe_macro` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: call to unsafe function is unsafe and requires unsafe block (error E0133)
-  --> $DIR/wrapping-unsafe-block-sugg.rs:46:36
+  --> $DIR/wrapping-unsafe-block-sugg.rs:42:36
    |
 LL | macro_rules! unsafe_macro { () => (unsf()) }
    |                                    ^^^^^^ call to unsafe function
diff --git a/tests/ui/unsafe/wrapping-unsafe-block-sugg.thir.fixed b/tests/ui/unsafe/wrapping-unsafe-block-sugg.thir.fixed
deleted file mode 100644
index b59029df642..00000000000
--- a/tests/ui/unsafe/wrapping-unsafe-block-sugg.thir.fixed
+++ /dev/null
@@ -1,73 +0,0 @@
-// run-rustfix
-// aux-build:external_unsafe_macro.rs
-// revisions: mir thir
-// [thir]compile-flags: -Zthir-unsafeck
-
-#![deny(unsafe_op_in_unsafe_fn)] //~ NOTE
-#![crate_name = "wrapping_unsafe_block_sugg"]
-
-extern crate external_unsafe_macro;
-
-unsafe fn unsf() {}
-
-pub unsafe fn foo() { unsafe {
-    //~^ NOTE an unsafe function restricts its caller, but its body is safe by default
-    unsf(); //[mir]~ ERROR call to unsafe function is unsafe
-     //[thir]~^ ERROR call to unsafe function `unsf` is unsafe
-    //~^^ NOTE
-    //~| NOTE
-    unsf(); //[mir]~ ERROR call to unsafe function is unsafe
-    //[thir]~^ ERROR call to unsafe function `unsf` is unsafe
-    //~^^ NOTE
-    //~| NOTE
-}}
-
-pub unsafe fn bar(x: *const i32) -> i32 { unsafe {
-    //~^ NOTE an unsafe function restricts its caller, but its body is safe by default
-    let y = *x; //~ ERROR dereference of raw pointer is unsafe and requires unsafe block
-    //~^ NOTE
-    //~| NOTE
-    y + *x //~ ERROR dereference of raw pointer is unsafe and requires unsafe block
-    //~^ NOTE
-    //~| NOTE
-}}
-
-static mut BAZ: i32 = 0;
-pub unsafe fn baz() -> i32 { unsafe {
-    //~^ NOTE an unsafe function restricts its caller, but its body is safe by default
-    let y = BAZ; //~ ERROR use of mutable static is unsafe and requires unsafe block
-    //~^ NOTE
-    //~| NOTE
-    y + BAZ //~ ERROR use of mutable static is unsafe and requires unsafe block
-    //~^ NOTE
-    //~| NOTE
-}}
-
-macro_rules! unsafe_macro { () => (unsf()) }
-//[mir]~^ ERROR call to unsafe function is unsafe
-//[thir]~^^ ERROR call to unsafe function `unsf` is unsafe
-//~| NOTE
-//~| NOTE
-//[mir]~| ERROR call to unsafe function is unsafe
-//[thir]~| ERROR call to unsafe function `unsf` is unsafe
-//~| NOTE
-//~| NOTE
-
-pub unsafe fn unsafe_in_macro() { unsafe {
-    //~^ NOTE an unsafe function restricts its caller, but its body is safe by default
-    unsafe_macro!();
-    //~^ NOTE
-    //~| NOTE
-    unsafe_macro!();
-    //~^ NOTE
-    //~| NOTE
-}}
-
-pub unsafe fn unsafe_in_external_macro() {
-    // FIXME: https://github.com/rust-lang/rust/issues/112504
-    // FIXME: ~^ NOTE an unsafe function restricts its caller, but its body is safe by default
-    external_unsafe_macro::unsafe_macro!();
-    external_unsafe_macro::unsafe_macro!();
-}
-
-fn main() {}
diff --git a/tests/ui/unsafe/wrapping-unsafe-block-sugg.thir.stderr b/tests/ui/unsafe/wrapping-unsafe-block-sugg.thir.stderr
deleted file mode 100644
index b1fb35f85a6..00000000000
--- a/tests/ui/unsafe/wrapping-unsafe-block-sugg.thir.stderr
+++ /dev/null
@@ -1,99 +0,0 @@
-error: call to unsafe function `unsf` is unsafe and requires unsafe block (error E0133)
-  --> $DIR/wrapping-unsafe-block-sugg.rs:15:5
-   |
-LL |     unsf();
-   |     ^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-note: an unsafe function restricts its caller, but its body is safe by default
-  --> $DIR/wrapping-unsafe-block-sugg.rs:13:1
-   |
-LL | pub unsafe fn foo() {
-   | ^^^^^^^^^^^^^^^^^^^
-note: the lint level is defined here
-  --> $DIR/wrapping-unsafe-block-sugg.rs:6:9
-   |
-LL | #![deny(unsafe_op_in_unsafe_fn)]
-   |         ^^^^^^^^^^^^^^^^^^^^^^
-
-error: call to unsafe function `unsf` is unsafe and requires unsafe block (error E0133)
-  --> $DIR/wrapping-unsafe-block-sugg.rs:19:5
-   |
-LL |     unsf();
-   |     ^^^^^^ call to unsafe function
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-
-error: dereference of raw pointer is unsafe and requires unsafe block (error E0133)
-  --> $DIR/wrapping-unsafe-block-sugg.rs:27:13
-   |
-LL |     let y = *x;
-   |             ^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-note: an unsafe function restricts its caller, but its body is safe by default
-  --> $DIR/wrapping-unsafe-block-sugg.rs:25:1
-   |
-LL | pub unsafe fn bar(x: *const i32) -> i32 {
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-error: dereference of raw pointer is unsafe and requires unsafe block (error E0133)
-  --> $DIR/wrapping-unsafe-block-sugg.rs:30:9
-   |
-LL |     y + *x
-   |         ^^ dereference of raw pointer
-   |
-   = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
-
-error: use of mutable static is unsafe and requires unsafe block (error E0133)
-  --> $DIR/wrapping-unsafe-block-sugg.rs:38:13
-   |
-LL |     let y = BAZ;
-   |             ^^^ use of mutable static
-   |
-   = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
-note: an unsafe function restricts its caller, but its body is safe by default
-  --> $DIR/wrapping-unsafe-block-sugg.rs:36:1
-   |
-LL | pub unsafe fn baz() -> i32 {
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-error: use of mutable static is unsafe and requires unsafe block (error E0133)
-  --> $DIR/wrapping-unsafe-block-sugg.rs:41:9
-   |
-LL |     y + BAZ
-   |         ^^^ use of mutable static
-   |
-   = note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
-
-error: call to unsafe function `unsf` is unsafe and requires unsafe block (error E0133)
-  --> $DIR/wrapping-unsafe-block-sugg.rs:46:36
-   |
-LL | macro_rules! unsafe_macro { () => (unsf()) }
-   |                                    ^^^^^^ call to unsafe function
-...
-LL |     unsafe_macro!();
-   |     --------------- in this macro invocation
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-note: an unsafe function restricts its caller, but its body is safe by default
-  --> $DIR/wrapping-unsafe-block-sugg.rs:56:1
-   |
-LL | pub unsafe fn unsafe_in_macro() {
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   = note: this error originates in the macro `unsafe_macro` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error: call to unsafe function `unsf` is unsafe and requires unsafe block (error E0133)
-  --> $DIR/wrapping-unsafe-block-sugg.rs:46:36
-   |
-LL | macro_rules! unsafe_macro { () => (unsf()) }
-   |                                    ^^^^^^ call to unsafe function
-...
-LL |     unsafe_macro!();
-   |     --------------- in this macro invocation
-   |
-   = note: consult the function's documentation for information on how to avoid undefined behavior
-   = note: this error originates in the macro `unsafe_macro` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error: aborting due to 8 previous errors
-