about summary refs log tree commit diff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/codegen/simd/issue-120720-reduce-nan.rs22
-rw-r--r--tests/coverage/closure_macro.cov-map9
-rw-r--r--tests/coverage/closure_macro_async.cov-map9
-rw-r--r--tests/debuginfo/mutex.rs2
-rw-r--r--tests/debuginfo/rwlock-read.rs2
-rw-r--r--tests/mir-opt/building/issue_101867.main.built.after.mir20
-rw-r--r--tests/mir-opt/building/issue_49232.main.built.after.mir34
-rw-r--r--tests/mir-opt/building/logical_or_in_conditional.test_complex.built.after.mir130
-rw-r--r--tests/mir-opt/building/match_false_edges.full_tested_match.built.after.mir48
-rw-r--r--tests/mir-opt/building/match_false_edges.full_tested_match2.built.after.mir50
-rw-r--r--tests/mir-opt/building/match_false_edges.main.built.after.mir72
-rw-r--r--tests/mir-opt/building/simple_match.match_bool.built.after.mir18
-rw-r--r--tests/mir-opt/building/uniform_array_move_out.move_out_by_subslice.built.after.mir34
-rw-r--r--tests/mir-opt/building/uniform_array_move_out.move_out_from_end.built.after.mir34
-rw-r--r--tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-abort.diff18
-rw-r--r--tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-unwind.diff18
-rw-r--r--tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-abort.diff18
-rw-r--r--tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-unwind.diff18
-rw-r--r--tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-abort.diff18
-rw-r--r--tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-unwind.diff18
-rw-r--r--tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-abort.diff18
-rw-r--r--tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-unwind.diff18
-rw-r--r--tests/mir-opt/dataflow-const-prop/enum.rs2
-rw-r--r--tests/mir-opt/exponential_or.match_tuple.SimplifyCfg-initial.after.mir8
-rw-r--r--tests/mir-opt/issue_72181.bar.built.after.mir4
-rw-r--r--tests/mir-opt/issue_72181.main.built.after.mir16
-rw-r--r--tests/mir-opt/issue_91633.bar.built.after.mir14
-rw-r--r--tests/mir-opt/issue_91633.hey.built.after.mir8
-rw-r--r--tests/mir-opt/issue_99325.main.built.after.32bit.mir82
-rw-r--r--tests/mir-opt/issue_99325.main.built.after.64bit.mir82
-rw-r--r--tests/mir-opt/pre-codegen/slice_index.slice_get_mut_usize.PreCodegen.after.panic-abort.mir78
-rw-r--r--tests/mir-opt/pre-codegen/slice_index.slice_get_mut_usize.PreCodegen.after.panic-unwind.mir78
-rw-r--r--tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-abort.mir104
-rw-r--r--tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-unwind.mir104
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-abort.mir2
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-unwind.mir2
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-abort.mir2
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-unwind.mir2
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-abort.mir2
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-unwind.mir2
-rw-r--r--tests/ui-fulldeps/internal-lints/diagnostics.rs13
-rw-r--r--tests/ui-fulldeps/internal-lints/diagnostics.stderr8
-rw-r--r--tests/ui-fulldeps/session-diagnostic/diagnostic-derive-doc-comment-field.stderr7
-rw-r--r--tests/ui-fulldeps/session-diagnostic/diagnostic-derive.rs4
-rw-r--r--tests/ui-fulldeps/session-diagnostic/diagnostic-derive.stderr4
-rw-r--r--tests/ui-fulldeps/stable-mir/compilation-result.rs2
-rw-r--r--tests/ui/asm/bad-arch.stderr2
-rw-r--r--tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.rs4
-rw-r--r--tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr16
-rw-r--r--tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr14
-rw-r--r--tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.rs4
-rw-r--r--tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr16
-rw-r--r--tests/ui/associated-type-bounds/no-gat-position.rs18
-rw-r--r--tests/ui/associated-type-bounds/no-gat-position.stderr9
-rw-r--r--tests/ui/async-await/async-fn/auxiliary/block-on.rs20
-rw-r--r--tests/ui/async-await/async-fn/impl-header.rs6
-rw-r--r--tests/ui/async-await/async-fn/impl-header.stderr45
-rw-r--r--tests/ui/async-await/async-fn/mbe-async-trait-bound-theoretical-regression.rs21
-rw-r--r--tests/ui/async-await/async-fn/mbe-async-trait-bound-theoretical-regression.stderr47
-rw-r--r--tests/ui/async-await/async-fn/simple.rs7
-rw-r--r--tests/ui/async-await/async-fn/trait-bounds-in-macro.rs12
-rw-r--r--tests/ui/async-await/async-fn/trait-bounds-in-macro.stderr14
-rw-r--r--tests/ui/async-await/for-await-passthrough.rs2
-rw-r--r--tests/ui/auto-traits/issue-117789.rs2
-rw-r--r--tests/ui/auto-traits/issue-117789.stderr4
-rw-r--r--tests/ui/auto-traits/issue-83857-ub.rs1
-rw-r--r--tests/ui/auto-traits/issue-83857-ub.stderr12
-rw-r--r--tests/ui/auto-traits/suspicious-impls-lint.rs50
-rw-r--r--tests/ui/auto-traits/suspicious-impls-lint.stderr82
-rw-r--r--tests/ui/auto-traits/suspicious-negative-impls-lint.rs21
-rw-r--r--tests/ui/auto-traits/suspicious-negative-impls-lint.stderr52
-rw-r--r--tests/ui/check-static-values-constraints.stderr22
-rw-r--r--tests/ui/coherence/coherence-conflicting-negative-trait-impl.rs2
-rw-r--r--tests/ui/coherence/coherence-conflicting-negative-trait-impl.stderr18
-rw-r--r--tests/ui/coherence/coherence-fn-implied-bounds.rs2
-rw-r--r--tests/ui/coherence/coherence-fn-implied-bounds.stderr2
-rw-r--r--tests/ui/coherence/coherence-free-vs-bound-region.rs2
-rw-r--r--tests/ui/coherence/coherence-free-vs-bound-region.stderr2
-rw-r--r--tests/ui/coherence/coherence-orphan.rs12
-rw-r--r--tests/ui/coherence/coherence-orphan.stderr25
-rw-r--r--tests/ui/coherence/coherence-overlap-negative-impls.rs13
-rw-r--r--tests/ui/coherence/coherence-subtyping.rs4
-rw-r--r--tests/ui/coherence/coherence-subtyping.stderr2
-rw-r--r--tests/ui/coherence/coherence-wasm-bindgen.rs2
-rw-r--r--tests/ui/coherence/coherence-wasm-bindgen.stderr2
-rw-r--r--tests/ui/coherence/const-errs-dont-conflict-103369.rs14
-rw-r--r--tests/ui/coherence/const-errs-dont-conflict-103369.stderr39
-rw-r--r--tests/ui/coherence/negative-coherence-placeholder-region-constraints-on-unification.explicit.stderr2
-rw-r--r--tests/ui/coherence/negative-coherence-placeholder-region-constraints-on-unification.rs2
-rw-r--r--tests/ui/coherence/occurs-check/associated-type.next.stderr16
-rw-r--r--tests/ui/coherence/occurs-check/associated-type.old.stderr16
-rw-r--r--tests/ui/compiletest-self-test/aux-aux.rs14
-rw-r--r--tests/ui/compiletest-self-test/auxiliary/aux_aux_bar.rs3
-rw-r--r--tests/ui/compiletest-self-test/auxiliary/aux_aux_foo.rs4
-rw-r--r--tests/ui/const-generics/invariant.rs10
-rw-r--r--tests/ui/const-generics/invariant.stderr4
-rw-r--r--tests/ui/const-generics/issues/issue-100313.rs1
-rw-r--r--tests/ui/const-generics/issues/issue-100313.stderr13
-rw-r--r--tests/ui/consts/const-array-oob.rs3
-rw-r--r--tests/ui/consts/const-array-oob.stderr10
-rw-r--r--tests/ui/consts/const-eval/const-eval-query-stack.stderr3
-rw-r--r--tests/ui/consts/const-eval/const_fn_ptr.stderr10
-rw-r--r--tests/ui/consts/const-eval/generic-slice.stderr28
-rw-r--r--tests/ui/consts/const-eval/validate_uninhabited_zsts.rs2
-rw-r--r--tests/ui/consts/const-eval/validate_uninhabited_zsts.stderr32
-rw-r--r--tests/ui/consts/const-mut-refs/issue-76510.rs1
-rw-r--r--tests/ui/consts/const-mut-refs/issue-76510.stderr12
-rw-r--r--tests/ui/consts/const_cmp_type_id.stderr12
-rw-r--r--tests/ui/consts/const_let_assign3.stderr16
-rw-r--r--tests/ui/consts/const_refs_to_static_fail_invalid.stderr24
-rw-r--r--tests/ui/consts/fn_trait_refs.stderr36
-rw-r--r--tests/ui/consts/issue-16538.stderr18
-rw-r--r--tests/ui/consts/issue-66693.rs4
-rw-r--r--tests/ui/consts/issue-66693.stderr19
-rw-r--r--tests/ui/consts/miri_unleashed/const_refers_to_static_cross_crate.stderr36
-rw-r--r--tests/ui/consts/miri_unleashed/mutable_references.rs15
-rw-r--r--tests/ui/consts/miri_unleashed/mutable_references.stderr48
-rw-r--r--tests/ui/consts/promote-not.stderr40
-rw-r--r--tests/ui/consts/promoted_const_call2.stderr12
-rw-r--r--tests/ui/consts/qualif-indirect-mutation-fail.stderr51
-rw-r--r--tests/ui/consts/recursive-zst-static.default.stderr12
-rw-r--r--tests/ui/consts/recursive-zst-static.unleash.stderr12
-rw-r--r--tests/ui/coroutine/async_gen_fn_iter.rs1
-rw-r--r--tests/ui/diagnostic-width/long-E0308.stderr4
-rw-r--r--tests/ui/did_you_mean/bad-assoc-ty.stderr9
-rw-r--r--tests/ui/drop/missing-drop-method.rs4
-rw-r--r--tests/ui/drop/missing-drop-method.stderr11
-rw-r--r--tests/ui/drop/repeat-drop-2.stderr18
-rw-r--r--tests/ui/error-codes/E0017.rs4
-rw-r--r--tests/ui/error-codes/E0017.stderr33
-rw-r--r--tests/ui/error-codes/E0388.rs6
-rw-r--r--tests/ui/error-codes/E0388.stderr6
-rw-r--r--tests/ui/error-codes/E0396.stderr32
-rw-r--r--tests/ui/extern-flag/empty-extern-arg.stderr9
-rw-r--r--tests/ui/extern/issue-28324.rs1
-rw-r--r--tests/ui/extern/issue-28324.stderr11
-rw-r--r--tests/ui/fmt/ifmt-unimpl.stderr2
-rw-r--r--tests/ui/generic-associated-types/issue-79636-1.rs1
-rw-r--r--tests/ui/generic-associated-types/issue-79636-1.stderr17
-rw-r--r--tests/ui/generic-const-items/trivially-unsatisfied-bounds-0.rs2
-rw-r--r--tests/ui/generic-const-items/trivially-unsatisfied-bounds-0.stderr13
-rw-r--r--tests/ui/impl-trait/equality-in-canonical-query.clone.stderr2
-rw-r--r--tests/ui/impl-trait/rpit/early_bound.rs1
-rw-r--r--tests/ui/impl-trait/rpit/early_bound.stderr14
-rw-r--r--tests/ui/impl-trait/where-allowed.rs1
-rw-r--r--tests/ui/impl-trait/where-allowed.stderr86
-rw-r--r--tests/ui/inference/issue-80409.no-compat.stderr14
-rw-r--r--tests/ui/inference/issue-80409.rs1
-rw-r--r--tests/ui/issues/issue-106755.rs2
-rw-r--r--tests/ui/issues/issue-106755.stderr18
-rw-r--r--tests/ui/issues/issue-17252.rs1
-rw-r--r--tests/ui/issues/issue-17252.stderr21
-rw-r--r--tests/ui/issues/issue-23302-enum-infinite-recursion/issue-23302-3.stderr10
-rw-r--r--tests/ui/issues/issue-30123.stderr5
-rw-r--r--tests/ui/issues/issue-76191.rs1
-rw-r--r--tests/ui/issues/issue-76191.stderr17
-rw-r--r--tests/ui/lazy-type-alias/constrained-late-bound-regions.rs15
-rw-r--r--tests/ui/lazy-type-alias/constrained-params-in-impl.rs (renamed from tests/ui/lazy-type-alias/constrained-params.rs)0
-rw-r--r--tests/ui/lazy-type-alias/unconstrained-late-bound-regions.rs23
-rw-r--r--tests/ui/lazy-type-alias/unconstrained-late-bound-regions.stderr22
-rw-r--r--tests/ui/lazy-type-alias/unconstrained-params-in-impl-due-to-overflow.rs (renamed from tests/ui/lazy-type-alias/unconstrained-param-due-to-overflow.rs)0
-rw-r--r--tests/ui/lazy-type-alias/unconstrained-params-in-impl-due-to-overflow.stderr (renamed from tests/ui/lazy-type-alias/unconstrained-param-due-to-overflow.stderr)2
-rw-r--r--tests/ui/lazy-type-alias/unconstrained-params-in-impl.rs (renamed from tests/ui/lazy-type-alias/unconstrained-params.rs)0
-rw-r--r--tests/ui/lazy-type-alias/unconstrained-params-in-impl.stderr (renamed from tests/ui/lazy-type-alias/unconstrained-params.stderr)2
-rw-r--r--tests/ui/lint/ambiguous_wide_pointer_comparisons_suggestions.fixed13
-rw-r--r--tests/ui/lint/ambiguous_wide_pointer_comparisons_suggestions.rs13
-rw-r--r--tests/ui/lint/ambiguous_wide_pointer_comparisons_suggestions.stderr18
-rw-r--r--tests/ui/lint/unsafe_code/lint-global-asm-as-unsafe.rs20
-rw-r--r--tests/ui/lint/unsafe_code/lint-global-asm-as-unsafe.stderr27
-rw-r--r--tests/ui/liveness/liveness-consts.stderr12
-rw-r--r--tests/ui/parser/bad-recover-kw-after-impl.rs4
-rw-r--r--tests/ui/parser/bad-recover-kw-after-impl.stderr23
-rw-r--r--tests/ui/parser/trait-object-delimiters.rs2
-rw-r--r--tests/ui/parser/trait-object-delimiters.stderr4
-rw-r--r--tests/ui/precondition-checks/out-of-bounds-get-unchecked.rs2
-rw-r--r--tests/ui/proc-macro/custom-attr-panic.rs8
-rw-r--r--tests/ui/proc-macro/custom-attr-panic.stderr10
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/call-const-trait-method-pass.stderr18
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/const-closures.stderr22
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/const-drop-fail.precise.stderr55
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/const-drop.precise.stderr89
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/const-drop.stock.stderr16
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/mbe-const-trait-bound-theoretical-regression.rs13
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/mbe-const-trait-bound-theoretical-regression.stderr40
-rw-r--r--tests/ui/rust-2024/prelude2024.rs9
-rw-r--r--tests/ui/static/static-drop-scope.stderr32
-rw-r--r--tests/ui/statics/issue-14227.rs1
-rw-r--r--tests/ui/statics/issue-14227.stderr11
-rw-r--r--tests/ui/statics/uninhabited-static.rs2
-rw-r--r--tests/ui/statics/uninhabited-static.stderr31
-rw-r--r--tests/ui/traits/issue-77982.stderr1
-rw-r--r--tests/ui/traits/next-solver/coherence-fulfill-overflow.rs15
-rw-r--r--tests/ui/traits/next-solver/coherence-fulfill-overflow.stderr11
-rw-r--r--tests/ui/traits/next-solver/generalize/occurs-check-nested-alias.next.stderr4
-rw-r--r--tests/ui/traits/next-solver/issue-118950-root-region.stderr16
-rw-r--r--tests/ui/traits/non_lifetime_binders/bad-suggestion-on-missing-assoc.rs26
-rw-r--r--tests/ui/traits/non_lifetime_binders/bad-suggestion-on-missing-assoc.stderr34
-rw-r--r--tests/ui/treat-err-as-bug/err.stderr2
-rw-r--r--tests/ui/try-trait/bad-interconversion.stderr1
-rw-r--r--tests/ui/type-alias-impl-trait/impl-trait-in-type-alias-with-bad-substs.rs1
-rw-r--r--tests/ui/type-alias-impl-trait/impl-trait-in-type-alias-with-bad-substs.stderr10
-rw-r--r--tests/ui/type-alias-impl-trait/rpit_tait_equality_in_canonical_query.current.stderr2
-rw-r--r--tests/ui/typeck/cyclic_type_ice.rs7
-rw-r--r--tests/ui/typeck/cyclic_type_ice.stderr31
-rw-r--r--tests/ui/typeck/typeck-default-trait-impl-cross-crate-coherence.rs13
-rw-r--r--tests/ui/typeck/typeck-default-trait-impl-cross-crate-coherence.stderr16
-rw-r--r--tests/ui/typeck/typeck_type_placeholder_item.stderr12
-rw-r--r--tests/ui/ufcs/bad-builder.rs6
-rw-r--r--tests/ui/ufcs/bad-builder.stderr20
-rw-r--r--tests/ui/wf/issue-110157.rs3
-rw-r--r--tests/ui/wf/issue-110157.stderr25
211 files changed, 2009 insertions, 1627 deletions
diff --git a/tests/codegen/simd/issue-120720-reduce-nan.rs b/tests/codegen/simd/issue-120720-reduce-nan.rs
new file mode 100644
index 00000000000..233131aa01c
--- /dev/null
+++ b/tests/codegen/simd/issue-120720-reduce-nan.rs
@@ -0,0 +1,22 @@
+// compile-flags: -C opt-level=3 -C target-cpu=cannonlake
+// only-x86_64
+
+// In a previous implementation, _mm512_reduce_add_pd did the reduction with all fast-math flags
+// enabled, making it UB to reduce a vector containing a NaN.
+
+#![crate_type = "lib"]
+#![feature(stdarch_x86_avx512, avx512_target_feature)]
+use std::arch::x86_64::*;
+
+// CHECK-label: @demo(
+#[no_mangle]
+#[target_feature(enable = "avx512f")] // Function-level target feature mismatches inhibit inlining
+pub unsafe fn demo() -> bool {
+    // CHECK: %0 = tail call reassoc nsz arcp contract double @llvm.vector.reduce.fadd.v8f64(
+    // CHECK: %_0.i = fcmp uno double %0, 0.000000e+00
+    // CHECK: ret i1 %_0.i
+    let res = unsafe {
+        _mm512_reduce_add_pd(_mm512_set_pd(0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, f64::NAN))
+    };
+    res.is_nan()
+}
diff --git a/tests/coverage/closure_macro.cov-map b/tests/coverage/closure_macro.cov-map
index 571e5564b65..e43ed1f76f3 100644
--- a/tests/coverage/closure_macro.cov-map
+++ b/tests/coverage/closure_macro.cov-map
@@ -7,18 +7,17 @@ Number of file 0 mappings: 1
 - Code(Counter(0)) at (prev + 29, 1) to (start + 2, 2)
 
 Function name: closure_macro::main
-Raw bytes (43): 0x[01, 01, 02, 01, 05, 05, 02, 07, 01, 21, 01, 01, 21, 02, 02, 09, 00, 0f, 05, 00, 12, 00, 13, 02, 00, 12, 00, 13, 05, 00, 54, 00, 55, 02, 02, 09, 02, 0b, 07, 03, 01, 00, 02]
+Raw bytes (38): 0x[01, 01, 02, 01, 05, 05, 02, 06, 01, 21, 01, 01, 21, 02, 02, 09, 00, 12, 02, 00, 0f, 00, 54, 05, 00, 54, 00, 55, 02, 02, 09, 02, 0b, 07, 03, 01, 00, 02]
 Number of files: 1
 - file 0 => global file 1
 Number of expressions: 2
 - expression 0 operands: lhs = Counter(0), rhs = Counter(1)
 - expression 1 operands: lhs = Counter(1), rhs = Expression(0, Sub)
-Number of file 0 mappings: 7
+Number of file 0 mappings: 6
 - Code(Counter(0)) at (prev + 33, 1) to (start + 1, 33)
-- Code(Expression(0, Sub)) at (prev + 2, 9) to (start + 0, 15)
+- Code(Expression(0, Sub)) at (prev + 2, 9) to (start + 0, 18)
     = (c0 - c1)
-- Code(Counter(1)) at (prev + 0, 18) to (start + 0, 19)
-- Code(Expression(0, Sub)) at (prev + 0, 18) to (start + 0, 19)
+- Code(Expression(0, Sub)) at (prev + 0, 15) to (start + 0, 84)
     = (c0 - c1)
 - Code(Counter(1)) at (prev + 0, 84) to (start + 0, 85)
 - Code(Expression(0, Sub)) at (prev + 2, 9) to (start + 2, 11)
diff --git a/tests/coverage/closure_macro_async.cov-map b/tests/coverage/closure_macro_async.cov-map
index 49ec767eab3..212b67a8a3e 100644
--- a/tests/coverage/closure_macro_async.cov-map
+++ b/tests/coverage/closure_macro_async.cov-map
@@ -15,18 +15,17 @@ Number of file 0 mappings: 1
 - Code(Counter(0)) at (prev + 35, 1) to (start + 0, 43)
 
 Function name: closure_macro_async::test::{closure#0}
-Raw bytes (43): 0x[01, 01, 02, 01, 05, 05, 02, 07, 01, 23, 2b, 01, 21, 02, 02, 09, 00, 0f, 05, 00, 12, 00, 13, 02, 00, 12, 00, 13, 05, 00, 54, 00, 55, 02, 02, 09, 02, 0b, 07, 03, 01, 00, 02]
+Raw bytes (38): 0x[01, 01, 02, 01, 05, 05, 02, 06, 01, 23, 2b, 01, 21, 02, 02, 09, 00, 12, 02, 00, 0f, 00, 54, 05, 00, 54, 00, 55, 02, 02, 09, 02, 0b, 07, 03, 01, 00, 02]
 Number of files: 1
 - file 0 => global file 1
 Number of expressions: 2
 - expression 0 operands: lhs = Counter(0), rhs = Counter(1)
 - expression 1 operands: lhs = Counter(1), rhs = Expression(0, Sub)
-Number of file 0 mappings: 7
+Number of file 0 mappings: 6
 - Code(Counter(0)) at (prev + 35, 43) to (start + 1, 33)
-- Code(Expression(0, Sub)) at (prev + 2, 9) to (start + 0, 15)
+- Code(Expression(0, Sub)) at (prev + 2, 9) to (start + 0, 18)
     = (c0 - c1)
-- Code(Counter(1)) at (prev + 0, 18) to (start + 0, 19)
-- Code(Expression(0, Sub)) at (prev + 0, 18) to (start + 0, 19)
+- Code(Expression(0, Sub)) at (prev + 0, 15) to (start + 0, 84)
     = (c0 - c1)
 - Code(Counter(1)) at (prev + 0, 84) to (start + 0, 85)
 - Code(Expression(0, Sub)) at (prev + 2, 9) to (start + 2, 11)
diff --git a/tests/debuginfo/mutex.rs b/tests/debuginfo/mutex.rs
index 7a58c5c2224..ab9fb8b7e81 100644
--- a/tests/debuginfo/mutex.rs
+++ b/tests/debuginfo/mutex.rs
@@ -10,7 +10,7 @@
 //
 // cdb-command:dx m,d
 // cdb-check:m,d              [Type: std::sync::mutex::Mutex<i32>]
-// cdb-check:    [...] inner            [Type: std::sys::pal::windows::locks::mutex::Mutex]
+// cdb-check:    [...] inner            [Type: std::sys::locks::mutex::windows::Mutex]
 // cdb-check:    [...] poison           [Type: std::sync::poison::Flag]
 // cdb-check:    [...] data             : 0 [Type: core::cell::UnsafeCell<i32>]
 
diff --git a/tests/debuginfo/rwlock-read.rs b/tests/debuginfo/rwlock-read.rs
index 4ed1ebd0b37..7e9838871ba 100644
--- a/tests/debuginfo/rwlock-read.rs
+++ b/tests/debuginfo/rwlock-read.rs
@@ -16,7 +16,7 @@
 // cdb-command:dx r
 // cdb-check:r                [Type: std::sync::rwlock::RwLockReadGuard<i32>]
 // cdb-check:    [...] data             : NonNull([...]: 0) [Type: core::ptr::non_null::NonNull<i32>]
-// cdb-check:    [...] inner_lock       : [...] [Type: std::sys::pal::windows::locks::rwlock::RwLock *]
+// cdb-check:    [...] inner_lock       : [...] [Type: std::sys::locks::rwlock::windows::RwLock *]
 
 #[allow(unused_variables)]
 
diff --git a/tests/mir-opt/building/issue_101867.main.built.after.mir b/tests/mir-opt/building/issue_101867.main.built.after.mir
index 028d7ee7cd8..19a777cb03b 100644
--- a/tests/mir-opt/building/issue_101867.main.built.after.mir
+++ b/tests/mir-opt/building/issue_101867.main.built.after.mir
@@ -27,13 +27,13 @@ fn main() -> () {
         StorageLive(_5);
         PlaceMention(_1);
         _6 = discriminant(_1);
-        switchInt(move _6) -> [1: bb5, otherwise: bb4];
+        switchInt(move _6) -> [1: bb6, otherwise: bb4];
     }
 
     bb1: {
         StorageLive(_3);
         StorageLive(_4);
-        _4 = begin_panic::<&str>(const "explicit panic") -> bb8;
+        _4 = begin_panic::<&str>(const "explicit panic") -> bb10;
     }
 
     bb2: {
@@ -48,14 +48,22 @@ fn main() -> () {
     }
 
     bb4: {
-        goto -> bb7;
+        goto -> bb9;
     }
 
     bb5: {
-        falseEdge -> [real: bb6, imaginary: bb4];
+        goto -> bb3;
     }
 
     bb6: {
+        falseEdge -> [real: bb8, imaginary: bb4];
+    }
+
+    bb7: {
+        goto -> bb4;
+    }
+
+    bb8: {
         _5 = ((_1 as Some).0: u8);
         _0 = const ();
         StorageDead(_5);
@@ -63,12 +71,12 @@ fn main() -> () {
         return;
     }
 
-    bb7: {
+    bb9: {
         StorageDead(_5);
         goto -> bb1;
     }
 
-    bb8 (cleanup): {
+    bb10 (cleanup): {
         resume;
     }
 }
diff --git a/tests/mir-opt/building/issue_49232.main.built.after.mir b/tests/mir-opt/building/issue_49232.main.built.after.mir
index 7c1f5a6ec72..d09a1748a8b 100644
--- a/tests/mir-opt/building/issue_49232.main.built.after.mir
+++ b/tests/mir-opt/building/issue_49232.main.built.after.mir
@@ -17,7 +17,7 @@ fn main() -> () {
     }
 
     bb1: {
-        falseUnwind -> [real: bb2, unwind: bb12];
+        falseUnwind -> [real: bb2, unwind: bb14];
     }
 
     bb2: {
@@ -25,7 +25,7 @@ fn main() -> () {
         StorageLive(_3);
         _3 = const true;
         PlaceMention(_3);
-        switchInt(_3) -> [0: bb4, otherwise: bb5];
+        switchInt(_3) -> [0: bb4, otherwise: bb6];
     }
 
     bb3: {
@@ -34,37 +34,45 @@ fn main() -> () {
     }
 
     bb4: {
-        falseEdge -> [real: bb6, imaginary: bb5];
+        falseEdge -> [real: bb8, imaginary: bb6];
     }
 
     bb5: {
-        _0 = const ();
-        goto -> bb11;
+        goto -> bb3;
     }
 
     bb6: {
-        _2 = const 4_i32;
-        goto -> bb9;
+        _0 = const ();
+        goto -> bb13;
     }
 
     bb7: {
-        unreachable;
+        goto -> bb3;
     }
 
     bb8: {
-        goto -> bb9;
+        _2 = const 4_i32;
+        goto -> bb11;
     }
 
     bb9: {
+        unreachable;
+    }
+
+    bb10: {
+        goto -> bb11;
+    }
+
+    bb11: {
         FakeRead(ForLet(None), _2);
         StorageDead(_3);
         StorageLive(_5);
         StorageLive(_6);
         _6 = &_2;
-        _5 = std::mem::drop::<&i32>(move _6) -> [return: bb10, unwind: bb12];
+        _5 = std::mem::drop::<&i32>(move _6) -> [return: bb12, unwind: bb14];
     }
 
-    bb10: {
+    bb12: {
         StorageDead(_6);
         StorageDead(_5);
         _1 = const ();
@@ -72,13 +80,13 @@ fn main() -> () {
         goto -> bb1;
     }
 
-    bb11: {
+    bb13: {
         StorageDead(_3);
         StorageDead(_2);
         return;
     }
 
-    bb12 (cleanup): {
+    bb14 (cleanup): {
         resume;
     }
 }
diff --git a/tests/mir-opt/building/logical_or_in_conditional.test_complex.built.after.mir b/tests/mir-opt/building/logical_or_in_conditional.test_complex.built.after.mir
index d7c758d8876..89572177b1d 100644
--- a/tests/mir-opt/building/logical_or_in_conditional.test_complex.built.after.mir
+++ b/tests/mir-opt/building/logical_or_in_conditional.test_complex.built.after.mir
@@ -19,13 +19,13 @@ fn test_complex() -> () {
     bb0: {
         StorageLive(_1);
         StorageLive(_2);
-        _2 = E::f() -> [return: bb1, unwind: bb33];
+        _2 = E::f() -> [return: bb1, unwind: bb37];
     }
 
     bb1: {
         PlaceMention(_2);
         _3 = discriminant(_2);
-        switchInt(move _3) -> [0: bb4, otherwise: bb3];
+        switchInt(move _3) -> [0: bb5, otherwise: bb3];
     }
 
     bb2: {
@@ -34,163 +34,179 @@ fn test_complex() -> () {
     }
 
     bb3: {
-        goto -> bb20;
+        goto -> bb22;
     }
 
     bb4: {
-        falseEdge -> [real: bb5, imaginary: bb3];
+        goto -> bb2;
     }
 
     bb5: {
-        StorageLive(_4);
-        _4 = always_true() -> [return: bb6, unwind: bb33];
+        falseEdge -> [real: bb7, imaginary: bb3];
     }
 
     bb6: {
-        switchInt(move _4) -> [0: bb8, otherwise: bb7];
+        goto -> bb3;
     }
 
     bb7: {
+        StorageLive(_4);
+        _4 = always_true() -> [return: bb8, unwind: bb37];
+    }
+
+    bb8: {
+        switchInt(move _4) -> [0: bb10, otherwise: bb9];
+    }
+
+    bb9: {
         StorageLive(_5);
         StorageLive(_6);
         StorageLive(_7);
         _7 = Droppy(const 0_u8);
         _6 = (_7.0: u8);
         _5 = Gt(move _6, const 0_u8);
-        switchInt(move _5) -> [0: bb10, otherwise: bb9];
+        switchInt(move _5) -> [0: bb12, otherwise: bb11];
     }
 
-    bb8: {
-        goto -> bb14;
+    bb10: {
+        goto -> bb16;
     }
 
-    bb9: {
-        drop(_7) -> [return: bb11, unwind: bb33];
+    bb11: {
+        drop(_7) -> [return: bb13, unwind: bb37];
     }
 
-    bb10: {
-        goto -> bb12;
+    bb12: {
+        goto -> bb14;
     }
 
-    bb11: {
+    bb13: {
         StorageDead(_7);
         StorageDead(_6);
-        goto -> bb17;
+        goto -> bb19;
     }
 
-    bb12: {
-        drop(_7) -> [return: bb13, unwind: bb33];
+    bb14: {
+        drop(_7) -> [return: bb15, unwind: bb37];
     }
 
-    bb13: {
+    bb15: {
         StorageDead(_7);
         StorageDead(_6);
-        goto -> bb14;
+        goto -> bb16;
     }
 
-    bb14: {
+    bb16: {
         StorageLive(_8);
         StorageLive(_9);
         StorageLive(_10);
         _10 = Droppy(const 1_u8);
         _9 = (_10.0: u8);
         _8 = Gt(move _9, const 1_u8);
-        switchInt(move _8) -> [0: bb16, otherwise: bb15];
+        switchInt(move _8) -> [0: bb18, otherwise: bb17];
     }
 
-    bb15: {
-        drop(_10) -> [return: bb17, unwind: bb33];
+    bb17: {
+        drop(_10) -> [return: bb19, unwind: bb37];
     }
 
-    bb16: {
-        goto -> bb18;
+    bb18: {
+        goto -> bb20;
     }
 
-    bb17: {
+    bb19: {
         StorageDead(_10);
         StorageDead(_9);
         _1 = const ();
-        goto -> bb21;
+        goto -> bb23;
     }
 
-    bb18: {
-        drop(_10) -> [return: bb19, unwind: bb33];
+    bb20: {
+        drop(_10) -> [return: bb21, unwind: bb37];
     }
 
-    bb19: {
+    bb21: {
         StorageDead(_10);
         StorageDead(_9);
-        goto -> bb20;
+        goto -> bb22;
     }
 
-    bb20: {
+    bb22: {
         _1 = const ();
-        goto -> bb21;
+        goto -> bb23;
     }
 
-    bb21: {
+    bb23: {
         StorageDead(_8);
         StorageDead(_5);
         StorageDead(_4);
         StorageDead(_2);
         StorageDead(_1);
         StorageLive(_11);
-        _11 = always_true() -> [return: bb22, unwind: bb33];
+        _11 = always_true() -> [return: bb24, unwind: bb37];
     }
 
-    bb22: {
-        switchInt(move _11) -> [0: bb24, otherwise: bb23];
+    bb24: {
+        switchInt(move _11) -> [0: bb26, otherwise: bb25];
     }
 
-    bb23: {
-        goto -> bb31;
+    bb25: {
+        goto -> bb35;
     }
 
-    bb24: {
-        goto -> bb25;
+    bb26: {
+        goto -> bb27;
     }
 
-    bb25: {
+    bb27: {
         StorageLive(_12);
-        _12 = E::f() -> [return: bb26, unwind: bb33];
+        _12 = E::f() -> [return: bb28, unwind: bb37];
     }
 
-    bb26: {
+    bb28: {
         PlaceMention(_12);
         _13 = discriminant(_12);
-        switchInt(move _13) -> [1: bb29, otherwise: bb28];
+        switchInt(move _13) -> [1: bb32, otherwise: bb30];
     }
 
-    bb27: {
+    bb29: {
         FakeRead(ForMatchedPlace(None), _12);
         unreachable;
     }
 
-    bb28: {
-        goto -> bb31;
+    bb30: {
+        goto -> bb35;
     }
 
-    bb29: {
-        falseEdge -> [real: bb30, imaginary: bb28];
+    bb31: {
+        goto -> bb29;
     }
 
-    bb30: {
+    bb32: {
+        falseEdge -> [real: bb34, imaginary: bb30];
+    }
+
+    bb33: {
+        goto -> bb30;
+    }
+
+    bb34: {
         _0 = const ();
-        goto -> bb32;
+        goto -> bb36;
     }
 
-    bb31: {
+    bb35: {
         _0 = const ();
-        goto -> bb32;
+        goto -> bb36;
     }
 
-    bb32: {
+    bb36: {
         StorageDead(_11);
         StorageDead(_12);
         return;
     }
 
-    bb33 (cleanup): {
+    bb37 (cleanup): {
         resume;
     }
 }
diff --git a/tests/mir-opt/building/match_false_edges.full_tested_match.built.after.mir b/tests/mir-opt/building/match_false_edges.full_tested_match.built.after.mir
index 88292dd0597..4e91eb6f76f 100644
--- a/tests/mir-opt/building/match_false_edges.full_tested_match.built.after.mir
+++ b/tests/mir-opt/building/match_false_edges.full_tested_match.built.after.mir
@@ -28,7 +28,7 @@ fn full_tested_match() -> () {
         _2 = Option::<i32>::Some(const 42_i32);
         PlaceMention(_2);
         _3 = discriminant(_2);
-        switchInt(move _3) -> [0: bb2, 1: bb3, otherwise: bb1];
+        switchInt(move _3) -> [0: bb2, 1: bb4, otherwise: bb1];
     }
 
     bb1: {
@@ -38,30 +38,38 @@ fn full_tested_match() -> () {
 
     bb2: {
         _1 = (const 3_i32, const 3_i32);
-        goto -> bb11;
+        goto -> bb13;
     }
 
     bb3: {
-        falseEdge -> [real: bb5, imaginary: bb4];
+        goto -> bb1;
     }
 
     bb4: {
-        falseEdge -> [real: bb10, imaginary: bb2];
+        falseEdge -> [real: bb7, imaginary: bb5];
     }
 
     bb5: {
+        falseEdge -> [real: bb12, imaginary: bb2];
+    }
+
+    bb6: {
+        goto -> bb1;
+    }
+
+    bb7: {
         StorageLive(_6);
         _6 = &((_2 as Some).0: i32);
         _4 = &fake _2;
         StorageLive(_7);
-        _7 = guard() -> [return: bb6, unwind: bb13];
+        _7 = guard() -> [return: bb8, unwind: bb16];
     }
 
-    bb6: {
-        switchInt(move _7) -> [0: bb8, otherwise: bb7];
+    bb8: {
+        switchInt(move _7) -> [0: bb10, otherwise: bb9];
     }
 
-    bb7: {
+    bb9: {
         StorageDead(_7);
         FakeRead(ForMatchGuard, _4);
         FakeRead(ForGuardBinding, _6);
@@ -73,20 +81,20 @@ fn full_tested_match() -> () {
         StorageDead(_8);
         StorageDead(_5);
         StorageDead(_6);
-        goto -> bb11;
+        goto -> bb13;
     }
 
-    bb8: {
-        goto -> bb9;
+    bb10: {
+        goto -> bb11;
     }
 
-    bb9: {
+    bb11: {
         StorageDead(_7);
         StorageDead(_6);
-        goto -> bb4;
+        goto -> bb5;
     }
 
-    bb10: {
+    bb12: {
         StorageLive(_9);
         _9 = ((_2 as Some).0: i32);
         StorageLive(_10);
@@ -94,10 +102,10 @@ fn full_tested_match() -> () {
         _1 = (const 2_i32, move _10);
         StorageDead(_10);
         StorageDead(_9);
-        goto -> bb11;
+        goto -> bb13;
     }
 
-    bb11: {
+    bb13: {
         PlaceMention(_1);
         StorageDead(_2);
         StorageDead(_1);
@@ -105,12 +113,16 @@ fn full_tested_match() -> () {
         return;
     }
 
-    bb12: {
+    bb14: {
         FakeRead(ForMatchedPlace(None), _1);
         unreachable;
     }
 
-    bb13 (cleanup): {
+    bb15: {
+        goto -> bb14;
+    }
+
+    bb16 (cleanup): {
         resume;
     }
 }
diff --git a/tests/mir-opt/building/match_false_edges.full_tested_match2.built.after.mir b/tests/mir-opt/building/match_false_edges.full_tested_match2.built.after.mir
index 205bb4980d9..0c67cc9f71e 100644
--- a/tests/mir-opt/building/match_false_edges.full_tested_match2.built.after.mir
+++ b/tests/mir-opt/building/match_false_edges.full_tested_match2.built.after.mir
@@ -28,7 +28,7 @@ fn full_tested_match2() -> () {
         _2 = Option::<i32>::Some(const 42_i32);
         PlaceMention(_2);
         _3 = discriminant(_2);
-        switchInt(move _3) -> [0: bb2, 1: bb3, otherwise: bb1];
+        switchInt(move _3) -> [0: bb2, 1: bb4, otherwise: bb1];
     }
 
     bb1: {
@@ -37,14 +37,18 @@ fn full_tested_match2() -> () {
     }
 
     bb2: {
-        falseEdge -> [real: bb10, imaginary: bb4];
+        falseEdge -> [real: bb12, imaginary: bb5];
     }
 
     bb3: {
-        falseEdge -> [real: bb5, imaginary: bb2];
+        goto -> bb1;
     }
 
     bb4: {
+        falseEdge -> [real: bb7, imaginary: bb2];
+    }
+
+    bb5: {
         StorageLive(_9);
         _9 = ((_2 as Some).0: i32);
         StorageLive(_10);
@@ -52,22 +56,26 @@ fn full_tested_match2() -> () {
         _1 = (const 2_i32, move _10);
         StorageDead(_10);
         StorageDead(_9);
-        goto -> bb11;
+        goto -> bb13;
     }
 
-    bb5: {
+    bb6: {
+        goto -> bb1;
+    }
+
+    bb7: {
         StorageLive(_6);
         _6 = &((_2 as Some).0: i32);
         _4 = &fake _2;
         StorageLive(_7);
-        _7 = guard() -> [return: bb6, unwind: bb13];
+        _7 = guard() -> [return: bb8, unwind: bb16];
     }
 
-    bb6: {
-        switchInt(move _7) -> [0: bb8, otherwise: bb7];
+    bb8: {
+        switchInt(move _7) -> [0: bb10, otherwise: bb9];
     }
 
-    bb7: {
+    bb9: {
         StorageDead(_7);
         FakeRead(ForMatchGuard, _4);
         FakeRead(ForGuardBinding, _6);
@@ -79,25 +87,25 @@ fn full_tested_match2() -> () {
         StorageDead(_8);
         StorageDead(_5);
         StorageDead(_6);
-        goto -> bb11;
+        goto -> bb13;
     }
 
-    bb8: {
-        goto -> bb9;
+    bb10: {
+        goto -> bb11;
     }
 
-    bb9: {
+    bb11: {
         StorageDead(_7);
         StorageDead(_6);
-        falseEdge -> [real: bb4, imaginary: bb2];
+        falseEdge -> [real: bb5, imaginary: bb2];
     }
 
-    bb10: {
+    bb12: {
         _1 = (const 3_i32, const 3_i32);
-        goto -> bb11;
+        goto -> bb13;
     }
 
-    bb11: {
+    bb13: {
         PlaceMention(_1);
         StorageDead(_2);
         StorageDead(_1);
@@ -105,12 +113,16 @@ fn full_tested_match2() -> () {
         return;
     }
 
-    bb12: {
+    bb14: {
         FakeRead(ForMatchedPlace(None), _1);
         unreachable;
     }
 
-    bb13 (cleanup): {
+    bb15: {
+        goto -> bb14;
+    }
+
+    bb16 (cleanup): {
         resume;
     }
 }
diff --git a/tests/mir-opt/building/match_false_edges.main.built.after.mir b/tests/mir-opt/building/match_false_edges.main.built.after.mir
index 21f377a6404..b71b2412cdf 100644
--- a/tests/mir-opt/building/match_false_edges.main.built.after.mir
+++ b/tests/mir-opt/building/match_false_edges.main.built.after.mir
@@ -39,7 +39,7 @@ fn main() -> () {
         _2 = Option::<i32>::Some(const 1_i32);
         PlaceMention(_2);
         _4 = discriminant(_2);
-        switchInt(move _4) -> [1: bb7, otherwise: bb2];
+        switchInt(move _4) -> [1: bb8, otherwise: bb2];
     }
 
     bb1: {
@@ -48,12 +48,12 @@ fn main() -> () {
     }
 
     bb2: {
-        falseEdge -> [real: bb14, imaginary: bb5];
+        falseEdge -> [real: bb15, imaginary: bb6];
     }
 
     bb3: {
         _3 = discriminant(_2);
-        switchInt(move _3) -> [1: bb5, otherwise: bb4];
+        switchInt(move _3) -> [1: bb6, otherwise: bb4];
     }
 
     bb4: {
@@ -61,38 +61,42 @@ fn main() -> () {
         _14 = _2;
         _1 = const 4_i32;
         StorageDead(_14);
-        goto -> bb20;
+        goto -> bb21;
     }
 
     bb5: {
-        falseEdge -> [real: bb15, imaginary: bb4];
+        goto -> bb1;
     }
 
     bb6: {
-        goto -> bb4;
+        falseEdge -> [real: bb16, imaginary: bb4];
     }
 
     bb7: {
-        falseEdge -> [real: bb9, imaginary: bb2];
+        goto -> bb4;
     }
 
     bb8: {
-        goto -> bb2;
+        falseEdge -> [real: bb10, imaginary: bb2];
     }
 
     bb9: {
+        goto -> bb2;
+    }
+
+    bb10: {
         StorageLive(_7);
         _7 = &((_2 as Some).0: i32);
         _5 = &fake _2;
         StorageLive(_8);
-        _8 = guard() -> [return: bb10, unwind: bb22];
+        _8 = guard() -> [return: bb11, unwind: bb24];
     }
 
-    bb10: {
-        switchInt(move _8) -> [0: bb12, otherwise: bb11];
+    bb11: {
+        switchInt(move _8) -> [0: bb13, otherwise: bb12];
     }
 
-    bb11: {
+    bb12: {
         StorageDead(_8);
         FakeRead(ForMatchGuard, _5);
         FakeRead(ForGuardBinding, _7);
@@ -101,42 +105,42 @@ fn main() -> () {
         _1 = const 1_i32;
         StorageDead(_6);
         StorageDead(_7);
-        goto -> bb20;
+        goto -> bb21;
     }
 
-    bb12: {
-        goto -> bb13;
+    bb13: {
+        goto -> bb14;
     }
 
-    bb13: {
+    bb14: {
         StorageDead(_8);
         StorageDead(_7);
-        falseEdge -> [real: bb8, imaginary: bb2];
+        falseEdge -> [real: bb9, imaginary: bb2];
     }
 
-    bb14: {
+    bb15: {
         StorageLive(_9);
         _9 = _2;
         _1 = const 2_i32;
         StorageDead(_9);
-        goto -> bb20;
+        goto -> bb21;
     }
 
-    bb15: {
+    bb16: {
         StorageLive(_11);
         _11 = &((_2 as Some).0: i32);
         _5 = &fake _2;
         StorageLive(_12);
         StorageLive(_13);
         _13 = (*_11);
-        _12 = guard2(move _13) -> [return: bb16, unwind: bb22];
+        _12 = guard2(move _13) -> [return: bb17, unwind: bb24];
     }
 
-    bb16: {
-        switchInt(move _12) -> [0: bb18, otherwise: bb17];
+    bb17: {
+        switchInt(move _12) -> [0: bb19, otherwise: bb18];
     }
 
-    bb17: {
+    bb18: {
         StorageDead(_13);
         StorageDead(_12);
         FakeRead(ForMatchGuard, _5);
@@ -146,21 +150,21 @@ fn main() -> () {
         _1 = const 3_i32;
         StorageDead(_10);
         StorageDead(_11);
-        goto -> bb20;
+        goto -> bb21;
     }
 
-    bb18: {
-        goto -> bb19;
+    bb19: {
+        goto -> bb20;
     }
 
-    bb19: {
+    bb20: {
         StorageDead(_13);
         StorageDead(_12);
         StorageDead(_11);
-        falseEdge -> [real: bb6, imaginary: bb4];
+        falseEdge -> [real: bb7, imaginary: bb4];
     }
 
-    bb20: {
+    bb21: {
         PlaceMention(_1);
         StorageDead(_2);
         StorageDead(_1);
@@ -168,12 +172,16 @@ fn main() -> () {
         return;
     }
 
-    bb21: {
+    bb22: {
         FakeRead(ForMatchedPlace(None), _1);
         unreachable;
     }
 
-    bb22 (cleanup): {
+    bb23: {
+        goto -> bb22;
+    }
+
+    bb24 (cleanup): {
         resume;
     }
 }
diff --git a/tests/mir-opt/building/simple_match.match_bool.built.after.mir b/tests/mir-opt/building/simple_match.match_bool.built.after.mir
index cd51c942bee..faa2456fd10 100644
--- a/tests/mir-opt/building/simple_match.match_bool.built.after.mir
+++ b/tests/mir-opt/building/simple_match.match_bool.built.after.mir
@@ -6,7 +6,7 @@ fn match_bool(_1: bool) -> usize {
 
     bb0: {
         PlaceMention(_1);
-        switchInt(_1) -> [0: bb2, otherwise: bb3];
+        switchInt(_1) -> [0: bb2, otherwise: bb4];
     }
 
     bb1: {
@@ -16,19 +16,27 @@ fn match_bool(_1: bool) -> usize {
 
     bb2: {
         _0 = const 20_usize;
-        goto -> bb5;
+        goto -> bb7;
     }
 
     bb3: {
-        falseEdge -> [real: bb4, imaginary: bb2];
+        goto -> bb1;
     }
 
     bb4: {
-        _0 = const 10_usize;
-        goto -> bb5;
+        falseEdge -> [real: bb6, imaginary: bb2];
     }
 
     bb5: {
+        goto -> bb2;
+    }
+
+    bb6: {
+        _0 = const 10_usize;
+        goto -> bb7;
+    }
+
+    bb7: {
         return;
     }
 }
diff --git a/tests/mir-opt/building/uniform_array_move_out.move_out_by_subslice.built.after.mir b/tests/mir-opt/building/uniform_array_move_out.move_out_by_subslice.built.after.mir
index 282c9704ffc..128af9c5602 100644
--- a/tests/mir-opt/building/uniform_array_move_out.move_out_by_subslice.built.after.mir
+++ b/tests/mir-opt/building/uniform_array_move_out.move_out_by_subslice.built.after.mir
@@ -30,7 +30,7 @@ fn move_out_by_subslice() -> () {
         StorageLive(_2);
         _3 = SizeOf(i32);
         _4 = AlignOf(i32);
-        _5 = alloc::alloc::exchange_malloc(move _3, move _4) -> [return: bb1, unwind: bb13];
+        _5 = alloc::alloc::exchange_malloc(move _3, move _4) -> [return: bb1, unwind: bb14];
     }
 
     bb1: {
@@ -38,7 +38,7 @@ fn move_out_by_subslice() -> () {
         _6 = ShallowInitBox(move _5, i32);
         (*_6) = const 1_i32;
         _2 = move _6;
-        drop(_6) -> [return: bb2, unwind: bb12];
+        drop(_6) -> [return: bb2, unwind: bb13];
     }
 
     bb2: {
@@ -46,7 +46,7 @@ fn move_out_by_subslice() -> () {
         StorageLive(_7);
         _8 = SizeOf(i32);
         _9 = AlignOf(i32);
-        _10 = alloc::alloc::exchange_malloc(move _8, move _9) -> [return: bb3, unwind: bb12];
+        _10 = alloc::alloc::exchange_malloc(move _8, move _9) -> [return: bb3, unwind: bb13];
     }
 
     bb3: {
@@ -54,18 +54,18 @@ fn move_out_by_subslice() -> () {
         _11 = ShallowInitBox(move _10, i32);
         (*_11) = const 2_i32;
         _7 = move _11;
-        drop(_11) -> [return: bb4, unwind: bb11];
+        drop(_11) -> [return: bb4, unwind: bb12];
     }
 
     bb4: {
         StorageDead(_11);
         _1 = [move _2, move _7];
-        drop(_7) -> [return: bb5, unwind: bb12];
+        drop(_7) -> [return: bb5, unwind: bb13];
     }
 
     bb5: {
         StorageDead(_7);
-        drop(_2) -> [return: bb6, unwind: bb13];
+        drop(_2) -> [return: bb6, unwind: bb14];
     }
 
     bb6: {
@@ -75,7 +75,7 @@ fn move_out_by_subslice() -> () {
         StorageLive(_12);
         _12 = move _1[0..2];
         _0 = const ();
-        drop(_12) -> [return: bb8, unwind: bb10];
+        drop(_12) -> [return: bb9, unwind: bb11];
     }
 
     bb7: {
@@ -84,28 +84,32 @@ fn move_out_by_subslice() -> () {
     }
 
     bb8: {
-        StorageDead(_12);
-        drop(_1) -> [return: bb9, unwind: bb13];
+        goto -> bb7;
     }
 
     bb9: {
-        StorageDead(_1);
-        return;
+        StorageDead(_12);
+        drop(_1) -> [return: bb10, unwind: bb14];
     }
 
-    bb10 (cleanup): {
-        drop(_1) -> [return: bb13, unwind terminate(cleanup)];
+    bb10: {
+        StorageDead(_1);
+        return;
     }
 
     bb11 (cleanup): {
-        drop(_7) -> [return: bb12, unwind terminate(cleanup)];
+        drop(_1) -> [return: bb14, unwind terminate(cleanup)];
     }
 
     bb12 (cleanup): {
-        drop(_2) -> [return: bb13, unwind terminate(cleanup)];
+        drop(_7) -> [return: bb13, unwind terminate(cleanup)];
     }
 
     bb13 (cleanup): {
+        drop(_2) -> [return: bb14, unwind terminate(cleanup)];
+    }
+
+    bb14 (cleanup): {
         resume;
     }
 }
diff --git a/tests/mir-opt/building/uniform_array_move_out.move_out_from_end.built.after.mir b/tests/mir-opt/building/uniform_array_move_out.move_out_from_end.built.after.mir
index d1956c91b88..d50a6872a41 100644
--- a/tests/mir-opt/building/uniform_array_move_out.move_out_from_end.built.after.mir
+++ b/tests/mir-opt/building/uniform_array_move_out.move_out_from_end.built.after.mir
@@ -30,7 +30,7 @@ fn move_out_from_end() -> () {
         StorageLive(_2);
         _3 = SizeOf(i32);
         _4 = AlignOf(i32);
-        _5 = alloc::alloc::exchange_malloc(move _3, move _4) -> [return: bb1, unwind: bb13];
+        _5 = alloc::alloc::exchange_malloc(move _3, move _4) -> [return: bb1, unwind: bb14];
     }
 
     bb1: {
@@ -38,7 +38,7 @@ fn move_out_from_end() -> () {
         _6 = ShallowInitBox(move _5, i32);
         (*_6) = const 1_i32;
         _2 = move _6;
-        drop(_6) -> [return: bb2, unwind: bb12];
+        drop(_6) -> [return: bb2, unwind: bb13];
     }
 
     bb2: {
@@ -46,7 +46,7 @@ fn move_out_from_end() -> () {
         StorageLive(_7);
         _8 = SizeOf(i32);
         _9 = AlignOf(i32);
-        _10 = alloc::alloc::exchange_malloc(move _8, move _9) -> [return: bb3, unwind: bb12];
+        _10 = alloc::alloc::exchange_malloc(move _8, move _9) -> [return: bb3, unwind: bb13];
     }
 
     bb3: {
@@ -54,18 +54,18 @@ fn move_out_from_end() -> () {
         _11 = ShallowInitBox(move _10, i32);
         (*_11) = const 2_i32;
         _7 = move _11;
-        drop(_11) -> [return: bb4, unwind: bb11];
+        drop(_11) -> [return: bb4, unwind: bb12];
     }
 
     bb4: {
         StorageDead(_11);
         _1 = [move _2, move _7];
-        drop(_7) -> [return: bb5, unwind: bb12];
+        drop(_7) -> [return: bb5, unwind: bb13];
     }
 
     bb5: {
         StorageDead(_7);
-        drop(_2) -> [return: bb6, unwind: bb13];
+        drop(_2) -> [return: bb6, unwind: bb14];
     }
 
     bb6: {
@@ -75,7 +75,7 @@ fn move_out_from_end() -> () {
         StorageLive(_12);
         _12 = move _1[1 of 2];
         _0 = const ();
-        drop(_12) -> [return: bb8, unwind: bb10];
+        drop(_12) -> [return: bb9, unwind: bb11];
     }
 
     bb7: {
@@ -84,28 +84,32 @@ fn move_out_from_end() -> () {
     }
 
     bb8: {
-        StorageDead(_12);
-        drop(_1) -> [return: bb9, unwind: bb13];
+        goto -> bb7;
     }
 
     bb9: {
-        StorageDead(_1);
-        return;
+        StorageDead(_12);
+        drop(_1) -> [return: bb10, unwind: bb14];
     }
 
-    bb10 (cleanup): {
-        drop(_1) -> [return: bb13, unwind terminate(cleanup)];
+    bb10: {
+        StorageDead(_1);
+        return;
     }
 
     bb11 (cleanup): {
-        drop(_7) -> [return: bb12, unwind terminate(cleanup)];
+        drop(_1) -> [return: bb14, unwind terminate(cleanup)];
     }
 
     bb12 (cleanup): {
-        drop(_2) -> [return: bb13, unwind terminate(cleanup)];
+        drop(_7) -> [return: bb13, unwind terminate(cleanup)];
     }
 
     bb13 (cleanup): {
+        drop(_2) -> [return: bb14, unwind terminate(cleanup)];
+    }
+
+    bb14 (cleanup): {
         resume;
     }
 }
diff --git a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-abort.diff b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-abort.diff
index 80191a21f4f..e6b8d5e6c21 100644
--- a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-abort.diff
+++ b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-abort.diff
@@ -17,26 +17,28 @@
           scope 4 (inlined Unique::<[bool; 0]>::dangling) {
               let mut _5: std::ptr::NonNull<[bool; 0]>;
               scope 5 (inlined NonNull::<[bool; 0]>::dangling) {
-                  let mut _7: usize;
                   scope 6 {
                       let _6: *mut [bool; 0];
                       scope 7 {
                           debug ptr => _6;
-                          scope 11 (inlined NonNull::<[bool; 0]>::new_unchecked) {
+                          scope 12 (inlined NonNull::<[bool; 0]>::new_unchecked) {
                               debug ptr => _6;
                               let mut _8: bool;
                               let _9: ();
                               let mut _10: *mut ();
                               let mut _11: *const [bool; 0];
-                              scope 12 {
+                              scope 13 {
                               }
                           }
                       }
-                      scope 8 (inlined align_of::<[bool; 0]>) {
-                      }
-                      scope 9 (inlined invalid_mut::<[bool; 0]>) {
-                          debug addr => _7;
-                          scope 10 {
+                      scope 8 (inlined dangling_mut::<[bool; 0]>) {
+                          let mut _7: usize;
+                          scope 9 (inlined align_of::<[bool; 0]>) {
+                          }
+                          scope 10 (inlined without_provenance_mut::<[bool; 0]>) {
+                              debug addr => _7;
+                              scope 11 {
+                              }
                           }
                       }
                   }
diff --git a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-unwind.diff b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-unwind.diff
index ed878978e4b..bd74591018b 100644
--- a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-unwind.diff
+++ b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-unwind.diff
@@ -17,26 +17,28 @@
           scope 4 (inlined Unique::<[bool; 0]>::dangling) {
               let mut _5: std::ptr::NonNull<[bool; 0]>;
               scope 5 (inlined NonNull::<[bool; 0]>::dangling) {
-                  let mut _7: usize;
                   scope 6 {
                       let _6: *mut [bool; 0];
                       scope 7 {
                           debug ptr => _6;
-                          scope 11 (inlined NonNull::<[bool; 0]>::new_unchecked) {
+                          scope 12 (inlined NonNull::<[bool; 0]>::new_unchecked) {
                               debug ptr => _6;
                               let mut _8: bool;
                               let _9: ();
                               let mut _10: *mut ();
                               let mut _11: *const [bool; 0];
-                              scope 12 {
+                              scope 13 {
                               }
                           }
                       }
-                      scope 8 (inlined align_of::<[bool; 0]>) {
-                      }
-                      scope 9 (inlined invalid_mut::<[bool; 0]>) {
-                          debug addr => _7;
-                          scope 10 {
+                      scope 8 (inlined dangling_mut::<[bool; 0]>) {
+                          let mut _7: usize;
+                          scope 9 (inlined align_of::<[bool; 0]>) {
+                          }
+                          scope 10 (inlined without_provenance_mut::<[bool; 0]>) {
+                              debug addr => _7;
+                              scope 11 {
+                              }
                           }
                       }
                   }
diff --git a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-abort.diff b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-abort.diff
index a61902501bf..fdbb0b2df03 100644
--- a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-abort.diff
+++ b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-abort.diff
@@ -17,26 +17,28 @@
           scope 4 (inlined Unique::<[bool; 0]>::dangling) {
               let mut _5: std::ptr::NonNull<[bool; 0]>;
               scope 5 (inlined NonNull::<[bool; 0]>::dangling) {
-                  let mut _7: usize;
                   scope 6 {
                       let _6: *mut [bool; 0];
                       scope 7 {
                           debug ptr => _6;
-                          scope 11 (inlined NonNull::<[bool; 0]>::new_unchecked) {
+                          scope 12 (inlined NonNull::<[bool; 0]>::new_unchecked) {
                               debug ptr => _6;
                               let mut _8: bool;
                               let _9: ();
                               let mut _10: *mut ();
                               let mut _11: *const [bool; 0];
-                              scope 12 {
+                              scope 13 {
                               }
                           }
                       }
-                      scope 8 (inlined align_of::<[bool; 0]>) {
-                      }
-                      scope 9 (inlined invalid_mut::<[bool; 0]>) {
-                          debug addr => _7;
-                          scope 10 {
+                      scope 8 (inlined dangling_mut::<[bool; 0]>) {
+                          let mut _7: usize;
+                          scope 9 (inlined align_of::<[bool; 0]>) {
+                          }
+                          scope 10 (inlined without_provenance_mut::<[bool; 0]>) {
+                              debug addr => _7;
+                              scope 11 {
+                              }
                           }
                       }
                   }
diff --git a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-unwind.diff b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-unwind.diff
index fca7fe89b4a..d6b5984b81d 100644
--- a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-unwind.diff
+++ b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-unwind.diff
@@ -17,26 +17,28 @@
           scope 4 (inlined Unique::<[bool; 0]>::dangling) {
               let mut _5: std::ptr::NonNull<[bool; 0]>;
               scope 5 (inlined NonNull::<[bool; 0]>::dangling) {
-                  let mut _7: usize;
                   scope 6 {
                       let _6: *mut [bool; 0];
                       scope 7 {
                           debug ptr => _6;
-                          scope 11 (inlined NonNull::<[bool; 0]>::new_unchecked) {
+                          scope 12 (inlined NonNull::<[bool; 0]>::new_unchecked) {
                               debug ptr => _6;
                               let mut _8: bool;
                               let _9: ();
                               let mut _10: *mut ();
                               let mut _11: *const [bool; 0];
-                              scope 12 {
+                              scope 13 {
                               }
                           }
                       }
-                      scope 8 (inlined align_of::<[bool; 0]>) {
-                      }
-                      scope 9 (inlined invalid_mut::<[bool; 0]>) {
-                          debug addr => _7;
-                          scope 10 {
+                      scope 8 (inlined dangling_mut::<[bool; 0]>) {
+                          let mut _7: usize;
+                          scope 9 (inlined align_of::<[bool; 0]>) {
+                          }
+                          scope 10 (inlined without_provenance_mut::<[bool; 0]>) {
+                              debug addr => _7;
+                              scope 11 {
+                              }
                           }
                       }
                   }
diff --git a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-abort.diff b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-abort.diff
index 0ced2e4deed..c7445aaee6c 100644
--- a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-abort.diff
+++ b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-abort.diff
@@ -17,26 +17,28 @@
           scope 4 (inlined Unique::<[bool; 0]>::dangling) {
               let mut _5: std::ptr::NonNull<[bool; 0]>;
               scope 5 (inlined NonNull::<[bool; 0]>::dangling) {
-                  let mut _7: usize;
                   scope 6 {
                       let _6: *mut [bool; 0];
                       scope 7 {
                           debug ptr => _6;
-                          scope 11 (inlined NonNull::<[bool; 0]>::new_unchecked) {
+                          scope 12 (inlined NonNull::<[bool; 0]>::new_unchecked) {
                               debug ptr => _6;
                               let mut _8: bool;
                               let _9: ();
                               let mut _10: *mut ();
                               let mut _11: *const [bool; 0];
-                              scope 12 {
+                              scope 13 {
                               }
                           }
                       }
-                      scope 8 (inlined align_of::<[bool; 0]>) {
-                      }
-                      scope 9 (inlined invalid_mut::<[bool; 0]>) {
-                          debug addr => _7;
-                          scope 10 {
+                      scope 8 (inlined dangling_mut::<[bool; 0]>) {
+                          let mut _7: usize;
+                          scope 9 (inlined align_of::<[bool; 0]>) {
+                          }
+                          scope 10 (inlined without_provenance_mut::<[bool; 0]>) {
+                              debug addr => _7;
+                              scope 11 {
+                              }
                           }
                       }
                   }
diff --git a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-unwind.diff b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-unwind.diff
index e17d76a6d95..b8e961bc087 100644
--- a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-unwind.diff
+++ b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-unwind.diff
@@ -17,26 +17,28 @@
           scope 4 (inlined Unique::<[bool; 0]>::dangling) {
               let mut _5: std::ptr::NonNull<[bool; 0]>;
               scope 5 (inlined NonNull::<[bool; 0]>::dangling) {
-                  let mut _7: usize;
                   scope 6 {
                       let _6: *mut [bool; 0];
                       scope 7 {
                           debug ptr => _6;
-                          scope 11 (inlined NonNull::<[bool; 0]>::new_unchecked) {
+                          scope 12 (inlined NonNull::<[bool; 0]>::new_unchecked) {
                               debug ptr => _6;
                               let mut _8: bool;
                               let _9: ();
                               let mut _10: *mut ();
                               let mut _11: *const [bool; 0];
-                              scope 12 {
+                              scope 13 {
                               }
                           }
                       }
-                      scope 8 (inlined align_of::<[bool; 0]>) {
-                      }
-                      scope 9 (inlined invalid_mut::<[bool; 0]>) {
-                          debug addr => _7;
-                          scope 10 {
+                      scope 8 (inlined dangling_mut::<[bool; 0]>) {
+                          let mut _7: usize;
+                          scope 9 (inlined align_of::<[bool; 0]>) {
+                          }
+                          scope 10 (inlined without_provenance_mut::<[bool; 0]>) {
+                              debug addr => _7;
+                              scope 11 {
+                              }
                           }
                       }
                   }
diff --git a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-abort.diff b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-abort.diff
index ff68b3c2d55..9678db90d05 100644
--- a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-abort.diff
+++ b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-abort.diff
@@ -17,26 +17,28 @@
           scope 4 (inlined Unique::<[bool; 0]>::dangling) {
               let mut _5: std::ptr::NonNull<[bool; 0]>;
               scope 5 (inlined NonNull::<[bool; 0]>::dangling) {
-                  let mut _7: usize;
                   scope 6 {
                       let _6: *mut [bool; 0];
                       scope 7 {
                           debug ptr => _6;
-                          scope 11 (inlined NonNull::<[bool; 0]>::new_unchecked) {
+                          scope 12 (inlined NonNull::<[bool; 0]>::new_unchecked) {
                               debug ptr => _6;
                               let mut _8: bool;
                               let _9: ();
                               let mut _10: *mut ();
                               let mut _11: *const [bool; 0];
-                              scope 12 {
+                              scope 13 {
                               }
                           }
                       }
-                      scope 8 (inlined align_of::<[bool; 0]>) {
-                      }
-                      scope 9 (inlined invalid_mut::<[bool; 0]>) {
-                          debug addr => _7;
-                          scope 10 {
+                      scope 8 (inlined dangling_mut::<[bool; 0]>) {
+                          let mut _7: usize;
+                          scope 9 (inlined align_of::<[bool; 0]>) {
+                          }
+                          scope 10 (inlined without_provenance_mut::<[bool; 0]>) {
+                              debug addr => _7;
+                              scope 11 {
+                              }
                           }
                       }
                   }
diff --git a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-unwind.diff b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-unwind.diff
index de951e57fb9..8aa6c9c23e9 100644
--- a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-unwind.diff
+++ b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-unwind.diff
@@ -17,26 +17,28 @@
           scope 4 (inlined Unique::<[bool; 0]>::dangling) {
               let mut _5: std::ptr::NonNull<[bool; 0]>;
               scope 5 (inlined NonNull::<[bool; 0]>::dangling) {
-                  let mut _7: usize;
                   scope 6 {
                       let _6: *mut [bool; 0];
                       scope 7 {
                           debug ptr => _6;
-                          scope 11 (inlined NonNull::<[bool; 0]>::new_unchecked) {
+                          scope 12 (inlined NonNull::<[bool; 0]>::new_unchecked) {
                               debug ptr => _6;
                               let mut _8: bool;
                               let _9: ();
                               let mut _10: *mut ();
                               let mut _11: *const [bool; 0];
-                              scope 12 {
+                              scope 13 {
                               }
                           }
                       }
-                      scope 8 (inlined align_of::<[bool; 0]>) {
-                      }
-                      scope 9 (inlined invalid_mut::<[bool; 0]>) {
-                          debug addr => _7;
-                          scope 10 {
+                      scope 8 (inlined dangling_mut::<[bool; 0]>) {
+                          let mut _7: usize;
+                          scope 9 (inlined align_of::<[bool; 0]>) {
+                          }
+                          scope 10 (inlined without_provenance_mut::<[bool; 0]>) {
+                              debug addr => _7;
+                              scope 11 {
+                              }
                           }
                       }
                   }
diff --git a/tests/mir-opt/dataflow-const-prop/enum.rs b/tests/mir-opt/dataflow-const-prop/enum.rs
index 78410e49d2a..34792cb9f01 100644
--- a/tests/mir-opt/dataflow-const-prop/enum.rs
+++ b/tests/mir-opt/dataflow-const-prop/enum.rs
@@ -62,7 +62,7 @@ fn statics() {
 
     static RC: &E = &E::V2(4);
 
-    // CHECK: [[t:_.*]] = const {alloc2: &&E};
+    // CHECK: [[t:_.*]] = const {alloc5: &&E};
     // CHECK: [[e2]] = (*[[t]]);
     let e2 = RC;
 
diff --git a/tests/mir-opt/exponential_or.match_tuple.SimplifyCfg-initial.after.mir b/tests/mir-opt/exponential_or.match_tuple.SimplifyCfg-initial.after.mir
index 596dcef85fd..ea5cd55b560 100644
--- a/tests/mir-opt/exponential_or.match_tuple.SimplifyCfg-initial.after.mir
+++ b/tests/mir-opt/exponential_or.match_tuple.SimplifyCfg-initial.after.mir
@@ -19,7 +19,8 @@ fn match_tuple(_1: (u32, bool, Option<i32>, u32)) -> u32 {
 
     bb0: {
         PlaceMention(_1);
-        switchInt((_1.0: u32)) -> [1: bb2, 4: bb2, otherwise: bb1];
+        _2 = discriminant((_1.2: std::option::Option<i32>));
+        switchInt(move _2) -> [0: bb3, 1: bb2, otherwise: bb1];
     }
 
     bb1: {
@@ -28,12 +29,11 @@ fn match_tuple(_1: (u32, bool, Option<i32>, u32)) -> u32 {
     }
 
     bb2: {
-        _2 = discriminant((_1.2: std::option::Option<i32>));
-        switchInt(move _2) -> [0: bb4, 1: bb3, otherwise: bb1];
+        switchInt((((_1.2: std::option::Option<i32>) as Some).0: i32)) -> [1: bb3, 8: bb3, otherwise: bb1];
     }
 
     bb3: {
-        switchInt((((_1.2: std::option::Option<i32>) as Some).0: i32)) -> [1: bb4, 8: bb4, otherwise: bb1];
+        switchInt((_1.0: u32)) -> [1: bb4, 4: bb4, otherwise: bb1];
     }
 
     bb4: {
diff --git a/tests/mir-opt/issue_72181.bar.built.after.mir b/tests/mir-opt/issue_72181.bar.built.after.mir
index b6cc7d22195..3ab9152f8bb 100644
--- a/tests/mir-opt/issue_72181.bar.built.after.mir
+++ b/tests/mir-opt/issue_72181.bar.built.after.mir
@@ -19,4 +19,8 @@ fn bar(_1: [(Never, u32); 1]) -> u32 {
         FakeRead(ForMatchedPlace(None), _1);
         unreachable;
     }
+
+    bb2: {
+        goto -> bb1;
+    }
 }
diff --git a/tests/mir-opt/issue_72181.main.built.after.mir b/tests/mir-opt/issue_72181.main.built.after.mir
index 12c4a2b6325..cff20702bf7 100644
--- a/tests/mir-opt/issue_72181.main.built.after.mir
+++ b/tests/mir-opt/issue_72181.main.built.after.mir
@@ -22,7 +22,7 @@ fn main() -> () {
 
     bb0: {
         StorageLive(_1);
-        _1 = std::mem::size_of::<Foo>() -> [return: bb1, unwind: bb5];
+        _1 = std::mem::size_of::<Foo>() -> [return: bb1, unwind: bb7];
     }
 
     bb1: {
@@ -42,7 +42,7 @@ fn main() -> () {
         _6 = const 0_usize;
         _7 = Len(_2);
         _8 = Lt(_6, _7);
-        assert(move _8, "index out of bounds: the length is {} but the index is {}", move _7, _6) -> [success: bb3, unwind: bb5];
+        assert(move _8, "index out of bounds: the length is {} but the index is {}", move _7, _6) -> [success: bb4, unwind: bb7];
     }
 
     bb2: {
@@ -51,6 +51,10 @@ fn main() -> () {
     }
 
     bb3: {
+        goto -> bb2;
+    }
+
+    bb4: {
         _5 = (_2[_6].0: u64);
         PlaceMention(_5);
         StorageDead(_6);
@@ -60,12 +64,16 @@ fn main() -> () {
         return;
     }
 
-    bb4: {
+    bb5: {
         FakeRead(ForMatchedPlace(None), _5);
         unreachable;
     }
 
-    bb5 (cleanup): {
+    bb6: {
+        goto -> bb5;
+    }
+
+    bb7 (cleanup): {
         resume;
     }
 }
diff --git a/tests/mir-opt/issue_91633.bar.built.after.mir b/tests/mir-opt/issue_91633.bar.built.after.mir
index 53829588a1b..3dcdcab9dea 100644
--- a/tests/mir-opt/issue_91633.bar.built.after.mir
+++ b/tests/mir-opt/issue_91633.bar.built.after.mir
@@ -12,7 +12,7 @@ fn bar(_1: Box<[T]>) -> () {
         StorageLive(_2);
         StorageLive(_3);
         _3 = &(*_1);
-        _2 = <[T] as Index<usize>>::index(move _3, const 0_usize) -> [return: bb1, unwind: bb4];
+        _2 = <[T] as Index<usize>>::index(move _3, const 0_usize) -> [return: bb1, unwind: bb5];
     }
 
     bb1: {
@@ -20,7 +20,7 @@ fn bar(_1: Box<[T]>) -> () {
         PlaceMention((*_2));
         StorageDead(_2);
         _0 = const ();
-        drop(_1) -> [return: bb3, unwind: bb5];
+        drop(_1) -> [return: bb4, unwind: bb6];
     }
 
     bb2: {
@@ -29,14 +29,18 @@ fn bar(_1: Box<[T]>) -> () {
     }
 
     bb3: {
-        return;
+        goto -> bb2;
     }
 
-    bb4 (cleanup): {
-        drop(_1) -> [return: bb5, unwind terminate(cleanup)];
+    bb4: {
+        return;
     }
 
     bb5 (cleanup): {
+        drop(_1) -> [return: bb6, unwind terminate(cleanup)];
+    }
+
+    bb6 (cleanup): {
         resume;
     }
 }
diff --git a/tests/mir-opt/issue_91633.hey.built.after.mir b/tests/mir-opt/issue_91633.hey.built.after.mir
index a537e509996..e782f4d1a23 100644
--- a/tests/mir-opt/issue_91633.hey.built.after.mir
+++ b/tests/mir-opt/issue_91633.hey.built.after.mir
@@ -14,7 +14,7 @@ fn hey(_1: &[T]) -> () {
         StorageLive(_3);
         StorageLive(_4);
         _4 = &(*_1);
-        _3 = <[T] as Index<usize>>::index(move _4, const 0_usize) -> [return: bb1, unwind: bb3];
+        _3 = <[T] as Index<usize>>::index(move _4, const 0_usize) -> [return: bb1, unwind: bb4];
     }
 
     bb1: {
@@ -32,7 +32,11 @@ fn hey(_1: &[T]) -> () {
         unreachable;
     }
 
-    bb3 (cleanup): {
+    bb3: {
+        goto -> bb2;
+    }
+
+    bb4 (cleanup): {
         resume;
     }
 }
diff --git a/tests/mir-opt/issue_99325.main.built.after.32bit.mir b/tests/mir-opt/issue_99325.main.built.after.32bit.mir
index 53254f76dbc..f8e195466ee 100644
--- a/tests/mir-opt/issue_99325.main.built.after.32bit.mir
+++ b/tests/mir-opt/issue_99325.main.built.after.32bit.mir
@@ -67,7 +67,7 @@ fn main() -> () {
         StorageLive(_2);
         StorageLive(_3);
         StorageLive(_4);
-        _4 = function_with_bytes::<&*b"AAAA">() -> [return: bb1, unwind: bb23];
+        _4 = function_with_bytes::<&*b"AAAA">() -> [return: bb1, unwind: bb25];
     }
 
     bb1: {
@@ -91,7 +91,7 @@ fn main() -> () {
         _11 = &(*_8);
         StorageLive(_12);
         _12 = &(*_9);
-        _10 = <&[u8] as PartialEq<&[u8; 4]>>::eq(move _11, move _12) -> [return: bb3, unwind: bb23];
+        _10 = <&[u8] as PartialEq<&[u8; 4]>>::eq(move _11, move _12) -> [return: bb4, unwind: bb25];
     }
 
     bb2: {
@@ -100,20 +100,24 @@ fn main() -> () {
     }
 
     bb3: {
-        switchInt(move _10) -> [0: bb5, otherwise: bb4];
+        goto -> bb2;
     }
 
     bb4: {
-        StorageDead(_12);
-        StorageDead(_11);
-        goto -> bb9;
+        switchInt(move _10) -> [0: bb6, otherwise: bb5];
     }
 
     bb5: {
-        goto -> bb6;
+        StorageDead(_12);
+        StorageDead(_11);
+        goto -> bb10;
     }
 
     bb6: {
+        goto -> bb7;
+    }
+
+    bb7: {
         StorageDead(_12);
         StorageDead(_11);
         StorageLive(_14);
@@ -132,10 +136,10 @@ fn main() -> () {
         _19 = &(*_20);
         StorageLive(_21);
         _21 = Option::<Arguments<'_>>::None;
-        _15 = core::panicking::assert_failed::<&[u8], &[u8; 4]>(move _16, move _17, move _19, move _21) -> bb23;
+        _15 = core::panicking::assert_failed::<&[u8], &[u8; 4]>(move _16, move _17, move _19, move _21) -> bb25;
     }
 
-    bb7: {
+    bb8: {
         StorageDead(_21);
         StorageDead(_19);
         StorageDead(_17);
@@ -147,23 +151,23 @@ fn main() -> () {
         unreachable;
     }
 
-    bb8: {
-        goto -> bb10;
+    bb9: {
+        goto -> bb11;
     }
 
-    bb9: {
+    bb10: {
         _1 = const ();
-        goto -> bb10;
+        goto -> bb11;
     }
 
-    bb10: {
+    bb11: {
         StorageDead(_10);
         StorageDead(_9);
         StorageDead(_8);
-        goto -> bb11;
+        goto -> bb12;
     }
 
-    bb11: {
+    bb12: {
         StorageDead(_7);
         StorageDead(_6);
         StorageDead(_4);
@@ -173,10 +177,10 @@ fn main() -> () {
         StorageLive(_23);
         StorageLive(_24);
         StorageLive(_25);
-        _25 = function_with_bytes::<&*b"AAAA">() -> [return: bb12, unwind: bb23];
+        _25 = function_with_bytes::<&*b"AAAA">() -> [return: bb13, unwind: bb25];
     }
 
-    bb12: {
+    bb13: {
         _24 = &_25;
         StorageLive(_26);
         StorageLive(_27);
@@ -195,29 +199,33 @@ fn main() -> () {
         _31 = &(*_28);
         StorageLive(_32);
         _32 = &(*_29);
-        _30 = <&[u8] as PartialEq<&[u8; 4]>>::eq(move _31, move _32) -> [return: bb14, unwind: bb23];
+        _30 = <&[u8] as PartialEq<&[u8; 4]>>::eq(move _31, move _32) -> [return: bb16, unwind: bb25];
     }
 
-    bb13: {
+    bb14: {
         FakeRead(ForMatchedPlace(None), _23);
         unreachable;
     }
 
-    bb14: {
-        switchInt(move _30) -> [0: bb16, otherwise: bb15];
+    bb15: {
+        goto -> bb14;
     }
 
-    bb15: {
+    bb16: {
+        switchInt(move _30) -> [0: bb18, otherwise: bb17];
+    }
+
+    bb17: {
         StorageDead(_32);
         StorageDead(_31);
-        goto -> bb20;
+        goto -> bb22;
     }
 
-    bb16: {
-        goto -> bb17;
+    bb18: {
+        goto -> bb19;
     }
 
-    bb17: {
+    bb19: {
         StorageDead(_32);
         StorageDead(_31);
         StorageLive(_34);
@@ -236,10 +244,10 @@ fn main() -> () {
         _39 = &(*_40);
         StorageLive(_41);
         _41 = Option::<Arguments<'_>>::None;
-        _35 = core::panicking::assert_failed::<&[u8], &[u8; 4]>(move _36, move _37, move _39, move _41) -> bb23;
+        _35 = core::panicking::assert_failed::<&[u8], &[u8; 4]>(move _36, move _37, move _39, move _41) -> bb25;
     }
 
-    bb18: {
+    bb20: {
         StorageDead(_41);
         StorageDead(_39);
         StorageDead(_37);
@@ -251,23 +259,23 @@ fn main() -> () {
         unreachable;
     }
 
-    bb19: {
-        goto -> bb21;
+    bb21: {
+        goto -> bb23;
     }
 
-    bb20: {
+    bb22: {
         _22 = const ();
-        goto -> bb21;
+        goto -> bb23;
     }
 
-    bb21: {
+    bb23: {
         StorageDead(_30);
         StorageDead(_29);
         StorageDead(_28);
-        goto -> bb22;
+        goto -> bb24;
     }
 
-    bb22: {
+    bb24: {
         StorageDead(_27);
         StorageDead(_25);
         StorageDead(_23);
@@ -276,7 +284,7 @@ fn main() -> () {
         return;
     }
 
-    bb23 (cleanup): {
+    bb25 (cleanup): {
         resume;
     }
 }
diff --git a/tests/mir-opt/issue_99325.main.built.after.64bit.mir b/tests/mir-opt/issue_99325.main.built.after.64bit.mir
index 53254f76dbc..f8e195466ee 100644
--- a/tests/mir-opt/issue_99325.main.built.after.64bit.mir
+++ b/tests/mir-opt/issue_99325.main.built.after.64bit.mir
@@ -67,7 +67,7 @@ fn main() -> () {
         StorageLive(_2);
         StorageLive(_3);
         StorageLive(_4);
-        _4 = function_with_bytes::<&*b"AAAA">() -> [return: bb1, unwind: bb23];
+        _4 = function_with_bytes::<&*b"AAAA">() -> [return: bb1, unwind: bb25];
     }
 
     bb1: {
@@ -91,7 +91,7 @@ fn main() -> () {
         _11 = &(*_8);
         StorageLive(_12);
         _12 = &(*_9);
-        _10 = <&[u8] as PartialEq<&[u8; 4]>>::eq(move _11, move _12) -> [return: bb3, unwind: bb23];
+        _10 = <&[u8] as PartialEq<&[u8; 4]>>::eq(move _11, move _12) -> [return: bb4, unwind: bb25];
     }
 
     bb2: {
@@ -100,20 +100,24 @@ fn main() -> () {
     }
 
     bb3: {
-        switchInt(move _10) -> [0: bb5, otherwise: bb4];
+        goto -> bb2;
     }
 
     bb4: {
-        StorageDead(_12);
-        StorageDead(_11);
-        goto -> bb9;
+        switchInt(move _10) -> [0: bb6, otherwise: bb5];
     }
 
     bb5: {
-        goto -> bb6;
+        StorageDead(_12);
+        StorageDead(_11);
+        goto -> bb10;
     }
 
     bb6: {
+        goto -> bb7;
+    }
+
+    bb7: {
         StorageDead(_12);
         StorageDead(_11);
         StorageLive(_14);
@@ -132,10 +136,10 @@ fn main() -> () {
         _19 = &(*_20);
         StorageLive(_21);
         _21 = Option::<Arguments<'_>>::None;
-        _15 = core::panicking::assert_failed::<&[u8], &[u8; 4]>(move _16, move _17, move _19, move _21) -> bb23;
+        _15 = core::panicking::assert_failed::<&[u8], &[u8; 4]>(move _16, move _17, move _19, move _21) -> bb25;
     }
 
-    bb7: {
+    bb8: {
         StorageDead(_21);
         StorageDead(_19);
         StorageDead(_17);
@@ -147,23 +151,23 @@ fn main() -> () {
         unreachable;
     }
 
-    bb8: {
-        goto -> bb10;
+    bb9: {
+        goto -> bb11;
     }
 
-    bb9: {
+    bb10: {
         _1 = const ();
-        goto -> bb10;
+        goto -> bb11;
     }
 
-    bb10: {
+    bb11: {
         StorageDead(_10);
         StorageDead(_9);
         StorageDead(_8);
-        goto -> bb11;
+        goto -> bb12;
     }
 
-    bb11: {
+    bb12: {
         StorageDead(_7);
         StorageDead(_6);
         StorageDead(_4);
@@ -173,10 +177,10 @@ fn main() -> () {
         StorageLive(_23);
         StorageLive(_24);
         StorageLive(_25);
-        _25 = function_with_bytes::<&*b"AAAA">() -> [return: bb12, unwind: bb23];
+        _25 = function_with_bytes::<&*b"AAAA">() -> [return: bb13, unwind: bb25];
     }
 
-    bb12: {
+    bb13: {
         _24 = &_25;
         StorageLive(_26);
         StorageLive(_27);
@@ -195,29 +199,33 @@ fn main() -> () {
         _31 = &(*_28);
         StorageLive(_32);
         _32 = &(*_29);
-        _30 = <&[u8] as PartialEq<&[u8; 4]>>::eq(move _31, move _32) -> [return: bb14, unwind: bb23];
+        _30 = <&[u8] as PartialEq<&[u8; 4]>>::eq(move _31, move _32) -> [return: bb16, unwind: bb25];
     }
 
-    bb13: {
+    bb14: {
         FakeRead(ForMatchedPlace(None), _23);
         unreachable;
     }
 
-    bb14: {
-        switchInt(move _30) -> [0: bb16, otherwise: bb15];
+    bb15: {
+        goto -> bb14;
     }
 
-    bb15: {
+    bb16: {
+        switchInt(move _30) -> [0: bb18, otherwise: bb17];
+    }
+
+    bb17: {
         StorageDead(_32);
         StorageDead(_31);
-        goto -> bb20;
+        goto -> bb22;
     }
 
-    bb16: {
-        goto -> bb17;
+    bb18: {
+        goto -> bb19;
     }
 
-    bb17: {
+    bb19: {
         StorageDead(_32);
         StorageDead(_31);
         StorageLive(_34);
@@ -236,10 +244,10 @@ fn main() -> () {
         _39 = &(*_40);
         StorageLive(_41);
         _41 = Option::<Arguments<'_>>::None;
-        _35 = core::panicking::assert_failed::<&[u8], &[u8; 4]>(move _36, move _37, move _39, move _41) -> bb23;
+        _35 = core::panicking::assert_failed::<&[u8], &[u8; 4]>(move _36, move _37, move _39, move _41) -> bb25;
     }
 
-    bb18: {
+    bb20: {
         StorageDead(_41);
         StorageDead(_39);
         StorageDead(_37);
@@ -251,23 +259,23 @@ fn main() -> () {
         unreachable;
     }
 
-    bb19: {
-        goto -> bb21;
+    bb21: {
+        goto -> bb23;
     }
 
-    bb20: {
+    bb22: {
         _22 = const ();
-        goto -> bb21;
+        goto -> bb23;
     }
 
-    bb21: {
+    bb23: {
         StorageDead(_30);
         StorageDead(_29);
         StorageDead(_28);
-        goto -> bb22;
+        goto -> bb24;
     }
 
-    bb22: {
+    bb24: {
         StorageDead(_27);
         StorageDead(_25);
         StorageDead(_23);
@@ -276,7 +284,7 @@ fn main() -> () {
         return;
     }
 
-    bb23 (cleanup): {
+    bb25 (cleanup): {
         resume;
     }
 }
diff --git a/tests/mir-opt/pre-codegen/slice_index.slice_get_mut_usize.PreCodegen.after.panic-abort.mir b/tests/mir-opt/pre-codegen/slice_index.slice_get_mut_usize.PreCodegen.after.panic-abort.mir
index bc7617bb6dd..153505b1bbb 100644
--- a/tests/mir-opt/pre-codegen/slice_index.slice_get_mut_usize.PreCodegen.after.panic-abort.mir
+++ b/tests/mir-opt/pre-codegen/slice_index.slice_get_mut_usize.PreCodegen.after.panic-abort.mir
@@ -7,89 +7,13 @@ fn slice_get_mut_usize(_1: &mut [u32], _2: usize) -> Option<&mut u32> {
     scope 1 (inlined core::slice::<impl [u32]>::get_mut::<usize>) {
         debug self => _1;
         debug index => _2;
-        scope 2 (inlined <usize as SliceIndex<[u32]>>::get_mut) {
-            debug self => _2;
-            debug slice => _1;
-            let mut _3: usize;
-            let mut _4: bool;
-            let mut _5: *mut [u32];
-            let mut _7: *mut u32;
-            let mut _8: &mut u32;
-            scope 3 {
-                scope 4 (inlined <usize as SliceIndex<[u32]>>::get_unchecked_mut) {
-                    debug self => _2;
-                    debug slice => _5;
-                    let mut _6: *mut u32;
-                    let mut _9: *mut [u32];
-                    let mut _10: &[&str];
-                    scope 5 {
-                        scope 10 (inlined std::ptr::mut_ptr::<impl *mut [u32]>::as_mut_ptr) {
-                            debug self => _5;
-                        }
-                        scope 11 (inlined std::ptr::mut_ptr::<impl *mut u32>::add) {
-                            debug self => _6;
-                            debug count => _2;
-                            scope 12 {
-                            }
-                        }
-                    }
-                    scope 6 (inlined std::ptr::mut_ptr::<impl *mut [u32]>::len) {
-                        debug self => _9;
-                        let mut _11: *const [u32];
-                        scope 7 (inlined std::ptr::metadata::<[u32]>) {
-                            debug ptr => _11;
-                            scope 8 {
-                            }
-                        }
-                    }
-                    scope 9 (inlined Arguments::<'_>::new_const) {
-                        debug pieces => _10;
-                    }
-                }
-            }
-        }
     }
 
     bb0: {
-        StorageLive(_7);
-        StorageLive(_4);
-        StorageLive(_3);
-        _3 = Len((*_1));
-        _4 = Lt(_2, move _3);
-        switchInt(move _4) -> [0: bb1, otherwise: bb2];
+        _0 = <usize as SliceIndex<[u32]>>::get_mut(move _2, move _1) -> [return: bb1, unwind unreachable];
     }
 
     bb1: {
-        StorageDead(_3);
-        _0 = const Option::<&mut u32>::None;
-        goto -> bb3;
-    }
-
-    bb2: {
-        StorageDead(_3);
-        StorageLive(_8);
-        StorageLive(_5);
-        _5 = &raw mut (*_1);
-        StorageLive(_9);
-        StorageLive(_10);
-        StorageLive(_11);
-        StorageLive(_6);
-        _6 = _5 as *mut u32 (PtrToPtr);
-        _7 = Offset(_6, _2);
-        StorageDead(_6);
-        StorageDead(_11);
-        StorageDead(_10);
-        StorageDead(_9);
-        StorageDead(_5);
-        _8 = &mut (*_7);
-        _0 = Option::<&mut u32>::Some(move _8);
-        StorageDead(_8);
-        goto -> bb3;
-    }
-
-    bb3: {
-        StorageDead(_4);
-        StorageDead(_7);
         return;
     }
 }
diff --git a/tests/mir-opt/pre-codegen/slice_index.slice_get_mut_usize.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/slice_index.slice_get_mut_usize.PreCodegen.after.panic-unwind.mir
index bc7617bb6dd..d37ee783117 100644
--- a/tests/mir-opt/pre-codegen/slice_index.slice_get_mut_usize.PreCodegen.after.panic-unwind.mir
+++ b/tests/mir-opt/pre-codegen/slice_index.slice_get_mut_usize.PreCodegen.after.panic-unwind.mir
@@ -7,89 +7,13 @@ fn slice_get_mut_usize(_1: &mut [u32], _2: usize) -> Option<&mut u32> {
     scope 1 (inlined core::slice::<impl [u32]>::get_mut::<usize>) {
         debug self => _1;
         debug index => _2;
-        scope 2 (inlined <usize as SliceIndex<[u32]>>::get_mut) {
-            debug self => _2;
-            debug slice => _1;
-            let mut _3: usize;
-            let mut _4: bool;
-            let mut _5: *mut [u32];
-            let mut _7: *mut u32;
-            let mut _8: &mut u32;
-            scope 3 {
-                scope 4 (inlined <usize as SliceIndex<[u32]>>::get_unchecked_mut) {
-                    debug self => _2;
-                    debug slice => _5;
-                    let mut _6: *mut u32;
-                    let mut _9: *mut [u32];
-                    let mut _10: &[&str];
-                    scope 5 {
-                        scope 10 (inlined std::ptr::mut_ptr::<impl *mut [u32]>::as_mut_ptr) {
-                            debug self => _5;
-                        }
-                        scope 11 (inlined std::ptr::mut_ptr::<impl *mut u32>::add) {
-                            debug self => _6;
-                            debug count => _2;
-                            scope 12 {
-                            }
-                        }
-                    }
-                    scope 6 (inlined std::ptr::mut_ptr::<impl *mut [u32]>::len) {
-                        debug self => _9;
-                        let mut _11: *const [u32];
-                        scope 7 (inlined std::ptr::metadata::<[u32]>) {
-                            debug ptr => _11;
-                            scope 8 {
-                            }
-                        }
-                    }
-                    scope 9 (inlined Arguments::<'_>::new_const) {
-                        debug pieces => _10;
-                    }
-                }
-            }
-        }
     }
 
     bb0: {
-        StorageLive(_7);
-        StorageLive(_4);
-        StorageLive(_3);
-        _3 = Len((*_1));
-        _4 = Lt(_2, move _3);
-        switchInt(move _4) -> [0: bb1, otherwise: bb2];
+        _0 = <usize as SliceIndex<[u32]>>::get_mut(move _2, move _1) -> [return: bb1, unwind continue];
     }
 
     bb1: {
-        StorageDead(_3);
-        _0 = const Option::<&mut u32>::None;
-        goto -> bb3;
-    }
-
-    bb2: {
-        StorageDead(_3);
-        StorageLive(_8);
-        StorageLive(_5);
-        _5 = &raw mut (*_1);
-        StorageLive(_9);
-        StorageLive(_10);
-        StorageLive(_11);
-        StorageLive(_6);
-        _6 = _5 as *mut u32 (PtrToPtr);
-        _7 = Offset(_6, _2);
-        StorageDead(_6);
-        StorageDead(_11);
-        StorageDead(_10);
-        StorageDead(_9);
-        StorageDead(_5);
-        _8 = &mut (*_7);
-        _0 = Option::<&mut u32>::Some(move _8);
-        StorageDead(_8);
-        goto -> bb3;
-    }
-
-    bb3: {
-        StorageDead(_4);
-        StorageDead(_7);
         return;
     }
 }
diff --git a/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-abort.mir b/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-abort.mir
index 2fdc21d636f..bcc540ae6fc 100644
--- a/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-abort.mir
+++ b/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-abort.mir
@@ -4,106 +4,24 @@ fn slice_get_unchecked_mut_range(_1: &mut [u32], _2: std::ops::Range<usize>) ->
     debug slice => _1;
     debug index => _2;
     let mut _0: &mut [u32];
-    let mut _3: usize;
-    let mut _4: usize;
     scope 1 (inlined core::slice::<impl [u32]>::get_unchecked_mut::<std::ops::Range<usize>>) {
         debug self => _1;
-        debug ((index: std::ops::Range<usize>).0: usize) => _3;
-        debug ((index: std::ops::Range<usize>).1: usize) => _4;
-        let mut _5: *mut [u32];
-        let mut _13: *mut [u32];
+        debug index => _2;
+        let mut _3: *mut [u32];
+        let mut _4: *mut [u32];
         scope 2 {
-            scope 3 (inlined <std::ops::Range<usize> as SliceIndex<[u32]>>::get_unchecked_mut) {
-                debug ((self: std::ops::Range<usize>).0: usize) => _3;
-                debug ((self: std::ops::Range<usize>).1: usize) => _4;
-                debug slice => _5;
-                let mut _7: *mut u32;
-                let mut _8: *mut u32;
-                let mut _14: *mut [u32];
-                let mut _15: &[&str];
-                scope 4 {
-                    let _6: usize;
-                    scope 5 {
-                        debug new_len => _6;
-                        scope 10 (inlined std::ptr::mut_ptr::<impl *mut [u32]>::as_mut_ptr) {
-                            debug self => _5;
-                        }
-                        scope 11 (inlined std::ptr::mut_ptr::<impl *mut u32>::add) {
-                            debug self => _7;
-                            debug count => _3;
-                            scope 12 {
-                            }
-                        }
-                        scope 13 (inlined slice_from_raw_parts_mut::<u32>) {
-                            debug data => _8;
-                            debug len => _6;
-                            let mut _9: *mut ();
-                            scope 14 (inlined std::ptr::mut_ptr::<impl *mut u32>::cast::<()>) {
-                                debug self => _8;
-                            }
-                            scope 15 (inlined std::ptr::from_raw_parts_mut::<[u32]>) {
-                                debug data_pointer => _9;
-                                debug metadata => _6;
-                                let mut _10: *const ();
-                                let mut _11: std::ptr::metadata::PtrComponents<[u32]>;
-                                let mut _12: std::ptr::metadata::PtrRepr<[u32]>;
-                                scope 16 {
-                                }
-                            }
-                        }
-                    }
-                }
-                scope 6 (inlined std::ptr::mut_ptr::<impl *mut [u32]>::len) {
-                    debug self => _14;
-                    let mut _16: *const [u32];
-                    scope 7 (inlined std::ptr::metadata::<[u32]>) {
-                        debug ptr => _16;
-                        scope 8 {
-                        }
-                    }
-                }
-                scope 9 (inlined Arguments::<'_>::new_const) {
-                    debug pieces => _15;
-                }
-            }
         }
     }
 
     bb0: {
-        _3 = move (_2.0: usize);
-        _4 = move (_2.1: usize);
-        StorageLive(_5);
-        _5 = &raw mut (*_1);
-        StorageLive(_14);
-        StorageLive(_15);
-        StorageLive(_6);
-        StorageLive(_16);
-        _6 = SubUnchecked(_4, _3);
-        StorageLive(_8);
-        StorageLive(_7);
-        _7 = _5 as *mut u32 (PtrToPtr);
-        _8 = Offset(_7, _3);
-        StorageDead(_7);
-        StorageLive(_9);
-        _9 = _8 as *mut () (PtrToPtr);
-        StorageLive(_12);
-        StorageLive(_11);
-        StorageLive(_10);
-        _10 = _8 as *const () (PtrToPtr);
-        _11 = std::ptr::metadata::PtrComponents::<[u32]> { data_pointer: move _10, metadata: _6 };
-        StorageDead(_10);
-        _12 = std::ptr::metadata::PtrRepr::<[u32]> { const_ptr: move _11 };
-        StorageDead(_11);
-        _13 = (_12.1: *mut [u32]);
-        StorageDead(_12);
-        StorageDead(_9);
-        StorageDead(_8);
-        StorageDead(_16);
-        StorageDead(_6);
-        StorageDead(_15);
-        StorageDead(_14);
-        StorageDead(_5);
-        _0 = &mut (*_13);
+        StorageLive(_3);
+        _3 = &raw mut (*_1);
+        _4 = <std::ops::Range<usize> as SliceIndex<[u32]>>::get_unchecked_mut(move _2, move _3) -> [return: bb1, unwind unreachable];
+    }
+
+    bb1: {
+        StorageDead(_3);
+        _0 = &mut (*_4);
         return;
     }
 }
diff --git a/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-unwind.mir
index 2fdc21d636f..1fe7da7d2fd 100644
--- a/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-unwind.mir
+++ b/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-unwind.mir
@@ -4,106 +4,24 @@ fn slice_get_unchecked_mut_range(_1: &mut [u32], _2: std::ops::Range<usize>) ->
     debug slice => _1;
     debug index => _2;
     let mut _0: &mut [u32];
-    let mut _3: usize;
-    let mut _4: usize;
     scope 1 (inlined core::slice::<impl [u32]>::get_unchecked_mut::<std::ops::Range<usize>>) {
         debug self => _1;
-        debug ((index: std::ops::Range<usize>).0: usize) => _3;
-        debug ((index: std::ops::Range<usize>).1: usize) => _4;
-        let mut _5: *mut [u32];
-        let mut _13: *mut [u32];
+        debug index => _2;
+        let mut _3: *mut [u32];
+        let mut _4: *mut [u32];
         scope 2 {
-            scope 3 (inlined <std::ops::Range<usize> as SliceIndex<[u32]>>::get_unchecked_mut) {
-                debug ((self: std::ops::Range<usize>).0: usize) => _3;
-                debug ((self: std::ops::Range<usize>).1: usize) => _4;
-                debug slice => _5;
-                let mut _7: *mut u32;
-                let mut _8: *mut u32;
-                let mut _14: *mut [u32];
-                let mut _15: &[&str];
-                scope 4 {
-                    let _6: usize;
-                    scope 5 {
-                        debug new_len => _6;
-                        scope 10 (inlined std::ptr::mut_ptr::<impl *mut [u32]>::as_mut_ptr) {
-                            debug self => _5;
-                        }
-                        scope 11 (inlined std::ptr::mut_ptr::<impl *mut u32>::add) {
-                            debug self => _7;
-                            debug count => _3;
-                            scope 12 {
-                            }
-                        }
-                        scope 13 (inlined slice_from_raw_parts_mut::<u32>) {
-                            debug data => _8;
-                            debug len => _6;
-                            let mut _9: *mut ();
-                            scope 14 (inlined std::ptr::mut_ptr::<impl *mut u32>::cast::<()>) {
-                                debug self => _8;
-                            }
-                            scope 15 (inlined std::ptr::from_raw_parts_mut::<[u32]>) {
-                                debug data_pointer => _9;
-                                debug metadata => _6;
-                                let mut _10: *const ();
-                                let mut _11: std::ptr::metadata::PtrComponents<[u32]>;
-                                let mut _12: std::ptr::metadata::PtrRepr<[u32]>;
-                                scope 16 {
-                                }
-                            }
-                        }
-                    }
-                }
-                scope 6 (inlined std::ptr::mut_ptr::<impl *mut [u32]>::len) {
-                    debug self => _14;
-                    let mut _16: *const [u32];
-                    scope 7 (inlined std::ptr::metadata::<[u32]>) {
-                        debug ptr => _16;
-                        scope 8 {
-                        }
-                    }
-                }
-                scope 9 (inlined Arguments::<'_>::new_const) {
-                    debug pieces => _15;
-                }
-            }
         }
     }
 
     bb0: {
-        _3 = move (_2.0: usize);
-        _4 = move (_2.1: usize);
-        StorageLive(_5);
-        _5 = &raw mut (*_1);
-        StorageLive(_14);
-        StorageLive(_15);
-        StorageLive(_6);
-        StorageLive(_16);
-        _6 = SubUnchecked(_4, _3);
-        StorageLive(_8);
-        StorageLive(_7);
-        _7 = _5 as *mut u32 (PtrToPtr);
-        _8 = Offset(_7, _3);
-        StorageDead(_7);
-        StorageLive(_9);
-        _9 = _8 as *mut () (PtrToPtr);
-        StorageLive(_12);
-        StorageLive(_11);
-        StorageLive(_10);
-        _10 = _8 as *const () (PtrToPtr);
-        _11 = std::ptr::metadata::PtrComponents::<[u32]> { data_pointer: move _10, metadata: _6 };
-        StorageDead(_10);
-        _12 = std::ptr::metadata::PtrRepr::<[u32]> { const_ptr: move _11 };
-        StorageDead(_11);
-        _13 = (_12.1: *mut [u32]);
-        StorageDead(_12);
-        StorageDead(_9);
-        StorageDead(_8);
-        StorageDead(_16);
-        StorageDead(_6);
-        StorageDead(_15);
-        StorageDead(_14);
-        StorageDead(_5);
-        _0 = &mut (*_13);
+        StorageLive(_3);
+        _3 = &raw mut (*_1);
+        _4 = <std::ops::Range<usize> as SliceIndex<[u32]>>::get_unchecked_mut(move _2, move _3) -> [return: bb1, unwind continue];
+    }
+
+    bb1: {
+        StorageDead(_3);
+        _0 = &mut (*_4);
         return;
     }
 }
diff --git a/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-abort.mir b/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-abort.mir
index 05b01404b69..1eda1ac1365 100644
--- a/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-abort.mir
+++ b/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-abort.mir
@@ -42,7 +42,7 @@ fn enumerated_loop(_1: &[T], _2: impl Fn(usize, &T)) -> () {
                         scope 8 {
                             debug end_or_len => _11;
                         }
-                        scope 14 (inlined invalid::<T>) {
+                        scope 14 (inlined without_provenance::<T>) {
                             debug addr => _3;
                             scope 15 {
                             }
diff --git a/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-unwind.mir
index 1fb29f5c662..3cd79654fac 100644
--- a/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-unwind.mir
+++ b/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-unwind.mir
@@ -42,7 +42,7 @@ fn enumerated_loop(_1: &[T], _2: impl Fn(usize, &T)) -> () {
                         scope 8 {
                             debug end_or_len => _11;
                         }
-                        scope 14 (inlined invalid::<T>) {
+                        scope 14 (inlined without_provenance::<T>) {
                             debug addr => _3;
                             scope 15 {
                             }
diff --git a/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-abort.mir b/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-abort.mir
index 2e63030aa5e..a6995bbcbe3 100644
--- a/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-abort.mir
+++ b/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-abort.mir
@@ -39,7 +39,7 @@ fn forward_loop(_1: &[T], _2: impl Fn(&T)) -> () {
                         scope 8 {
                             debug end_or_len => _11;
                         }
-                        scope 14 (inlined invalid::<T>) {
+                        scope 14 (inlined without_provenance::<T>) {
                             debug addr => _3;
                             scope 15 {
                             }
diff --git a/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-unwind.mir
index b6b6b6972e9..039b7e1aa47 100644
--- a/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-unwind.mir
+++ b/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-unwind.mir
@@ -39,7 +39,7 @@ fn forward_loop(_1: &[T], _2: impl Fn(&T)) -> () {
                         scope 8 {
                             debug end_or_len => _11;
                         }
-                        scope 14 (inlined invalid::<T>) {
+                        scope 14 (inlined without_provenance::<T>) {
                             debug addr => _3;
                             scope 15 {
                             }
diff --git a/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-abort.mir b/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-abort.mir
index a78e46a0b78..2465c2381ad 100644
--- a/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-abort.mir
+++ b/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-abort.mir
@@ -44,7 +44,7 @@ fn reverse_loop(_1: &[T], _2: impl Fn(&T)) -> () {
                         scope 8 {
                             debug end_or_len => _11;
                         }
-                        scope 14 (inlined invalid::<T>) {
+                        scope 14 (inlined without_provenance::<T>) {
                             debug addr => _3;
                             scope 15 {
                             }
diff --git a/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-unwind.mir
index 4e54a23e819..c5219ac3390 100644
--- a/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-unwind.mir
+++ b/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-unwind.mir
@@ -44,7 +44,7 @@ fn reverse_loop(_1: &[T], _2: impl Fn(&T)) -> () {
                         scope 8 {
                             debug end_or_len => _11;
                         }
-                        scope 14 (inlined invalid::<T>) {
+                        scope 14 (inlined without_provenance::<T>) {
                             debug addr => _3;
                             scope 15 {
                             }
diff --git a/tests/ui-fulldeps/internal-lints/diagnostics.rs b/tests/ui-fulldeps/internal-lints/diagnostics.rs
index 5a2099865d6..dcf948d2a88 100644
--- a/tests/ui-fulldeps/internal-lints/diagnostics.rs
+++ b/tests/ui-fulldeps/internal-lints/diagnostics.rs
@@ -55,8 +55,11 @@ impl<'a, G: EmissionGuarantee> IntoDiagnostic<'a, G> for TranslatableInIntoDiagn
 pub struct UntranslatableInAddToDiagnostic;
 
 impl AddToDiagnostic for UntranslatableInAddToDiagnostic {
-    fn add_to_diagnostic_with<F: SubdiagnosticMessageOp>(self, diag: &mut Diagnostic, _: F)
-    {
+    fn add_to_diagnostic_with<G: EmissionGuarantee, F: SubdiagnosticMessageOp<G>>(
+        self,
+        diag: &mut DiagnosticBuilder<'_, G>,
+        f: F,
+    ) {
         diag.note("untranslatable diagnostic");
         //~^ ERROR diagnostics should be created using translatable messages
     }
@@ -65,7 +68,11 @@ impl AddToDiagnostic for UntranslatableInAddToDiagnostic {
 pub struct TranslatableInAddToDiagnostic;
 
 impl AddToDiagnostic for TranslatableInAddToDiagnostic {
-    fn add_to_diagnostic_with<F: SubdiagnosticMessageOp>(self, diag: &mut Diagnostic, _: F) {
+    fn add_to_diagnostic_with<G: EmissionGuarantee, F: SubdiagnosticMessageOp<G>>(
+        self,
+        diag: &mut DiagnosticBuilder<'_, G>,
+        f: F,
+    ) {
         diag.note(crate::fluent_generated::no_crate_note);
     }
 }
diff --git a/tests/ui-fulldeps/internal-lints/diagnostics.stderr b/tests/ui-fulldeps/internal-lints/diagnostics.stderr
index 108b7c8ea9c..a69a71bf50e 100644
--- a/tests/ui-fulldeps/internal-lints/diagnostics.stderr
+++ b/tests/ui-fulldeps/internal-lints/diagnostics.stderr
@@ -11,13 +11,13 @@ LL | #![deny(rustc::untranslatable_diagnostic)]
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: diagnostics should be created using translatable messages
-  --> $DIR/diagnostics.rs:60:14
+  --> $DIR/diagnostics.rs:63:14
    |
 LL |         diag.note("untranslatable diagnostic");
    |              ^^^^
 
 error: diagnostics should only be created in `IntoDiagnostic`/`AddToDiagnostic` impls
-  --> $DIR/diagnostics.rs:74:21
+  --> $DIR/diagnostics.rs:81:21
    |
 LL |     let _diag = dcx.struct_err(crate::fluent_generated::no_crate_example);
    |                     ^^^^^^^^^^
@@ -29,13 +29,13 @@ LL | #![deny(rustc::diagnostic_outside_of_impl)]
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: diagnostics should only be created in `IntoDiagnostic`/`AddToDiagnostic` impls
-  --> $DIR/diagnostics.rs:77:21
+  --> $DIR/diagnostics.rs:84:21
    |
 LL |     let _diag = dcx.struct_err("untranslatable diagnostic");
    |                     ^^^^^^^^^^
 
 error: diagnostics should be created using translatable messages
-  --> $DIR/diagnostics.rs:77:21
+  --> $DIR/diagnostics.rs:84:21
    |
 LL |     let _diag = dcx.struct_err("untranslatable diagnostic");
    |                     ^^^^^^^^^^
diff --git a/tests/ui-fulldeps/session-diagnostic/diagnostic-derive-doc-comment-field.stderr b/tests/ui-fulldeps/session-diagnostic/diagnostic-derive-doc-comment-field.stderr
index f07b69326b0..7844e60c654 100644
--- a/tests/ui-fulldeps/session-diagnostic/diagnostic-derive-doc-comment-field.stderr
+++ b/tests/ui-fulldeps/session-diagnostic/diagnostic-derive-doc-comment-field.stderr
@@ -9,8 +9,8 @@ LL |     arg: NotIntoDiagnosticArg,
    |
    = help: normalized in stderr
 note: required by a bound in `DiagnosticBuilder::<'a, G>::arg`
-  --> $COMPILER_DIR/rustc_errors/src/diagnostic_builder.rs:LL:CC
-   = note: this error originates in the macro `forward` (in Nightly builds, run with -Z macro-backtrace for more info)
+  --> $COMPILER_DIR/rustc_errors/src/diagnostic.rs:LL:CC
+   = note: this error originates in the macro `with_fn` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error[E0277]: the trait bound `NotIntoDiagnosticArg: IntoDiagnosticArg` is not satisfied
   --> $DIR/diagnostic-derive-doc-comment-field.rs:46:10
@@ -22,8 +22,9 @@ LL |     arg: NotIntoDiagnosticArg,
    |          ^^^^^^^^^^^^^^^^^^^^ the trait `IntoDiagnosticArg` is not implemented for `NotIntoDiagnosticArg`
    |
    = help: normalized in stderr
-note: required by a bound in `Diagnostic::arg`
+note: required by a bound in `DiagnosticBuilder::<'a, G>::arg`
   --> $COMPILER_DIR/rustc_errors/src/diagnostic.rs:LL:CC
+   = note: this error originates in the macro `with_fn` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: aborting due to 2 previous errors
 
diff --git a/tests/ui-fulldeps/session-diagnostic/diagnostic-derive.rs b/tests/ui-fulldeps/session-diagnostic/diagnostic-derive.rs
index 6cc6fdfc0eb..856f32fafa0 100644
--- a/tests/ui-fulldeps/session-diagnostic/diagnostic-derive.rs
+++ b/tests/ui-fulldeps/session-diagnostic/diagnostic-derive.rs
@@ -1,8 +1,8 @@
 // check-fail
 // Tests error conditions for specifying diagnostics using #[derive(Diagnostic)]
-
 // normalize-stderr-test "the following other types implement trait `IntoDiagnosticArg`:(?:.*\n){0,9}\s+and \d+ others" -> "normalized in stderr"
-// normalize-stderr-test "diagnostic_builder\.rs:[0-9]+:[0-9]+" -> "diagnostic_builder.rs:LL:CC"
+// normalize-stderr-test "(COMPILER_DIR/.*\.rs):[0-9]+:[0-9]+" -> "$1:LL:CC"
+
 // The proc_macro2 crate handles spans differently when on beta/stable release rather than nightly,
 // changing the output of this test. Since Diagnostic is strictly internal to the compiler
 // the test is just ignored on stable and beta:
diff --git a/tests/ui-fulldeps/session-diagnostic/diagnostic-derive.stderr b/tests/ui-fulldeps/session-diagnostic/diagnostic-derive.stderr
index f2dbc718c76..8732629db47 100644
--- a/tests/ui-fulldeps/session-diagnostic/diagnostic-derive.stderr
+++ b/tests/ui-fulldeps/session-diagnostic/diagnostic-derive.stderr
@@ -629,8 +629,8 @@ LL |     other: Hello,
    |
    = help: normalized in stderr
 note: required by a bound in `DiagnosticBuilder::<'a, G>::arg`
-  --> $COMPILER_DIR/rustc_errors/src/diagnostic_builder.rs:LL:CC
-   = note: this error originates in the macro `forward` (in Nightly builds, run with -Z macro-backtrace for more info)
+  --> $COMPILER_DIR/rustc_errors/src/diagnostic.rs:LL:CC
+   = note: this error originates in the macro `with_fn` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: aborting due to 86 previous errors
 
diff --git a/tests/ui-fulldeps/stable-mir/compilation-result.rs b/tests/ui-fulldeps/stable-mir/compilation-result.rs
index e6dd9fa132d..cd61d599eb4 100644
--- a/tests/ui-fulldeps/stable-mir/compilation-result.rs
+++ b/tests/ui-fulldeps/stable-mir/compilation-result.rs
@@ -55,7 +55,7 @@ fn test_skipped(mut args: Vec<String>) {
 fn test_failed(mut args: Vec<String>) {
     args.push("--cfg=broken".to_string());
     let result = run!(args, || unreachable!() as ControlFlow<()>);
-    assert_eq!(result, Err(stable_mir::CompilerError::CompilationFailed));
+    assert_eq!(result, Err(stable_mir::CompilerError::Failed));
 }
 
 /// Test that we are able to pass a closure and set the return according to the captured value.
diff --git a/tests/ui/asm/bad-arch.stderr b/tests/ui/asm/bad-arch.stderr
index 23aad9908ef..c6f726600eb 100644
--- a/tests/ui/asm/bad-arch.stderr
+++ b/tests/ui/asm/bad-arch.stderr
@@ -9,8 +9,6 @@ error[E0472]: inline assembly is unsupported on this target
    |
 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
 
diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.rs b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.rs
index 0315938a7ed..be8162c86b9 100644
--- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.rs
+++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.rs
@@ -4,12 +4,12 @@ trait Foo {
     const BAR: u32;
 }
 
-const IMPL_REF_BAR: u32 = GlobalImplRef::BAR;
+const IMPL_REF_BAR: u32 = GlobalImplRef::BAR; //~ ERROR E0391
 
 struct GlobalImplRef;
 
 impl GlobalImplRef {
-    const BAR: u32 = IMPL_REF_BAR; //~ ERROR E0391
+    const BAR: u32 = IMPL_REF_BAR;
 }
 
 fn main() {}
diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr
index 88b17be601c..bf37f537a49 100644
--- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr
+++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr
@@ -1,14 +1,9 @@
-error[E0391]: cycle detected when elaborating drops for `<impl at $DIR/issue-24949-assoc-const-static-recursion-impl.rs:11:1: 11:19>::BAR`
-  --> $DIR/issue-24949-assoc-const-static-recursion-impl.rs:12:22
-   |
-LL |     const BAR: u32 = IMPL_REF_BAR;
-   |                      ^^^^^^^^^^^^
-   |
-note: ...which requires simplifying constant for the type system `IMPL_REF_BAR`...
+error[E0391]: cycle detected when simplifying constant for the type system `IMPL_REF_BAR`
   --> $DIR/issue-24949-assoc-const-static-recursion-impl.rs:7:1
    |
 LL | const IMPL_REF_BAR: u32 = GlobalImplRef::BAR;
    | ^^^^^^^^^^^^^^^^^^^^^^^
+   |
 note: ...which requires const-evaluating + checking `IMPL_REF_BAR`...
   --> $DIR/issue-24949-assoc-const-static-recursion-impl.rs:7:27
    |
@@ -29,7 +24,12 @@ note: ...which requires caching mir of `<impl at $DIR/issue-24949-assoc-const-st
    |
 LL |     const BAR: u32 = IMPL_REF_BAR;
    |     ^^^^^^^^^^^^^^
-   = note: ...which again requires elaborating drops for `<impl at $DIR/issue-24949-assoc-const-static-recursion-impl.rs:11:1: 11:19>::BAR`, completing the cycle
+note: ...which requires elaborating drops for `<impl at $DIR/issue-24949-assoc-const-static-recursion-impl.rs:11:1: 11:19>::BAR`...
+  --> $DIR/issue-24949-assoc-const-static-recursion-impl.rs:12:22
+   |
+LL |     const BAR: u32 = IMPL_REF_BAR;
+   |                      ^^^^^^^^^^^^
+   = note: ...which again requires simplifying constant for the type system `IMPL_REF_BAR`, completing the cycle
    = note: cycle used when running analysis passes on this crate
    = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr
index fd1b4f2f964..d0ada37b99e 100644
--- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr
+++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr
@@ -1,9 +1,14 @@
-error[E0391]: cycle detected when elaborating drops for `FooDefault::BAR`
+error[E0391]: cycle detected when caching mir of `FooDefault::BAR` for CTFE
+  --> $DIR/issue-24949-assoc-const-static-recursion-trait-default.rs:8:5
+   |
+LL |     const BAR: u32 = DEFAULT_REF_BAR;
+   |     ^^^^^^^^^^^^^^
+   |
+note: ...which requires elaborating drops for `FooDefault::BAR`...
   --> $DIR/issue-24949-assoc-const-static-recursion-trait-default.rs:8:22
    |
 LL |     const BAR: u32 = DEFAULT_REF_BAR;
    |                      ^^^^^^^^^^^^^^^
-   |
 note: ...which requires simplifying constant for the type system `DEFAULT_REF_BAR`...
   --> $DIR/issue-24949-assoc-const-static-recursion-trait-default.rs:11:1
    |
@@ -24,13 +29,12 @@ note: ...which requires const-evaluating + checking `FooDefault::BAR`...
    |
 LL |     const BAR: u32 = DEFAULT_REF_BAR;
    |     ^^^^^^^^^^^^^^
-note: ...which requires caching mir of `FooDefault::BAR` for CTFE...
+   = note: ...which again requires caching mir of `FooDefault::BAR` for CTFE, completing the cycle
+note: cycle used when const-evaluating + checking `FooDefault::BAR`
   --> $DIR/issue-24949-assoc-const-static-recursion-trait-default.rs:8:5
    |
 LL |     const BAR: u32 = DEFAULT_REF_BAR;
    |     ^^^^^^^^^^^^^^
-   = note: ...which again requires elaborating drops for `FooDefault::BAR`, completing the cycle
-   = note: cycle used when running analysis passes on this crate
    = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
 error: aborting due to 1 previous error
diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.rs b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.rs
index 68b653ff3c5..62af8534340 100644
--- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.rs
+++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.rs
@@ -4,12 +4,12 @@ trait Foo {
     const BAR: u32;
 }
 
-const TRAIT_REF_BAR: u32 = <GlobalTraitRef>::BAR;
+const TRAIT_REF_BAR: u32 = <GlobalTraitRef>::BAR; //~ ERROR E0391
 
 struct GlobalTraitRef;
 
 impl Foo for GlobalTraitRef {
-    const BAR: u32 = TRAIT_REF_BAR; //~ ERROR E0391
+    const BAR: u32 = TRAIT_REF_BAR;
 }
 
 fn main() {}
diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr
index 303400f928e..317af7975aa 100644
--- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr
+++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr
@@ -1,14 +1,9 @@
-error[E0391]: cycle detected when elaborating drops for `<impl at $DIR/issue-24949-assoc-const-static-recursion-trait.rs:11:1: 11:28>::BAR`
-  --> $DIR/issue-24949-assoc-const-static-recursion-trait.rs:12:22
-   |
-LL |     const BAR: u32 = TRAIT_REF_BAR;
-   |                      ^^^^^^^^^^^^^
-   |
-note: ...which requires simplifying constant for the type system `TRAIT_REF_BAR`...
+error[E0391]: cycle detected when simplifying constant for the type system `TRAIT_REF_BAR`
   --> $DIR/issue-24949-assoc-const-static-recursion-trait.rs:7:1
    |
 LL | const TRAIT_REF_BAR: u32 = <GlobalTraitRef>::BAR;
    | ^^^^^^^^^^^^^^^^^^^^^^^^
+   |
 note: ...which requires const-evaluating + checking `TRAIT_REF_BAR`...
   --> $DIR/issue-24949-assoc-const-static-recursion-trait.rs:7:28
    |
@@ -29,7 +24,12 @@ note: ...which requires caching mir of `<impl at $DIR/issue-24949-assoc-const-st
    |
 LL |     const BAR: u32 = TRAIT_REF_BAR;
    |     ^^^^^^^^^^^^^^
-   = note: ...which again requires elaborating drops for `<impl at $DIR/issue-24949-assoc-const-static-recursion-trait.rs:11:1: 11:28>::BAR`, completing the cycle
+note: ...which requires elaborating drops for `<impl at $DIR/issue-24949-assoc-const-static-recursion-trait.rs:11:1: 11:28>::BAR`...
+  --> $DIR/issue-24949-assoc-const-static-recursion-trait.rs:12:22
+   |
+LL |     const BAR: u32 = TRAIT_REF_BAR;
+   |                      ^^^^^^^^^^^^^
+   = note: ...which again requires simplifying constant for the type system `TRAIT_REF_BAR`, completing the cycle
    = note: cycle used when running analysis passes on this crate
    = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
diff --git a/tests/ui/associated-type-bounds/no-gat-position.rs b/tests/ui/associated-type-bounds/no-gat-position.rs
new file mode 100644
index 00000000000..01740e6242e
--- /dev/null
+++ b/tests/ui/associated-type-bounds/no-gat-position.rs
@@ -0,0 +1,18 @@
+#![feature(associated_type_bounds)]
+
+// Test for <https://github.com/rust-lang/rust/issues/119857>.
+
+pub trait Iter {
+    type Item<'a>: 'a where Self: 'a;
+
+    fn next<'a>(&'a mut self) -> Option<Self::Item<'a, As1: Copy>>;
+    //~^ ERROR associated type bindings are not allowed here
+}
+
+impl Iter for () {
+    type Item<'a> = &'a mut [()];
+
+    fn next<'a>(&'a mut self) -> Option<Self::Item<'a>> { None }
+}
+
+fn main() {}
diff --git a/tests/ui/associated-type-bounds/no-gat-position.stderr b/tests/ui/associated-type-bounds/no-gat-position.stderr
new file mode 100644
index 00000000000..5692b2c7d09
--- /dev/null
+++ b/tests/ui/associated-type-bounds/no-gat-position.stderr
@@ -0,0 +1,9 @@
+error[E0229]: associated type bindings are not allowed here
+  --> $DIR/no-gat-position.rs:8:56
+   |
+LL |     fn next<'a>(&'a mut self) -> Option<Self::Item<'a, As1: Copy>>;
+   |                                                        ^^^^^^^^^ associated type not allowed here
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0229`.
diff --git a/tests/ui/async-await/async-fn/auxiliary/block-on.rs b/tests/ui/async-await/async-fn/auxiliary/block-on.rs
new file mode 100644
index 00000000000..dcb710fc97c
--- /dev/null
+++ b/tests/ui/async-await/async-fn/auxiliary/block-on.rs
@@ -0,0 +1,20 @@
+//@ edition: 2021
+
+#![feature(async_closure, noop_waker)]
+
+use std::future::Future;
+use std::pin::pin;
+use std::task::*;
+
+pub fn block_on<T>(fut: impl Future<Output = T>) -> T {
+    let mut fut = pin!(fut);
+    // Poll loop, just to test the future...
+    let ctx = &mut Context::from_waker(Waker::noop());
+
+    loop {
+        match unsafe { fut.as_mut().poll(ctx) } {
+            Poll::Pending => {}
+            Poll::Ready(t) => break t,
+        }
+    }
+}
diff --git a/tests/ui/async-await/async-fn/impl-header.rs b/tests/ui/async-await/async-fn/impl-header.rs
index b9ae90292bb..9af5f1f42a9 100644
--- a/tests/ui/async-await/async-fn/impl-header.rs
+++ b/tests/ui/async-await/async-fn/impl-header.rs
@@ -3,6 +3,10 @@
 struct F;
 
 impl async Fn<()> for F {}
-//~^ ERROR expected type, found keyword `async`
+//~^ ERROR `async` trait implementations are unsupported
+//~| ERROR the precise format of `Fn`-family traits' type parameters is subject to change
+//~| ERROR manual implementations of `Fn` are experimental
+//~| ERROR expected a `FnMut()` closure, found `F`
+//~| ERROR not all trait items implemented, missing: `call`
 
 fn main() {}
diff --git a/tests/ui/async-await/async-fn/impl-header.stderr b/tests/ui/async-await/async-fn/impl-header.stderr
index 02cb4326242..2fb862af04e 100644
--- a/tests/ui/async-await/async-fn/impl-header.stderr
+++ b/tests/ui/async-await/async-fn/impl-header.stderr
@@ -1,8 +1,47 @@
-error: expected type, found keyword `async`
+error: `async` trait implementations are unsupported
   --> $DIR/impl-header.rs:5:6
    |
 LL | impl async Fn<()> for F {}
-   |      ^^^^^ expected type
+   |      ^^^^^
 
-error: aborting due to 1 previous error
+error[E0658]: the precise format of `Fn`-family traits' type parameters is subject to change
+  --> $DIR/impl-header.rs:5:12
+   |
+LL | impl async Fn<()> for F {}
+   |            ^^^^^^
+   |
+   = note: see issue #29625 <https://github.com/rust-lang/rust/issues/29625> for more information
+   = help: add `#![feature(unboxed_closures)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
+
+error[E0183]: manual implementations of `Fn` are experimental
+  --> $DIR/impl-header.rs:5:12
+   |
+LL | impl async Fn<()> for F {}
+   |            ^^^^^^ manual implementations of `Fn` are experimental
+   |
+   = help: add `#![feature(unboxed_closures)]` to the crate attributes to enable
+
+error[E0277]: expected a `FnMut()` closure, found `F`
+  --> $DIR/impl-header.rs:5:23
+   |
+LL | impl async Fn<()> for F {}
+   |                       ^ expected an `FnMut()` closure, found `F`
+   |
+   = help: the trait `FnMut<()>` is not implemented for `F`
+   = note: wrap the `F` in a closure with no arguments: `|| { /* code */ }`
+note: required by a bound in `Fn`
+  --> $SRC_DIR/core/src/ops/function.rs:LL:COL
+
+error[E0046]: not all trait items implemented, missing: `call`
+  --> $DIR/impl-header.rs:5:1
+   |
+LL | impl async Fn<()> for F {}
+   | ^^^^^^^^^^^^^^^^^^^^^^^ missing `call` in implementation
+   |
+   = help: implement the missing item: `fn call(&self, _: ()) -> <Self as FnOnce<()>>::Output { todo!() }`
+
+error: aborting due to 5 previous errors
 
+Some errors have detailed explanations: E0046, E0183, E0277, E0658.
+For more information about an error, try `rustc --explain E0046`.
diff --git a/tests/ui/async-await/async-fn/mbe-async-trait-bound-theoretical-regression.rs b/tests/ui/async-await/async-fn/mbe-async-trait-bound-theoretical-regression.rs
new file mode 100644
index 00000000000..abc429772fd
--- /dev/null
+++ b/tests/ui/async-await/async-fn/mbe-async-trait-bound-theoretical-regression.rs
@@ -0,0 +1,21 @@
+// Demonstrates and records a theoretical regressions / breaking changes caused by the
+// introduction of async trait bounds.
+
+// Setting the edition to 2018 since we don't regress `demo! { dyn async }` in Rust <2018.
+//@ edition:2018
+
+macro_rules! demo {
+    ($ty:ty) => { compile_error!("ty"); };
+    //~^ ERROR ty
+    //~| ERROR ty
+    (impl $c:ident Trait) => {};
+    (dyn $c:ident Trait) => {};
+}
+
+demo! { impl async Trait }
+//~^ ERROR async closures are unstable
+
+demo! { dyn async Trait }
+//~^ ERROR async closures are unstable
+
+fn main() {}
diff --git a/tests/ui/async-await/async-fn/mbe-async-trait-bound-theoretical-regression.stderr b/tests/ui/async-await/async-fn/mbe-async-trait-bound-theoretical-regression.stderr
new file mode 100644
index 00000000000..13b8e72b49d
--- /dev/null
+++ b/tests/ui/async-await/async-fn/mbe-async-trait-bound-theoretical-regression.stderr
@@ -0,0 +1,47 @@
+error: ty
+  --> $DIR/mbe-async-trait-bound-theoretical-regression.rs:8:19
+   |
+LL |     ($ty:ty) => { compile_error!("ty"); };
+   |                   ^^^^^^^^^^^^^^^^^^^^
+...
+LL | demo! { impl async Trait }
+   | -------------------------- in this macro invocation
+   |
+   = note: this error originates in the macro `demo` (in Nightly builds, run with -Z macro-backtrace for more info)
+
+error: ty
+  --> $DIR/mbe-async-trait-bound-theoretical-regression.rs:8:19
+   |
+LL |     ($ty:ty) => { compile_error!("ty"); };
+   |                   ^^^^^^^^^^^^^^^^^^^^
+...
+LL | demo! { dyn async Trait }
+   | ------------------------- in this macro invocation
+   |
+   = note: this error originates in the macro `demo` (in Nightly builds, run with -Z macro-backtrace for more info)
+
+error[E0658]: async closures are unstable
+  --> $DIR/mbe-async-trait-bound-theoretical-regression.rs:15:14
+   |
+LL | demo! { impl async Trait }
+   |              ^^^^^
+   |
+   = note: see issue #62290 <https://github.com/rust-lang/rust/issues/62290> for more information
+   = help: add `#![feature(async_closure)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
+   = help: to use an async block, remove the `||`: `async {`
+
+error[E0658]: async closures are unstable
+  --> $DIR/mbe-async-trait-bound-theoretical-regression.rs:18:13
+   |
+LL | demo! { dyn async Trait }
+   |             ^^^^^
+   |
+   = note: see issue #62290 <https://github.com/rust-lang/rust/issues/62290> for more information
+   = help: add `#![feature(async_closure)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
+   = help: to use an async block, remove the `||`: `async {`
+
+error: aborting due to 4 previous errors
+
+For more information about this error, try `rustc --explain E0658`.
diff --git a/tests/ui/async-await/async-fn/simple.rs b/tests/ui/async-await/async-fn/simple.rs
index e2a183a8c0b..21972ba5aef 100644
--- a/tests/ui/async-await/async-fn/simple.rs
+++ b/tests/ui/async-await/async-fn/simple.rs
@@ -1,8 +1,11 @@
+//@ aux-build:block-on.rs
 //@ edition: 2021
 //@ build-pass
 
 #![feature(async_fn_traits)]
 
+extern crate block_on;
+
 use std::ops::AsyncFn;
 
 async fn foo() {}
@@ -12,5 +15,7 @@ async fn call_asyncly(f: impl AsyncFn(i32) -> i32) -> i32 {
 }
 
 fn main() {
-    let fut = call_asyncly(|x| async move { x + 1 });
+    block_on::block_on(async {
+        call_asyncly(|x| async move { x + 1 }).await;
+    });
 }
diff --git a/tests/ui/async-await/async-fn/trait-bounds-in-macro.rs b/tests/ui/async-await/async-fn/trait-bounds-in-macro.rs
new file mode 100644
index 00000000000..329a1528e8b
--- /dev/null
+++ b/tests/ui/async-await/async-fn/trait-bounds-in-macro.rs
@@ -0,0 +1,12 @@
+//@ edition: 2021
+
+macro_rules! x {
+    ($x:item) => {}
+}
+
+x! {
+    async fn foo() -> impl async Fn() { }
+    //~^ ERROR async closures are unstable
+}
+
+fn main() {}
diff --git a/tests/ui/async-await/async-fn/trait-bounds-in-macro.stderr b/tests/ui/async-await/async-fn/trait-bounds-in-macro.stderr
new file mode 100644
index 00000000000..f68c09737db
--- /dev/null
+++ b/tests/ui/async-await/async-fn/trait-bounds-in-macro.stderr
@@ -0,0 +1,14 @@
+error[E0658]: async closures are unstable
+  --> $DIR/trait-bounds-in-macro.rs:8:28
+   |
+LL |     async fn foo() -> impl async Fn() { }
+   |                            ^^^^^
+   |
+   = note: see issue #62290 <https://github.com/rust-lang/rust/issues/62290> for more information
+   = help: add `#![feature(async_closure)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
+   = help: to use an async block, remove the `||`: `async {`
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0658`.
diff --git a/tests/ui/async-await/for-await-passthrough.rs b/tests/ui/async-await/for-await-passthrough.rs
index 3769ef60b01..e09e843332e 100644
--- a/tests/ui/async-await/for-await-passthrough.rs
+++ b/tests/ui/async-await/for-await-passthrough.rs
@@ -4,8 +4,6 @@
 #![feature(async_iterator, async_iter_from_iter, const_waker, async_for_loop, noop_waker,
            gen_blocks)]
 
-use std::future::Future;
-
 async gen fn async_iter() -> i32 {
     let iter = core::async_iter::from_iter(0..3);
     for await i in iter {
diff --git a/tests/ui/auto-traits/issue-117789.rs b/tests/ui/auto-traits/issue-117789.rs
index 0c30931a1b5..63f796771db 100644
--- a/tests/ui/auto-traits/issue-117789.rs
+++ b/tests/ui/auto-traits/issue-117789.rs
@@ -1,5 +1,3 @@
-#![deny(suspicious_auto_trait_impls)]
-
 auto trait Trait<P> {} //~ ERROR auto traits cannot have generic parameters
 //~^ ERROR auto traits are experimental and possibly buggy
 impl<P> Trait<P> for () {}
diff --git a/tests/ui/auto-traits/issue-117789.stderr b/tests/ui/auto-traits/issue-117789.stderr
index 1f8880b1ef4..99efb213417 100644
--- a/tests/ui/auto-traits/issue-117789.stderr
+++ b/tests/ui/auto-traits/issue-117789.stderr
@@ -1,5 +1,5 @@
 error[E0567]: auto traits cannot have generic parameters
-  --> $DIR/issue-117789.rs:3:17
+  --> $DIR/issue-117789.rs:1:17
    |
 LL | auto trait Trait<P> {}
    |            -----^^^ help: remove the parameters
@@ -7,7 +7,7 @@ LL | auto trait Trait<P> {}
    |            auto trait cannot have generic parameters
 
 error[E0658]: auto traits are experimental and possibly buggy
-  --> $DIR/issue-117789.rs:3:1
+  --> $DIR/issue-117789.rs:1:1
    |
 LL | auto trait Trait<P> {}
    | ^^^^^^^^^^^^^^^^^^^^^^
diff --git a/tests/ui/auto-traits/issue-83857-ub.rs b/tests/ui/auto-traits/issue-83857-ub.rs
index f9b47d2b0c6..20abfdd851a 100644
--- a/tests/ui/auto-traits/issue-83857-ub.rs
+++ b/tests/ui/auto-traits/issue-83857-ub.rs
@@ -1,4 +1,3 @@
-#![allow(suspicious_auto_trait_impls)]
 // Tests that we don't incorrectly allow overlap between a builtin auto trait
 // impl and a user written one. See #83857 for more details
 
diff --git a/tests/ui/auto-traits/issue-83857-ub.stderr b/tests/ui/auto-traits/issue-83857-ub.stderr
index 6372bdfe762..20bfe7e36ca 100644
--- a/tests/ui/auto-traits/issue-83857-ub.stderr
+++ b/tests/ui/auto-traits/issue-83857-ub.stderr
@@ -1,12 +1,12 @@
 error[E0277]: `Foo<T, U>` cannot be sent between threads safely
-  --> $DIR/issue-83857-ub.rs:22:38
+  --> $DIR/issue-83857-ub.rs:21:38
    |
 LL | fn generic<T, U>(v: Foo<T, U>, f: fn(<Foo<T, U> as WithAssoc>::Output) -> i32) {
    |                                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ `Foo<T, U>` cannot be sent between threads safely
    |
    = help: the trait `Send` is not implemented for `Foo<T, U>`, which is required by `Foo<T, U>: WithAssoc`
 note: required for `Foo<T, U>` to implement `WithAssoc`
-  --> $DIR/issue-83857-ub.rs:15:15
+  --> $DIR/issue-83857-ub.rs:14:15
    |
 LL | impl<T: Send> WithAssoc for T {
    |         ----  ^^^^^^^^^     ^
@@ -18,7 +18,7 @@ LL | fn generic<T, U>(v: Foo<T, U>, f: fn(<Foo<T, U> as WithAssoc>::Output) -> i
    |                                                                                +++++++++++++++++++++
 
 error[E0277]: `Foo<T, U>` cannot be sent between threads safely
-  --> $DIR/issue-83857-ub.rs:22:80
+  --> $DIR/issue-83857-ub.rs:21:80
    |
 LL |   fn generic<T, U>(v: Foo<T, U>, f: fn(<Foo<T, U> as WithAssoc>::Output) -> i32) {
    |  ________________________________________________________________________________^
@@ -31,7 +31,7 @@ LL | | }
    |
    = help: the trait `Send` is not implemented for `Foo<T, U>`, which is required by `Foo<T, U>: WithAssoc`
 note: required for `Foo<T, U>` to implement `WithAssoc`
-  --> $DIR/issue-83857-ub.rs:15:15
+  --> $DIR/issue-83857-ub.rs:14:15
    |
 LL | impl<T: Send> WithAssoc for T {
    |         ----  ^^^^^^^^^     ^
@@ -43,7 +43,7 @@ LL | fn generic<T, U>(v: Foo<T, U>, f: fn(<Foo<T, U> as WithAssoc>::Output) -> i
    |                                                                                +++++++++++++++++++++
 
 error[E0277]: `Foo<T, U>` cannot be sent between threads safely
-  --> $DIR/issue-83857-ub.rs:25:11
+  --> $DIR/issue-83857-ub.rs:24:11
    |
 LL |     f(foo(v));
    |       --- ^ `Foo<T, U>` cannot be sent between threads safely
@@ -52,7 +52,7 @@ LL |     f(foo(v));
    |
    = help: the trait `Send` is not implemented for `Foo<T, U>`
 note: required by a bound in `foo`
-  --> $DIR/issue-83857-ub.rs:29:11
+  --> $DIR/issue-83857-ub.rs:28:11
    |
 LL | fn foo<T: Send>(x: T) -> <T as WithAssoc>::Output {
    |           ^^^^ required by this bound in `foo`
diff --git a/tests/ui/auto-traits/suspicious-impls-lint.rs b/tests/ui/auto-traits/suspicious-impls-lint.rs
deleted file mode 100644
index 7712e84f4a2..00000000000
--- a/tests/ui/auto-traits/suspicious-impls-lint.rs
+++ /dev/null
@@ -1,50 +0,0 @@
-#![deny(suspicious_auto_trait_impls)]
-
-use std::marker::PhantomData;
-
-struct MayImplementSendOk<T>(T);
-unsafe impl<T: Send> Send for MayImplementSendOk<T> {} // ok
-
-struct MayImplementSendErr<T>(T);
-unsafe impl<T: Send> Send for MayImplementSendErr<&T> {}
-//~^ ERROR
-//~| WARNING this will change its meaning
-
-struct ContainsNonSendDirect<T>(*const T);
-unsafe impl<T: Send> Send for ContainsNonSendDirect<&T> {} // ok
-
-struct ContainsPtr<T>(*const T);
-struct ContainsIndirectNonSend<T>(ContainsPtr<T>);
-unsafe impl<T: Send> Send for ContainsIndirectNonSend<&T> {} // ok
-
-struct ContainsVec<T>(Vec<T>);
-unsafe impl Send for ContainsVec<i32> {}
-//~^ ERROR
-//~| WARNING this will change its meaning
-
-struct TwoParams<T, U>(T, U);
-unsafe impl<T: Send, U: Send> Send for TwoParams<T, U> {} // ok
-
-struct TwoParamsFlipped<T, U>(T, U);
-unsafe impl<T: Send, U: Send> Send for TwoParamsFlipped<U, T> {} // ok
-
-struct TwoParamsSame<T, U>(T, U);
-unsafe impl<T: Send> Send for TwoParamsSame<T, T> {}
-//~^ ERROR
-//~| WARNING this will change its meaning
-
-pub struct WithPhantomDataNonSend<T, U>(PhantomData<*const T>, U);
-unsafe impl<T> Send for WithPhantomDataNonSend<T, i8> {} // ok
-
-pub struct WithPhantomDataSend<T, U>(PhantomData<T>, U);
-unsafe impl<T> Send for WithPhantomDataSend<*const T, i8> {}
-//~^ ERROR
-//~| WARNING this will change its meaning
-
-pub struct WithLifetime<'a, T>(&'a (), T);
-unsafe impl<T> Send for WithLifetime<'static, T> {} // ok
-unsafe impl<T> Sync for WithLifetime<'static, Vec<T>> {}
-//~^ ERROR
-//~| WARNING this will change its meaning
-
-fn main() {}
diff --git a/tests/ui/auto-traits/suspicious-impls-lint.stderr b/tests/ui/auto-traits/suspicious-impls-lint.stderr
deleted file mode 100644
index 9cd4e79f851..00000000000
--- a/tests/ui/auto-traits/suspicious-impls-lint.stderr
+++ /dev/null
@@ -1,82 +0,0 @@
-error: cross-crate traits with a default impl, like `Send`, should not be specialized
-  --> $DIR/suspicious-impls-lint.rs:9:1
-   |
-LL | unsafe impl<T: Send> Send for MayImplementSendErr<&T> {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = warning: this will change its meaning in a future release!
-   = note: for more information, see issue #93367 <https://github.com/rust-lang/rust/issues/93367>
-   = note: `&T` is not a generic parameter
-note: try using the same sequence of generic parameters as the struct definition
-  --> $DIR/suspicious-impls-lint.rs:8:1
-   |
-LL | struct MayImplementSendErr<T>(T);
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-note: the lint level is defined here
-  --> $DIR/suspicious-impls-lint.rs:1:9
-   |
-LL | #![deny(suspicious_auto_trait_impls)]
-   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-error: cross-crate traits with a default impl, like `Send`, should not be specialized
-  --> $DIR/suspicious-impls-lint.rs:21:1
-   |
-LL | unsafe impl Send for ContainsVec<i32> {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = warning: this will change its meaning in a future release!
-   = note: for more information, see issue #93367 <https://github.com/rust-lang/rust/issues/93367>
-   = note: `i32` is not a generic parameter
-note: try using the same sequence of generic parameters as the struct definition
-  --> $DIR/suspicious-impls-lint.rs:20:1
-   |
-LL | struct ContainsVec<T>(Vec<T>);
-   | ^^^^^^^^^^^^^^^^^^^^^
-
-error: cross-crate traits with a default impl, like `Send`, should not be specialized
-  --> $DIR/suspicious-impls-lint.rs:32:1
-   |
-LL | unsafe impl<T: Send> Send for TwoParamsSame<T, T> {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = warning: this will change its meaning in a future release!
-   = note: for more information, see issue #93367 <https://github.com/rust-lang/rust/issues/93367>
-   = note: `T` is mentioned multiple times
-note: try using the same sequence of generic parameters as the struct definition
-  --> $DIR/suspicious-impls-lint.rs:31:1
-   |
-LL | struct TwoParamsSame<T, U>(T, U);
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-error: cross-crate traits with a default impl, like `Send`, should not be specialized
-  --> $DIR/suspicious-impls-lint.rs:40:1
-   |
-LL | unsafe impl<T> Send for WithPhantomDataSend<*const T, i8> {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = warning: this will change its meaning in a future release!
-   = note: for more information, see issue #93367 <https://github.com/rust-lang/rust/issues/93367>
-   = note: `*const T` is not a generic parameter
-note: try using the same sequence of generic parameters as the struct definition
-  --> $DIR/suspicious-impls-lint.rs:39:1
-   |
-LL | pub struct WithPhantomDataSend<T, U>(PhantomData<T>, U);
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-error: cross-crate traits with a default impl, like `Sync`, should not be specialized
-  --> $DIR/suspicious-impls-lint.rs:46:1
-   |
-LL | unsafe impl<T> Sync for WithLifetime<'static, Vec<T>> {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = warning: this will change its meaning in a future release!
-   = note: for more information, see issue #93367 <https://github.com/rust-lang/rust/issues/93367>
-   = note: `Vec<T>` is not a generic parameter
-note: try using the same sequence of generic parameters as the struct definition
-  --> $DIR/suspicious-impls-lint.rs:44:1
-   |
-LL | pub struct WithLifetime<'a, T>(&'a (), T);
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-error: aborting due to 5 previous errors
-
diff --git a/tests/ui/auto-traits/suspicious-negative-impls-lint.rs b/tests/ui/auto-traits/suspicious-negative-impls-lint.rs
deleted file mode 100644
index 34842e5944b..00000000000
--- a/tests/ui/auto-traits/suspicious-negative-impls-lint.rs
+++ /dev/null
@@ -1,21 +0,0 @@
-#![feature(negative_impls)]
-#![deny(suspicious_auto_trait_impls)]
-
-use std::marker::PhantomData;
-
-struct ContainsVec<T>(Vec<T>);
-impl !Send for ContainsVec<u32> {}
-//~^ ERROR
-//~| WARNING this will change its meaning
-
-pub struct WithPhantomDataSend<T, U>(PhantomData<T>, U);
-impl<T> !Send for WithPhantomDataSend<*const T, u8> {}
-//~^ ERROR
-//~| WARNING this will change its meaning
-
-pub struct WithLifetime<'a, T>(&'a (), T);
-impl<T> !Sync for WithLifetime<'static, Option<T>> {}
-//~^ ERROR
-//~| WARNING this will change its meaning
-
-fn main() {}
diff --git a/tests/ui/auto-traits/suspicious-negative-impls-lint.stderr b/tests/ui/auto-traits/suspicious-negative-impls-lint.stderr
deleted file mode 100644
index ee03ea12557..00000000000
--- a/tests/ui/auto-traits/suspicious-negative-impls-lint.stderr
+++ /dev/null
@@ -1,52 +0,0 @@
-error: cross-crate traits with a default impl, like `Send`, should not be specialized
-  --> $DIR/suspicious-negative-impls-lint.rs:7:1
-   |
-LL | impl !Send for ContainsVec<u32> {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = warning: this will change its meaning in a future release!
-   = note: for more information, see issue #93367 <https://github.com/rust-lang/rust/issues/93367>
-   = note: `u32` is not a generic parameter
-note: try using the same sequence of generic parameters as the struct definition
-  --> $DIR/suspicious-negative-impls-lint.rs:6:1
-   |
-LL | struct ContainsVec<T>(Vec<T>);
-   | ^^^^^^^^^^^^^^^^^^^^^
-note: the lint level is defined here
-  --> $DIR/suspicious-negative-impls-lint.rs:2:9
-   |
-LL | #![deny(suspicious_auto_trait_impls)]
-   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-error: cross-crate traits with a default impl, like `Send`, should not be specialized
-  --> $DIR/suspicious-negative-impls-lint.rs:12:1
-   |
-LL | impl<T> !Send for WithPhantomDataSend<*const T, u8> {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = warning: this will change its meaning in a future release!
-   = note: for more information, see issue #93367 <https://github.com/rust-lang/rust/issues/93367>
-   = note: `*const T` is not a generic parameter
-note: try using the same sequence of generic parameters as the struct definition
-  --> $DIR/suspicious-negative-impls-lint.rs:11:1
-   |
-LL | pub struct WithPhantomDataSend<T, U>(PhantomData<T>, U);
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-error: cross-crate traits with a default impl, like `Sync`, should not be specialized
-  --> $DIR/suspicious-negative-impls-lint.rs:17:1
-   |
-LL | impl<T> !Sync for WithLifetime<'static, Option<T>> {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = warning: this will change its meaning in a future release!
-   = note: for more information, see issue #93367 <https://github.com/rust-lang/rust/issues/93367>
-   = note: `Option<T>` is not a generic parameter
-note: try using the same sequence of generic parameters as the struct definition
-  --> $DIR/suspicious-negative-impls-lint.rs:16:1
-   |
-LL | pub struct WithLifetime<'a, T>(&'a (), T);
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-error: aborting due to 3 previous errors
-
diff --git a/tests/ui/check-static-values-constraints.stderr b/tests/ui/check-static-values-constraints.stderr
index 064eb4b8a5c..e7532de5647 100644
--- a/tests/ui/check-static-values-constraints.stderr
+++ b/tests/ui/check-static-values-constraints.stderr
@@ -129,17 +129,6 @@ LL | static STATIC19: Vec<isize> = vec![3];
    = note: consider wrapping this expression in `Lazy::new(|| ...)` from the `once_cell` crate: https://crates.io/crates/once_cell
    = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
 
-error[E0507]: cannot move out of static item `x`
-  --> $DIR/check-static-values-constraints.rs:119:9
-   |
-LL |         x
-   |         ^ move occurs because `x` has type `Vec<isize>`, which does not implement the `Copy` trait
-   |
-help: consider borrowing here
-   |
-LL |         &x
-   |         +
-
 error[E0010]: allocations are not allowed in statics
   --> $DIR/check-static-values-constraints.rs:117:32
    |
@@ -158,6 +147,17 @@ LL |         static x: Vec<isize> = vec![3];
    = note: consider wrapping this expression in `Lazy::new(|| ...)` from the `once_cell` crate: https://crates.io/crates/once_cell
    = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
 
+error[E0507]: cannot move out of static item `x`
+  --> $DIR/check-static-values-constraints.rs:119:9
+   |
+LL |         x
+   |         ^ move occurs because `x` has type `Vec<isize>`, which does not implement the `Copy` trait
+   |
+help: consider borrowing here
+   |
+LL |         &x
+   |         +
+
 error: aborting due to 17 previous errors
 
 Some errors have detailed explanations: E0010, E0015, E0493, E0507.
diff --git a/tests/ui/coherence/coherence-conflicting-negative-trait-impl.rs b/tests/ui/coherence/coherence-conflicting-negative-trait-impl.rs
index 76a57936e69..24b87892753 100644
--- a/tests/ui/coherence/coherence-conflicting-negative-trait-impl.rs
+++ b/tests/ui/coherence/coherence-conflicting-negative-trait-impl.rs
@@ -13,7 +13,5 @@ impl<T: MyTrait> !Send for TestType<T> {} //~ ERROR found both positive and nega
 unsafe impl<T: 'static> Send for TestType<T> {} //~ ERROR conflicting implementations
 
 impl !Send for TestType<i32> {}
-//~^ WARNING
-//~| WARNING this will change its meaning
 
 fn main() {}
diff --git a/tests/ui/coherence/coherence-conflicting-negative-trait-impl.stderr b/tests/ui/coherence/coherence-conflicting-negative-trait-impl.stderr
index 020199da991..2463f38a922 100644
--- a/tests/ui/coherence/coherence-conflicting-negative-trait-impl.stderr
+++ b/tests/ui/coherence/coherence-conflicting-negative-trait-impl.stderr
@@ -16,23 +16,7 @@ LL | unsafe impl<T: MyTrait + 'static> Send for TestType<T> {}
 LL | unsafe impl<T: 'static> Send for TestType<T> {}
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ conflicting implementation for `TestType<_>`
 
-warning: cross-crate traits with a default impl, like `Send`, should not be specialized
-  --> $DIR/coherence-conflicting-negative-trait-impl.rs:15:1
-   |
-LL | impl !Send for TestType<i32> {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = warning: this will change its meaning in a future release!
-   = note: for more information, see issue #93367 <https://github.com/rust-lang/rust/issues/93367>
-   = note: `i32` is not a generic parameter
-note: try using the same sequence of generic parameters as the struct definition
-  --> $DIR/coherence-conflicting-negative-trait-impl.rs:7:1
-   |
-LL | struct TestType<T>(::std::marker::PhantomData<T>);
-   | ^^^^^^^^^^^^^^^^^^
-   = note: `#[warn(suspicious_auto_trait_impls)]` on by default
-
-error: aborting due to 2 previous errors; 1 warning emitted
+error: aborting due to 2 previous errors
 
 Some errors have detailed explanations: E0119, E0751.
 For more information about an error, try `rustc --explain E0119`.
diff --git a/tests/ui/coherence/coherence-fn-implied-bounds.rs b/tests/ui/coherence/coherence-fn-implied-bounds.rs
index 4539af9a32e..0ae54284102 100644
--- a/tests/ui/coherence/coherence-fn-implied-bounds.rs
+++ b/tests/ui/coherence/coherence-fn-implied-bounds.rs
@@ -20,7 +20,7 @@ impl Trait for for<'a, 'b> fn(&'a &'b u32, &'b &'a u32) -> &'b u32 {}
 
 impl Trait for for<'c> fn(&'c &'c u32, &'c &'c u32) -> &'c u32 {
     //~^ ERROR conflicting implementations
-    //~| WARNING this was previously accepted by the compiler
+    //~| WARN the behavior may change in a future release
 }
 
 fn main() {}
diff --git a/tests/ui/coherence/coherence-fn-implied-bounds.stderr b/tests/ui/coherence/coherence-fn-implied-bounds.stderr
index b0dea746709..ece3288989d 100644
--- a/tests/ui/coherence/coherence-fn-implied-bounds.stderr
+++ b/tests/ui/coherence/coherence-fn-implied-bounds.stderr
@@ -7,7 +7,7 @@ LL |
 LL | impl Trait for for<'c> fn(&'c &'c u32, &'c &'c u32) -> &'c u32 {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ conflicting implementation for `for<'a, 'b> fn(&'a &'b u32, &'b &'a u32) -> &'b u32`
    |
-   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+   = warning: the behavior may change in a future release
    = note: for more information, see issue #56105 <https://github.com/rust-lang/rust/issues/56105>
    = note: this behavior recently changed as a result of a bug fix; see rust-lang/rust#56105 for details
 note: the lint level is defined here
diff --git a/tests/ui/coherence/coherence-free-vs-bound-region.rs b/tests/ui/coherence/coherence-free-vs-bound-region.rs
index 2f5c49d293d..89d0005fb79 100644
--- a/tests/ui/coherence/coherence-free-vs-bound-region.rs
+++ b/tests/ui/coherence/coherence-free-vs-bound-region.rs
@@ -15,7 +15,7 @@ impl<'a> TheTrait for fn(&'a u8) {}
 
 impl TheTrait for fn(&u8) {
     //~^ ERROR conflicting implementations of trait
-    //~| WARNING this was previously accepted by the compiler
+    //~| WARN the behavior may change in a future release
 }
 
 fn main() {}
diff --git a/tests/ui/coherence/coherence-free-vs-bound-region.stderr b/tests/ui/coherence/coherence-free-vs-bound-region.stderr
index c97b32e429d..e45cf5ad3a4 100644
--- a/tests/ui/coherence/coherence-free-vs-bound-region.stderr
+++ b/tests/ui/coherence/coherence-free-vs-bound-region.stderr
@@ -7,7 +7,7 @@ LL |
 LL | impl TheTrait for fn(&u8) {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^ conflicting implementation for `fn(&u8)`
    |
-   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+   = warning: the behavior may change in a future release
    = note: for more information, see issue #56105 <https://github.com/rust-lang/rust/issues/56105>
    = note: this behavior recently changed as a result of a bug fix; see rust-lang/rust#56105 for details
 note: the lint level is defined here
diff --git a/tests/ui/coherence/coherence-orphan.rs b/tests/ui/coherence/coherence-orphan.rs
index c06705133c8..9c96958f21a 100644
--- a/tests/ui/coherence/coherence-orphan.rs
+++ b/tests/ui/coherence/coherence-orphan.rs
@@ -7,18 +7,16 @@ use lib::TheTrait;
 
 struct TheType;
 
-impl TheTrait<usize> for isize { }
+impl TheTrait<usize> for isize {}
 //~^ ERROR E0117
 //~| ERROR not all trait items implemented
 
-impl TheTrait<TheType> for isize { }
+impl TheTrait<TheType> for isize {}
 //~^ ERROR not all trait items implemented
 
-impl TheTrait<isize> for TheType { }
+impl TheTrait<isize> for TheType {}
 //~^ ERROR not all trait items implemented
 
-impl !Send for Vec<isize> { } //~ ERROR E0117
-//~^ WARNING
-//~| WARNING this will change its meaning
+impl !Send for Vec<isize> {} //~ ERROR E0117
 
-fn main() { }
+fn main() {}
diff --git a/tests/ui/coherence/coherence-orphan.stderr b/tests/ui/coherence/coherence-orphan.stderr
index 78fad837647..b1bb75bfe51 100644
--- a/tests/ui/coherence/coherence-orphan.stderr
+++ b/tests/ui/coherence/coherence-orphan.stderr
@@ -1,7 +1,7 @@
 error[E0117]: only traits defined in the current crate can be implemented for primitive types
   --> $DIR/coherence-orphan.rs:10:1
    |
-LL | impl TheTrait<usize> for isize { }
+LL | impl TheTrait<usize> for isize {}
    | ^^^^^---------------^^^^^-----
    | |    |                   |
    | |    |                   `isize` is not defined in the current crate
@@ -13,7 +13,7 @@ LL | impl TheTrait<usize> for isize { }
 error[E0117]: only traits defined in the current crate can be implemented for types defined outside of the crate
   --> $DIR/coherence-orphan.rs:20:1
    |
-LL | impl !Send for Vec<isize> { }
+LL | impl !Send for Vec<isize> {}
    | ^^^^^^^^^^^^^^^----------
    | |              |
    | |              `Vec` is not defined in the current crate
@@ -21,23 +21,10 @@ LL | impl !Send for Vec<isize> { }
    |
    = note: define and implement a trait or new type instead
 
-warning: cross-crate traits with a default impl, like `Send`, should not be specialized
-  --> $DIR/coherence-orphan.rs:20:1
-   |
-LL | impl !Send for Vec<isize> { }
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = warning: this will change its meaning in a future release!
-   = note: for more information, see issue #93367 <https://github.com/rust-lang/rust/issues/93367>
-   = note: `isize` is not a generic parameter
-note: try using the same sequence of generic parameters as the struct definition
-  --> $SRC_DIR/alloc/src/vec/mod.rs:LL:COL
-   = note: `#[warn(suspicious_auto_trait_impls)]` on by default
-
 error[E0046]: not all trait items implemented, missing: `the_fn`
   --> $DIR/coherence-orphan.rs:10:1
    |
-LL | impl TheTrait<usize> for isize { }
+LL | impl TheTrait<usize> for isize {}
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `the_fn` in implementation
    |
    = help: implement the missing item: `fn the_fn(&self) { todo!() }`
@@ -45,7 +32,7 @@ LL | impl TheTrait<usize> for isize { }
 error[E0046]: not all trait items implemented, missing: `the_fn`
   --> $DIR/coherence-orphan.rs:14:1
    |
-LL | impl TheTrait<TheType> for isize { }
+LL | impl TheTrait<TheType> for isize {}
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `the_fn` in implementation
    |
    = help: implement the missing item: `fn the_fn(&self) { todo!() }`
@@ -53,12 +40,12 @@ LL | impl TheTrait<TheType> for isize { }
 error[E0046]: not all trait items implemented, missing: `the_fn`
   --> $DIR/coherence-orphan.rs:17:1
    |
-LL | impl TheTrait<isize> for TheType { }
+LL | impl TheTrait<isize> for TheType {}
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `the_fn` in implementation
    |
    = help: implement the missing item: `fn the_fn(&self) { todo!() }`
 
-error: aborting due to 5 previous errors; 1 warning emitted
+error: aborting due to 5 previous errors
 
 Some errors have detailed explanations: E0046, E0117.
 For more information about an error, try `rustc --explain E0046`.
diff --git a/tests/ui/coherence/coherence-overlap-negative-impls.rs b/tests/ui/coherence/coherence-overlap-negative-impls.rs
index 9a85d8c5a63..ffcd56817e5 100644
--- a/tests/ui/coherence/coherence-overlap-negative-impls.rs
+++ b/tests/ui/coherence/coherence-overlap-negative-impls.rs
@@ -15,16 +15,20 @@ struct Test;
 
 trait Fold<F> {}
 
-impl<T, F> Fold<F> for Cons<T> // 0
+impl<T, F> Fold<F> for Cons<T>
+// 0
 where
     T: Fold<Nil>,
-{}
+{
+}
 
-impl<T, F> Fold<F> for Cons<T> // 1
+impl<T, F> Fold<F> for Cons<T>
+// 1
 where
     T: Fold<F>,
     private::Is<T>: private::NotNil,
-{}
+{
+}
 
 impl<F> Fold<F> for Test {} // 2
 
@@ -34,7 +38,6 @@ mod private {
     pub struct Is<T>(T);
     pub auto trait NotNil {}
 
-    #[allow(suspicious_auto_trait_impls)]
     impl !NotNil for Is<Nil> {}
 }
 
diff --git a/tests/ui/coherence/coherence-subtyping.rs b/tests/ui/coherence/coherence-subtyping.rs
index da0cc2d0265..4365ad5c884 100644
--- a/tests/ui/coherence/coherence-subtyping.rs
+++ b/tests/ui/coherence/coherence-subtyping.rs
@@ -13,8 +13,8 @@ trait TheTrait {
 impl TheTrait for for<'a, 'b> fn(&'a u8, &'b u8) -> &'a u8 {}
 
 impl TheTrait for for<'a> fn(&'a u8, &'a u8) -> &'a u8 {
-    //~^ WARNING conflicting implementation
-    //~^^ WARNING this was previously accepted by the compiler but is being phased out
+    //~^ WARN conflicting implementation
+    //~| WARN the behavior may change in a future release
 }
 
 fn main() {}
diff --git a/tests/ui/coherence/coherence-subtyping.stderr b/tests/ui/coherence/coherence-subtyping.stderr
index 9d90019a50f..42f256ace78 100644
--- a/tests/ui/coherence/coherence-subtyping.stderr
+++ b/tests/ui/coherence/coherence-subtyping.stderr
@@ -7,7 +7,7 @@ LL |
 LL | impl TheTrait for for<'a> fn(&'a u8, &'a u8) -> &'a u8 {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ conflicting implementation for `for<'a, 'b> fn(&'a u8, &'b u8) -> &'a u8`
    |
-   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+   = warning: the behavior may change in a future release
    = note: for more information, see issue #56105 <https://github.com/rust-lang/rust/issues/56105>
    = note: this behavior recently changed as a result of a bug fix; see rust-lang/rust#56105 for details
    = note: `#[warn(coherence_leak_check)]` on by default
diff --git a/tests/ui/coherence/coherence-wasm-bindgen.rs b/tests/ui/coherence/coherence-wasm-bindgen.rs
index ee09a72449b..57daaa134d4 100644
--- a/tests/ui/coherence/coherence-wasm-bindgen.rs
+++ b/tests/ui/coherence/coherence-wasm-bindgen.rs
@@ -31,7 +31,7 @@ where
     R: ReturnWasmAbi,
 {
     //~^^^^^ ERROR conflicting implementation
-    //~| WARNING this was previously accepted
+    //~| WARN the behavior may change in a future release
 }
 
 fn main() {}
diff --git a/tests/ui/coherence/coherence-wasm-bindgen.stderr b/tests/ui/coherence/coherence-wasm-bindgen.stderr
index b3c3dac612d..939f1fce9a4 100644
--- a/tests/ui/coherence/coherence-wasm-bindgen.stderr
+++ b/tests/ui/coherence/coherence-wasm-bindgen.stderr
@@ -13,7 +13,7 @@ LL | |     A: RefFromWasmAbi,
 LL | |     R: ReturnWasmAbi,
    | |_____________________^ conflicting implementation for `&dyn Fn(&_) -> _`
    |
-   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+   = warning: the behavior may change in a future release
    = note: for more information, see issue #56105 <https://github.com/rust-lang/rust/issues/56105>
    = note: downstream crates may implement trait `FromWasmAbi` for type `&_`
    = note: this behavior recently changed as a result of a bug fix; see rust-lang/rust#56105 for details
diff --git a/tests/ui/coherence/const-errs-dont-conflict-103369.rs b/tests/ui/coherence/const-errs-dont-conflict-103369.rs
new file mode 100644
index 00000000000..c7d46a8000d
--- /dev/null
+++ b/tests/ui/coherence/const-errs-dont-conflict-103369.rs
@@ -0,0 +1,14 @@
+// #103369: don't complain about conflicting implementations with [const error]
+
+pub trait ConstGenericTrait<const N: u32> {}
+
+impl ConstGenericTrait<{my_fn(1)}> for () {}
+
+impl ConstGenericTrait<{my_fn(2)}> for () {}
+
+const fn my_fn(v: u32) -> u32 {
+    panic!("Some error occurred"); //~ ERROR E0080
+    //~| ERROR E0080
+}
+
+fn main() {}
diff --git a/tests/ui/coherence/const-errs-dont-conflict-103369.stderr b/tests/ui/coherence/const-errs-dont-conflict-103369.stderr
new file mode 100644
index 00000000000..22066d6b6bd
--- /dev/null
+++ b/tests/ui/coherence/const-errs-dont-conflict-103369.stderr
@@ -0,0 +1,39 @@
+error[E0080]: evaluation of constant value failed
+  --> $DIR/const-errs-dont-conflict-103369.rs:10:5
+   |
+LL |     panic!("Some error occurred");
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the evaluated program panicked at 'Some error occurred', $DIR/const-errs-dont-conflict-103369.rs:10:5
+   |
+note: inside `my_fn`
+  --> $DIR/const-errs-dont-conflict-103369.rs:10:5
+   |
+LL |     panic!("Some error occurred");
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+note: inside `<() as ConstGenericTrait<{my_fn(1)}>>::{constant#0}`
+  --> $DIR/const-errs-dont-conflict-103369.rs:5:25
+   |
+LL | impl ConstGenericTrait<{my_fn(1)}> for () {}
+   |                         ^^^^^^^^
+   = note: this error originates in the macro `$crate::panic::panic_2015` which comes from the expansion of the macro `panic` (in Nightly builds, run with -Z macro-backtrace for more info)
+
+error[E0080]: evaluation of constant value failed
+  --> $DIR/const-errs-dont-conflict-103369.rs:10:5
+   |
+LL |     panic!("Some error occurred");
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the evaluated program panicked at 'Some error occurred', $DIR/const-errs-dont-conflict-103369.rs:10:5
+   |
+note: inside `my_fn`
+  --> $DIR/const-errs-dont-conflict-103369.rs:10:5
+   |
+LL |     panic!("Some error occurred");
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+note: inside `<() as ConstGenericTrait<{my_fn(2)}>>::{constant#0}`
+  --> $DIR/const-errs-dont-conflict-103369.rs:7:25
+   |
+LL | impl ConstGenericTrait<{my_fn(2)}> for () {}
+   |                         ^^^^^^^^
+   = note: this error originates in the macro `$crate::panic::panic_2015` which comes from the expansion of the macro `panic` (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 E0080`.
diff --git a/tests/ui/coherence/negative-coherence-placeholder-region-constraints-on-unification.explicit.stderr b/tests/ui/coherence/negative-coherence-placeholder-region-constraints-on-unification.explicit.stderr
index 5368db29338..832c56a4554 100644
--- a/tests/ui/coherence/negative-coherence-placeholder-region-constraints-on-unification.explicit.stderr
+++ b/tests/ui/coherence/negative-coherence-placeholder-region-constraints-on-unification.explicit.stderr
@@ -6,7 +6,7 @@ LL | impl<T: ?Sized + Marker> FnMarker for fn(T) {}
 LL | impl<T: ?Sized> FnMarker for fn(&T) {}
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ conflicting implementation for `fn(&_)`
    |
-   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+   = warning: the behavior may change in a future release
    = note: for more information, see issue #56105 <https://github.com/rust-lang/rust/issues/56105>
    = note: this behavior recently changed as a result of a bug fix; see rust-lang/rust#56105 for details
 note: the lint level is defined here
diff --git a/tests/ui/coherence/negative-coherence-placeholder-region-constraints-on-unification.rs b/tests/ui/coherence/negative-coherence-placeholder-region-constraints-on-unification.rs
index 7967002e021..e487dcc3c0e 100644
--- a/tests/ui/coherence/negative-coherence-placeholder-region-constraints-on-unification.rs
+++ b/tests/ui/coherence/negative-coherence-placeholder-region-constraints-on-unification.rs
@@ -20,6 +20,6 @@ trait FnMarker {}
 impl<T: ?Sized + Marker> FnMarker for fn(T) {}
 impl<T: ?Sized> FnMarker for fn(&T) {}
 //[explicit]~^ ERROR conflicting implementations of trait `FnMarker` for type `fn(&_)`
-//[explicit]~| WARN this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+//[explicit]~| WARN the behavior may change in a future release
 
 fn main() {}
diff --git a/tests/ui/coherence/occurs-check/associated-type.next.stderr b/tests/ui/coherence/occurs-check/associated-type.next.stderr
index 65be4a9c884..6119e6149a7 100644
--- a/tests/ui/coherence/occurs-check/associated-type.next.stderr
+++ b/tests/ui/coherence/occurs-check/associated-type.next.stderr
@@ -1,11 +1,11 @@
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Projection, AliasTy { args: [*const ?1t, ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Projection, AliasTy { args: [*const ?1t, RePlaceholder(!2_BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Projection, AliasTy { args: [*const ?1t, ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Projection, AliasTy { args: [*const ?1t, RePlaceholder(!2_BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Projection, AliasTy { args: [*const ?1t, ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Projection, AliasTy { args: [*const ?1t, RePlaceholder(!2_BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Projection, AliasTy { args: [*const ?1t, ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Projection, AliasTy { args: [*const ?1t, RePlaceholder(!2_BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) })
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [*const ?1t, ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [*const ?1t, RePlaceholder(!1_BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [*const ?1t, ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [*const ?1t, RePlaceholder(!1_BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [*const ?1t, ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [*const ?1t, RePlaceholder(!1_BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [*const ?1t, ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [*const ?1t, RePlaceholder(!1_BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) }
 error[E0119]: conflicting implementations of trait `Overlap<for<'a> fn(&'a (), ())>` for type `for<'a> fn(&'a (), ())`
   --> $DIR/associated-type.rs:31:1
    |
diff --git a/tests/ui/coherence/occurs-check/associated-type.old.stderr b/tests/ui/coherence/occurs-check/associated-type.old.stderr
index 8e852ec796e..655809b827e 100644
--- a/tests/ui/coherence/occurs-check/associated-type.old.stderr
+++ b/tests/ui/coherence/occurs-check/associated-type.old.stderr
@@ -1,11 +1,11 @@
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Projection, AliasTy { args: [*const ?1t, ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Projection, AliasTy { args: [*const ?1t, RePlaceholder(!3_BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Projection, AliasTy { args: [*const ?1t, ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Projection, AliasTy { args: [*const ?1t, RePlaceholder(!3_BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Projection, AliasTy { args: [*const ?1t, ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Projection, AliasTy { args: [*const ?1t, RePlaceholder(!3_BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Projection, AliasTy { args: [*const ?1t, ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Projection, AliasTy { args: [*const ?1t, RePlaceholder(!3_BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) })
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [*const ?1t, ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [*const ?1t, RePlaceholder(!2_BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [*const ?1t, ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [*const ?1t, RePlaceholder(!2_BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [*const ?1t, ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [*const ?1t, RePlaceholder(!2_BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [*const ?1t, ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [*const ?1t, RePlaceholder(!2_BoundRegion { var: 0, kind: BrNamed(DefId(0:27 ~ associated_type[f554]::{impl#3}::'a#1), 'a) })], def_id: DefId(0:5 ~ associated_type[f554]::ToUnit::Unit) }
 error[E0119]: conflicting implementations of trait `Overlap<for<'a> fn(&'a (), _)>` for type `for<'a> fn(&'a (), _)`
   --> $DIR/associated-type.rs:31:1
    |
diff --git a/tests/ui/compiletest-self-test/aux-aux.rs b/tests/ui/compiletest-self-test/aux-aux.rs
new file mode 100644
index 00000000000..c87905ff775
--- /dev/null
+++ b/tests/ui/compiletest-self-test/aux-aux.rs
@@ -0,0 +1,14 @@
+//@ aux-crate: aux_aux_foo=aux_aux_foo.rs
+//@ aux-crate: aux_aux_bar=aux_aux_bar.rs
+//@ edition: 2021
+//@ compile-flags: --crate-type lib
+//@ check-pass
+
+use aux_aux_foo::Bar as IndirectBar;
+use aux_aux_bar::Bar as DirectBar;
+
+fn foo(x: IndirectBar) {}
+
+fn main() {
+    foo(DirectBar);
+}
diff --git a/tests/ui/compiletest-self-test/auxiliary/aux_aux_bar.rs b/tests/ui/compiletest-self-test/auxiliary/aux_aux_bar.rs
new file mode 100644
index 00000000000..eefcc270c38
--- /dev/null
+++ b/tests/ui/compiletest-self-test/auxiliary/aux_aux_bar.rs
@@ -0,0 +1,3 @@
+//@ edition: 2021
+
+pub struct Bar;
diff --git a/tests/ui/compiletest-self-test/auxiliary/aux_aux_foo.rs b/tests/ui/compiletest-self-test/auxiliary/aux_aux_foo.rs
new file mode 100644
index 00000000000..f96c6bb0b27
--- /dev/null
+++ b/tests/ui/compiletest-self-test/auxiliary/aux_aux_foo.rs
@@ -0,0 +1,4 @@
+//@ aux-crate: aux_aux_bar=aux_aux_bar.rs
+//@ edition: 2021
+
+pub use aux_aux_bar::Bar;
diff --git a/tests/ui/const-generics/invariant.rs b/tests/ui/const-generics/invariant.rs
index 39d658be67d..ee4ad4e7c4e 100644
--- a/tests/ui/const-generics/invariant.rs
+++ b/tests/ui/const-generics/invariant.rs
@@ -12,18 +12,16 @@ impl SadBee for for<'a> fn(&'a ()) {
     const ASSOC: usize = 0;
 }
 impl SadBee for fn(&'static ()) {
-    //~^ WARNING conflicting implementations of trait
-    //~| WARNING this was previously accepted
+    //~^ WARN conflicting implementations of trait
+    //~| WARN the behavior may change in a future release
     const ASSOC: usize = 100;
 }
 
 struct Foo<T: SadBee>([u8; <T as SadBee>::ASSOC], PhantomData<T>)
 where
-    [(); <T as SadBee>::ASSOC]: ;
+    [(); <T as SadBee>::ASSOC]:;
 
-fn covariant(
-    v: &'static Foo<for<'a> fn(&'a ())>
-) -> &'static Foo<fn(&'static ())> {
+fn covariant(v: &'static Foo<for<'a> fn(&'a ())>) -> &'static Foo<fn(&'static ())> {
     v
     //~^ ERROR mismatched types
 }
diff --git a/tests/ui/const-generics/invariant.stderr b/tests/ui/const-generics/invariant.stderr
index f631e131146..b4e46e55268 100644
--- a/tests/ui/const-generics/invariant.stderr
+++ b/tests/ui/const-generics/invariant.stderr
@@ -7,13 +7,13 @@ LL | impl SadBee for for<'a> fn(&'a ()) {
 LL | impl SadBee for fn(&'static ()) {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ conflicting implementation for `for<'a> fn(&'a ())`
    |
-   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+   = warning: the behavior may change in a future release
    = note: for more information, see issue #56105 <https://github.com/rust-lang/rust/issues/56105>
    = note: this behavior recently changed as a result of a bug fix; see rust-lang/rust#56105 for details
    = note: `#[warn(coherence_leak_check)]` on by default
 
 error[E0308]: mismatched types
-  --> $DIR/invariant.rs:27:5
+  --> $DIR/invariant.rs:25:5
    |
 LL |     v
    |     ^ one type is more general than the other
diff --git a/tests/ui/const-generics/issues/issue-100313.rs b/tests/ui/const-generics/issues/issue-100313.rs
index 9af9b5ca458..4e9d3626aa8 100644
--- a/tests/ui/const-generics/issues/issue-100313.rs
+++ b/tests/ui/const-generics/issues/issue-100313.rs
@@ -9,7 +9,6 @@ impl <const B: &'static bool> T<B> {
         unsafe {
             *(B as *const bool as *mut bool) = false;
             //~^ ERROR evaluation of constant value failed [E0080]
-            //~| ERROR assigning to `&T` is undefined behavior
         }
     }
 }
diff --git a/tests/ui/const-generics/issues/issue-100313.stderr b/tests/ui/const-generics/issues/issue-100313.stderr
index 5832dbe1777..a422764fe2c 100644
--- a/tests/ui/const-generics/issues/issue-100313.stderr
+++ b/tests/ui/const-generics/issues/issue-100313.stderr
@@ -1,12 +1,3 @@
-error: assigning to `&T` is undefined behavior, consider using an `UnsafeCell`
-  --> $DIR/issue-100313.rs:10:13
-   |
-LL |             *(B as *const bool as *mut bool) = false;
-   |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = note: for more information, visit <https://doc.rust-lang.org/book/ch15-05-interior-mutability.html>
-   = note: `#[deny(invalid_reference_casting)]` on by default
-
 error[E0080]: evaluation of constant value failed
   --> $DIR/issue-100313.rs:10:13
    |
@@ -19,11 +10,11 @@ note: inside `T::<&true>::set_false`
 LL |             *(B as *const bool as *mut bool) = false;
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 note: inside `_`
-  --> $DIR/issue-100313.rs:19:5
+  --> $DIR/issue-100313.rs:18:5
    |
 LL |     x.set_false();
    |     ^^^^^^^^^^^^^
 
-error: aborting due to 2 previous errors
+error: aborting due to 1 previous error
 
 For more information about this error, try `rustc --explain E0080`.
diff --git a/tests/ui/consts/const-array-oob.rs b/tests/ui/consts/const-array-oob.rs
index c747ab50c16..cf3db077e36 100644
--- a/tests/ui/consts/const-array-oob.rs
+++ b/tests/ui/consts/const-array-oob.rs
@@ -1,5 +1,6 @@
 const FOO: [usize; 3] = [1, 2, 3];
-const BAR: usize = FOO[5]; // no error, because the error below occurs before regular const eval
+const BAR: usize = FOO[5];
+//~^ ERROR: evaluation of constant value failed
 
 const BLUB: [u32; FOO[4]] = [5, 6];
 //~^ ERROR evaluation of constant value failed [E0080]
diff --git a/tests/ui/consts/const-array-oob.stderr b/tests/ui/consts/const-array-oob.stderr
index d481d772894..be31f183b9a 100644
--- a/tests/ui/consts/const-array-oob.stderr
+++ b/tests/ui/consts/const-array-oob.stderr
@@ -1,9 +1,15 @@
 error[E0080]: evaluation of constant value failed
-  --> $DIR/const-array-oob.rs:4:19
+  --> $DIR/const-array-oob.rs:5:19
    |
 LL | const BLUB: [u32; FOO[4]] = [5, 6];
    |                   ^^^^^^ index out of bounds: the length is 3 but the index is 4
 
-error: aborting due to 1 previous error
+error[E0080]: evaluation of constant value failed
+  --> $DIR/const-array-oob.rs:2:20
+   |
+LL | const BAR: usize = FOO[5];
+   |                    ^^^^^^ index out of bounds: the length is 3 but the index is 5
+
+error: aborting due to 2 previous errors
 
 For more information about this error, try `rustc --explain E0080`.
diff --git a/tests/ui/consts/const-eval/const-eval-query-stack.stderr b/tests/ui/consts/const-eval/const-eval-query-stack.stderr
index 2fcb3d41dd9..96fd9ed5f04 100644
--- a/tests/ui/consts/const-eval/const-eval-query-stack.stderr
+++ b/tests/ui/consts/const-eval/const-eval-query-stack.stderr
@@ -7,6 +7,5 @@ LL | const X: i32 = 1 / 0;
 query stack during panic:
 #0 [eval_to_allocation_raw] const-evaluating + checking `X`
 #1 [eval_to_const_value_raw] simplifying constant for the type system `X`
-#2 [lint_mod] linting top-level module
-#3 [analysis] running analysis passes on this crate
+#2 [analysis] running analysis passes on this crate
 end of query stack
diff --git a/tests/ui/consts/const-eval/const_fn_ptr.stderr b/tests/ui/consts/const-eval/const_fn_ptr.stderr
index ca1585f8837..682a5a23afc 100644
--- a/tests/ui/consts/const-eval/const_fn_ptr.stderr
+++ b/tests/ui/consts/const-eval/const_fn_ptr.stderr
@@ -1,11 +1,6 @@
 warning: skipping const checks
    |
 help: skipping check that does not even have a feature gate
-  --> $DIR/const_fn_ptr.rs:11:5
-   |
-LL |     X(x)
-   |     ^^^^
-help: skipping check that does not even have a feature gate
   --> $DIR/const_fn_ptr.rs:15:5
    |
 LL |     X_CONST(x)
@@ -15,6 +10,11 @@ help: skipping check that does not even have a feature gate
    |
 LL |     x(y)
    |     ^^^^
+help: skipping check that does not even have a feature gate
+  --> $DIR/const_fn_ptr.rs:11:5
+   |
+LL |     X(x)
+   |     ^^^^
 
 warning: 1 warning emitted
 
diff --git a/tests/ui/consts/const-eval/generic-slice.stderr b/tests/ui/consts/const-eval/generic-slice.stderr
index ff1dc29ccfd..8559f6d1a44 100644
--- a/tests/ui/consts/const-eval/generic-slice.stderr
+++ b/tests/ui/consts/const-eval/generic-slice.stderr
@@ -1,4 +1,18 @@
 error[E0597]: `x` does not live long enough
+  --> $DIR/generic-slice.rs:27:5
+   |
+LL |     let x: &[_] = &[];
+   |         - binding `x` declared here
+LL |     &x
+   |     ^^
+   |     |
+   |     borrowed value does not live long enough
+   |     using this value as a static requires that `x` is borrowed for `'static`
+LL |
+LL | };
+   | - `x` dropped here while still borrowed
+
+error[E0597]: `x` does not live long enough
   --> $DIR/generic-slice.rs:15:9
    |
 LL | impl<'a, T: 'static> Generic<'a, T> {
@@ -15,20 +29,6 @@ LL |
 LL |     };
    |     - `x` dropped here while still borrowed
 
-error[E0597]: `x` does not live long enough
-  --> $DIR/generic-slice.rs:27:5
-   |
-LL |     let x: &[_] = &[];
-   |         - binding `x` declared here
-LL |     &x
-   |     ^^
-   |     |
-   |     borrowed value does not live long enough
-   |     using this value as a static requires that `x` is borrowed for `'static`
-LL |
-LL | };
-   | - `x` dropped here while still borrowed
-
 error: aborting due to 2 previous errors
 
 For more information about this error, try `rustc --explain E0597`.
diff --git a/tests/ui/consts/const-eval/validate_uninhabited_zsts.rs b/tests/ui/consts/const-eval/validate_uninhabited_zsts.rs
index 5fc0674c576..261dea6182d 100644
--- a/tests/ui/consts/const-eval/validate_uninhabited_zsts.rs
+++ b/tests/ui/consts/const-eval/validate_uninhabited_zsts.rs
@@ -1,7 +1,6 @@
 const fn foo() -> ! {
     unsafe { std::mem::transmute(()) }
     //~^ ERROR evaluation of constant value failed
-    //~| WARN the type `!` does not permit zero-initialization [invalid_value]
 }
 
 // Type defined in a submodule, so that it is not "visibly"
@@ -18,7 +17,6 @@ const FOO: [empty::Empty; 3] = [foo(); 3];
 
 const BAR: [empty::Empty; 3] = [unsafe { std::mem::transmute(()) }; 3];
 //~^ ERROR evaluation of constant value failed
-//~| WARN the type `empty::Empty` does not permit zero-initialization
 
 fn main() {
     FOO;
diff --git a/tests/ui/consts/const-eval/validate_uninhabited_zsts.stderr b/tests/ui/consts/const-eval/validate_uninhabited_zsts.stderr
index 4c50ab5319e..d9f1780f7b9 100644
--- a/tests/ui/consts/const-eval/validate_uninhabited_zsts.stderr
+++ b/tests/ui/consts/const-eval/validate_uninhabited_zsts.stderr
@@ -1,12 +1,3 @@
-warning: the type `!` does not permit zero-initialization
-  --> $DIR/validate_uninhabited_zsts.rs:2:14
-   |
-LL |     unsafe { std::mem::transmute(()) }
-   |              ^^^^^^^^^^^^^^^^^^^^^^^ this code causes undefined behavior when executed
-   |
-   = note: the `!` type has no valid value
-   = note: `#[warn(invalid_value)]` on by default
-
 error[E0080]: evaluation of constant value failed
   --> $DIR/validate_uninhabited_zsts.rs:2:14
    |
@@ -19,34 +10,17 @@ note: inside `foo`
 LL |     unsafe { std::mem::transmute(()) }
    |              ^^^^^^^^^^^^^^^^^^^^^^^
 note: inside `FOO`
-  --> $DIR/validate_uninhabited_zsts.rs:17:33
+  --> $DIR/validate_uninhabited_zsts.rs:16:33
    |
 LL | const FOO: [empty::Empty; 3] = [foo(); 3];
    |                                 ^^^^^
 
 error[E0080]: evaluation of constant value failed
-  --> $DIR/validate_uninhabited_zsts.rs:19:42
+  --> $DIR/validate_uninhabited_zsts.rs:18:42
    |
 LL | const BAR: [empty::Empty; 3] = [unsafe { std::mem::transmute(()) }; 3];
    |                                          ^^^^^^^^^^^^^^^^^^^^^^^ constructing invalid value at .0: encountered a value of uninhabited type `Void`
 
-warning: the type `empty::Empty` does not permit zero-initialization
-  --> $DIR/validate_uninhabited_zsts.rs:19:42
-   |
-LL | const BAR: [empty::Empty; 3] = [unsafe { std::mem::transmute(()) }; 3];
-   |                                          ^^^^^^^^^^^^^^^^^^^^^^^ this code causes undefined behavior when executed
-   |
-note: in this struct field
-  --> $DIR/validate_uninhabited_zsts.rs:14:22
-   |
-LL |     pub struct Empty(Void);
-   |                      ^^^^
-note: enums with no inhabited variants have no valid value
-  --> $DIR/validate_uninhabited_zsts.rs:11:5
-   |
-LL |     enum Void {}
-   |     ^^^^^^^^^
-
-error: aborting due to 2 previous errors; 2 warnings emitted
+error: aborting due to 2 previous errors
 
 For more information about this error, try `rustc --explain E0080`.
diff --git a/tests/ui/consts/const-mut-refs/issue-76510.rs b/tests/ui/consts/const-mut-refs/issue-76510.rs
index b6a73abb09c..685e3a129c2 100644
--- a/tests/ui/consts/const-mut-refs/issue-76510.rs
+++ b/tests/ui/consts/const-mut-refs/issue-76510.rs
@@ -3,7 +3,6 @@ use std::mem::{transmute, ManuallyDrop};
 const S: &'static mut str = &mut " hello ";
 //~^ ERROR: mutable references are not allowed in the final value of constants
 //~| ERROR: mutation through a reference is not allowed in constants
-//~| ERROR: cannot borrow data in a `&` reference as mutable
 
 const fn trigger() -> [(); unsafe {
         let s = transmute::<(*const u8, usize), &ManuallyDrop<str>>((S.as_ptr(), 3));
diff --git a/tests/ui/consts/const-mut-refs/issue-76510.stderr b/tests/ui/consts/const-mut-refs/issue-76510.stderr
index 8a1b19baff7..ab4487026cf 100644
--- a/tests/ui/consts/const-mut-refs/issue-76510.stderr
+++ b/tests/ui/consts/const-mut-refs/issue-76510.stderr
@@ -14,13 +14,7 @@ LL | const S: &'static mut str = &mut " hello ";
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
-error[E0596]: cannot borrow data in a `&` reference as mutable
-  --> $DIR/issue-76510.rs:3:29
-   |
-LL | const S: &'static mut str = &mut " hello ";
-   |                             ^^^^^^^^^^^^^^ cannot borrow as mutable
-
-error: aborting due to 3 previous errors
+error: aborting due to 2 previous errors
 
-Some errors have detailed explanations: E0596, E0658, E0764.
-For more information about an error, try `rustc --explain E0596`.
+Some errors have detailed explanations: E0658, E0764.
+For more information about an error, try `rustc --explain E0658`.
diff --git a/tests/ui/consts/const_cmp_type_id.stderr b/tests/ui/consts/const_cmp_type_id.stderr
index 84be0b67307..98f5b3a5e90 100644
--- a/tests/ui/consts/const_cmp_type_id.stderr
+++ b/tests/ui/consts/const_cmp_type_id.stderr
@@ -4,6 +4,12 @@ error[E0131]: `main` function is not allowed to have generic parameters
 LL | const fn main() {
    |              ^ `main` cannot have generic parameters
 
+error[E0080]: evaluation of constant value failed
+  --> $DIR/const_cmp_type_id.rs:10:22
+   |
+LL |     const _A: bool = TypeId::of::<u8>() < TypeId::of::<u16>();
+   |                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ calling non-const function `<TypeId as PartialOrd>::lt`
+
 error[E0308]: mismatched types
   --> $DIR/const_cmp_type_id.rs:8:13
    |
@@ -22,7 +28,7 @@ LL |     assert!(TypeId::of::<()>() != TypeId::of::<u8>());
    = note: expected constant `host`
               found constant `true`
 
-error: aborting due to 3 previous errors
+error: aborting due to 4 previous errors
 
-Some errors have detailed explanations: E0131, E0308.
-For more information about an error, try `rustc --explain E0131`.
+Some errors have detailed explanations: E0080, E0131, E0308.
+For more information about an error, try `rustc --explain E0080`.
diff --git a/tests/ui/consts/const_let_assign3.stderr b/tests/ui/consts/const_let_assign3.stderr
index 40c11acee5c..ae890131715 100644
--- a/tests/ui/consts/const_let_assign3.stderr
+++ b/tests/ui/consts/const_let_assign3.stderr
@@ -1,18 +1,18 @@
-error[E0658]: mutable references are not allowed in constant functions
-  --> $DIR/const_let_assign3.rs:6:18
+error[E0658]: mutable references are not allowed in constants
+  --> $DIR/const_let_assign3.rs:14:5
    |
-LL |     const fn foo(&mut self, x: u32) {
-   |                  ^^^^^^^^^
+LL |     s.foo(3);
+   |     ^
    |
    = 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
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
-error[E0658]: mutable references are not allowed in constants
-  --> $DIR/const_let_assign3.rs:14:5
+error[E0658]: mutable references are not allowed in constant functions
+  --> $DIR/const_let_assign3.rs:6:18
    |
-LL |     s.foo(3);
-   |     ^
+LL |     const fn foo(&mut self, x: u32) {
+   |                  ^^^^^^^^^
    |
    = 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
diff --git a/tests/ui/consts/const_refs_to_static_fail_invalid.stderr b/tests/ui/consts/const_refs_to_static_fail_invalid.stderr
index 4ff15f0c28b..d5bb4847746 100644
--- a/tests/ui/consts/const_refs_to_static_fail_invalid.stderr
+++ b/tests/ui/consts/const_refs_to_static_fail_invalid.stderr
@@ -9,12 +9,6 @@ LL |     const C: &bool = unsafe { std::mem::transmute(&S) };
                HEX_DUMP
            }
 
-error: could not evaluate constant pattern
-  --> $DIR/const_refs_to_static_fail_invalid.rs:15:9
-   |
-LL |         C => {}
-   |         ^
-
 error[E0080]: it is undefined behavior to use this value
   --> $DIR/const_refs_to_static_fail_invalid.rs:25:5
    |
@@ -26,12 +20,6 @@ LL |     const C: &i8 = unsafe { &S };
                HEX_DUMP
            }
 
-error: could not evaluate constant pattern
-  --> $DIR/const_refs_to_static_fail_invalid.rs:31:9
-   |
-LL |         C => {}
-   |         ^
-
 error[E0080]: it is undefined behavior to use this value
   --> $DIR/const_refs_to_static_fail_invalid.rs:39:5
    |
@@ -44,6 +32,18 @@ LL |     const C: &i32 = unsafe { &S_MUT };
            }
 
 error: could not evaluate constant pattern
+  --> $DIR/const_refs_to_static_fail_invalid.rs:15:9
+   |
+LL |         C => {}
+   |         ^
+
+error: could not evaluate constant pattern
+  --> $DIR/const_refs_to_static_fail_invalid.rs:31:9
+   |
+LL |         C => {}
+   |         ^
+
+error: could not evaluate constant pattern
   --> $DIR/const_refs_to_static_fail_invalid.rs:46:9
    |
 LL |         C => {}
diff --git a/tests/ui/consts/fn_trait_refs.stderr b/tests/ui/consts/fn_trait_refs.stderr
index afe89461f03..527579d99ea 100644
--- a/tests/ui/consts/fn_trait_refs.stderr
+++ b/tests/ui/consts/fn_trait_refs.stderr
@@ -74,6 +74,24 @@ LL |     T: ~const FnMut<()> + ~const Destruct,
    |
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
+error[E0015]: cannot call non-const operator in constants
+  --> $DIR/fn_trait_refs.rs:72:17
+   |
+LL |         assert!(test_one == (1, 1, 1));
+   |                 ^^^^^^^^^^^^^^^^^^^^^
+   |
+   = note: calls in constants are limited to constant functions, tuple structs and tuple variants
+   = help: add `#![feature(effects)]` to the crate attributes to enable
+
+error[E0015]: cannot call non-const operator in constants
+  --> $DIR/fn_trait_refs.rs:75:17
+   |
+LL |         assert!(test_two == (2, 2));
+   |                 ^^^^^^^^^^^^^^^^^^
+   |
+   = note: calls in constants are limited to constant functions, tuple structs and tuple variants
+   = help: add `#![feature(effects)]` to the crate attributes to enable
+
 error[E0015]: cannot call non-const closure in constant functions
   --> $DIR/fn_trait_refs.rs:17:5
    |
@@ -149,24 +167,6 @@ LL | const fn test_fn_mut<T>(mut f: T) -> (T::Output, T::Output)
 LL | }
    | - value is dropped here
 
-error[E0015]: cannot call non-const operator in constants
-  --> $DIR/fn_trait_refs.rs:72:17
-   |
-LL |         assert!(test_one == (1, 1, 1));
-   |                 ^^^^^^^^^^^^^^^^^^^^^
-   |
-   = note: calls in constants are limited to constant functions, tuple structs and tuple variants
-   = help: add `#![feature(effects)]` to the crate attributes to enable
-
-error[E0015]: cannot call non-const operator in constants
-  --> $DIR/fn_trait_refs.rs:75:17
-   |
-LL |         assert!(test_two == (2, 2));
-   |                 ^^^^^^^^^^^^^^^^^^
-   |
-   = note: calls in constants are limited to constant functions, tuple structs and tuple variants
-   = help: add `#![feature(effects)]` to the crate attributes to enable
-
 error: aborting due to 20 previous errors
 
 Some errors have detailed explanations: E0015, E0493, E0635.
diff --git a/tests/ui/consts/issue-16538.stderr b/tests/ui/consts/issue-16538.stderr
index 834ffa8d3a0..3981b4ada49 100644
--- a/tests/ui/consts/issue-16538.stderr
+++ b/tests/ui/consts/issue-16538.stderr
@@ -1,3 +1,12 @@
+error[E0015]: cannot call non-const fn `Y::foo` in statics
+  --> $DIR/issue-16538.rs:11: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[E0133]: dereference of raw pointer is unsafe and requires unsafe function or block
   --> $DIR/issue-16538.rs:11:22
    |
@@ -14,15 +23,6 @@ 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[E0015]: cannot call non-const fn `Y::foo` in statics
-  --> $DIR/issue-16538.rs:11: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.
diff --git a/tests/ui/consts/issue-66693.rs b/tests/ui/consts/issue-66693.rs
index df45d01ec02..416bd8ec72a 100644
--- a/tests/ui/consts/issue-66693.rs
+++ b/tests/ui/consts/issue-66693.rs
@@ -12,9 +12,11 @@ const fn _foo() {
     //~^ ERROR: argument to `panic!()` in a const context must have type `&str`
 }
 
-// ensure that conforming panics don't cause an error
+// ensure that conforming panics don't cause an error beyond the failure to const eval
 const _: () = panic!();
+//~^ ERROR: evaluation of constant value failed
 static _BAR: () = panic!("panic in static");
+//~^ ERROR could not evaluate static initializer
 
 const fn _bar() {
     panic!("panic in const fn");
diff --git a/tests/ui/consts/issue-66693.stderr b/tests/ui/consts/issue-66693.stderr
index f4898fd9732..a435ace4773 100644
--- a/tests/ui/consts/issue-66693.stderr
+++ b/tests/ui/consts/issue-66693.stderr
@@ -14,6 +14,22 @@ LL | static _FOO: () = panic!(true);
    |
    = note: this error originates in the macro `$crate::panic::panic_2015` which comes from the expansion of the macro `panic` (in Nightly builds, run with -Z macro-backtrace for more info)
 
+error[E0080]: evaluation of constant value failed
+  --> $DIR/issue-66693.rs:16:15
+   |
+LL | const _: () = panic!();
+   |               ^^^^^^^^ the evaluated program panicked at 'explicit panic', $DIR/issue-66693.rs:16:15
+   |
+   = note: this error originates in the macro `$crate::panic::panic_2015` which comes from the expansion of the macro `panic` (in Nightly builds, run with -Z macro-backtrace for more info)
+
+error[E0080]: could not evaluate static initializer
+  --> $DIR/issue-66693.rs:18:19
+   |
+LL | static _BAR: () = panic!("panic in static");
+   |                   ^^^^^^^^^^^^^^^^^^^^^^^^^ the evaluated program panicked at 'panic in static', $DIR/issue-66693.rs:18:19
+   |
+   = note: this error originates in the macro `$crate::panic::panic_2015` which comes from the expansion of the macro `panic` (in Nightly builds, run with -Z macro-backtrace for more info)
+
 error: argument to `panic!()` in a const context must have type `&str`
   --> $DIR/issue-66693.rs:11:5
    |
@@ -22,5 +38,6 @@ LL |     panic!(&1);
    |
    = note: this error originates in the macro `$crate::panic::panic_2015` which comes from the expansion of the macro `panic` (in Nightly builds, run with -Z macro-backtrace for more info)
 
-error: aborting due to 3 previous errors
+error: aborting due to 5 previous errors
 
+For more information about this error, try `rustc --explain E0080`.
diff --git a/tests/ui/consts/miri_unleashed/const_refers_to_static_cross_crate.stderr b/tests/ui/consts/miri_unleashed/const_refers_to_static_cross_crate.stderr
index 7b22fa4399f..7a7b7bc57da 100644
--- a/tests/ui/consts/miri_unleashed/const_refers_to_static_cross_crate.stderr
+++ b/tests/ui/consts/miri_unleashed/const_refers_to_static_cross_crate.stderr
@@ -9,12 +9,6 @@ LL | const SLICE_MUT: &[u8; 1] = {
                HEX_DUMP
            }
 
-error: could not evaluate constant pattern
-  --> $DIR/const_refers_to_static_cross_crate.rs:40:9
-   |
-LL |         SLICE_MUT => true,
-   |         ^^^^^^^^^
-
 error[E0080]: it is undefined behavior to use this value
   --> $DIR/const_refers_to_static_cross_crate.rs:17:1
    |
@@ -26,12 +20,6 @@ LL | const U8_MUT: &u8 = {
                HEX_DUMP
            }
 
-error: could not evaluate constant pattern
-  --> $DIR/const_refers_to_static_cross_crate.rs:48:9
-   |
-LL |         U8_MUT => true,
-   |         ^^^^^^
-
 error[E0080]: it is undefined behavior to use this value
   --> $DIR/const_refers_to_static_cross_crate.rs:23:1
    |
@@ -43,12 +31,6 @@ LL | const U8_MUT2: &u8 = {
                HEX_DUMP
            }
 
-error: could not evaluate constant pattern
-  --> $DIR/const_refers_to_static_cross_crate.rs:58:9
-   |
-LL |         U8_MUT2 => true,
-   |         ^^^^^^^
-
 error[E0080]: evaluation of constant value failed
   --> $DIR/const_refers_to_static_cross_crate.rs:29:15
    |
@@ -56,6 +38,24 @@ LL |         match static_cross_crate::OPT_ZERO {
    |               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ constant accesses mutable global memory
 
 error: could not evaluate constant pattern
+  --> $DIR/const_refers_to_static_cross_crate.rs:40:9
+   |
+LL |         SLICE_MUT => true,
+   |         ^^^^^^^^^
+
+error: could not evaluate constant pattern
+  --> $DIR/const_refers_to_static_cross_crate.rs:48:9
+   |
+LL |         U8_MUT => true,
+   |         ^^^^^^
+
+error: could not evaluate constant pattern
+  --> $DIR/const_refers_to_static_cross_crate.rs:58:9
+   |
+LL |         U8_MUT2 => true,
+   |         ^^^^^^^
+
+error: could not evaluate constant pattern
   --> $DIR/const_refers_to_static_cross_crate.rs:65:9
    |
 LL |         U8_MUT3 => true,
diff --git a/tests/ui/consts/miri_unleashed/mutable_references.rs b/tests/ui/consts/miri_unleashed/mutable_references.rs
index a361c504b5e..ce7df4b1620 100644
--- a/tests/ui/consts/miri_unleashed/mutable_references.rs
+++ b/tests/ui/consts/miri_unleashed/mutable_references.rs
@@ -4,29 +4,26 @@ use std::cell::UnsafeCell;
 
 // a test demonstrating what things we could allow with a smarter const qualification
 
-// this is fine because is not possible to mutate through an immutable reference.
 static FOO: &&mut u32 = &&mut 42;
+//~^ ERROR encountered mutable pointer in final value of static
 
-// this is fine because accessing an immutable static `BAR` is equivalent to accessing `*&BAR`
-// which puts the mutable reference behind an immutable one.
 static BAR: &mut () = &mut ();
+//~^ ERROR encountered mutable pointer in final value of static
 
 struct Foo<T>(T);
 
-// this is fine for the same reason as `BAR`.
 static BOO: &mut Foo<()> = &mut Foo(());
+//~^ ERROR encountered mutable pointer in final value of static
 
-// interior mutability is fine
 struct Meh {
     x: &'static UnsafeCell<i32>,
 }
 unsafe impl Sync for Meh {}
-static MEH: Meh = Meh {
-    x: &UnsafeCell::new(42),
-};
+static MEH: Meh = Meh { x: &UnsafeCell::new(42) };
+//~^ ERROR encountered mutable pointer in final value of static
 
-// this is fine for the same reason as `BAR`.
 static OH_YES: &mut i32 = &mut 42;
+//~^ ERROR encountered mutable pointer in final value of static
 
 fn main() {
     unsafe {
diff --git a/tests/ui/consts/miri_unleashed/mutable_references.stderr b/tests/ui/consts/miri_unleashed/mutable_references.stderr
index 39298842a33..532d7408e68 100644
--- a/tests/ui/consts/miri_unleashed/mutable_references.stderr
+++ b/tests/ui/consts/miri_unleashed/mutable_references.stderr
@@ -1,5 +1,35 @@
+error: encountered mutable pointer in final value of static
+  --> $DIR/mutable_references.rs:7:1
+   |
+LL | static FOO: &&mut u32 = &&mut 42;
+   | ^^^^^^^^^^^^^^^^^^^^^
+
+error: encountered mutable pointer in final value of static
+  --> $DIR/mutable_references.rs:10:1
+   |
+LL | static BAR: &mut () = &mut ();
+   | ^^^^^^^^^^^^^^^^^^^
+
+error: encountered mutable pointer in final value of static
+  --> $DIR/mutable_references.rs:15:1
+   |
+LL | static BOO: &mut Foo<()> = &mut Foo(());
+   | ^^^^^^^^^^^^^^^^^^^^^^^^
+
+error: encountered mutable pointer in final value of static
+  --> $DIR/mutable_references.rs:22:1
+   |
+LL | static MEH: Meh = Meh { x: &UnsafeCell::new(42) };
+   | ^^^^^^^^^^^^^^^
+
+error: encountered mutable pointer in final value of static
+  --> $DIR/mutable_references.rs:25:1
+   |
+LL | static OH_YES: &mut i32 = &mut 42;
+   | ^^^^^^^^^^^^^^^^^^^^^^^
+
 error[E0594]: cannot assign to `*OH_YES`, as `OH_YES` is an immutable static item
-  --> $DIR/mutable_references.rs:35:5
+  --> $DIR/mutable_references.rs:32:5
    |
 LL |     *OH_YES = 99;
    |     ^^^^^^^^^^^^ cannot assign
@@ -7,31 +37,31 @@ LL |     *OH_YES = 99;
 warning: skipping const checks
    |
 help: skipping check that does not even have a feature gate
-  --> $DIR/mutable_references.rs:8:26
+  --> $DIR/mutable_references.rs:7:26
    |
 LL | static FOO: &&mut u32 = &&mut 42;
    |                          ^^^^^^^
 help: skipping check that does not even have a feature gate
-  --> $DIR/mutable_references.rs:12:23
+  --> $DIR/mutable_references.rs:10:23
    |
 LL | static BAR: &mut () = &mut ();
    |                       ^^^^^^^
 help: skipping check that does not even have a feature gate
-  --> $DIR/mutable_references.rs:17:28
+  --> $DIR/mutable_references.rs:15:28
    |
 LL | static BOO: &mut Foo<()> = &mut Foo(());
    |                            ^^^^^^^^^^^^
 help: skipping check that does not even have a feature gate
-  --> $DIR/mutable_references.rs:25:8
+  --> $DIR/mutable_references.rs:22:28
    |
-LL |     x: &UnsafeCell::new(42),
-   |        ^^^^^^^^^^^^^^^^^^^^
+LL | static MEH: Meh = Meh { x: &UnsafeCell::new(42) };
+   |                            ^^^^^^^^^^^^^^^^^^^^
 help: skipping check that does not even have a feature gate
-  --> $DIR/mutable_references.rs:29:27
+  --> $DIR/mutable_references.rs:25:27
    |
 LL | static OH_YES: &mut i32 = &mut 42;
    |                           ^^^^^^^
 
-error: aborting due to 1 previous error; 1 warning emitted
+error: aborting due to 6 previous errors; 1 warning emitted
 
 For more information about this error, try `rustc --explain E0594`.
diff --git a/tests/ui/consts/promote-not.stderr b/tests/ui/consts/promote-not.stderr
index b93358e8dcc..524d6981721 100644
--- a/tests/ui/consts/promote-not.stderr
+++ b/tests/ui/consts/promote-not.stderr
@@ -19,26 +19,6 @@ LL | };
    | - temporary value is freed at the end of this statement
 
 error[E0716]: temporary value dropped while borrowed
-  --> $DIR/promote-not.rs:20:32
-   |
-LL |         let _x: &'static () = &foo();
-   |                 -----------    ^^^^^ creates a temporary value which is freed while still in use
-   |                 |
-   |                 type annotation requires that borrow lasts for `'static`
-LL |     }
-   |     - temporary value is freed at the end of this statement
-
-error[E0716]: temporary value dropped while borrowed
-  --> $DIR/promote-not.rs:28:29
-   |
-LL |     let _x: &'static i32 = &unsafe { U { x: 0 }.x };
-   |             ------------    ^^^^^^^^^^^^^^^^^^^^^^^ creates a temporary value which is freed while still in use
-   |             |
-   |             type annotation requires that borrow lasts for `'static`
-LL | }
-   | - temporary value is freed at the end of this statement
-
-error[E0716]: temporary value dropped while borrowed
   --> $DIR/promote-not.rs:33:29
    |
 LL |     let _x: &'static i32 = &unsafe { U { x: 0 }.x };
@@ -59,6 +39,26 @@ LL | };
    | - temporary value is freed at the end of this statement
 
 error[E0716]: temporary value dropped while borrowed
+  --> $DIR/promote-not.rs:20:32
+   |
+LL |         let _x: &'static () = &foo();
+   |                 -----------    ^^^^^ creates a temporary value which is freed while still in use
+   |                 |
+   |                 type annotation requires that borrow lasts for `'static`
+LL |     }
+   |     - temporary value is freed at the end of this statement
+
+error[E0716]: temporary value dropped while borrowed
+  --> $DIR/promote-not.rs:28:29
+   |
+LL |     let _x: &'static i32 = &unsafe { U { x: 0 }.x };
+   |             ------------    ^^^^^^^^^^^^^^^^^^^^^^^ creates a temporary value which is freed while still in use
+   |             |
+   |             type annotation requires that borrow lasts for `'static`
+LL | }
+   | - temporary value is freed at the end of this statement
+
+error[E0716]: temporary value dropped while borrowed
   --> $DIR/promote-not.rs:46:29
    |
 LL |     let _val: &'static _ = &(Cell::new(1), 2).0;
diff --git a/tests/ui/consts/promoted_const_call2.stderr b/tests/ui/consts/promoted_const_call2.stderr
index 13d864ed3db..177f7aed17d 100644
--- a/tests/ui/consts/promoted_const_call2.stderr
+++ b/tests/ui/consts/promoted_const_call2.stderr
@@ -18,6 +18,12 @@ LL |     let _: &'static _ = &id(&String::new());
    |            |                 creates a temporary value which is freed while still in use
    |            type annotation requires that borrow lasts for `'static`
 
+error[E0493]: destructor of `String` cannot be evaluated at compile-time
+  --> $DIR/promoted_const_call2.rs:4:30
+   |
+LL |     let _: &'static _ = &id(&String::new());
+   |                              ^^^^^^^^^^^^^ the destructor for this type cannot be evaluated in constants
+
 error[E0716]: temporary value dropped while borrowed
   --> $DIR/promoted_const_call2.rs:11:26
    |
@@ -38,12 +44,6 @@ LL |     let _: &'static _ = &id(&String::new());
    |            |                 creates a temporary value which is freed while still in use
    |            type annotation requires that borrow lasts for `'static`
 
-error[E0493]: destructor of `String` cannot be evaluated at compile-time
-  --> $DIR/promoted_const_call2.rs:4:30
-   |
-LL |     let _: &'static _ = &id(&String::new());
-   |                              ^^^^^^^^^^^^^ the destructor for this type cannot be evaluated in constants
-
 error: aborting due to 5 previous errors
 
 Some errors have detailed explanations: E0493, E0716.
diff --git a/tests/ui/consts/qualif-indirect-mutation-fail.stderr b/tests/ui/consts/qualif-indirect-mutation-fail.stderr
index 6379c00e4b4..458dc2071c4 100644
--- a/tests/ui/consts/qualif-indirect-mutation-fail.stderr
+++ b/tests/ui/consts/qualif-indirect-mutation-fail.stderr
@@ -1,21 +1,55 @@
-error[E0493]: destructor of `(u32, Option<String>)` cannot be evaluated at compile-time
-  --> $DIR/qualif-indirect-mutation-fail.rs:9:9
-   |
-LL |     let mut a: (u32, Option<String>) = (0, None);
-   |         ^^^^^ the destructor for this type cannot be evaluated in constant functions
-
 error[E0493]: destructor of `Option<String>` cannot be evaluated at compile-time
   --> $DIR/qualif-indirect-mutation-fail.rs:15:9
    |
 LL |     let mut x = None;
    |         ^^^^^ the destructor for this type cannot be evaluated in constants
 
+error[E0080]: evaluation of constant value failed
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+   |
+   = note: calling non-const function `<Vec<u8> as Drop>::drop`
+   |
+note: inside `std::ptr::drop_in_place::<Vec<u8>> - shim(Some(Vec<u8>))`
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+note: inside `std::ptr::drop_in_place::<String> - shim(Some(String))`
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+note: inside `std::ptr::drop_in_place::<Option<String>> - shim(Some(Option<String>))`
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+note: inside `A1`
+  --> $DIR/qualif-indirect-mutation-fail.rs:21:1
+   |
+LL | };
+   | ^
+
 error[E0493]: destructor of `Option<String>` cannot be evaluated at compile-time
   --> $DIR/qualif-indirect-mutation-fail.rs:31:9
    |
 LL |     let _z = x;
    |         ^^ the destructor for this type cannot be evaluated in constants
 
+error[E0080]: evaluation of constant value failed
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+   |
+   = note: calling non-const function `<Vec<u8> as Drop>::drop`
+   |
+note: inside `std::ptr::drop_in_place::<Vec<u8>> - shim(Some(Vec<u8>))`
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+note: inside `std::ptr::drop_in_place::<String> - shim(Some(String))`
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+note: inside `std::ptr::drop_in_place::<Option<String>> - shim(Some(Option<String>))`
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+note: inside `A2`
+  --> $DIR/qualif-indirect-mutation-fail.rs:32:1
+   |
+LL | };
+   | ^
+
+error[E0493]: destructor of `(u32, Option<String>)` cannot be evaluated at compile-time
+  --> $DIR/qualif-indirect-mutation-fail.rs:9:9
+   |
+LL |     let mut a: (u32, Option<String>) = (0, None);
+   |         ^^^^^ the destructor for this type cannot be evaluated in constant functions
+
 error[E0493]: destructor of `Option<T>` cannot be evaluated at compile-time
   --> $DIR/qualif-indirect-mutation-fail.rs:36:9
    |
@@ -52,6 +86,7 @@ error[E0493]: destructor of `Option<String>` cannot be evaluated at compile-time
 LL |     let x: Option<String> = None;
    |         ^ the destructor for this type cannot be evaluated in constant functions
 
-error: aborting due to 9 previous errors
+error: aborting due to 11 previous errors
 
-For more information about this error, try `rustc --explain E0493`.
+Some errors have detailed explanations: E0080, E0493.
+For more information about an error, try `rustc --explain E0080`.
diff --git a/tests/ui/consts/recursive-zst-static.default.stderr b/tests/ui/consts/recursive-zst-static.default.stderr
index 7679c50c74b..dedca16db8d 100644
--- a/tests/ui/consts/recursive-zst-static.default.stderr
+++ b/tests/ui/consts/recursive-zst-static.default.stderr
@@ -16,17 +16,7 @@ note: ...which requires evaluating initializer of static `B`...
 LL | static B: () = A;
    |                ^
    = note: ...which again requires evaluating initializer of static `A`, completing the cycle
-note: cycle used when linting top-level module
-  --> $DIR/recursive-zst-static.rs:10:1
-   |
-LL | / static FOO: () = FOO;
-LL | |
-LL | |
-LL | | static A: () = B;
-...  |
-LL | |     FOO
-LL | | }
-   | |_^
+   = note: cycle used when running analysis passes on this crate
    = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
 error: aborting due to 2 previous errors
diff --git a/tests/ui/consts/recursive-zst-static.unleash.stderr b/tests/ui/consts/recursive-zst-static.unleash.stderr
index 7679c50c74b..dedca16db8d 100644
--- a/tests/ui/consts/recursive-zst-static.unleash.stderr
+++ b/tests/ui/consts/recursive-zst-static.unleash.stderr
@@ -16,17 +16,7 @@ note: ...which requires evaluating initializer of static `B`...
 LL | static B: () = A;
    |                ^
    = note: ...which again requires evaluating initializer of static `A`, completing the cycle
-note: cycle used when linting top-level module
-  --> $DIR/recursive-zst-static.rs:10:1
-   |
-LL | / static FOO: () = FOO;
-LL | |
-LL | |
-LL | | static A: () = B;
-...  |
-LL | |     FOO
-LL | | }
-   | |_^
+   = note: cycle used when running analysis passes on this crate
    = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
 error: aborting due to 2 previous errors
diff --git a/tests/ui/coroutine/async_gen_fn_iter.rs b/tests/ui/coroutine/async_gen_fn_iter.rs
index c4a7629f314..42288712c70 100644
--- a/tests/ui/coroutine/async_gen_fn_iter.rs
+++ b/tests/ui/coroutine/async_gen_fn_iter.rs
@@ -46,7 +46,6 @@ async fn async_main() {
 use std::pin::{Pin, pin};
 use std::task::*;
 use std::async_iter::AsyncIterator;
-use std::future::Future;
 
 trait AsyncIterExt {
     fn next(&mut self) -> Next<'_, Self>;
diff --git a/tests/ui/diagnostic-width/long-E0308.stderr b/tests/ui/diagnostic-width/long-E0308.stderr
index 1e5966a1c5d..eb37da037e9 100644
--- a/tests/ui/diagnostic-width/long-E0308.stderr
+++ b/tests/ui/diagnostic-width/long-E0308.stderr
@@ -21,6 +21,7 @@ LL |  |     ))))))))))))))))))))))))))))));
    = note: expected struct `Atype<Btype<..., ...>, ...>`
                 found enum `Result<Result<..., ...>, ...>`
    = note: the full type name has been written to '$TEST_BUILD_DIR/diagnostic-width/long-E0308/long-E0308.long-type-hash.txt'
+   = note: consider using `--verbose` to print the full type name to the console
 
 error[E0308]: mismatched types
   --> $DIR/long-E0308.rs:57:26
@@ -36,6 +37,7 @@ LL | |     ))))))))))))))))))))))));
    = note: expected enum `Option<Result<..., ...>>`
               found enum `Result<Result<..., ...>, ...>`
    = note: the full type name has been written to '$TEST_BUILD_DIR/diagnostic-width/long-E0308/long-E0308.long-type-hash.txt'
+   = note: consider using `--verbose` to print the full type name to the console
 
 error[E0308]: mismatched types
   --> $DIR/long-E0308.rs:88:9
@@ -55,6 +57,7 @@ LL | |     > = ();
    = note: expected struct `Atype<Btype<..., ...>, ...>`
            found unit type `()`
    = note: the full type name has been written to '$TEST_BUILD_DIR/diagnostic-width/long-E0308/long-E0308.long-type-hash.txt'
+   = note: consider using `--verbose` to print the full type name to the console
 
 error[E0308]: mismatched types
   --> $DIR/long-E0308.rs:91:17
@@ -72,6 +75,7 @@ LL | |     ))))))))))))))))))))))));
    = note: expected unit type `()`
                    found enum `Result<Result<..., ...>, ...>`
    = note: the full type name has been written to '$TEST_BUILD_DIR/diagnostic-width/long-E0308/long-E0308.long-type-hash.txt'
+   = note: consider using `--verbose` to print the full type name to the console
 
 error: aborting due to 4 previous errors
 
diff --git a/tests/ui/did_you_mean/bad-assoc-ty.stderr b/tests/ui/did_you_mean/bad-assoc-ty.stderr
index 4a119f673c8..dc93762c9b1 100644
--- a/tests/ui/did_you_mean/bad-assoc-ty.stderr
+++ b/tests/ui/did_you_mean/bad-assoc-ty.stderr
@@ -191,7 +191,14 @@ error[E0223]: ambiguous associated type
   --> $DIR/bad-assoc-ty.rs:33:10
    |
 LL | type H = Fn(u8) -> (u8)::Output;
-   |          ^^^^^^^^^^^^^^^^^^^^^^ help: use fully-qualified syntax: `<(dyn Fn(u8) -> u8 + 'static) as IntoFuture>::Output`
+   |          ^^^^^^^^^^^^^^^^^^^^^^
+   |
+help: use fully-qualified syntax
+   |
+LL | type H = <(dyn Fn(u8) -> u8 + 'static) as BitOr>::Output;
+   |          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+LL | type H = <(dyn Fn(u8) -> u8 + 'static) as IntoFuture>::Output;
+   |          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
 error[E0223]: ambiguous associated type
   --> $DIR/bad-assoc-ty.rs:39:19
diff --git a/tests/ui/drop/missing-drop-method.rs b/tests/ui/drop/missing-drop-method.rs
new file mode 100644
index 00000000000..5828fd6c063
--- /dev/null
+++ b/tests/ui/drop/missing-drop-method.rs
@@ -0,0 +1,4 @@
+struct DropNoMethod;
+impl Drop for DropNoMethod {} //~ ERROR not all trait items implemented, missing: `drop`
+
+fn main() {}
diff --git a/tests/ui/drop/missing-drop-method.stderr b/tests/ui/drop/missing-drop-method.stderr
new file mode 100644
index 00000000000..1128f33e627
--- /dev/null
+++ b/tests/ui/drop/missing-drop-method.stderr
@@ -0,0 +1,11 @@
+error[E0046]: not all trait items implemented, missing: `drop`
+  --> $DIR/missing-drop-method.rs:2:1
+   |
+LL | impl Drop for DropNoMethod {}
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `drop` in implementation
+   |
+   = help: implement the missing item: `fn drop(&mut self) { todo!() }`
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0046`.
diff --git a/tests/ui/drop/repeat-drop-2.stderr b/tests/ui/drop/repeat-drop-2.stderr
index f030228f71a..009a2057212 100644
--- a/tests/ui/drop/repeat-drop-2.stderr
+++ b/tests/ui/drop/repeat-drop-2.stderr
@@ -1,3 +1,12 @@
+error[E0493]: destructor of `String` cannot be evaluated at compile-time
+  --> $DIR/repeat-drop-2.rs:7:25
+   |
+LL | const _: [String; 0] = [String::new(); 0];
+   |                        -^^^^^^^^^^^^^----
+   |                        ||
+   |                        |the destructor for this type cannot be evaluated in constants
+   |                        value is dropped here
+
 error[E0382]: use of moved value: `foo`
   --> $DIR/repeat-drop-2.rs:4:17
    |
@@ -13,15 +22,6 @@ help: consider cloning the value if the performance cost is acceptable
 LL |     let _bar = foo.clone();
    |                   ++++++++
 
-error[E0493]: destructor of `String` cannot be evaluated at compile-time
-  --> $DIR/repeat-drop-2.rs:7:25
-   |
-LL | const _: [String; 0] = [String::new(); 0];
-   |                        -^^^^^^^^^^^^^----
-   |                        ||
-   |                        |the destructor for this type cannot be evaluated in constants
-   |                        value is dropped here
-
 error[E0381]: used binding `x` isn't initialized
   --> $DIR/repeat-drop-2.rs:12:14
    |
diff --git a/tests/ui/error-codes/E0017.rs b/tests/ui/error-codes/E0017.rs
index 144340b3512..c29015c8f33 100644
--- a/tests/ui/error-codes/E0017.rs
+++ b/tests/ui/error-codes/E0017.rs
@@ -1,5 +1,8 @@
 #![feature(const_mut_refs)]
 
+//@ normalize-stderr-test "\(size: ., align: .\)" -> ""
+//@ normalize-stderr-test " +│ ╾─+╼" -> ""
+
 static X: i32 = 1;
 const C: i32 = 2;
 static mut M: i32 = 3;
@@ -14,5 +17,6 @@ static CONST_REF: &'static mut i32 = &mut C; //~ ERROR mutable references are no
 
 static STATIC_MUT_REF: &'static mut i32 = unsafe { &mut M };
 //~^ WARN mutable reference to mutable static is discouraged [static_mut_refs]
+//~| ERROR undefined behavior
 
 fn main() {}
diff --git a/tests/ui/error-codes/E0017.stderr b/tests/ui/error-codes/E0017.stderr
index 982ce52764e..b5e9bacb122 100644
--- a/tests/ui/error-codes/E0017.stderr
+++ b/tests/ui/error-codes/E0017.stderr
@@ -1,5 +1,5 @@
 warning: creating a mutable reference to mutable static is discouraged
-  --> $DIR/E0017.rs:15:52
+  --> $DIR/E0017.rs:18:52
    |
 LL | static STATIC_MUT_REF: &'static mut i32 = unsafe { &mut M };
    |                                                    ^^^^^^ mutable reference to mutable static
@@ -14,7 +14,7 @@ LL | static STATIC_MUT_REF: &'static mut i32 = unsafe { addr_of_mut!(M) };
    |                                                    ~~~~~~~~~~~~~~~
 
 warning: taking a mutable reference to a `const` item
-  --> $DIR/E0017.rs:7:30
+  --> $DIR/E0017.rs:10:30
    |
 LL | const CR: &'static mut i32 = &mut C;
    |                              ^^^^^^
@@ -22,26 +22,26 @@ LL | const CR: &'static mut i32 = &mut C;
    = note: each usage of a `const` item creates a new temporary
    = note: the mutable reference will refer to this temporary, not the original `const` item
 note: `const` item defined here
-  --> $DIR/E0017.rs:4:1
+  --> $DIR/E0017.rs:7:1
    |
 LL | const C: i32 = 2;
    | ^^^^^^^^^^^^
    = note: `#[warn(const_item_mutation)]` on by default
 
 error[E0764]: mutable references are not allowed in the final value of constants
-  --> $DIR/E0017.rs:7:30
+  --> $DIR/E0017.rs:10:30
    |
 LL | const CR: &'static mut i32 = &mut C;
    |                              ^^^^^^
 
 error[E0596]: cannot borrow immutable static item `X` as mutable
-  --> $DIR/E0017.rs:10:39
+  --> $DIR/E0017.rs:13:39
    |
 LL | static STATIC_REF: &'static mut i32 = &mut X;
    |                                       ^^^^^^ cannot borrow as mutable
 
 warning: taking a mutable reference to a `const` item
-  --> $DIR/E0017.rs:12:38
+  --> $DIR/E0017.rs:15:38
    |
 LL | static CONST_REF: &'static mut i32 = &mut C;
    |                                      ^^^^^^
@@ -49,18 +49,29 @@ LL | static CONST_REF: &'static mut i32 = &mut C;
    = note: each usage of a `const` item creates a new temporary
    = note: the mutable reference will refer to this temporary, not the original `const` item
 note: `const` item defined here
-  --> $DIR/E0017.rs:4:1
+  --> $DIR/E0017.rs:7:1
    |
 LL | const C: i32 = 2;
    | ^^^^^^^^^^^^
 
 error[E0764]: mutable references are not allowed in the final value of statics
-  --> $DIR/E0017.rs:12:38
+  --> $DIR/E0017.rs:15:38
    |
 LL | static CONST_REF: &'static mut i32 = &mut C;
    |                                      ^^^^^^
 
-error: aborting due to 3 previous errors; 3 warnings emitted
+error[E0080]: it is undefined behavior to use this value
+  --> $DIR/E0017.rs:18:1
+   |
+LL | static STATIC_MUT_REF: &'static mut i32 = unsafe { &mut M };
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ constructing invalid value: encountered mutable reference in a `const` or `static`
+   |
+   = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rustc repository if you believe it should not be considered undefined behavior.
+   = note: the raw bytes of the constant  {
+               ╾ALLOC0╼
+           }
+
+error: aborting due to 4 previous errors; 3 warnings emitted
 
-Some errors have detailed explanations: E0596, E0764.
-For more information about an error, try `rustc --explain E0596`.
+Some errors have detailed explanations: E0080, E0596, E0764.
+For more information about an error, try `rustc --explain E0080`.
diff --git a/tests/ui/error-codes/E0388.rs b/tests/ui/error-codes/E0388.rs
index bd371328e6b..bbc5f2710bf 100644
--- a/tests/ui/error-codes/E0388.rs
+++ b/tests/ui/error-codes/E0388.rs
@@ -2,10 +2,12 @@ static X: i32 = 1;
 const C: i32 = 2;
 
 const CR: &'static mut i32 = &mut C; //~ ERROR mutable references are not allowed
-                                     //~| WARN taking a mutable
+
+//~| WARN taking a mutable
 static STATIC_REF: &'static mut i32 = &mut X; //~ ERROR E0658
 
 static CONST_REF: &'static mut i32 = &mut C; //~ ERROR mutable references are not allowed
-                                             //~| WARN taking a mutable
+
+//~| WARN taking a mutable
 
 fn main() {}
diff --git a/tests/ui/error-codes/E0388.stderr b/tests/ui/error-codes/E0388.stderr
index 3e89e3f804b..cb7047072bd 100644
--- a/tests/ui/error-codes/E0388.stderr
+++ b/tests/ui/error-codes/E0388.stderr
@@ -20,7 +20,7 @@ LL | const CR: &'static mut i32 = &mut C;
    |                              ^^^^^^
 
 error[E0658]: mutable references are not allowed in statics
-  --> $DIR/E0388.rs:6:39
+  --> $DIR/E0388.rs:7:39
    |
 LL | static STATIC_REF: &'static mut i32 = &mut X;
    |                                       ^^^^^^
@@ -30,7 +30,7 @@ LL | static STATIC_REF: &'static mut i32 = &mut X;
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: taking a mutable reference to a `const` item
-  --> $DIR/E0388.rs:8:38
+  --> $DIR/E0388.rs:9:38
    |
 LL | static CONST_REF: &'static mut i32 = &mut C;
    |                                      ^^^^^^
@@ -44,7 +44,7 @@ LL | const C: i32 = 2;
    | ^^^^^^^^^^^^
 
 error[E0764]: mutable references are not allowed in the final value of statics
-  --> $DIR/E0388.rs:8:38
+  --> $DIR/E0388.rs:9:38
    |
 LL | static CONST_REF: &'static mut i32 = &mut C;
    |                                      ^^^^^^
diff --git a/tests/ui/error-codes/E0396.stderr b/tests/ui/error-codes/E0396.stderr
index ac1e7d65ce8..8bc14139d63 100644
--- a/tests/ui/error-codes/E0396.stderr
+++ b/tests/ui/error-codes/E0396.stderr
@@ -8,42 +8,42 @@ LL | const VALUE: u8 = unsafe { *REG_ADDR };
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
-error[E0658]: dereferencing raw mutable pointers in constant functions is unstable
-  --> $DIR/E0396.rs:10:11
+error[E0658]: dereferencing raw mutable pointers in constants is unstable
+  --> $DIR/E0396.rs:14:36
    |
-LL |     match *INFALLIBLE {}
-   |           ^^^^^^^^^^^
+LL |     const BAD: () = unsafe { match *INFALLIBLE {} };
+   |                                    ^^^^^^^^^^^
    |
    = 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
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
-error[E0658]: dereferencing raw mutable pointers in constant functions is unstable
-  --> $DIR/E0396.rs:10:11
+error[E0658]: dereferencing raw mutable pointers in constants is unstable
+  --> $DIR/E0396.rs:14:36
    |
-LL |     match *INFALLIBLE {}
-   |           ^^^^^^^^^^^
+LL |     const BAD: () = unsafe { match *INFALLIBLE {} };
+   |                                    ^^^^^^^^^^^
    |
    = 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
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
-error[E0658]: dereferencing raw mutable pointers in constants is unstable
-  --> $DIR/E0396.rs:14:36
+error[E0658]: dereferencing raw mutable pointers in constant functions is unstable
+  --> $DIR/E0396.rs:10:11
    |
-LL |     const BAD: () = unsafe { match *INFALLIBLE {} };
-   |                                    ^^^^^^^^^^^
+LL |     match *INFALLIBLE {}
+   |           ^^^^^^^^^^^
    |
    = 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
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
-error[E0658]: dereferencing raw mutable pointers in constants is unstable
-  --> $DIR/E0396.rs:14:36
+error[E0658]: dereferencing raw mutable pointers in constant functions is unstable
+  --> $DIR/E0396.rs:10:11
    |
-LL |     const BAD: () = unsafe { match *INFALLIBLE {} };
-   |                                    ^^^^^^^^^^^
+LL |     match *INFALLIBLE {}
+   |           ^^^^^^^^^^^
    |
    = 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
diff --git a/tests/ui/extern-flag/empty-extern-arg.stderr b/tests/ui/extern-flag/empty-extern-arg.stderr
index 6ad3effe0e2..2785b12a0ae 100644
--- a/tests/ui/extern-flag/empty-extern-arg.stderr
+++ b/tests/ui/extern-flag/empty-extern-arg.stderr
@@ -1,6 +1,13 @@
 error: extern location for std does not exist: 
 
+error: `#[panic_handler]` function required, but not found
+
+error: unwinding panics are not supported without std
+   |
+   = help: using nightly cargo, use -Zbuild-std with panic="abort" to avoid unwinding
+   = note: since the core library is usually precompiled with panic="unwind", rebuilding your crate with panic="abort" may not be enough to fix the problem
+
 error: requires `sized` lang_item
 
-error: aborting due to 2 previous errors
+error: aborting due to 4 previous errors
 
diff --git a/tests/ui/extern/issue-28324.rs b/tests/ui/extern/issue-28324.rs
index f74726e8166..a5e240fa283 100644
--- a/tests/ui/extern/issue-28324.rs
+++ b/tests/ui/extern/issue-28324.rs
@@ -4,5 +4,6 @@ extern "C" {
 
 pub static BAZ: u32 = *&error_message_count;
 //~^ ERROR use of extern static is unsafe and requires
+//~| ERROR could not evaluate static initializer
 
 fn main() {}
diff --git a/tests/ui/extern/issue-28324.stderr b/tests/ui/extern/issue-28324.stderr
index 94ff2131993..1fccb34fdf3 100644
--- a/tests/ui/extern/issue-28324.stderr
+++ b/tests/ui/extern/issue-28324.stderr
@@ -1,3 +1,9 @@
+error[E0080]: could not evaluate static initializer
+  --> $DIR/issue-28324.rs:5:23
+   |
+LL | pub static BAZ: u32 = *&error_message_count;
+   |                       ^^^^^^^^^^^^^^^^^^^^^ cannot access extern static (DefId(0:4 ~ issue_28324[8ec4]::{extern#0}::error_message_count))
+
 error[E0133]: use of extern static is unsafe and requires unsafe function or block
   --> $DIR/issue-28324.rs:5:25
    |
@@ -6,6 +12,7 @@ LL | pub static BAZ: u32 = *&error_message_count;
    |
    = 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
+error: aborting due to 2 previous errors
 
-For more information about this error, try `rustc --explain E0133`.
+Some errors have detailed explanations: E0080, E0133.
+For more information about an error, try `rustc --explain E0080`.
diff --git a/tests/ui/fmt/ifmt-unimpl.stderr b/tests/ui/fmt/ifmt-unimpl.stderr
index 58531c61bbe..3c5428e59fb 100644
--- a/tests/ui/fmt/ifmt-unimpl.stderr
+++ b/tests/ui/fmt/ifmt-unimpl.stderr
@@ -15,7 +15,7 @@ LL |     format!("{:X}", "3");
              i128
              usize
              u8
-           and 20 others
+           and 9 others
    = note: required for `&str` to implement `UpperHex`
 note: required by a bound in `core::fmt::rt::Argument::<'a>::new_upper_hex`
   --> $SRC_DIR/core/src/fmt/rt.rs:LL:COL
diff --git a/tests/ui/generic-associated-types/issue-79636-1.rs b/tests/ui/generic-associated-types/issue-79636-1.rs
index a05311d59c1..3357afb9d4d 100644
--- a/tests/ui/generic-associated-types/issue-79636-1.rs
+++ b/tests/ui/generic-associated-types/issue-79636-1.rs
@@ -15,7 +15,6 @@ where
     //~^ ERROR: missing generics for associated type `Monad::Wrapped`
 {
     outer.bind(|inner| inner)
-    //~^ ERROR type annotations needed
 }
 
 fn main() {
diff --git a/tests/ui/generic-associated-types/issue-79636-1.stderr b/tests/ui/generic-associated-types/issue-79636-1.stderr
index 743d8b7d462..c31064dec62 100644
--- a/tests/ui/generic-associated-types/issue-79636-1.stderr
+++ b/tests/ui/generic-associated-types/issue-79636-1.stderr
@@ -30,19 +30,8 @@ help: function arguments must have a statically known size, borrowed types alway
 LL |     fn bind<B, F>(&self, f: F) -> Self::Wrapped<B> {
    |                   +
 
-error[E0282]: type annotations needed
-  --> $DIR/issue-79636-1.rs:17:17
-   |
-LL |     outer.bind(|inner| inner)
-   |                 ^^^^^
-   |
-help: consider giving this closure parameter an explicit type
-   |
-LL |     outer.bind(|inner: /* Type */| inner)
-   |                      ++++++++++++
-
 error[E0277]: the trait bound `Option<Option<bool>>: Monad` is not satisfied
-  --> $DIR/issue-79636-1.rs:22:21
+  --> $DIR/issue-79636-1.rs:21:21
    |
 LL |     assert_eq!(join(Some(Some(true))), Some(true));
    |                ---- ^^^^^^^^^^^^^^^^ the trait `Monad` is not implemented for `Option<Option<bool>>`
@@ -63,7 +52,7 @@ LL | where
 LL |     MOuter: Monad<Unwrapped = MInner>,
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `join`
 
-error: aborting due to 4 previous errors
+error: aborting due to 3 previous errors
 
-Some errors have detailed explanations: E0107, E0277, E0282.
+Some errors have detailed explanations: E0107, E0277.
 For more information about an error, try `rustc --explain E0107`.
diff --git a/tests/ui/generic-const-items/trivially-unsatisfied-bounds-0.rs b/tests/ui/generic-const-items/trivially-unsatisfied-bounds-0.rs
index dd00b327d2d..93f01c9577c 100644
--- a/tests/ui/generic-const-items/trivially-unsatisfied-bounds-0.rs
+++ b/tests/ui/generic-const-items/trivially-unsatisfied-bounds-0.rs
@@ -3,7 +3,7 @@
 
 // Ensure that we check if trivial bounds on const items hold or not.
 
-const UNUSABLE: () = ()
+const UNUSABLE: () = () //~ ERROR evaluation of constant value failed
 where
     String: Copy;
 
diff --git a/tests/ui/generic-const-items/trivially-unsatisfied-bounds-0.stderr b/tests/ui/generic-const-items/trivially-unsatisfied-bounds-0.stderr
index 942e5dbd88e..407682fee56 100644
--- a/tests/ui/generic-const-items/trivially-unsatisfied-bounds-0.stderr
+++ b/tests/ui/generic-const-items/trivially-unsatisfied-bounds-0.stderr
@@ -1,3 +1,11 @@
+error[E0080]: evaluation of constant value failed
+  --> $DIR/trivially-unsatisfied-bounds-0.rs:6:1
+   |
+LL | / const UNUSABLE: () = ()
+LL | | where
+LL | |     String: Copy;
+   | |_________________^ entering unreachable code
+
 error[E0277]: the trait bound `String: Copy` is not satisfied
   --> $DIR/trivially-unsatisfied-bounds-0.rs:11:13
    |
@@ -13,6 +21,7 @@ LL | where
 LL |     String: Copy;
    |             ^^^^ required by this bound in `UNUSABLE`
 
-error: aborting due to 1 previous error
+error: aborting due to 2 previous errors
 
-For more information about this error, try `rustc --explain E0277`.
+Some errors have detailed explanations: E0080, E0277.
+For more information about an error, try `rustc --explain E0080`.
diff --git a/tests/ui/impl-trait/equality-in-canonical-query.clone.stderr b/tests/ui/impl-trait/equality-in-canonical-query.clone.stderr
index 0e3cd2ff060..e4c8aec3973 100644
--- a/tests/ui/impl-trait/equality-in-canonical-query.clone.stderr
+++ b/tests/ui/impl-trait/equality-in-canonical-query.clone.stderr
@@ -21,5 +21,3 @@ LL |     same_output(foo, rpit);
 
 query stack during panic:
 end of query stack
-error: aborting due to 2 previous errors
-
diff --git a/tests/ui/impl-trait/rpit/early_bound.rs b/tests/ui/impl-trait/rpit/early_bound.rs
index 03bd64d4d76..6dda687929c 100644
--- a/tests/ui/impl-trait/rpit/early_bound.rs
+++ b/tests/ui/impl-trait/rpit/early_bound.rs
@@ -5,7 +5,6 @@ fn test<'a: 'a>(n: bool) -> impl Sized + 'a {
     let true = n else { loop {} };
     let _ = || {
         let _ = identity::<&'a ()>(test(false));
-        //~^ ERROR hidden type for `impl Sized + 'a` captures lifetime that does not appear in bounds
     };
     loop {}
 }
diff --git a/tests/ui/impl-trait/rpit/early_bound.stderr b/tests/ui/impl-trait/rpit/early_bound.stderr
index 815368f250e..780dea4e284 100644
--- a/tests/ui/impl-trait/rpit/early_bound.stderr
+++ b/tests/ui/impl-trait/rpit/early_bound.stderr
@@ -1,14 +1,3 @@
-error[E0700]: hidden type for `impl Sized + 'a` captures lifetime that does not appear in bounds
-  --> $DIR/early_bound.rs:7:17
-   |
-LL | fn test<'a: 'a>(n: bool) -> impl Sized + 'a {
-   |         --                  --------------- opaque type defined here
-   |         |
-   |         hidden type `&'a ()` captures the lifetime `'a` as defined here
-...
-LL |         let _ = identity::<&'a ()>(test(false));
-   |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
 error: concrete type differs from previous defining opaque type use
   --> $DIR/early_bound.rs:3:29
    |
@@ -21,6 +10,5 @@ note: previous use here
 LL |         let _ = identity::<&'a ()>(test(false));
    |                                    ^^^^^^^^^^^
 
-error: aborting due to 2 previous errors
+error: aborting due to 1 previous error
 
-For more information about this error, try `rustc --explain E0700`.
diff --git a/tests/ui/impl-trait/where-allowed.rs b/tests/ui/impl-trait/where-allowed.rs
index 505e2d6c171..72ce617693e 100644
--- a/tests/ui/impl-trait/where-allowed.rs
+++ b/tests/ui/impl-trait/where-allowed.rs
@@ -59,7 +59,6 @@ fn in_impl_Fn_return_in_parameters(_: &impl Fn() -> impl Debug) { panic!() }
 fn in_impl_Fn_parameter_in_return() -> &'static impl Fn(impl Debug) { panic!() }
 //~^ ERROR `impl Trait` is not allowed in the parameters of `Fn` trait bounds
 //~| ERROR nested `impl Trait` is not allowed
-//~| ERROR: type annotations needed
 
 // Allowed
 fn in_impl_Fn_return_in_return() -> &'static impl Fn() -> impl Debug { panic!() }
diff --git a/tests/ui/impl-trait/where-allowed.stderr b/tests/ui/impl-trait/where-allowed.stderr
index c22312cce19..f203f4cabc8 100644
--- a/tests/ui/impl-trait/where-allowed.stderr
+++ b/tests/ui/impl-trait/where-allowed.stderr
@@ -17,7 +17,7 @@ LL | fn in_impl_Fn_parameter_in_return() -> &'static impl Fn(impl Debug) { panic
    |                                                 outer `impl Trait`
 
 error[E0658]: `impl Trait` in associated types is unstable
-  --> $DIR/where-allowed.rs:123:16
+  --> $DIR/where-allowed.rs:122:16
    |
 LL |     type Out = impl Debug;
    |                ^^^^^^^^^^
@@ -27,7 +27,7 @@ LL |     type Out = impl Debug;
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0658]: `impl Trait` in type aliases is unstable
-  --> $DIR/where-allowed.rs:160:23
+  --> $DIR/where-allowed.rs:159:23
    |
 LL | type InTypeAlias<R> = impl Debug;
    |                       ^^^^^^^^^^
@@ -37,7 +37,7 @@ LL | type InTypeAlias<R> = impl Debug;
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0658]: `impl Trait` in type aliases is unstable
-  --> $DIR/where-allowed.rs:163:39
+  --> $DIR/where-allowed.rs:162:39
    |
 LL | type InReturnInTypeAlias<R> = fn() -> impl Debug;
    |                                       ^^^^^^^^^^
@@ -127,7 +127,7 @@ LL | fn in_impl_Fn_parameter_in_return() -> &'static impl Fn(impl Debug) { panic
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in the parameters of `Fn` trait bounds
-  --> $DIR/where-allowed.rs:69:38
+  --> $DIR/where-allowed.rs:68:38
    |
 LL | fn in_Fn_parameter_in_generics<F: Fn(impl Debug)> (_: F) { panic!() }
    |                                      ^^^^^^^^^^
@@ -135,7 +135,7 @@ LL | fn in_Fn_parameter_in_generics<F: Fn(impl Debug)> (_: F) { panic!() }
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in the return type of `Fn` trait bounds
-  --> $DIR/where-allowed.rs:73:40
+  --> $DIR/where-allowed.rs:72:40
    |
 LL | fn in_Fn_return_in_generics<F: Fn() -> impl Debug> (_: F) { panic!() }
    |                                        ^^^^^^^^^^
@@ -143,7 +143,7 @@ LL | fn in_Fn_return_in_generics<F: Fn() -> impl Debug> (_: F) { panic!() }
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in field types
-  --> $DIR/where-allowed.rs:87:32
+  --> $DIR/where-allowed.rs:86:32
    |
 LL | struct InBraceStructField { x: impl Debug }
    |                                ^^^^^^^^^^
@@ -151,7 +151,7 @@ LL | struct InBraceStructField { x: impl Debug }
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in field types
-  --> $DIR/where-allowed.rs:91:41
+  --> $DIR/where-allowed.rs:90:41
    |
 LL | struct InAdtInBraceStructField { x: Vec<impl Debug> }
    |                                         ^^^^^^^^^^
@@ -159,7 +159,7 @@ LL | struct InAdtInBraceStructField { x: Vec<impl Debug> }
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in field types
-  --> $DIR/where-allowed.rs:95:27
+  --> $DIR/where-allowed.rs:94:27
    |
 LL | struct InTupleStructField(impl Debug);
    |                           ^^^^^^^^^^
@@ -167,7 +167,7 @@ LL | struct InTupleStructField(impl Debug);
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in field types
-  --> $DIR/where-allowed.rs:100:25
+  --> $DIR/where-allowed.rs:99:25
    |
 LL |     InBraceVariant { x: impl Debug },
    |                         ^^^^^^^^^^
@@ -175,7 +175,7 @@ LL |     InBraceVariant { x: impl Debug },
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in field types
-  --> $DIR/where-allowed.rs:102:20
+  --> $DIR/where-allowed.rs:101:20
    |
 LL |     InTupleVariant(impl Debug),
    |                    ^^^^^^^^^^
@@ -183,7 +183,7 @@ LL |     InTupleVariant(impl Debug),
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in `extern fn` parameters
-  --> $DIR/where-allowed.rs:144:33
+  --> $DIR/where-allowed.rs:143:33
    |
 LL |     fn in_foreign_parameters(_: impl Debug);
    |                                 ^^^^^^^^^^
@@ -191,7 +191,7 @@ LL |     fn in_foreign_parameters(_: impl Debug);
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in `extern fn` return types
-  --> $DIR/where-allowed.rs:147:31
+  --> $DIR/where-allowed.rs:146:31
    |
 LL |     fn in_foreign_return() -> impl Debug;
    |                               ^^^^^^^^^^
@@ -199,7 +199,7 @@ LL |     fn in_foreign_return() -> impl Debug;
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in `fn` pointer return types
-  --> $DIR/where-allowed.rs:163:39
+  --> $DIR/where-allowed.rs:162:39
    |
 LL | type InReturnInTypeAlias<R> = fn() -> impl Debug;
    |                                       ^^^^^^^^^^
@@ -207,7 +207,7 @@ LL | type InReturnInTypeAlias<R> = fn() -> impl Debug;
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in traits
-  --> $DIR/where-allowed.rs:168:16
+  --> $DIR/where-allowed.rs:167:16
    |
 LL | impl PartialEq<impl Debug> for () {
    |                ^^^^^^^^^^
@@ -215,7 +215,7 @@ LL | impl PartialEq<impl Debug> for () {
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in impl headers
-  --> $DIR/where-allowed.rs:173:24
+  --> $DIR/where-allowed.rs:172:24
    |
 LL | impl PartialEq<()> for impl Debug {
    |                        ^^^^^^^^^^
@@ -223,7 +223,7 @@ LL | impl PartialEq<()> for impl Debug {
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in impl headers
-  --> $DIR/where-allowed.rs:178:6
+  --> $DIR/where-allowed.rs:177:6
    |
 LL | impl impl Debug {
    |      ^^^^^^^^^^
@@ -231,7 +231,7 @@ LL | impl impl Debug {
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in impl headers
-  --> $DIR/where-allowed.rs:184:24
+  --> $DIR/where-allowed.rs:183:24
    |
 LL | impl InInherentImplAdt<impl Debug> {
    |                        ^^^^^^^^^^
@@ -239,7 +239,7 @@ LL | impl InInherentImplAdt<impl Debug> {
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in bounds
-  --> $DIR/where-allowed.rs:190:11
+  --> $DIR/where-allowed.rs:189:11
    |
 LL |     where impl Debug: Debug
    |           ^^^^^^^^^^
@@ -247,7 +247,7 @@ LL |     where impl Debug: Debug
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in bounds
-  --> $DIR/where-allowed.rs:197:15
+  --> $DIR/where-allowed.rs:196:15
    |
 LL |     where Vec<impl Debug>: Debug
    |               ^^^^^^^^^^
@@ -255,7 +255,7 @@ LL |     where Vec<impl Debug>: Debug
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in bounds
-  --> $DIR/where-allowed.rs:204:24
+  --> $DIR/where-allowed.rs:203:24
    |
 LL |     where T: PartialEq<impl Debug>
    |                        ^^^^^^^^^^
@@ -263,7 +263,7 @@ LL |     where T: PartialEq<impl Debug>
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in the parameters of `Fn` trait bounds
-  --> $DIR/where-allowed.rs:211:17
+  --> $DIR/where-allowed.rs:210:17
    |
 LL |     where T: Fn(impl Debug)
    |                 ^^^^^^^^^^
@@ -271,7 +271,7 @@ LL |     where T: Fn(impl Debug)
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in the return type of `Fn` trait bounds
-  --> $DIR/where-allowed.rs:218:22
+  --> $DIR/where-allowed.rs:217:22
    |
 LL |     where T: Fn() -> impl Debug
    |                      ^^^^^^^^^^
@@ -279,7 +279,7 @@ LL |     where T: Fn() -> impl Debug
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in generic parameter defaults
-  --> $DIR/where-allowed.rs:224:40
+  --> $DIR/where-allowed.rs:223:40
    |
 LL | struct InStructGenericParamDefault<T = impl Debug>(T);
    |                                        ^^^^^^^^^^
@@ -287,7 +287,7 @@ LL | struct InStructGenericParamDefault<T = impl Debug>(T);
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in generic parameter defaults
-  --> $DIR/where-allowed.rs:228:36
+  --> $DIR/where-allowed.rs:227:36
    |
 LL | enum InEnumGenericParamDefault<T = impl Debug> { Variant(T) }
    |                                    ^^^^^^^^^^
@@ -295,7 +295,7 @@ LL | enum InEnumGenericParamDefault<T = impl Debug> { Variant(T) }
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in generic parameter defaults
-  --> $DIR/where-allowed.rs:232:38
+  --> $DIR/where-allowed.rs:231:38
    |
 LL | trait InTraitGenericParamDefault<T = impl Debug> {}
    |                                      ^^^^^^^^^^
@@ -303,7 +303,7 @@ LL | trait InTraitGenericParamDefault<T = impl Debug> {}
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in generic parameter defaults
-  --> $DIR/where-allowed.rs:236:41
+  --> $DIR/where-allowed.rs:235:41
    |
 LL | type InTypeAliasGenericParamDefault<T = impl Debug> = T;
    |                                         ^^^^^^^^^^
@@ -311,7 +311,7 @@ LL | type InTypeAliasGenericParamDefault<T = impl Debug> = T;
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in generic parameter defaults
-  --> $DIR/where-allowed.rs:240:11
+  --> $DIR/where-allowed.rs:239:11
    |
 LL | impl <T = impl Debug> T {}
    |           ^^^^^^^^^^
@@ -319,7 +319,7 @@ LL | impl <T = impl Debug> T {}
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in generic parameter defaults
-  --> $DIR/where-allowed.rs:247:40
+  --> $DIR/where-allowed.rs:246:40
    |
 LL | fn in_method_generic_param_default<T = impl Debug>(_: T) {}
    |                                        ^^^^^^^^^^
@@ -327,7 +327,7 @@ LL | fn in_method_generic_param_default<T = impl Debug>(_: T) {}
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in the type of variable bindings
-  --> $DIR/where-allowed.rs:253:29
+  --> $DIR/where-allowed.rs:252:29
    |
 LL |     let _in_local_variable: impl Fn() = || {};
    |                             ^^^^^^^^^
@@ -335,7 +335,7 @@ LL |     let _in_local_variable: impl Fn() = || {};
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error[E0562]: `impl Trait` is not allowed in closure return types
-  --> $DIR/where-allowed.rs:255:46
+  --> $DIR/where-allowed.rs:254:46
    |
 LL |     let _in_return_in_local_variable = || -> impl Fn() { || {} };
    |                                              ^^^^^^^^^
@@ -343,7 +343,7 @@ LL |     let _in_return_in_local_variable = || -> impl Fn() { || {} };
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
 
 error: defaults for type parameters are only allowed in `struct`, `enum`, `type`, or `trait` definitions
-  --> $DIR/where-allowed.rs:240:7
+  --> $DIR/where-allowed.rs:239:7
    |
 LL | impl <T = impl Debug> T {}
    |       ^^^^^^^^^^^^^^
@@ -353,7 +353,7 @@ LL | impl <T = impl Debug> T {}
    = note: `#[deny(invalid_type_param_default)]` on by default
 
 error: defaults for type parameters are only allowed in `struct`, `enum`, `type`, or `trait` definitions
-  --> $DIR/where-allowed.rs:247:36
+  --> $DIR/where-allowed.rs:246:36
    |
 LL | fn in_method_generic_param_default<T = impl Debug>(_: T) {}
    |                                    ^^^^^^^^^^^^^^
@@ -362,7 +362,7 @@ LL | fn in_method_generic_param_default<T = impl Debug>(_: T) {}
    = note: for more information, see issue #36887 <https://github.com/rust-lang/rust/issues/36887>
 
 error[E0118]: no nominal type found for inherent implementation
-  --> $DIR/where-allowed.rs:240:1
+  --> $DIR/where-allowed.rs:239:1
    |
 LL | impl <T = impl Debug> T {}
    | ^^^^^^^^^^^^^^^^^^^^^^^ impl requires a nominal type
@@ -377,14 +377,8 @@ LL | fn in_dyn_Fn_return_in_return() -> &'static dyn Fn() -> impl Debug { panic!
    |
    = note: cannot satisfy `_: Debug`
 
-error[E0282]: type annotations needed
-  --> $DIR/where-allowed.rs:59:49
-   |
-LL | fn in_impl_Fn_parameter_in_return() -> &'static impl Fn(impl Debug) { panic!() }
-   |                                                 ^^^^^^^^^^^^^^^^^^^ cannot infer type
-
 error[E0283]: type annotations needed
-  --> $DIR/where-allowed.rs:65:46
+  --> $DIR/where-allowed.rs:64:46
    |
 LL | fn in_impl_Fn_return_in_return() -> &'static impl Fn() -> impl Debug { panic!() }
    |                                              ^^^^^^^^^^^^^^^^^^^^^^^ cannot infer type
@@ -396,7 +390,7 @@ LL | fn in_impl_Fn_return_in_return() -> &'static impl Fn() -> impl Debug { pani
              where Args: Tuple, F: Fn<Args>, A: Allocator, F: ?Sized;
 
 error[E0599]: no function or associated item named `into_vec` found for slice `[_]` in the current scope
-  --> $DIR/where-allowed.rs:82:5
+  --> $DIR/where-allowed.rs:81:5
    |
 LL |     vec![vec![0; 10], vec![12; 7], vec![8; 3]]
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function or associated item not found in `[_]`
@@ -404,7 +398,7 @@ LL |     vec![vec![0; 10], vec![12; 7], vec![8; 3]]
    = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error[E0053]: method `in_trait_impl_return` has an incompatible type for trait
-  --> $DIR/where-allowed.rs:130:34
+  --> $DIR/where-allowed.rs:129:34
    |
 LL |     type Out = impl Debug;
    |                ---------- the expected opaque type
@@ -416,7 +410,7 @@ LL |     fn in_trait_impl_return() -> impl Debug { () }
    |                                  help: change the output type to match the trait: `<() as DummyTrait>::Out`
    |
 note: type in trait
-  --> $DIR/where-allowed.rs:120:34
+  --> $DIR/where-allowed.rs:119:34
    |
 LL |     fn in_trait_impl_return() -> Self::Out;
    |                                  ^^^^^^^^^
@@ -425,14 +419,14 @@ LL |     fn in_trait_impl_return() -> Self::Out;
    = note: distinct uses of `impl Trait` result in different opaque types
 
 error: unconstrained opaque type
-  --> $DIR/where-allowed.rs:123:16
+  --> $DIR/where-allowed.rs:122:16
    |
 LL |     type Out = impl Debug;
    |                ^^^^^^^^^^
    |
    = note: `Out` must be used in combination with a concrete type within the same impl
 
-error: aborting due to 51 previous errors
+error: aborting due to 50 previous errors
 
-Some errors have detailed explanations: E0053, E0118, E0282, E0283, E0562, E0599, E0658, E0666.
+Some errors have detailed explanations: E0053, E0118, E0283, E0562, E0599, E0658, E0666.
 For more information about an error, try `rustc --explain E0053`.
diff --git a/tests/ui/inference/issue-80409.no-compat.stderr b/tests/ui/inference/issue-80409.no-compat.stderr
index 7bb4786db3a..523ca229b06 100644
--- a/tests/ui/inference/issue-80409.no-compat.stderr
+++ b/tests/ui/inference/issue-80409.no-compat.stderr
@@ -1,6 +1,14 @@
 error: internal compiler error: error performing ParamEnvAnd { param_env: ParamEnv { caller_bounds: [], reveal: UserFacing }, value: ImpliedOutlivesBounds { ty: &'?2 mut StateContext<'?3, usize> } }
+  --> $DIR/issue-80409.rs:49:30
    |
-   = query stack during panic:
-end of query stack
-error: aborting due to 1 previous error
+LL |     builder.state().on_entry(|_| {});
+   |                              ^^^
+   |
+note: 
+  --> $DIR/issue-80409.rs:49:30
+   |
+LL |     builder.state().on_entry(|_| {});
+   |                              ^^^
 
+query stack during panic:
+end of query stack
diff --git a/tests/ui/inference/issue-80409.rs b/tests/ui/inference/issue-80409.rs
index e54da78614f..dfb84563e6d 100644
--- a/tests/ui/inference/issue-80409.rs
+++ b/tests/ui/inference/issue-80409.rs
@@ -8,6 +8,7 @@
 //@[no-compat] check-fail
 //@[no-compat] known-bug: #80409
 //@[no-compat] failure-status: 101
+//@[no-compat] normalize-stderr-test "delayed at.*" -> ""
 //@[no-compat] normalize-stderr-test "note: .*\n\n" -> ""
 //@[no-compat] normalize-stderr-test "thread 'rustc' panicked.*\n" -> ""
 //@[no-compat] normalize-stderr-test "(error: internal compiler error: [^:]+):\d+:\d+: " -> "$1:LL:CC: "
diff --git a/tests/ui/issues/issue-106755.rs b/tests/ui/issues/issue-106755.rs
index 40cb83fcabc..689b1d885ae 100644
--- a/tests/ui/issues/issue-106755.rs
+++ b/tests/ui/issues/issue-106755.rs
@@ -15,7 +15,5 @@ impl<T: MyTrait> !Send for TestType<T> {} //~ ERROR found both positive and nega
 unsafe impl<T: 'static> Send for TestType<T> {} //~ ERROR conflicting implementations
 
 impl !Send for TestType<i32> {}
-//~^ WARNING
-//~| WARNING this will change its meaning
 
 fn main() {}
diff --git a/tests/ui/issues/issue-106755.stderr b/tests/ui/issues/issue-106755.stderr
index 6b3a8427e77..54397034062 100644
--- a/tests/ui/issues/issue-106755.stderr
+++ b/tests/ui/issues/issue-106755.stderr
@@ -16,23 +16,7 @@ LL | unsafe impl<T: MyTrait + 'static> Send for TestType<T> {}
 LL | unsafe impl<T: 'static> Send for TestType<T> {}
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ conflicting implementation for `TestType<_>`
 
-warning: cross-crate traits with a default impl, like `Send`, should not be specialized
-  --> $DIR/issue-106755.rs:17:1
-   |
-LL | impl !Send for TestType<i32> {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = warning: this will change its meaning in a future release!
-   = note: for more information, see issue #93367 <https://github.com/rust-lang/rust/issues/93367>
-   = note: `i32` is not a generic parameter
-note: try using the same sequence of generic parameters as the struct definition
-  --> $DIR/issue-106755.rs:9:1
-   |
-LL | struct TestType<T>(::std::marker::PhantomData<T>);
-   | ^^^^^^^^^^^^^^^^^^
-   = note: `#[warn(suspicious_auto_trait_impls)]` on by default
-
-error: aborting due to 2 previous errors; 1 warning emitted
+error: aborting due to 2 previous errors
 
 Some errors have detailed explanations: E0119, E0751.
 For more information about an error, try `rustc --explain E0119`.
diff --git a/tests/ui/issues/issue-17252.rs b/tests/ui/issues/issue-17252.rs
index 7141e4874c0..5941e10f8b0 100644
--- a/tests/ui/issues/issue-17252.rs
+++ b/tests/ui/issues/issue-17252.rs
@@ -4,6 +4,7 @@ fn main() {
     let _x: [u8; FOO]; // caused stack overflow prior to fix
     let _y: usize = 1 + {
         const BAR: usize = BAR;
+        //~^ ERROR: cycle
         let _z: [u8; BAR]; // caused stack overflow prior to fix
         1
     };
diff --git a/tests/ui/issues/issue-17252.stderr b/tests/ui/issues/issue-17252.stderr
index d8984860457..56bc32b19ab 100644
--- a/tests/ui/issues/issue-17252.stderr
+++ b/tests/ui/issues/issue-17252.stderr
@@ -10,13 +10,24 @@ note: ...which requires const-evaluating + checking `FOO`...
 LL | const FOO: usize = FOO;
    |                    ^^^
    = note: ...which again requires simplifying constant for the type system `FOO`, completing the cycle
-note: cycle used when const-evaluating + checking `main::{constant#0}`
-  --> $DIR/issue-17252.rs:4:18
+   = note: cycle used when running analysis passes on this crate
+   = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
+
+error[E0391]: cycle detected when simplifying constant for the type system `main::BAR`
+  --> $DIR/issue-17252.rs:6:9
+   |
+LL |         const BAR: usize = BAR;
+   |         ^^^^^^^^^^^^^^^^
+   |
+note: ...which requires const-evaluating + checking `main::BAR`...
+  --> $DIR/issue-17252.rs:6:28
    |
-LL |     let _x: [u8; FOO]; // caused stack overflow prior to fix
-   |                  ^^^
+LL |         const BAR: usize = BAR;
+   |                            ^^^
+   = note: ...which again requires simplifying constant for the type system `main::BAR`, completing the cycle
+   = note: cycle used when running analysis passes on this crate
    = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
-error: aborting due to 1 previous error
+error: aborting due to 2 previous errors
 
 For more information about this error, try `rustc --explain E0391`.
diff --git a/tests/ui/issues/issue-23302-enum-infinite-recursion/issue-23302-3.stderr b/tests/ui/issues/issue-23302-enum-infinite-recursion/issue-23302-3.stderr
index e23957c6de7..8a152f58966 100644
--- a/tests/ui/issues/issue-23302-enum-infinite-recursion/issue-23302-3.stderr
+++ b/tests/ui/issues/issue-23302-enum-infinite-recursion/issue-23302-3.stderr
@@ -20,15 +20,7 @@ note: ...which requires const-evaluating + checking `B`...
 LL | const B: i32 = A;
    |                ^
    = note: ...which again requires simplifying constant for the type system `A`, completing the cycle
-note: cycle used when linting top-level module
-  --> $DIR/issue-23302-3.rs:1:1
-   |
-LL | / const A: i32 = B;
-LL | |
-LL | | const B: i32 = A;
-LL | |
-LL | | fn main() { }
-   | |_____________^
+   = note: cycle used when running analysis passes on this crate
    = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
 error: aborting due to 1 previous error
diff --git a/tests/ui/issues/issue-30123.stderr b/tests/ui/issues/issue-30123.stderr
index cf71a01b58a..c086b45ac9b 100644
--- a/tests/ui/issues/issue-30123.stderr
+++ b/tests/ui/issues/issue-30123.stderr
@@ -4,6 +4,11 @@ error[E0599]: no function or associated item named `new_undirected` found for st
 LL |     let ug = Graph::<i32, i32>::new_undirected();
    |                                 ^^^^^^^^^^^^^^ function or associated item not found in `Graph<i32, i32>`
    |
+note: if you're trying to build a new `issue_30123_aux::Graph<i32, i32>`, consider using `issue_30123_aux::Graph::<N, E>::new` which returns `issue_30123_aux::Graph<_, _>`
+  --> $DIR/auxiliary/issue-30123-aux.rs:14:5
+   |
+LL |     pub fn new() -> Self {
+   |     ^^^^^^^^^^^^^^^^^^^^
    = note: the function or associated item was found for
            - `issue_30123_aux::Graph<N, E, Undirected>`
 
diff --git a/tests/ui/issues/issue-76191.rs b/tests/ui/issues/issue-76191.rs
index d9790d2b56e..277624c005a 100644
--- a/tests/ui/issues/issue-76191.rs
+++ b/tests/ui/issues/issue-76191.rs
@@ -6,6 +6,7 @@ use std::ops::RangeInclusive;
 const RANGE: RangeInclusive<i32> = 0..=255;
 
 const RANGE2: RangeInclusive<i32> = panic!();
+//~^ ERROR evaluation of constant value failed
 
 fn main() {
     let n: i32 = 1;
diff --git a/tests/ui/issues/issue-76191.stderr b/tests/ui/issues/issue-76191.stderr
index 32d9105b259..3702bfb7769 100644
--- a/tests/ui/issues/issue-76191.stderr
+++ b/tests/ui/issues/issue-76191.stderr
@@ -1,5 +1,13 @@
+error[E0080]: evaluation of constant value failed
+  --> $DIR/issue-76191.rs:8:37
+   |
+LL | const RANGE2: RangeInclusive<i32> = panic!();
+   |                                     ^^^^^^^^ the evaluated program panicked at 'explicit panic', $DIR/issue-76191.rs:8:37
+   |
+   = note: this error originates in the macro `$crate::panic::panic_2015` which comes from the expansion of the macro `panic` (in Nightly builds, run with -Z macro-backtrace for more info)
+
 error[E0308]: mismatched types
-  --> $DIR/issue-76191.rs:13:9
+  --> $DIR/issue-76191.rs:14:9
    |
 LL | const RANGE: RangeInclusive<i32> = 0..=255;
    | -------------------------------- constant defined here
@@ -20,7 +28,7 @@ LL |         0..=255 => {}
    |         ~~~~~~~
 
 error[E0308]: mismatched types
-  --> $DIR/issue-76191.rs:15:9
+  --> $DIR/issue-76191.rs:16:9
    |
 LL | const RANGE2: RangeInclusive<i32> = panic!();
    | --------------------------------- constant defined here
@@ -38,6 +46,7 @@ LL |         RANGE2 => {}
             found struct `RangeInclusive<i32>`
    = note: constants only support matching by type, if you meant to match against a range of values, consider using a range pattern like `min ..= max` in the match block
 
-error: aborting due to 2 previous errors
+error: aborting due to 3 previous errors
 
-For more information about this error, try `rustc --explain E0308`.
+Some errors have detailed explanations: E0080, E0308.
+For more information about an error, try `rustc --explain E0080`.
diff --git a/tests/ui/lazy-type-alias/constrained-late-bound-regions.rs b/tests/ui/lazy-type-alias/constrained-late-bound-regions.rs
new file mode 100644
index 00000000000..e759e72d745
--- /dev/null
+++ b/tests/ui/lazy-type-alias/constrained-late-bound-regions.rs
@@ -0,0 +1,15 @@
+//@ check-pass
+// Weak alias types constrain late-bound regions if their normalized form constrains them.
+
+#![feature(lazy_type_alias)]
+#![allow(incomplete_features)]
+
+type Ref<'a> = &'a ();
+
+type FnPtr = for<'a> fn(Ref<'a>) -> &'a (); // OK
+type DynCl = dyn for<'a> Fn(Ref<'a>) -> &'a (); // OK
+
+fn map0(_: Ref) -> Ref { &() } // OK
+fn map1(_: Ref<'_>) -> Ref<'_> { &() } // OK
+
+fn main() {}
diff --git a/tests/ui/lazy-type-alias/constrained-params.rs b/tests/ui/lazy-type-alias/constrained-params-in-impl.rs
index 59693dd5461..59693dd5461 100644
--- a/tests/ui/lazy-type-alias/constrained-params.rs
+++ b/tests/ui/lazy-type-alias/constrained-params-in-impl.rs
diff --git a/tests/ui/lazy-type-alias/unconstrained-late-bound-regions.rs b/tests/ui/lazy-type-alias/unconstrained-late-bound-regions.rs
new file mode 100644
index 00000000000..844570e22d2
--- /dev/null
+++ b/tests/ui/lazy-type-alias/unconstrained-late-bound-regions.rs
@@ -0,0 +1,23 @@
+// Weak alias types only constrain late-bound regions if their normalized form constrains them.
+
+#![feature(lazy_type_alias)]
+#![allow(incomplete_features)]
+
+type NotInjective<'a> = <() as Discard>::Output<'a>;
+
+type FnPtr0 = for<'a> fn(NotInjective<'a>) -> &'a ();
+//~^ ERROR references lifetime `'a`, which is not constrained by the fn input types
+type FnPtr1 = for<'a> fn(NotInjectiveEither<'a, ()>) -> NotInjectiveEither<'a, ()>;
+//~^ ERROR references lifetime `'a`, which is not constrained by the fn input types
+type DynCl = dyn for<'a> Fn(NotInjective<'a>) -> &'a ();
+//~^ ERROR references lifetime `'a`, which does not appear in the trait input types
+
+trait Discard { type Output<'a>; }
+impl Discard for () { type Output<'_a> = (); }
+
+type NotInjectiveEither<'a, Linchpin> = Linchpin
+where
+    Linchpin: Fn() -> &'a ();
+
+
+fn main() {}
diff --git a/tests/ui/lazy-type-alias/unconstrained-late-bound-regions.stderr b/tests/ui/lazy-type-alias/unconstrained-late-bound-regions.stderr
new file mode 100644
index 00000000000..241c7761c60
--- /dev/null
+++ b/tests/ui/lazy-type-alias/unconstrained-late-bound-regions.stderr
@@ -0,0 +1,22 @@
+error[E0581]: return type references lifetime `'a`, which is not constrained by the fn input types
+  --> $DIR/unconstrained-late-bound-regions.rs:8:47
+   |
+LL | type FnPtr0 = for<'a> fn(NotInjective<'a>) -> &'a ();
+   |                                               ^^^^^^
+
+error[E0581]: return type references lifetime `'a`, which is not constrained by the fn input types
+  --> $DIR/unconstrained-late-bound-regions.rs:10:57
+   |
+LL | type FnPtr1 = for<'a> fn(NotInjectiveEither<'a, ()>) -> NotInjectiveEither<'a, ()>;
+   |                                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+error[E0582]: binding for associated type `Output` references lifetime `'a`, which does not appear in the trait input types
+  --> $DIR/unconstrained-late-bound-regions.rs:12:50
+   |
+LL | type DynCl = dyn for<'a> Fn(NotInjective<'a>) -> &'a ();
+   |                                                  ^^^^^^
+
+error: aborting due to 3 previous errors
+
+Some errors have detailed explanations: E0581, E0582.
+For more information about an error, try `rustc --explain E0581`.
diff --git a/tests/ui/lazy-type-alias/unconstrained-param-due-to-overflow.rs b/tests/ui/lazy-type-alias/unconstrained-params-in-impl-due-to-overflow.rs
index eceefa719ec..eceefa719ec 100644
--- a/tests/ui/lazy-type-alias/unconstrained-param-due-to-overflow.rs
+++ b/tests/ui/lazy-type-alias/unconstrained-params-in-impl-due-to-overflow.rs
diff --git a/tests/ui/lazy-type-alias/unconstrained-param-due-to-overflow.stderr b/tests/ui/lazy-type-alias/unconstrained-params-in-impl-due-to-overflow.stderr
index 9af6f5dda0b..b65c84226ce 100644
--- a/tests/ui/lazy-type-alias/unconstrained-param-due-to-overflow.stderr
+++ b/tests/ui/lazy-type-alias/unconstrained-params-in-impl-due-to-overflow.stderr
@@ -1,5 +1,5 @@
 error[E0207]: the type parameter `T` is not constrained by the impl trait, self type, or predicates
-  --> $DIR/unconstrained-param-due-to-overflow.rs:4:6
+  --> $DIR/unconstrained-params-in-impl-due-to-overflow.rs:4:6
    |
 LL | impl<T> Loop<T> {}
    |      ^ unconstrained type parameter
diff --git a/tests/ui/lazy-type-alias/unconstrained-params.rs b/tests/ui/lazy-type-alias/unconstrained-params-in-impl.rs
index d58938b3070..d58938b3070 100644
--- a/tests/ui/lazy-type-alias/unconstrained-params.rs
+++ b/tests/ui/lazy-type-alias/unconstrained-params-in-impl.rs
diff --git a/tests/ui/lazy-type-alias/unconstrained-params.stderr b/tests/ui/lazy-type-alias/unconstrained-params-in-impl.stderr
index 3c52a06c319..2419c78cba8 100644
--- a/tests/ui/lazy-type-alias/unconstrained-params.stderr
+++ b/tests/ui/lazy-type-alias/unconstrained-params-in-impl.stderr
@@ -1,5 +1,5 @@
 error[E0207]: the type parameter `T` is not constrained by the impl trait, self type, or predicates
-  --> $DIR/unconstrained-params.rs:4:6
+  --> $DIR/unconstrained-params-in-impl.rs:4:6
    |
 LL | impl<T> NotInjective<T> {}
    |      ^ unconstrained type parameter
diff --git a/tests/ui/lint/ambiguous_wide_pointer_comparisons_suggestions.fixed b/tests/ui/lint/ambiguous_wide_pointer_comparisons_suggestions.fixed
new file mode 100644
index 00000000000..6ce68ff9640
--- /dev/null
+++ b/tests/ui/lint/ambiguous_wide_pointer_comparisons_suggestions.fixed
@@ -0,0 +1,13 @@
+//@ run-rustfix
+//@ rustfix-only-machine-applicable
+//@ check-pass
+
+// See <https://github.com/rust-lang/rust/issues/121330>.
+
+fn cmp<T: ?Sized>(a: *mut T, b: *mut T) -> bool {
+    let _ = a == b;
+    //~^ WARN ambiguous wide pointer comparison
+    panic!();
+}
+
+fn main() {}
diff --git a/tests/ui/lint/ambiguous_wide_pointer_comparisons_suggestions.rs b/tests/ui/lint/ambiguous_wide_pointer_comparisons_suggestions.rs
new file mode 100644
index 00000000000..6ce68ff9640
--- /dev/null
+++ b/tests/ui/lint/ambiguous_wide_pointer_comparisons_suggestions.rs
@@ -0,0 +1,13 @@
+//@ run-rustfix
+//@ rustfix-only-machine-applicable
+//@ check-pass
+
+// See <https://github.com/rust-lang/rust/issues/121330>.
+
+fn cmp<T: ?Sized>(a: *mut T, b: *mut T) -> bool {
+    let _ = a == b;
+    //~^ WARN ambiguous wide pointer comparison
+    panic!();
+}
+
+fn main() {}
diff --git a/tests/ui/lint/ambiguous_wide_pointer_comparisons_suggestions.stderr b/tests/ui/lint/ambiguous_wide_pointer_comparisons_suggestions.stderr
new file mode 100644
index 00000000000..d9190dbb813
--- /dev/null
+++ b/tests/ui/lint/ambiguous_wide_pointer_comparisons_suggestions.stderr
@@ -0,0 +1,18 @@
+warning: ambiguous wide pointer comparison, the comparison includes metadata which may not be expected
+  --> $DIR/ambiguous_wide_pointer_comparisons_suggestions.rs:8:13
+   |
+LL |     let _ = a == b;
+   |             ^^^^^^
+   |
+   = note: `#[warn(ambiguous_wide_pointer_comparisons)]` on by default
+help: use `std::ptr::addr_eq` or untyped pointers to only compare their addresses
+   |
+LL |     let _ = std::ptr::addr_eq(a, b);
+   |             ++++++++++++++++++ ~  +
+help: use explicit `std::ptr::eq` method to compare metadata and addresses
+   |
+LL |     let _ = std::ptr::eq(a, b);
+   |             +++++++++++++ ~  +
+
+warning: 1 warning emitted
+
diff --git a/tests/ui/lint/unsafe_code/lint-global-asm-as-unsafe.rs b/tests/ui/lint/unsafe_code/lint-global-asm-as-unsafe.rs
new file mode 100644
index 00000000000..02df0e6de95
--- /dev/null
+++ b/tests/ui/lint/unsafe_code/lint-global-asm-as-unsafe.rs
@@ -0,0 +1,20 @@
+//@ needs-asm-support
+#![deny(unsafe_code)]
+
+use std::arch::global_asm;
+
+#[allow(unsafe_code)]
+mod allowed_unsafe {
+    std::arch::global_asm!("");
+}
+
+macro_rules! unsafe_in_macro {
+    () => {
+        global_asm!(""); //~ ERROR: usage of `core::arch::global_asm`
+    };
+}
+
+global_asm!(""); //~ ERROR: usage of `core::arch::global_asm`
+unsafe_in_macro!();
+
+fn main() {}
diff --git a/tests/ui/lint/unsafe_code/lint-global-asm-as-unsafe.stderr b/tests/ui/lint/unsafe_code/lint-global-asm-as-unsafe.stderr
new file mode 100644
index 00000000000..deb67a174f1
--- /dev/null
+++ b/tests/ui/lint/unsafe_code/lint-global-asm-as-unsafe.stderr
@@ -0,0 +1,27 @@
+error: usage of `core::arch::global_asm`
+  --> $DIR/lint-global-asm-as-unsafe.rs:17:1
+   |
+LL | global_asm!("");
+   | ^^^^^^^^^^^^^^^
+   |
+   = note: using this macro is unsafe even though it does not need an `unsafe` block
+note: the lint level is defined here
+  --> $DIR/lint-global-asm-as-unsafe.rs:2:9
+   |
+LL | #![deny(unsafe_code)]
+   |         ^^^^^^^^^^^
+
+error: usage of `core::arch::global_asm`
+  --> $DIR/lint-global-asm-as-unsafe.rs:13:9
+   |
+LL |         global_asm!("");
+   |         ^^^^^^^^^^^^^^^
+...
+LL | unsafe_in_macro!();
+   | ------------------ in this macro invocation
+   |
+   = note: using this macro is unsafe even though it does not need an `unsafe` block
+   = note: this error originates in the macro `unsafe_in_macro` (in Nightly builds, run with -Z macro-backtrace for more info)
+
+error: aborting due to 2 previous errors
+
diff --git a/tests/ui/liveness/liveness-consts.stderr b/tests/ui/liveness/liveness-consts.stderr
index 016debdd396..34ce3947337 100644
--- a/tests/ui/liveness/liveness-consts.stderr
+++ b/tests/ui/liveness/liveness-consts.stderr
@@ -23,12 +23,6 @@ warning: unused variable: `z`
 LL | pub fn f(x: [u8; { let s = 17; 100 }]) -> [u8;  { let z = 18; 100 }] {
    |                                                       ^ help: if this is intentional, prefix it with an underscore: `_z`
 
-warning: unused variable: `z`
-  --> $DIR/liveness-consts.rs:60:13
-   |
-LL |         let z = 42;
-   |             ^ help: if this is intentional, prefix it with an underscore: `_z`
-
 warning: variable `a` is assigned to, but never used
   --> $DIR/liveness-consts.rs:7:13
    |
@@ -46,6 +40,12 @@ LL |     b += 1;
    = help: maybe it is overwritten before being read?
    = note: `#[warn(unused_assignments)]` implied by `#[warn(unused)]`
 
+warning: unused variable: `z`
+  --> $DIR/liveness-consts.rs:60:13
+   |
+LL |         let z = 42;
+   |             ^ help: if this is intentional, prefix it with an underscore: `_z`
+
 warning: value assigned to `t` is never read
   --> $DIR/liveness-consts.rs:42:9
    |
diff --git a/tests/ui/parser/bad-recover-kw-after-impl.rs b/tests/ui/parser/bad-recover-kw-after-impl.rs
index 23abceaf493..15c0b377c8a 100644
--- a/tests/ui/parser/bad-recover-kw-after-impl.rs
+++ b/tests/ui/parser/bad-recover-kw-after-impl.rs
@@ -1,4 +1,4 @@
-//@ check-pass
+// This is just `mbe-async-trait-bound-theoretical-regression.rs` in practice.
 
 //@ edition:2021
 // for the `impl` + keyword test
@@ -11,5 +11,7 @@ macro_rules! impl_primitive {
 }
 
 impl_primitive!(impl async);
+//~^ ERROR expected identifier, found `<eof>`
+//~| ERROR async closures are unstable
 
 fn main() {}
diff --git a/tests/ui/parser/bad-recover-kw-after-impl.stderr b/tests/ui/parser/bad-recover-kw-after-impl.stderr
new file mode 100644
index 00000000000..f617cf65498
--- /dev/null
+++ b/tests/ui/parser/bad-recover-kw-after-impl.stderr
@@ -0,0 +1,23 @@
+error: expected identifier, found `<eof>`
+  --> $DIR/bad-recover-kw-after-impl.rs:13:22
+   |
+LL |     ($ty:ty) => {
+   |      ------ while parsing argument for this `ty` macro fragment
+...
+LL | impl_primitive!(impl async);
+   |                      ^^^^^ expected identifier
+
+error[E0658]: async closures are unstable
+  --> $DIR/bad-recover-kw-after-impl.rs:13:22
+   |
+LL | impl_primitive!(impl async);
+   |                      ^^^^^
+   |
+   = note: see issue #62290 <https://github.com/rust-lang/rust/issues/62290> for more information
+   = help: add `#![feature(async_closure)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
+   = help: to use an async block, remove the `||`: `async {`
+
+error: aborting due to 2 previous errors
+
+For more information about this error, try `rustc --explain E0658`.
diff --git a/tests/ui/parser/trait-object-delimiters.rs b/tests/ui/parser/trait-object-delimiters.rs
index 84cd16c2796..d6bc629aa11 100644
--- a/tests/ui/parser/trait-object-delimiters.rs
+++ b/tests/ui/parser/trait-object-delimiters.rs
@@ -8,7 +8,7 @@ fn foo2(_: &dyn (Drop + AsRef<str>)) {} //~ ERROR incorrect parentheses around t
 fn foo2_no_space(_: &dyn(Drop + AsRef<str>)) {} //~ ERROR incorrect parentheses around trait bounds
 
 fn foo3(_: &dyn {Drop + AsRef<str>}) {} //~ ERROR expected parameter name, found `{`
-//~^ ERROR expected one of `!`, `(`, `)`, `*`, `,`, `?`, `const`, `for`, `~`, lifetime, or path, found `{`
+//~^ ERROR expected one of `!`, `(`, `)`, `*`, `,`, `?`, `async`, `const`, `for`, `~`, lifetime, or path, found `{`
 //~| ERROR at least one trait is required for an object type
 
 fn foo4(_: &dyn <Drop + AsRef<str>>) {} //~ ERROR expected identifier, found `<`
diff --git a/tests/ui/parser/trait-object-delimiters.stderr b/tests/ui/parser/trait-object-delimiters.stderr
index 2ddb734cee0..2b1f8df991f 100644
--- a/tests/ui/parser/trait-object-delimiters.stderr
+++ b/tests/ui/parser/trait-object-delimiters.stderr
@@ -34,11 +34,11 @@ error: expected parameter name, found `{`
 LL | fn foo3(_: &dyn {Drop + AsRef<str>}) {}
    |                 ^ expected parameter name
 
-error: expected one of `!`, `(`, `)`, `*`, `,`, `?`, `const`, `for`, `~`, lifetime, or path, found `{`
+error: expected one of `!`, `(`, `)`, `*`, `,`, `?`, `async`, `const`, `for`, `~`, lifetime, or path, found `{`
   --> $DIR/trait-object-delimiters.rs:10:17
    |
 LL | fn foo3(_: &dyn {Drop + AsRef<str>}) {}
-   |                -^ expected one of 11 possible tokens
+   |                -^ expected one of 12 possible tokens
    |                |
    |                help: missing `,`
 
diff --git a/tests/ui/precondition-checks/out-of-bounds-get-unchecked.rs b/tests/ui/precondition-checks/out-of-bounds-get-unchecked.rs
index 7956d5e8743..77bec6aab7f 100644
--- a/tests/ui/precondition-checks/out-of-bounds-get-unchecked.rs
+++ b/tests/ui/precondition-checks/out-of-bounds-get-unchecked.rs
@@ -1,6 +1,6 @@
 //@ run-fail
 //@ compile-flags: -Copt-level=3 -Cdebug-assertions=yes
-//@ error-pattern: unsafe precondition(s) violated: hint::assert_unchecked
+//@ error-pattern: slice::get_unchecked requires
 //@ ignore-debug
 //@ ignore-wasm32-bare no panic messages
 
diff --git a/tests/ui/proc-macro/custom-attr-panic.rs b/tests/ui/proc-macro/custom-attr-panic.rs
new file mode 100644
index 00000000000..23bcb66319d
--- /dev/null
+++ b/tests/ui/proc-macro/custom-attr-panic.rs
@@ -0,0 +1,8 @@
+//@ aux-build: test-macros.rs
+
+extern crate test_macros;
+
+#[test_macros::panic_attr] //~ ERROR custom attribute panicked
+fn foo() {}
+
+fn main() {}
diff --git a/tests/ui/proc-macro/custom-attr-panic.stderr b/tests/ui/proc-macro/custom-attr-panic.stderr
new file mode 100644
index 00000000000..e436162bcc1
--- /dev/null
+++ b/tests/ui/proc-macro/custom-attr-panic.stderr
@@ -0,0 +1,10 @@
+error: custom attribute panicked
+  --> $DIR/custom-attr-panic.rs:5:1
+   |
+LL | #[test_macros::panic_attr]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |
+   = help: message: panic-attr
+
+error: aborting due to 1 previous error
+
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/call-const-trait-method-pass.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/call-const-trait-method-pass.stderr
index e72d259e8a5..f802841d2e4 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/call-const-trait-method-pass.stderr
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/call-const-trait-method-pass.stderr
@@ -1,12 +1,3 @@
-error[E0015]: cannot call non-const fn `<i32 as Plus>::plus` in constant functions
-  --> $DIR/call-const-trait-method-pass.rs:36:7
-   |
-LL |     a.plus(b)
-   |       ^^^^^^^
-   |
-   = note: calls in constant functions are limited to constant functions, tuple structs and tuple variants
-   = help: add `#![feature(effects)]` to the crate attributes to enable
-
 error[E0015]: cannot call non-const operator in constants
   --> $DIR/call-const-trait-method-pass.rs:39:22
    |
@@ -21,6 +12,15 @@ LL | impl const std::ops::Add for Int {
    = note: calls in constants are limited to constant functions, tuple structs and tuple variants
    = help: add `#![feature(effects)]` to the crate attributes to enable
 
+error[E0015]: cannot call non-const fn `<i32 as Plus>::plus` in constant functions
+  --> $DIR/call-const-trait-method-pass.rs:36:7
+   |
+LL |     a.plus(b)
+   |       ^^^^^^^
+   |
+   = note: calls in constant functions are limited to constant functions, tuple structs and tuple variants
+   = help: add `#![feature(effects)]` to the crate attributes to enable
+
 error: aborting due to 2 previous errors
 
 For more information about this error, try `rustc --explain E0015`.
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/const-closures.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/const-closures.stderr
index b66b27ad2bd..a225125ef53 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/const-closures.stderr
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/const-closures.stderr
@@ -23,23 +23,23 @@ LL | const fn answer<F: ~const Fn() -> u8>(f: &F) -> u8 {
    |                           ^^^^^^^^^^
 
 error[E0015]: cannot call non-const closure in constant functions
-  --> $DIR/const-closures.rs:12:5
+  --> $DIR/const-closures.rs:24:5
    |
-LL |     f() * 7
+LL |     f() + f()
    |     ^^^
    |
    = note: calls in constant functions are limited to constant functions, tuple structs and tuple variants
    = help: add `#![feature(effects)]` to the crate attributes to enable
 help: consider further restricting this bound
    |
-LL |         F: ~const FnOnce() -> u8 + ~const std::ops::Fn<()>,
-   |                                  +++++++++++++++++++++++++
+LL | const fn answer<F: ~const Fn() -> u8 + ~const std::ops::Fn<()>>(f: &F) -> u8 {
+   |                                      +++++++++++++++++++++++++
 
 error[E0015]: cannot call non-const closure in constant functions
-  --> $DIR/const-closures.rs:24:5
+  --> $DIR/const-closures.rs:24:11
    |
 LL |     f() + f()
-   |     ^^^
+   |           ^^^
    |
    = note: calls in constant functions are limited to constant functions, tuple structs and tuple variants
    = help: add `#![feature(effects)]` to the crate attributes to enable
@@ -49,17 +49,17 @@ LL | const fn answer<F: ~const Fn() -> u8 + ~const std::ops::Fn<()>>(f: &F) -> u
    |                                      +++++++++++++++++++++++++
 
 error[E0015]: cannot call non-const closure in constant functions
-  --> $DIR/const-closures.rs:24:11
+  --> $DIR/const-closures.rs:12:5
    |
-LL |     f() + f()
-   |           ^^^
+LL |     f() * 7
+   |     ^^^
    |
    = note: calls in constant functions are limited to constant functions, tuple structs and tuple variants
    = help: add `#![feature(effects)]` to the crate attributes to enable
 help: consider further restricting this bound
    |
-LL | const fn answer<F: ~const Fn() -> u8 + ~const std::ops::Fn<()>>(f: &F) -> u8 {
-   |                                      +++++++++++++++++++++++++
+LL |         F: ~const FnOnce() -> u8 + ~const std::ops::Fn<()>,
+   |                                  +++++++++++++++++++++++++
 
 error: aborting due to 7 previous errors
 
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/const-drop-fail.precise.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/const-drop-fail.precise.stderr
index 8997e7ade6c..9afa2072dde 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/const-drop-fail.precise.stderr
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/const-drop-fail.precise.stderr
@@ -4,6 +4,57 @@ error[E0493]: destructor of `T` cannot be evaluated at compile-time
 LL | const fn check<T: ~const Destruct>(_: T) {}
    |                                    ^ the destructor for this type cannot be evaluated in constant functions
 
-error: aborting due to 1 previous error
+error[E0080]: evaluation of constant value failed
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+   |
+   = note: calling non-const function `<NonTrivialDrop as Drop>::drop`
+   |
+note: inside `std::ptr::drop_in_place::<NonTrivialDrop> - shim(Some(NonTrivialDrop))`
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+note: inside `check::<NonTrivialDrop>`
+  --> $DIR/const-drop-fail.rs:24:43
+   |
+LL | const fn check<T: ~const Destruct>(_: T) {}
+   |                                           ^
+note: inside `_`
+  --> $DIR/const-drop-fail.rs:28:23
+   |
+LL |           const _: () = check($exp);
+   |                         ^^^^^^^^^^^
+...
+LL | / check_all! {
+LL | |     NonTrivialDrop,
+LL | |     ConstImplWithDropGlue(NonTrivialDrop),
+LL | | }
+   | |_- in this macro invocation
+   = note: this error originates in the macro `check_all` (in Nightly builds, run with -Z macro-backtrace for more info)
+
+error[E0080]: evaluation of constant value failed
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+   |
+   = note: calling non-const function `<ConstImplWithDropGlue as Drop>::drop`
+   |
+note: inside `std::ptr::drop_in_place::<ConstImplWithDropGlue> - shim(Some(ConstImplWithDropGlue))`
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+note: inside `check::<ConstImplWithDropGlue>`
+  --> $DIR/const-drop-fail.rs:24:43
+   |
+LL | const fn check<T: ~const Destruct>(_: T) {}
+   |                                           ^
+note: inside `_`
+  --> $DIR/const-drop-fail.rs:28:23
+   |
+LL |           const _: () = check($exp);
+   |                         ^^^^^^^^^^^
+...
+LL | / check_all! {
+LL | |     NonTrivialDrop,
+LL | |     ConstImplWithDropGlue(NonTrivialDrop),
+LL | | }
+   | |_- in this macro invocation
+   = note: this error originates in the macro `check_all` (in Nightly builds, run with -Z macro-backtrace for more info)
+
+error: aborting due to 3 previous errors
 
-For more information about this error, try `rustc --explain E0493`.
+Some errors have detailed explanations: E0080, E0493.
+For more information about an error, try `rustc --explain E0080`.
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/const-drop.precise.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/const-drop.precise.stderr
index f166bdf6cec..5ff3be713a7 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/const-drop.precise.stderr
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/const-drop.precise.stderr
@@ -1,15 +1,92 @@
+error[E0493]: destructor of `S<'_>` cannot be evaluated at compile-time
+  --> $DIR/const-drop.rs:24:13
+   |
+LL |     let _ = S(&mut c);
+   |             ^^^^^^^^^ the destructor for this type cannot be evaluated in constant functions
+
+error[E0080]: evaluation of constant value failed
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+   |
+   = note: calling non-const function `<S<'_> as Drop>::drop`
+   |
+note: inside `std::ptr::drop_in_place::<S<'_>> - shim(Some(S<'_>))`
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+note: inside `b`
+  --> $DIR/const-drop.rs:24:22
+   |
+LL |     let _ = S(&mut c);
+   |                      ^
+note: inside `C`
+  --> $DIR/const-drop.rs:30:15
+   |
+LL | const C: u8 = b();
+   |               ^^^
+
 error[E0493]: destructor of `T` cannot be evaluated at compile-time
   --> $DIR/const-drop.rs:19:32
    |
 LL | const fn a<T: ~const Destruct>(_: T) {}
    |                                ^ the destructor for this type cannot be evaluated in constant functions
 
-error[E0493]: destructor of `S<'_>` cannot be evaluated at compile-time
-  --> $DIR/const-drop.rs:24:13
+error[E0080]: evaluation of constant value failed
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
    |
-LL |     let _ = S(&mut c);
-   |             ^^^^^^^^^ the destructor for this type cannot be evaluated in constant functions
+   = note: calling non-const function `<t::ConstDrop as Drop>::drop`
+   |
+note: inside `std::ptr::drop_in_place::<t::ConstDrop> - shim(Some(t::ConstDrop))`
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+note: inside `a::<t::ConstDrop>`
+  --> $DIR/const-drop.rs:19:39
+   |
+LL | const fn a<T: ~const Destruct>(_: T) {}
+   |                                       ^
+note: inside `_`
+  --> $DIR/const-drop.rs:35:27
+   |
+LL |               const _: () = a($exp);
+   |                             ^^^^^^^
+...
+LL | / implements_const_drop! {
+LL | |     1u8,
+LL | |     2,
+LL | |     3.0,
+...  |
+LL | |     Result::<i32, !>::Ok(1),
+LL | | }
+   | |_- in this macro invocation
+   = note: this error originates in the macro `implements_const_drop` (in Nightly builds, run with -Z macro-backtrace for more info)
+
+error[E0080]: evaluation of constant value failed
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+   |
+   = note: calling non-const function `<t::ConstDrop as Drop>::drop`
+   |
+note: inside `std::ptr::drop_in_place::<t::ConstDrop> - shim(Some(t::ConstDrop))`
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+note: inside `std::ptr::drop_in_place::<t::HasConstDrop> - shim(Some(t::HasConstDrop))`
+  --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+note: inside `a::<t::HasConstDrop>`
+  --> $DIR/const-drop.rs:19:39
+   |
+LL | const fn a<T: ~const Destruct>(_: T) {}
+   |                                       ^
+note: inside `_`
+  --> $DIR/const-drop.rs:35:27
+   |
+LL |               const _: () = a($exp);
+   |                             ^^^^^^^
+...
+LL | / implements_const_drop! {
+LL | |     1u8,
+LL | |     2,
+LL | |     3.0,
+...  |
+LL | |     Result::<i32, !>::Ok(1),
+LL | | }
+   | |_- in this macro invocation
+   = note: this error originates in the macro `implements_const_drop` (in Nightly builds, run with -Z macro-backtrace for more info)
 
-error: aborting due to 2 previous errors
+error: aborting due to 5 previous errors
 
-For more information about this error, try `rustc --explain E0493`.
+Some errors have detailed explanations: E0080, E0493.
+For more information about an error, try `rustc --explain E0080`.
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/const-drop.stock.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/const-drop.stock.stderr
index 23e36887025..40e39cbefbc 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/const-drop.stock.stderr
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/const-drop.stock.stderr
@@ -1,11 +1,3 @@
-error[E0493]: destructor of `T` cannot be evaluated at compile-time
-  --> $DIR/const-drop.rs:19:32
-   |
-LL | const fn a<T: ~const Destruct>(_: T) {}
-   |                                ^      - value is dropped here
-   |                                |
-   |                                the destructor for this type cannot be evaluated in constant functions
-
 error[E0493]: destructor of `S<'_>` cannot be evaluated at compile-time
   --> $DIR/const-drop.rs:24:13
    |
@@ -14,6 +6,14 @@ LL |     let _ = S(&mut c);
    |             |
    |             the destructor for this type cannot be evaluated in constant functions
 
+error[E0493]: destructor of `T` cannot be evaluated at compile-time
+  --> $DIR/const-drop.rs:19:32
+   |
+LL | const fn a<T: ~const Destruct>(_: T) {}
+   |                                ^      - value is dropped here
+   |                                |
+   |                                the destructor for this type cannot be evaluated in constant functions
+
 error: aborting due to 2 previous errors
 
 For more information about this error, try `rustc --explain E0493`.
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/mbe-const-trait-bound-theoretical-regression.rs b/tests/ui/rfcs/rfc-2632-const-trait-impl/mbe-const-trait-bound-theoretical-regression.rs
index 99806922ba5..3dcdb0cad94 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/mbe-const-trait-bound-theoretical-regression.rs
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/mbe-const-trait-bound-theoretical-regression.rs
@@ -6,15 +6,16 @@
 
 macro_rules! demo {
     ($ty:ty) => { compile_error!("ty"); };
-    (impl $c:ident) => {};
-    (dyn $c:ident) => {};
+    //~^ ERROR ty
+    //~| ERROR ty
+    (impl $c:ident Trait) => {};
+    (dyn $c:ident Trait) => {};
 }
 
-demo! { impl const }
-//~^ ERROR expected identifier, found `<eof>`
+demo! { impl const Trait }
+//~^ ERROR const trait impls are experimental
 
-demo! { dyn const }
+demo! { dyn const Trait }
 //~^ ERROR const trait impls are experimental
-//~| ERROR expected identifier, found `<eof>`
 
 fn main() {}
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/mbe-const-trait-bound-theoretical-regression.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/mbe-const-trait-bound-theoretical-regression.stderr
index fd9184b9dff..f4b401b7386 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/mbe-const-trait-bound-theoretical-regression.stderr
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/mbe-const-trait-bound-theoretical-regression.stderr
@@ -1,31 +1,45 @@
-error: expected identifier, found `<eof>`
-  --> $DIR/mbe-const-trait-bound-theoretical-regression.rs:13:14
+error: ty
+  --> $DIR/mbe-const-trait-bound-theoretical-regression.rs:8:19
    |
 LL |     ($ty:ty) => { compile_error!("ty"); };
-   |      ------ while parsing argument for this `ty` macro fragment
+   |                   ^^^^^^^^^^^^^^^^^^^^
 ...
-LL | demo! { impl const }
-   |              ^^^^^ expected identifier
+LL | demo! { impl const Trait }
+   | -------------------------- in this macro invocation
+   |
+   = note: this error originates in the macro `demo` (in Nightly builds, run with -Z macro-backtrace for more info)
 
-error: expected identifier, found `<eof>`
-  --> $DIR/mbe-const-trait-bound-theoretical-regression.rs:16:13
+error: ty
+  --> $DIR/mbe-const-trait-bound-theoretical-regression.rs:8:19
    |
 LL |     ($ty:ty) => { compile_error!("ty"); };
-   |      ------ while parsing argument for this `ty` macro fragment
+   |                   ^^^^^^^^^^^^^^^^^^^^
 ...
-LL | demo! { dyn const }
-   |             ^^^^^ expected identifier
+LL | demo! { dyn const Trait }
+   | ------------------------- in this macro invocation
+   |
+   = note: this error originates in the macro `demo` (in Nightly builds, run with -Z macro-backtrace for more info)
+
+error[E0658]: const trait impls are experimental
+  --> $DIR/mbe-const-trait-bound-theoretical-regression.rs:15:14
+   |
+LL | demo! { impl const Trait }
+   |              ^^^^^
+   |
+   = note: see issue #67792 <https://github.com/rust-lang/rust/issues/67792> for more information
+   = help: add `#![feature(const_trait_impl)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0658]: const trait impls are experimental
-  --> $DIR/mbe-const-trait-bound-theoretical-regression.rs:16:13
+  --> $DIR/mbe-const-trait-bound-theoretical-regression.rs:18:13
    |
-LL | demo! { dyn const }
+LL | demo! { dyn const Trait }
    |             ^^^^^
    |
    = note: see issue #67792 <https://github.com/rust-lang/rust/issues/67792> for more information
    = help: add `#![feature(const_trait_impl)]` to the crate attributes to enable
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
-error: aborting due to 3 previous errors
+error: aborting due to 4 previous errors
 
 For more information about this error, try `rustc --explain E0658`.
diff --git a/tests/ui/rust-2024/prelude2024.rs b/tests/ui/rust-2024/prelude2024.rs
new file mode 100644
index 00000000000..e58ebe74188
--- /dev/null
+++ b/tests/ui/rust-2024/prelude2024.rs
@@ -0,0 +1,9 @@
+//@ check-pass
+//@ compile-flags: -Zunstable-options
+//@ edition:2024
+
+fn main() {
+    fut(async {}.into_future(), async {});
+}
+
+fn fut(_: impl Future, _: impl IntoFuture) {}
diff --git a/tests/ui/static/static-drop-scope.stderr b/tests/ui/static/static-drop-scope.stderr
index 2c55161628f..24658bc601e 100644
--- a/tests/ui/static/static-drop-scope.stderr
+++ b/tests/ui/static/static-drop-scope.stderr
@@ -30,6 +30,22 @@ LL | const EARLY_DROP_C: i32 = (WithDtor, 0).1;
    |                           |
    |                           the destructor for this type cannot be evaluated in constants
 
+error[E0493]: destructor of `(Option<WithDtor>, i32)` cannot be evaluated at compile-time
+  --> $DIR/static-drop-scope.rs:27:34
+   |
+LL | const EARLY_DROP_C_OPTION: i32 = (Some(WithDtor), 0).1;
+   |                                  ^^^^^^^^^^^^^^^^^^^ - value is dropped here
+   |                                  |
+   |                                  the destructor for this type cannot be evaluated in constants
+
+error[E0493]: destructor of `(Option<WithDtor>, i32)` cannot be evaluated at compile-time
+  --> $DIR/static-drop-scope.rs:32:43
+   |
+LL | const EARLY_DROP_C_OPTION_CONSTANT: i32 = (HELPER, 0).1;
+   |                                           ^^^^^^^^^^^ - value is dropped here
+   |                                           |
+   |                                           the destructor for this type cannot be evaluated in constants
+
 error[E0493]: destructor of `T` cannot be evaluated at compile-time
   --> $DIR/static-drop-scope.rs:19:24
    |
@@ -47,22 +63,6 @@ LL |
 LL | }
    | - value is dropped here
 
-error[E0493]: destructor of `(Option<WithDtor>, i32)` cannot be evaluated at compile-time
-  --> $DIR/static-drop-scope.rs:27:34
-   |
-LL | const EARLY_DROP_C_OPTION: i32 = (Some(WithDtor), 0).1;
-   |                                  ^^^^^^^^^^^^^^^^^^^ - value is dropped here
-   |                                  |
-   |                                  the destructor for this type cannot be evaluated in constants
-
-error[E0493]: destructor of `(Option<WithDtor>, i32)` cannot be evaluated at compile-time
-  --> $DIR/static-drop-scope.rs:32:43
-   |
-LL | const EARLY_DROP_C_OPTION_CONSTANT: i32 = (HELPER, 0).1;
-   |                                           ^^^^^^^^^^^ - value is dropped here
-   |                                           |
-   |                                           the destructor for this type cannot be evaluated in constants
-
 error: aborting due to 8 previous errors
 
 For more information about this error, try `rustc --explain E0493`.
diff --git a/tests/ui/statics/issue-14227.rs b/tests/ui/statics/issue-14227.rs
index a1fde14600a..8a70f51d3b4 100644
--- a/tests/ui/statics/issue-14227.rs
+++ b/tests/ui/statics/issue-14227.rs
@@ -3,5 +3,6 @@ extern "C" {
 }
 static CRASH: u32 = symbol;
 //~^ ERROR use of extern static is unsafe and requires
+//~| ERROR could not evaluate static initializer
 
 fn main() {}
diff --git a/tests/ui/statics/issue-14227.stderr b/tests/ui/statics/issue-14227.stderr
index 085d6df9c41..0aeb973bff3 100644
--- a/tests/ui/statics/issue-14227.stderr
+++ b/tests/ui/statics/issue-14227.stderr
@@ -1,3 +1,9 @@
+error[E0080]: could not evaluate static initializer
+  --> $DIR/issue-14227.rs:4:21
+   |
+LL | static CRASH: u32 = symbol;
+   |                     ^^^^^^ cannot access extern static (DefId(0:4 ~ issue_14227[1133]::{extern#0}::symbol))
+
 error[E0133]: use of extern static is unsafe and requires unsafe function or block
   --> $DIR/issue-14227.rs:4:21
    |
@@ -6,6 +12,7 @@ LL | static CRASH: u32 = symbol;
    |
    = 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
+error: aborting due to 2 previous errors
 
-For more information about this error, try `rustc --explain E0133`.
+Some errors have detailed explanations: E0080, E0133.
+For more information about an error, try `rustc --explain E0080`.
diff --git a/tests/ui/statics/uninhabited-static.rs b/tests/ui/statics/uninhabited-static.rs
index f5c6f444317..a0f83f45079 100644
--- a/tests/ui/statics/uninhabited-static.rs
+++ b/tests/ui/statics/uninhabited-static.rs
@@ -12,10 +12,8 @@ extern {
 static VOID2: Void = unsafe { std::mem::transmute(()) }; //~ ERROR static of uninhabited type
 //~| WARN: previously accepted
 //~| ERROR could not evaluate static initializer
-//~| WARN: type `Void` does not permit zero-initialization
 static NEVER2: Void = unsafe { std::mem::transmute(()) }; //~ ERROR static of uninhabited type
 //~| WARN: previously accepted
 //~| ERROR could not evaluate static initializer
-//~| WARN: type `Void` does not permit zero-initialization
 
 fn main() {}
diff --git a/tests/ui/statics/uninhabited-static.stderr b/tests/ui/statics/uninhabited-static.stderr
index 9260930473f..f891c0ce25b 100644
--- a/tests/ui/statics/uninhabited-static.stderr
+++ b/tests/ui/statics/uninhabited-static.stderr
@@ -34,7 +34,7 @@ LL | static VOID2: Void = unsafe { std::mem::transmute(()) };
    = note: uninhabited statics cannot be initialized, and any access would be an immediate error
 
 error: static of uninhabited type
-  --> $DIR/uninhabited-static.rs:16:1
+  --> $DIR/uninhabited-static.rs:15:1
    |
 LL | static NEVER2: Void = unsafe { std::mem::transmute(()) };
    | ^^^^^^^^^^^^^^^^^^^
@@ -49,37 +49,12 @@ error[E0080]: could not evaluate static initializer
 LL | static VOID2: Void = unsafe { std::mem::transmute(()) };
    |                               ^^^^^^^^^^^^^^^^^^^^^^^ constructing invalid value: encountered a value of uninhabited type `Void`
 
-warning: the type `Void` does not permit zero-initialization
-  --> $DIR/uninhabited-static.rs:12:31
-   |
-LL | static VOID2: Void = unsafe { std::mem::transmute(()) };
-   |                               ^^^^^^^^^^^^^^^^^^^^^^^ this code causes undefined behavior when executed
-   |
-note: enums with no inhabited variants have no valid value
-  --> $DIR/uninhabited-static.rs:4:1
-   |
-LL | enum Void {}
-   | ^^^^^^^^^
-   = note: `#[warn(invalid_value)]` on by default
-
 error[E0080]: could not evaluate static initializer
-  --> $DIR/uninhabited-static.rs:16:32
+  --> $DIR/uninhabited-static.rs:15:32
    |
 LL | static NEVER2: Void = unsafe { std::mem::transmute(()) };
    |                                ^^^^^^^^^^^^^^^^^^^^^^^ constructing invalid value: encountered a value of uninhabited type `Void`
 
-warning: the type `Void` does not permit zero-initialization
-  --> $DIR/uninhabited-static.rs:16:32
-   |
-LL | static NEVER2: Void = unsafe { std::mem::transmute(()) };
-   |                                ^^^^^^^^^^^^^^^^^^^^^^^ this code causes undefined behavior when executed
-   |
-note: enums with no inhabited variants have no valid value
-  --> $DIR/uninhabited-static.rs:4:1
-   |
-LL | enum Void {}
-   | ^^^^^^^^^
-
-error: aborting due to 6 previous errors; 2 warnings emitted
+error: aborting due to 6 previous errors
 
 For more information about this error, try `rustc --explain E0080`.
diff --git a/tests/ui/traits/issue-77982.stderr b/tests/ui/traits/issue-77982.stderr
index bffad037fba..5be8d2f4b32 100644
--- a/tests/ui/traits/issue-77982.stderr
+++ b/tests/ui/traits/issue-77982.stderr
@@ -46,7 +46,6 @@ LL |     let ips: Vec<_> = (0..100_000).map(|_| u32::from(0u32.into())).collect(
    = note: multiple `impl`s satisfying `u32: From<_>` found in the `core` crate:
            - impl From<Char> for u32;
            - impl From<Ipv4Addr> for u32;
-           - impl From<NonZero<u32>> for u32;
            - impl From<bool> for u32;
            - impl From<char> for u32;
            - impl From<u16> for u32;
diff --git a/tests/ui/traits/next-solver/coherence-fulfill-overflow.rs b/tests/ui/traits/next-solver/coherence-fulfill-overflow.rs
new file mode 100644
index 00000000000..ff577da32c2
--- /dev/null
+++ b/tests/ui/traits/next-solver/coherence-fulfill-overflow.rs
@@ -0,0 +1,15 @@
+//@ compile-flags: -Znext-solver=coherence
+
+#![recursion_limit = "10"]
+
+trait Trait {}
+
+struct W<T: ?Sized>(*const T);
+trait TwoW {}
+impl<T: ?Sized + TwoW> TwoW for W<W<T>> {}
+
+impl<T: ?Sized + TwoW> Trait for W<T> {}
+impl<T: ?Sized + TwoW> Trait for T {}
+//~^ ERROR conflicting implementations of trait `Trait` for type `W
+
+fn main() {}
diff --git a/tests/ui/traits/next-solver/coherence-fulfill-overflow.stderr b/tests/ui/traits/next-solver/coherence-fulfill-overflow.stderr
new file mode 100644
index 00000000000..406c0ccca97
--- /dev/null
+++ b/tests/ui/traits/next-solver/coherence-fulfill-overflow.stderr
@@ -0,0 +1,11 @@
+error[E0119]: conflicting implementations of trait `Trait` for type `W<W<W<W<W<W<W<W<W<W<W<W<W<W<W<W<W<W<W<W<W<_>>>>>>>>>>>>>>>>>>>>>`
+  --> $DIR/coherence-fulfill-overflow.rs:12:1
+   |
+LL | impl<T: ?Sized + TwoW> Trait for W<T> {}
+   | ------------------------------------- first implementation here
+LL | impl<T: ?Sized + TwoW> Trait for T {}
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ conflicting implementation for `W<W<W<W<W<W<W<W<W<W<W<W<W<W<W<W<W<W<W<W<W<_>>>>>>>>>>>>>>>>>>>>>`
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0119`.
diff --git a/tests/ui/traits/next-solver/generalize/occurs-check-nested-alias.next.stderr b/tests/ui/traits/next-solver/generalize/occurs-check-nested-alias.next.stderr
index aaadf604a80..cde925db184 100644
--- a/tests/ui/traits/next-solver/generalize/occurs-check-nested-alias.next.stderr
+++ b/tests/ui/traits/next-solver/generalize/occurs-check-nested-alias.next.stderr
@@ -1,8 +1,8 @@
-error[E0284]: type annotations needed: cannot satisfy `<<T as Id<_>>::Id as Unnormalizable>::Assoc == _`
+error[E0284]: type annotations needed: cannot satisfy `_ == <<T as Id<_>>::Id as Unnormalizable>::Assoc`
   --> $DIR/occurs-check-nested-alias.rs:36:9
    |
 LL |     x = y;
-   |         ^ cannot satisfy `<<T as Id<_>>::Id as Unnormalizable>::Assoc == _`
+   |         ^ cannot satisfy `_ == <<T as Id<_>>::Id as Unnormalizable>::Assoc`
 
 error: aborting due to 1 previous error
 
diff --git a/tests/ui/traits/next-solver/issue-118950-root-region.stderr b/tests/ui/traits/next-solver/issue-118950-root-region.stderr
index f4638348358..e33320ed9e6 100644
--- a/tests/ui/traits/next-solver/issue-118950-root-region.stderr
+++ b/tests/ui/traits/next-solver/issue-118950-root-region.stderr
@@ -13,14 +13,14 @@ LL | #![feature(lazy_type_alias)]
    = note: see issue #112792 <https://github.com/rust-lang/rust/issues/112792> for more information
    = note: `#[warn(incomplete_features)]` on by default
 
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Weak, AliasTy { args: [ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:15 ~ issue_118950_root_region[d54f]::{impl#1}::'a), 'a) }), ?1t], def_id: DefId(0:8 ~ issue_118950_root_region[d54f]::Assoc) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Weak, AliasTy { args: [RePlaceholder(!1_BoundRegion { var: 0, kind: BrNamed(DefId(0:15 ~ issue_118950_root_region[d54f]::{impl#1}::'a), 'a) }), ?1t], def_id: DefId(0:8 ~ issue_118950_root_region[d54f]::Assoc) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Weak, AliasTy { args: [ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:15 ~ issue_118950_root_region[d54f]::{impl#1}::'a), 'a) }), ?1t], def_id: DefId(0:8 ~ issue_118950_root_region[d54f]::Assoc) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Weak, AliasTy { args: [RePlaceholder(!1_BoundRegion { var: 0, kind: BrNamed(DefId(0:15 ~ issue_118950_root_region[d54f]::{impl#1}::'a), 'a) }), ?1t], def_id: DefId(0:8 ~ issue_118950_root_region[d54f]::Assoc) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Weak, AliasTy { args: [ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:15 ~ issue_118950_root_region[d54f]::{impl#1}::'a), 'a) }), ?1t], def_id: DefId(0:8 ~ issue_118950_root_region[d54f]::Assoc) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Weak, AliasTy { args: [RePlaceholder(!1_BoundRegion { var: 0, kind: BrNamed(DefId(0:15 ~ issue_118950_root_region[d54f]::{impl#1}::'a), 'a) }), ?1t], def_id: DefId(0:8 ~ issue_118950_root_region[d54f]::Assoc) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Weak, AliasTy { args: [ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:15 ~ issue_118950_root_region[d54f]::{impl#1}::'a), 'a) }), ?1t], def_id: DefId(0:8 ~ issue_118950_root_region[d54f]::Assoc) })
-WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: Alias(Weak, AliasTy { args: [RePlaceholder(!1_BoundRegion { var: 0, kind: BrNamed(DefId(0:15 ~ issue_118950_root_region[d54f]::{impl#1}::'a), 'a) }), ?1t], def_id: DefId(0:8 ~ issue_118950_root_region[d54f]::Assoc) })
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:15 ~ issue_118950_root_region[d54f]::{impl#1}::'a), 'a) }), ?1t], def_id: DefId(0:8 ~ issue_118950_root_region[d54f]::Assoc) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [RePlaceholder(!1_BoundRegion { var: 0, kind: BrNamed(DefId(0:15 ~ issue_118950_root_region[d54f]::{impl#1}::'a), 'a) }), ?1t], def_id: DefId(0:8 ~ issue_118950_root_region[d54f]::Assoc) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:15 ~ issue_118950_root_region[d54f]::{impl#1}::'a), 'a) }), ?1t], def_id: DefId(0:8 ~ issue_118950_root_region[d54f]::Assoc) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [RePlaceholder(!1_BoundRegion { var: 0, kind: BrNamed(DefId(0:15 ~ issue_118950_root_region[d54f]::{impl#1}::'a), 'a) }), ?1t], def_id: DefId(0:8 ~ issue_118950_root_region[d54f]::Assoc) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:15 ~ issue_118950_root_region[d54f]::{impl#1}::'a), 'a) }), ?1t], def_id: DefId(0:8 ~ issue_118950_root_region[d54f]::Assoc) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [RePlaceholder(!1_BoundRegion { var: 0, kind: BrNamed(DefId(0:15 ~ issue_118950_root_region[d54f]::{impl#1}::'a), 'a) }), ?1t], def_id: DefId(0:8 ~ issue_118950_root_region[d54f]::Assoc) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [ReBound(DebruijnIndex(0), BoundRegion { var: 0, kind: BrNamed(DefId(0:15 ~ issue_118950_root_region[d54f]::{impl#1}::'a), 'a) }), ?1t], def_id: DefId(0:8 ~ issue_118950_root_region[d54f]::Assoc) }
+WARN rustc_infer::infer::relate::generalize may incompletely handle alias type: AliasTy { args: [RePlaceholder(!1_BoundRegion { var: 0, kind: BrNamed(DefId(0:15 ~ issue_118950_root_region[d54f]::{impl#1}::'a), 'a) }), ?1t], def_id: DefId(0:8 ~ issue_118950_root_region[d54f]::Assoc) }
 error[E0119]: conflicting implementations of trait `Overlap<fn(_)>` for type `fn(_)`
   --> $DIR/issue-118950-root-region.rs:19:1
    |
diff --git a/tests/ui/traits/non_lifetime_binders/bad-suggestion-on-missing-assoc.rs b/tests/ui/traits/non_lifetime_binders/bad-suggestion-on-missing-assoc.rs
new file mode 100644
index 00000000000..fc64381b961
--- /dev/null
+++ b/tests/ui/traits/non_lifetime_binders/bad-suggestion-on-missing-assoc.rs
@@ -0,0 +1,26 @@
+#![feature(generic_const_exprs)]
+//~^ WARN the feature `generic_const_exprs` is incomplete
+#![feature(non_lifetime_binders)]
+//~^ WARN the feature `non_lifetime_binders` is incomplete
+
+// Test for <https://github.com/rust-lang/rust/issues/115497>,
+// which originally relied on associated_type_bounds, but was
+// minimized away from that.
+
+trait TraitA {
+    type AsA;
+}
+trait TraitB {
+    type AsB;
+}
+trait TraitC {}
+
+fn foo<T>()
+where
+    for<const N: u8 = { T::A }> T: TraitA<AsA = impl TraitB<AsB = impl TraitC>>,
+    //~^ ERROR defaults for generic parameters are not allowed in `for<...>` binders
+    //~| ERROR `impl Trait` is not allowed in bounds
+{
+}
+
+fn main() {}
diff --git a/tests/ui/traits/non_lifetime_binders/bad-suggestion-on-missing-assoc.stderr b/tests/ui/traits/non_lifetime_binders/bad-suggestion-on-missing-assoc.stderr
new file mode 100644
index 00000000000..a4a79413a9b
--- /dev/null
+++ b/tests/ui/traits/non_lifetime_binders/bad-suggestion-on-missing-assoc.stderr
@@ -0,0 +1,34 @@
+warning: the feature `generic_const_exprs` is incomplete and may not be safe to use and/or cause compiler crashes
+  --> $DIR/bad-suggestion-on-missing-assoc.rs:1:12
+   |
+LL | #![feature(generic_const_exprs)]
+   |            ^^^^^^^^^^^^^^^^^^^
+   |
+   = note: see issue #76560 <https://github.com/rust-lang/rust/issues/76560> for more information
+   = note: `#[warn(incomplete_features)]` on by default
+
+warning: the feature `non_lifetime_binders` is incomplete and may not be safe to use and/or cause compiler crashes
+  --> $DIR/bad-suggestion-on-missing-assoc.rs:3:12
+   |
+LL | #![feature(non_lifetime_binders)]
+   |            ^^^^^^^^^^^^^^^^^^^^
+   |
+   = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
+
+error: defaults for generic parameters are not allowed in `for<...>` binders
+  --> $DIR/bad-suggestion-on-missing-assoc.rs:20:9
+   |
+LL |     for<const N: u8 = { T::A }> T: TraitA<AsA = impl TraitB<AsB = impl TraitC>>,
+   |         ^^^^^^^^^^^^^^^^^^^^^^
+
+error[E0562]: `impl Trait` is not allowed in bounds
+  --> $DIR/bad-suggestion-on-missing-assoc.rs:20:49
+   |
+LL |     for<const N: u8 = { T::A }> T: TraitA<AsA = impl TraitB<AsB = impl TraitC>>,
+   |                                                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |
+   = note: `impl Trait` is only allowed in arguments and return types of functions and methods
+
+error: aborting due to 2 previous errors; 2 warnings emitted
+
+For more information about this error, try `rustc --explain E0562`.
diff --git a/tests/ui/treat-err-as-bug/err.stderr b/tests/ui/treat-err-as-bug/err.stderr
index ca04ee9e0cf..eb7b50b4210 100644
--- a/tests/ui/treat-err-as-bug/err.stderr
+++ b/tests/ui/treat-err-as-bug/err.stderr
@@ -8,5 +8,5 @@ error: the compiler unexpectedly panicked. this is a bug.
 
 query stack during panic:
 #0 [eval_static_initializer] evaluating initializer of static `C`
-#1 [lint_mod] linting top-level module
+#1 [analysis] running analysis passes on this crate
 end of query stack
diff --git a/tests/ui/try-trait/bad-interconversion.stderr b/tests/ui/try-trait/bad-interconversion.stderr
index 80471c0ab1a..817acc8fc99 100644
--- a/tests/ui/try-trait/bad-interconversion.stderr
+++ b/tests/ui/try-trait/bad-interconversion.stderr
@@ -11,7 +11,6 @@ LL |     Ok(Err(123_i32)?)
    = note: the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait
    = help: the following other types implement trait `From<T>`:
              <u8 as From<bool>>
-             <u8 as From<NonZero<u8>>>
              <u8 as From<Char>>
    = note: required for `Result<u64, u8>` to implement `FromResidual<Result<Infallible, i32>>`
 
diff --git a/tests/ui/type-alias-impl-trait/impl-trait-in-type-alias-with-bad-substs.rs b/tests/ui/type-alias-impl-trait/impl-trait-in-type-alias-with-bad-substs.rs
index a3f65146f75..71416eb531a 100644
--- a/tests/ui/type-alias-impl-trait/impl-trait-in-type-alias-with-bad-substs.rs
+++ b/tests/ui/type-alias-impl-trait/impl-trait-in-type-alias-with-bad-substs.rs
@@ -18,7 +18,6 @@ impl Foo for () {
 
     type Baz<T> = impl Sized;
     //~^ ERROR type `Baz` has 1 type parameter but its trait declaration has 0 type parameters
-    //~| ERROR unconstrained opaque type
 
     fn test<'a>() -> Self::Bar<'a> {
         &()
diff --git a/tests/ui/type-alias-impl-trait/impl-trait-in-type-alias-with-bad-substs.stderr b/tests/ui/type-alias-impl-trait/impl-trait-in-type-alias-with-bad-substs.stderr
index 13f5d8b8ea6..e5a21ff8b4e 100644
--- a/tests/ui/type-alias-impl-trait/impl-trait-in-type-alias-with-bad-substs.stderr
+++ b/tests/ui/type-alias-impl-trait/impl-trait-in-type-alias-with-bad-substs.stderr
@@ -7,14 +7,6 @@ LL |     type Baz<'a>;
 LL |     type Baz<T> = impl Sized;
    |              ^ found 1 type parameter
 
-error: unconstrained opaque type
-  --> $DIR/impl-trait-in-type-alias-with-bad-substs.rs:19:19
-   |
-LL |     type Baz<T> = impl Sized;
-   |                   ^^^^^^^^^^
-   |
-   = note: `Baz` must be used in combination with a concrete type within the same impl
-
-error: aborting due to 2 previous errors
+error: aborting due to 1 previous error
 
 For more information about this error, try `rustc --explain E0049`.
diff --git a/tests/ui/type-alias-impl-trait/rpit_tait_equality_in_canonical_query.current.stderr b/tests/ui/type-alias-impl-trait/rpit_tait_equality_in_canonical_query.current.stderr
index fd76526644b..069292239bc 100644
--- a/tests/ui/type-alias-impl-trait/rpit_tait_equality_in_canonical_query.current.stderr
+++ b/tests/ui/type-alias-impl-trait/rpit_tait_equality_in_canonical_query.current.stderr
@@ -21,5 +21,3 @@ LL |     query(get_rpit);
 
 query stack during panic:
 end of query stack
-error: aborting due to 2 previous errors
-
diff --git a/tests/ui/typeck/cyclic_type_ice.rs b/tests/ui/typeck/cyclic_type_ice.rs
new file mode 100644
index 00000000000..7899b354f38
--- /dev/null
+++ b/tests/ui/typeck/cyclic_type_ice.rs
@@ -0,0 +1,7 @@
+fn thing() {
+    let f = |_, _| ();
+    f(f); //~ ERROR: closure/coroutine type that references itself
+    //~^ ERROR: this function takes 2 arguments but 1 argument was supplied
+}
+
+fn main() {}
diff --git a/tests/ui/typeck/cyclic_type_ice.stderr b/tests/ui/typeck/cyclic_type_ice.stderr
new file mode 100644
index 00000000000..bfff6830fc5
--- /dev/null
+++ b/tests/ui/typeck/cyclic_type_ice.stderr
@@ -0,0 +1,31 @@
+error[E0644]: closure/coroutine type that references itself
+  --> $DIR/cyclic_type_ice.rs:3:7
+   |
+LL |     f(f);
+   |       ^ cyclic type of infinite size
+   |
+   = note: closures cannot capture themselves or take themselves as argument;
+           this error may be the result of a recent compiler bug-fix,
+           see issue #46062 <https://github.com/rust-lang/rust/issues/46062>
+           for more information
+
+error[E0057]: this function takes 2 arguments but 1 argument was supplied
+  --> $DIR/cyclic_type_ice.rs:3:5
+   |
+LL |     f(f);
+   |     ^--- an argument is missing
+   |
+note: closure defined here
+  --> $DIR/cyclic_type_ice.rs:2:13
+   |
+LL |     let f = |_, _| ();
+   |             ^^^^^^
+help: provide the argument
+   |
+LL |     f(/*  */, /*  */);
+   |      ~~~~~~~~~~~~~~~~
+
+error: aborting due to 2 previous errors
+
+Some errors have detailed explanations: E0057, E0644.
+For more information about an error, try `rustc --explain E0057`.
diff --git a/tests/ui/typeck/typeck-default-trait-impl-cross-crate-coherence.rs b/tests/ui/typeck/typeck-default-trait-impl-cross-crate-coherence.rs
index 3e15e28b8fd..ce0b60b6411 100644
--- a/tests/ui/typeck/typeck-default-trait-impl-cross-crate-coherence.rs
+++ b/tests/ui/typeck/typeck-default-trait-impl-cross-crate-coherence.rs
@@ -1,5 +1,4 @@
 //@ aux-build:tdticc_coherence_lib.rs
-#![allow(suspicious_auto_trait_impls)]
 
 // Test that we do not consider associated types to be sendable without
 // some applicable trait bound (and we don't ICE).
@@ -11,15 +10,15 @@ extern crate tdticc_coherence_lib as lib;
 use lib::DefaultedTrait;
 
 struct A;
-impl DefaultedTrait for (A,) { } //~ ERROR E0117
+impl DefaultedTrait for (A,) {} //~ ERROR E0117
 
 struct B;
-impl !DefaultedTrait for (B,) { } //~ ERROR E0117
+impl !DefaultedTrait for (B,) {} //~ ERROR E0117
 
 struct C;
 struct D<T>(T);
-impl DefaultedTrait for Box<C> { } //~ ERROR E0321
-impl DefaultedTrait for lib::Something<C> { } //~ ERROR E0117
-impl DefaultedTrait for D<C> { } // OK
+impl DefaultedTrait for Box<C> {} //~ ERROR E0321
+impl DefaultedTrait for lib::Something<C> {} //~ ERROR E0117
+impl DefaultedTrait for D<C> {} // OK
 
-fn main() { }
+fn main() {}
diff --git a/tests/ui/typeck/typeck-default-trait-impl-cross-crate-coherence.stderr b/tests/ui/typeck/typeck-default-trait-impl-cross-crate-coherence.stderr
index fc3778b7967..32e6e88fc48 100644
--- a/tests/ui/typeck/typeck-default-trait-impl-cross-crate-coherence.stderr
+++ b/tests/ui/typeck/typeck-default-trait-impl-cross-crate-coherence.stderr
@@ -1,7 +1,7 @@
 error[E0117]: only traits defined in the current crate can be implemented for arbitrary types
-  --> $DIR/typeck-default-trait-impl-cross-crate-coherence.rs:14:1
+  --> $DIR/typeck-default-trait-impl-cross-crate-coherence.rs:13:1
    |
-LL | impl DefaultedTrait for (A,) { }
+LL | impl DefaultedTrait for (A,) {}
    | ^^^^^^^^^^^^^^^^^^^^^^^^----
    | |                       |
    | |                       this is not defined in the current crate because tuples are always foreign
@@ -10,9 +10,9 @@ LL | impl DefaultedTrait for (A,) { }
    = note: define and implement a trait or new type instead
 
 error[E0117]: only traits defined in the current crate can be implemented for arbitrary types
-  --> $DIR/typeck-default-trait-impl-cross-crate-coherence.rs:17:1
+  --> $DIR/typeck-default-trait-impl-cross-crate-coherence.rs:16:1
    |
-LL | impl !DefaultedTrait for (B,) { }
+LL | impl !DefaultedTrait for (B,) {}
    | ^^^^^^^^^^^^^^^^^^^^^^^^^----
    | |                        |
    | |                        this is not defined in the current crate because tuples are always foreign
@@ -21,15 +21,15 @@ LL | impl !DefaultedTrait for (B,) { }
    = note: define and implement a trait or new type instead
 
 error[E0321]: cross-crate traits with a default impl, like `DefaultedTrait`, can only be implemented for a struct/enum type defined in the current crate
-  --> $DIR/typeck-default-trait-impl-cross-crate-coherence.rs:21:1
+  --> $DIR/typeck-default-trait-impl-cross-crate-coherence.rs:20:1
    |
-LL | impl DefaultedTrait for Box<C> { }
+LL | impl DefaultedTrait for Box<C> {}
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ can't implement cross-crate trait for type in another crate
 
 error[E0117]: only traits defined in the current crate can be implemented for types defined outside of the crate
-  --> $DIR/typeck-default-trait-impl-cross-crate-coherence.rs:22:1
+  --> $DIR/typeck-default-trait-impl-cross-crate-coherence.rs:21:1
    |
-LL | impl DefaultedTrait for lib::Something<C> { }
+LL | impl DefaultedTrait for lib::Something<C> {}
    | ^^^^^^^^^^^^^^^^^^^^^^^^-----------------
    | |                       |
    | |                       `Something` is not defined in the current crate
diff --git a/tests/ui/typeck/typeck_type_placeholder_item.stderr b/tests/ui/typeck/typeck_type_placeholder_item.stderr
index 18f6edad5c0..c102926fcf5 100644
--- a/tests/ui/typeck/typeck_type_placeholder_item.stderr
+++ b/tests/ui/typeck/typeck_type_placeholder_item.stderr
@@ -666,12 +666,6 @@ LL |     type F: std::ops::Fn(_);
 LL | impl Qux for Struct {
    | ^^^^^^^^^^^^^^^^^^^ missing `F` in implementation
 
-error[E0515]: cannot return reference to function parameter `x`
-  --> $DIR/typeck_type_placeholder_item.rs:50:5
-   |
-LL |     &x
-   |     ^^ returns a reference to data owned by the current function
-
 error[E0015]: cannot call non-const fn `<std::ops::Range<i32> as Iterator>::filter::<{closure@$DIR/typeck_type_placeholder_item.rs:230:29: 230:32}>` in constants
   --> $DIR/typeck_type_placeholder_item.rs:230:22
    |
@@ -690,6 +684,12 @@ LL | const _: _ = (1..10).filter(|x| x % 2 == 0).map(|x| x * x);
    = note: calls in constants are limited to constant functions, tuple structs and tuple variants
    = help: add `#![feature(const_trait_impl)]` to the crate attributes to enable
 
+error[E0515]: cannot return reference to function parameter `x`
+  --> $DIR/typeck_type_placeholder_item.rs:50:5
+   |
+LL |     &x
+   |     ^^ returns a reference to data owned by the current function
+
 error: aborting due to 75 previous errors
 
 Some errors have detailed explanations: E0015, E0046, E0121, E0282, E0403, E0515.
diff --git a/tests/ui/ufcs/bad-builder.rs b/tests/ui/ufcs/bad-builder.rs
new file mode 100644
index 00000000000..350c96acca0
--- /dev/null
+++ b/tests/ui/ufcs/bad-builder.rs
@@ -0,0 +1,6 @@
+fn hello<Q>() -> Vec<Q> {
+    Vec::<Q>::mew()
+    //~^ ERROR no function or associated item named `mew` found for struct `Vec<Q>` in the current scope
+}
+
+fn main() {}
diff --git a/tests/ui/ufcs/bad-builder.stderr b/tests/ui/ufcs/bad-builder.stderr
new file mode 100644
index 00000000000..7fa47c82de2
--- /dev/null
+++ b/tests/ui/ufcs/bad-builder.stderr
@@ -0,0 +1,20 @@
+error[E0599]: no function or associated item named `mew` found for struct `Vec<Q>` in the current scope
+  --> $DIR/bad-builder.rs:2:15
+   |
+LL |     Vec::<Q>::mew()
+   |               ^^^
+   |               |
+   |               function or associated item not found in `Vec<Q>`
+   |               help: there is an associated function with a similar name: `new`
+   |
+note: if you're trying to build a new `Vec<Q>` consider using one of the following associated functions:
+      Vec::<T>::new
+      Vec::<T>::with_capacity
+      Vec::<T>::from_raw_parts
+      Vec::<T, A>::new_in
+      and 2 others
+  --> $SRC_DIR/alloc/src/vec/mod.rs:LL:COL
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0599`.
diff --git a/tests/ui/wf/issue-110157.rs b/tests/ui/wf/issue-110157.rs
index 07e2c5d58c3..1a3d13e93b0 100644
--- a/tests/ui/wf/issue-110157.rs
+++ b/tests/ui/wf/issue-110157.rs
@@ -1,8 +1,7 @@
 struct NeedsDropTypes<'tcx, F>(std::marker::PhantomData<&'tcx F>);
 
 impl<'tcx, F, I> Iterator for NeedsDropTypes<'tcx, F>
-//~^ ERROR type annotations needed
-//~| ERROR not all trait items implemented
+//~^ ERROR not all trait items implemented
 where
     F: Fn(&Missing) -> Result<I, ()>,
     //~^ ERROR cannot find type `Missing` in this scope
diff --git a/tests/ui/wf/issue-110157.stderr b/tests/ui/wf/issue-110157.stderr
index 16bd34a6d8e..e750ea47d51 100644
--- a/tests/ui/wf/issue-110157.stderr
+++ b/tests/ui/wf/issue-110157.stderr
@@ -1,37 +1,20 @@
 error[E0412]: cannot find type `Missing` in this scope
-  --> $DIR/issue-110157.rs:7:12
+  --> $DIR/issue-110157.rs:6:12
    |
 LL |     F: Fn(&Missing) -> Result<I, ()>,
    |            ^^^^^^^ not found in this scope
 
 error[E0412]: cannot find type `Missing` in this scope
-  --> $DIR/issue-110157.rs:9:24
+  --> $DIR/issue-110157.rs:8:24
    |
 LL |     I: Iterator<Item = Missing>,
    |                        ^^^^^^^ not found in this scope
 
-error[E0283]: type annotations needed
-  --> $DIR/issue-110157.rs:3:31
-   |
-LL | impl<'tcx, F, I> Iterator for NeedsDropTypes<'tcx, F>
-   |                               ^^^^^^^^^^^^^^^^^^^^^^^ cannot infer type for type parameter `I`
-   |
-   = note: cannot satisfy `_: Iterator`
-note: required for `NeedsDropTypes<'tcx, F>` to implement `Iterator`
-  --> $DIR/issue-110157.rs:3:18
-   |
-LL | impl<'tcx, F, I> Iterator for NeedsDropTypes<'tcx, F>
-   |                  ^^^^^^^^     ^^^^^^^^^^^^^^^^^^^^^^^
-...
-LL |     I: Iterator<Item = Missing>,
-   |        ------------------------ unsatisfied trait bound introduced here
-
 error[E0046]: not all trait items implemented, missing: `Item`, `next`
   --> $DIR/issue-110157.rs:3:1
    |
 LL | / impl<'tcx, F, I> Iterator for NeedsDropTypes<'tcx, F>
 LL | |
-LL | |
 LL | | where
 LL | |     F: Fn(&Missing) -> Result<I, ()>,
 LL | |
@@ -41,7 +24,7 @@ LL | |     I: Iterator<Item = Missing>,
    = help: implement the missing item: `type Item = /* Type */;`
    = help: implement the missing item: `fn next(&mut self) -> Option<<Self as Iterator>::Item> { todo!() }`
 
-error: aborting due to 4 previous errors
+error: aborting due to 3 previous errors
 
-Some errors have detailed explanations: E0046, E0283, E0412.
+Some errors have detailed explanations: E0046, E0412.
 For more information about an error, try `rustc --explain E0046`.