about summary refs log tree commit diff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/codegen/debuginfo-inline-callsite-location.rs4
-rw-r--r--tests/codegen/infallible-unwrap-in-opt-z.rs26
-rw-r--r--tests/debuginfo/mutex.rs2
-rw-r--r--tests/debuginfo/rwlock-read.rs2
-rw-r--r--tests/mir-opt/const_allocation.main.GVN.after.32bit.mir4
-rw-r--r--tests/mir-opt/const_allocation.main.GVN.after.64bit.mir4
-rw-r--r--tests/mir-opt/const_allocation2.main.GVN.after.32bit.mir4
-rw-r--r--tests/mir-opt/const_allocation2.main.GVN.after.64bit.mir4
-rw-r--r--tests/mir-opt/const_allocation3.main.GVN.after.32bit.mir4
-rw-r--r--tests/mir-opt/const_allocation3.main.GVN.after.64bit.mir4
-rw-r--r--tests/mir-opt/const_prop/address_of_pair.fn0.GVN.diff6
-rw-r--r--tests/mir-opt/const_prop/array_index.main.GVN.32bit.panic-abort.diff7
-rw-r--r--tests/mir-opt/const_prop/array_index.main.GVN.32bit.panic-unwind.diff7
-rw-r--r--tests/mir-opt/const_prop/array_index.main.GVN.64bit.panic-abort.diff7
-rw-r--r--tests/mir-opt/const_prop/array_index.main.GVN.64bit.panic-unwind.diff7
-rw-r--r--tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-abort.diff12
-rw-r--r--tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-unwind.diff12
-rw-r--r--tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-abort.diff12
-rw-r--r--tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-unwind.diff12
-rw-r--r--tests/mir-opt/const_prop/boolean_identities.rs7
-rw-r--r--tests/mir-opt/const_prop/boolean_identities.test.GVN.diff12
-rw-r--r--tests/mir-opt/const_prop/boxes.main.GVN.panic-abort.diff9
-rw-r--r--tests/mir-opt/const_prop/boxes.main.GVN.panic-unwind.diff9
-rw-r--r--tests/mir-opt/const_prop/boxes.rs2
-rw-r--r--tests/mir-opt/const_prop/indirect_mutation.bar.GVN.diff6
-rw-r--r--tests/mir-opt/const_prop/indirect_mutation.foo.GVN.diff6
-rw-r--r--tests/mir-opt/const_prop/issue_67019.main.GVN.panic-abort.diff4
-rw-r--r--tests/mir-opt/const_prop/issue_67019.main.GVN.panic-unwind.diff4
-rw-r--r--tests/mir-opt/const_prop/large_array_index.main.GVN.32bit.panic-abort.diff7
-rw-r--r--tests/mir-opt/const_prop/large_array_index.main.GVN.32bit.panic-unwind.diff7
-rw-r--r--tests/mir-opt/const_prop/large_array_index.main.GVN.64bit.panic-abort.diff7
-rw-r--r--tests/mir-opt/const_prop/large_array_index.main.GVN.64bit.panic-unwind.diff7
-rw-r--r--tests/mir-opt/const_prop/mult_by_zero.rs3
-rw-r--r--tests/mir-opt/const_prop/mult_by_zero.test.GVN.diff2
-rw-r--r--tests/mir-opt/const_prop/mutable_variable_aggregate_mut_ref.main.GVN.diff6
-rw-r--r--tests/mir-opt/const_prop/mutable_variable_no_prop.main.GVN.diff6
-rw-r--r--tests/mir-opt/const_prop/pointer_expose_address.main.GVN.panic-abort.diff6
-rw-r--r--tests/mir-opt/const_prop/pointer_expose_address.main.GVN.panic-unwind.diff6
-rw-r--r--tests/mir-opt/const_prop/ref_deref.main.GVN.diff6
-rw-r--r--tests/mir-opt/const_prop/ref_deref_project.main.GVN.diff6
-rw-r--r--tests/mir-opt/const_prop/repeat.main.GVN.32bit.panic-abort.diff7
-rw-r--r--tests/mir-opt/const_prop/repeat.main.GVN.32bit.panic-unwind.diff7
-rw-r--r--tests/mir-opt/const_prop/repeat.main.GVN.64bit.panic-abort.diff7
-rw-r--r--tests/mir-opt/const_prop/repeat.main.GVN.64bit.panic-unwind.diff7
-rw-r--r--tests/mir-opt/const_prop/slice_len.main.GVN.32bit.panic-abort.diff6
-rw-r--r--tests/mir-opt/const_prop/slice_len.main.GVN.32bit.panic-unwind.diff6
-rw-r--r--tests/mir-opt/const_prop/slice_len.main.GVN.64bit.panic-abort.diff6
-rw-r--r--tests/mir-opt/const_prop/slice_len.main.GVN.64bit.panic-unwind.diff6
-rw-r--r--tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.32bit.diff9
-rw-r--r--tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.64bit.diff9
-rw-r--r--tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-abort.diff15
-rw-r--r--tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-unwind.diff15
-rw-r--r--tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-abort.diff15
-rw-r--r--tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-unwind.diff15
-rw-r--r--tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-abort.diff15
-rw-r--r--tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-unwind.diff15
-rw-r--r--tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-abort.diff15
-rw-r--r--tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-unwind.diff15
-rw-r--r--tests/mir-opt/dead-store-elimination/call_arg_copy.move_packed.DeadStoreElimination-final.panic-abort.diff (renamed from tests/mir-opt/dead-store-elimination/call_arg_copy.move_packed.DeadStoreElimination.panic-abort.diff)4
-rw-r--r--tests/mir-opt/dead-store-elimination/call_arg_copy.move_packed.DeadStoreElimination-final.panic-unwind.diff (renamed from tests/mir-opt/dead-store-elimination/call_arg_copy.move_packed.DeadStoreElimination.panic-unwind.diff)4
-rw-r--r--tests/mir-opt/dead-store-elimination/call_arg_copy.move_simple.DeadStoreElimination-final.panic-abort.diff (renamed from tests/mir-opt/dead-store-elimination/call_arg_copy.move_simple.DeadStoreElimination.panic-abort.diff)8
-rw-r--r--tests/mir-opt/dead-store-elimination/call_arg_copy.move_simple.DeadStoreElimination-final.panic-unwind.diff (renamed from tests/mir-opt/dead-store-elimination/call_arg_copy.move_simple.DeadStoreElimination.panic-unwind.diff)8
-rw-r--r--tests/mir-opt/dead-store-elimination/call_arg_copy.rs12
-rw-r--r--tests/mir-opt/dead-store-elimination/cycle.cycle.DeadStoreElimination-initial.diff (renamed from tests/mir-opt/dead-store-elimination/cycle.cycle.DeadStoreElimination.diff)10
-rw-r--r--tests/mir-opt/dead-store-elimination/cycle.rs9
-rw-r--r--tests/mir-opt/dead-store-elimination/place_mention.main.DeadStoreElimination-initial.diff (renamed from tests/mir-opt/dead-store-elimination/place_mention.main.DeadStoreElimination.diff)4
-rw-r--r--tests/mir-opt/dead-store-elimination/place_mention.rs15
-rw-r--r--tests/mir-opt/dead-store-elimination/provenance_soundness.pointer_to_int.DeadStoreElimination-initial.diff (renamed from tests/mir-opt/dead-store-elimination/provenance_soundness.pointer_to_int.DeadStoreElimination.diff)4
-rw-r--r--tests/mir-opt/dead-store-elimination/provenance_soundness.retags.DeadStoreElimination-initial.diff (renamed from tests/mir-opt/dead-store-elimination/provenance_soundness.retags.DeadStoreElimination.diff)4
-rw-r--r--tests/mir-opt/dead-store-elimination/provenance_soundness.rs18
-rw-r--r--tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-abort.diff10
-rw-r--r--tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-unwind.diff10
-rw-r--r--tests/mir-opt/funky_arms.float_to_exponential_common.GVN.panic-abort.diff34
-rw-r--r--tests/mir-opt/funky_arms.float_to_exponential_common.GVN.panic-unwind.diff34
-rw-r--r--tests/mir-opt/gvn.arithmetic.GVN.panic-abort.diff357
-rw-r--r--tests/mir-opt/gvn.arithmetic.GVN.panic-unwind.diff357
-rw-r--r--tests/mir-opt/gvn.arithmetic_checked.GVN.panic-abort.diff101
-rw-r--r--tests/mir-opt/gvn.arithmetic_checked.GVN.panic-unwind.diff101
-rw-r--r--tests/mir-opt/gvn.comparison.GVN.panic-abort.diff10
-rw-r--r--tests/mir-opt/gvn.comparison.GVN.panic-unwind.diff10
-rw-r--r--tests/mir-opt/gvn.dereferences.GVN.panic-abort.diff18
-rw-r--r--tests/mir-opt/gvn.dereferences.GVN.panic-unwind.diff18
-rw-r--r--tests/mir-opt/gvn.fn_pointers.GVN.panic-abort.diff18
-rw-r--r--tests/mir-opt/gvn.fn_pointers.GVN.panic-unwind.diff18
-rw-r--r--tests/mir-opt/gvn.repeated_index.GVN.panic-abort.diff13
-rw-r--r--tests/mir-opt/gvn.repeated_index.GVN.panic-unwind.diff13
-rw-r--r--tests/mir-opt/gvn.rs128
-rw-r--r--tests/mir-opt/gvn.slices.GVN.panic-abort.diff12
-rw-r--r--tests/mir-opt/gvn.slices.GVN.panic-unwind.diff12
-rw-r--r--tests/mir-opt/gvn.subexpression_elimination.GVN.panic-abort.diff30
-rw-r--r--tests/mir-opt/gvn.subexpression_elimination.GVN.panic-unwind.diff30
-rw-r--r--tests/mir-opt/gvn.unary.GVN.panic-abort.diff153
-rw-r--r--tests/mir-opt/gvn.unary.GVN.panic-unwind.diff153
-rw-r--r--tests/mir-opt/gvn.wide_ptr_ops.GVN.panic-abort.diff386
-rw-r--r--tests/mir-opt/gvn.wide_ptr_ops.GVN.panic-unwind.diff386
-rw-r--r--tests/mir-opt/inline/inline_coroutine.main.Inline.panic-abort.diff2
-rw-r--r--tests/mir-opt/inline/inline_coroutine.main.Inline.panic-unwind.diff2
-rw-r--r--tests/mir-opt/inline/inline_diverging.h.Inline.panic-abort.diff2
-rw-r--r--tests/mir-opt/inline/inline_diverging.h.Inline.panic-unwind.diff2
-rw-r--r--tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-abort.mir2
-rw-r--r--tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-unwind.mir2
-rw-r--r--tests/mir-opt/issue_101973.inner.GVN.panic-abort.diff27
-rw-r--r--tests/mir-opt/issue_101973.inner.GVN.panic-unwind.diff27
-rw-r--r--tests/mir-opt/issues/issue_59352.num_to_digit.PreCodegen.after.panic-abort.mir2
-rw-r--r--tests/mir-opt/issues/issue_59352.num_to_digit.PreCodegen.after.panic-unwind.mir2
-rw-r--r--tests/mir-opt/jump_threading.identity.JumpThreading.panic-abort.diff4
-rw-r--r--tests/mir-opt/jump_threading.identity.JumpThreading.panic-unwind.diff4
-rw-r--r--tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.32bit.panic-abort.diff18
-rw-r--r--tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.32bit.panic-unwind.diff18
-rw-r--r--tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.64bit.panic-abort.diff18
-rw-r--r--tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.64bit.panic-unwind.diff18
-rw-r--r--tests/mir-opt/pre-codegen/loops.filter_mapped.PreCodegen.after.mir2
-rw-r--r--tests/mir-opt/pre-codegen/loops.int_range.PreCodegen.after.mir2
-rw-r--r--tests/mir-opt/pre-codegen/loops.mapped.PreCodegen.after.mir2
-rw-r--r--tests/mir-opt/pre-codegen/mem_replace.mem_replace.PreCodegen.after.mir19
-rw-r--r--tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.32bit.panic-abort.diff8
-rw-r--r--tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.32bit.panic-unwind.diff8
-rw-r--r--tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.64bit.panic-abort.diff8
-rw-r--r--tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.64bit.panic-unwind.diff8
-rw-r--r--tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-abort.mir2
-rw-r--r--tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-unwind.mir2
-rw-r--r--tests/mir-opt/pre-codegen/range_iter.inclusive_loop.PreCodegen.after.panic-abort.mir2
-rw-r--r--tests/mir-opt/pre-codegen/range_iter.inclusive_loop.PreCodegen.after.panic-unwind.mir2
-rw-r--r--tests/mir-opt/pre-codegen/slice_filter.variant_a-{closure#0}.PreCodegen.after.mir16
-rw-r--r--tests/mir-opt/pre-codegen/slice_index.slice_get_mut_usize.PreCodegen.after.panic-abort.mir15
-rw-r--r--tests/mir-opt/pre-codegen/slice_index.slice_get_mut_usize.PreCodegen.after.panic-unwind.mir15
-rw-r--r--tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-abort.mir17
-rw-r--r--tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-unwind.mir17
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-abort.mir19
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-unwind.mir19
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-abort.mir17
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-unwind.mir17
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-abort.mir2
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-unwind.mir2
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-abort.mir19
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-unwind.mir19
-rw-r--r--tests/mir-opt/pre-codegen/try_identity.new.PreCodegen.after.mir8
-rw-r--r--tests/mir-opt/pre-codegen/try_identity.old.PreCodegen.after.mir4
-rw-r--r--tests/mir-opt/separate_const_switch.identity.SeparateConstSwitch.diff82
-rw-r--r--tests/mir-opt/separate_const_switch.too_complex.SeparateConstSwitch.diff41
-rw-r--r--tests/mir-opt/simplify_match.main.GVN.panic-abort.diff10
-rw-r--r--tests/mir-opt/simplify_match.main.GVN.panic-unwind.diff10
-rw-r--r--tests/rustdoc-ui/feature-gate-custom_code_classes_in_docs.rs1
-rw-r--r--tests/rustdoc-ui/feature-gate-custom_code_classes_in_docs.stderr1
-rw-r--r--tests/rustdoc-ui/feature-gate-doc_cfg_hide.stderr1
-rw-r--r--tests/rustdoc-ui/ice-blanket-impl-52873.rs (renamed from tests/rustdoc/issue-52873.rs)4
-rw-r--r--tests/rustdoc-ui/ice-blanket-impl-selection-55001.rs (renamed from tests/rustdoc/issue-55001.rs)4
-rw-r--r--tests/rustdoc-ui/intra-doc/feature-gate-intra-doc-pointers.stderr2
-rw-r--r--tests/rustdoc-ui/lints/feature-gate-rustdoc_missing_doc_code_examples.rs1
-rw-r--r--tests/rustdoc-ui/lints/feature-gate-rustdoc_missing_doc_code_examples.stderr1
-rw-r--r--tests/rustdoc/auto-trait-bounds-by-associated-type-50159.rs (renamed from tests/rustdoc/issue-50159.rs)5
-rw-r--r--tests/rustdoc/auto-trait-bounds-inference-variables-54705.rs (renamed from tests/rustdoc/issue-54705.rs)5
-rw-r--r--tests/rustdoc/auto-trait-bounds-where-51236.rs (renamed from tests/rustdoc/issue-51236.rs)5
-rw-r--r--tests/rustdoc/auto-trait-negative-impl-55321.rs (renamed from tests/rustdoc/issue-55321.rs)7
-rw-r--r--tests/rustdoc/blank-line-in-doc-block-47197.rs11
-rw-r--r--tests/rustdoc/demo-allocator-54478.rs (renamed from tests/rustdoc/issue-54478-demo-allocator.rs)3
-rw-r--r--tests/rustdoc/deref-mut-35169-2.rs (renamed from tests/rustdoc/issue-35169-2.rs)5
-rw-r--r--tests/rustdoc/deref-mut-35169.rs (renamed from tests/rustdoc/issue-35169.rs)5
-rw-r--r--tests/rustdoc/doc-attr-comment-mix-42760.rs (renamed from tests/rustdoc/issue-42760.rs)5
-rw-r--r--tests/rustdoc/doctest/doctest-escape-boring-41783.codeblock.html (renamed from tests/rustdoc/issue-41783.codeblock.html)0
-rw-r--r--tests/rustdoc/doctest/doctest-escape-boring-41783.rs (renamed from tests/rustdoc/issue-41783.rs)5
-rw-r--r--tests/rustdoc/enum-variant-reexport-35488.rs16
-rw-r--r--tests/rustdoc/impl-blanket-53689.rs (renamed from tests/rustdoc/issue-53689.rs)1
-rw-r--r--tests/rustdoc/impl-trait-43869.rs (renamed from tests/rustdoc/issue-43869.rs)27
-rw-r--r--tests/rustdoc/inline_cross/auxiliary/issue-46727.rs (renamed from tests/rustdoc/auxiliary/issue-46727.rs)0
-rw-r--r--tests/rustdoc/inline_cross/const-eval-46727.rs (renamed from tests/rustdoc/issue-46727.rs)5
-rw-r--r--tests/rustdoc/intra-doc/module-scope-name-resolution-55364.rs (renamed from tests/rustdoc/issue-55364.rs)19
-rw-r--r--tests/rustdoc/issue-35488.rs13
-rw-r--r--tests/rustdoc/issue-46377.rs3
-rw-r--r--tests/rustdoc/issue-47197-blank-line-in-doc-block.rs8
-rw-r--r--tests/rustdoc/public-impl-mention-private-generic-46380-2.rs (renamed from tests/rustdoc/issue-46380-2.rs)5
-rw-r--r--tests/rustdoc/sort-53812.rs (renamed from tests/rustdoc/issue-53812.rs)5
-rw-r--r--tests/rustdoc/summary-header-46377.rs6
-rw-r--r--tests/ui-fulldeps/hash-stable-is-unstable.rs15
-rw-r--r--tests/ui-fulldeps/hash-stable-is-unstable.stderr15
-rw-r--r--tests/ui-fulldeps/pathless-extern-unstable.rs1
-rw-r--r--tests/ui-fulldeps/pathless-extern-unstable.stderr3
-rw-r--r--tests/ui-fulldeps/stable-mir/check_allocation.rs2
-rw-r--r--tests/ui/array-slice-vec/suggest-array-length.stderr7
-rw-r--r--tests/ui/associated-consts/issue-105330.stderr2
-rw-r--r--tests/ui/associated-consts/issue-93835.stderr2
-rw-r--r--tests/ui/associated-inherent-types/assoc-inherent-unstable.stderr1
-rw-r--r--tests/ui/associated-inherent-types/dont-select-if-disabled.stderr1
-rw-r--r--tests/ui/associated-inherent-types/issue-109071.no_gate.stderr1
-rw-r--r--tests/ui/associated-inherent-types/issue-109768.stderr1
-rw-r--r--tests/ui/associated-type-bounds/issue-99828.stderr1
-rw-r--r--tests/ui/associated-type-bounds/return-type-notation/bad-inputs-and-output.stderr2
-rw-r--r--tests/ui/associated-type-bounds/return-type-notation/unpretty-parenthesized.stderr1
-rw-r--r--tests/ui/async-await/feature-async-closure.stderr1
-rw-r--r--tests/ui/async-await/feature-async-for-loop.stderr2
-rw-r--r--tests/ui/async-await/issues/issue-65159.rs4
-rw-r--r--tests/ui/async-await/issues/issue-65159.stderr16
-rw-r--r--tests/ui/async-await/issues/issue-95307.stderr1
-rw-r--r--tests/ui/async-await/track-caller/async-block.afn.stderr3
-rw-r--r--tests/ui/async-await/track-caller/async-block.nofeat.stderr3
-rw-r--r--tests/ui/async-await/track-caller/async-closure-gate.afn.stderr6
-rw-r--r--tests/ui/async-await/track-caller/async-closure-gate.nofeat.stderr6
-rw-r--r--tests/ui/async-await/track-caller/panic-track-caller.cls.stderr2
-rw-r--r--tests/ui/async-await/track-caller/panic-track-caller.nofeat.stderr2
-rw-r--r--tests/ui/auto-traits/issue-117789.stderr1
-rw-r--r--tests/ui/auto-traits/pre-cfg.stderr1
-rw-r--r--tests/ui/binop/binary-op-suggest-deref.rs8
-rw-r--r--tests/ui/binop/binary-op-suggest-deref.stderr23
-rw-r--r--tests/ui/borrowck/fn-item-check-trait-ref.rs15
-rw-r--r--tests/ui/borrowck/fn-item-check-trait-ref.stderr12
-rw-r--r--tests/ui/borrowck/fn-item-check-type-params.rs57
-rw-r--r--tests/ui/borrowck/fn-item-check-type-params.stderr43
-rw-r--r--tests/ui/borrowck/issue-119915-bad-clone-suggestion.rs28
-rw-r--r--tests/ui/borrowck/issue-119915-bad-clone-suggestion.stderr17
-rw-r--r--tests/ui/borrowck/issue-82126-mismatched-subst-and-hir.rs1
-rw-r--r--tests/ui/borrowck/issue-82126-mismatched-subst-and-hir.stderr18
-rw-r--r--tests/ui/borrowck/issue-85765-closure.rs1
-rw-r--r--tests/ui/borrowck/issue-85765-closure.stderr13
-rw-r--r--tests/ui/borrowck/issue-85765.rs1
-rw-r--r--tests/ui/borrowck/issue-85765.stderr13
-rw-r--r--tests/ui/borrowck/issue-91206.rs1
-rw-r--r--tests/ui/borrowck/issue-91206.stderr7
-rw-r--r--tests/ui/bounds-lifetime.stderr2
-rw-r--r--tests/ui/box/alloc-unstable-fail.stderr1
-rw-r--r--tests/ui/c-variadic/feature-gate-extended_varargs_abi_support.stderr3
-rw-r--r--tests/ui/c-variadic/variadic-ffi-2.rs5
-rw-r--r--tests/ui/c-variadic/variadic-ffi-2.stderr2
-rw-r--r--tests/ui/cfg/cfg-false-feature.stderr2
-rw-r--r--tests/ui/cfg/diagnostics-cross-crate.rs2
-rw-r--r--tests/ui/cfg/diagnostics-cross-crate.stderr8
-rw-r--r--tests/ui/cfg/diagnostics-same-crate.rs3
-rw-r--r--tests/ui/cfg/diagnostics-same-crate.stderr12
-rw-r--r--tests/ui/closures/2229_closure_analysis/arrays-completely-captured.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/arrays-completely-captured.stderr11
-rw-r--r--tests/ui/closures/2229_closure_analysis/by_value.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/by_value.stderr13
-rw-r--r--tests/ui/closures/2229_closure_analysis/capture-analysis-1.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/capture-analysis-1.stderr17
-rw-r--r--tests/ui/closures/2229_closure_analysis/capture-analysis-2.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/capture-analysis-2.stderr11
-rw-r--r--tests/ui/closures/2229_closure_analysis/capture-analysis-3.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/capture-analysis-3.stderr11
-rw-r--r--tests/ui/closures/2229_closure_analysis/capture-analysis-4.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/capture-analysis-4.stderr11
-rw-r--r--tests/ui/closures/2229_closure_analysis/capture-disjoint-field-struct.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/capture-disjoint-field-struct.stderr9
-rw-r--r--tests/ui/closures/2229_closure_analysis/capture-disjoint-field-tuple.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/capture-disjoint-field-tuple.stderr9
-rw-r--r--tests/ui/closures/2229_closure_analysis/capture-enums.rs2
-rw-r--r--tests/ui/closures/2229_closure_analysis/capture-enums.stderr28
-rw-r--r--tests/ui/closures/2229_closure_analysis/deep-multilevel-struct.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/deep-multilevel-struct.stderr13
-rw-r--r--tests/ui/closures/2229_closure_analysis/deep-multilevel-tuple.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/deep-multilevel-tuple.stderr13
-rw-r--r--tests/ui/closures/2229_closure_analysis/destructure_patterns.rs3
-rw-r--r--tests/ui/closures/2229_closure_analysis/destructure_patterns.stderr47
-rw-r--r--tests/ui/closures/2229_closure_analysis/feature-gate-capture_disjoint_fields.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/feature-gate-capture_disjoint_fields.stderr9
-rw-r--r--tests/ui/closures/2229_closure_analysis/issue-87378.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/issue-87378.stderr9
-rw-r--r--tests/ui/closures/2229_closure_analysis/issue-88476.rs2
-rw-r--r--tests/ui/closures/2229_closure_analysis/issue-88476.stderr16
-rw-r--r--tests/ui/closures/2229_closure_analysis/move_closure.rs11
-rw-r--r--tests/ui/closures/2229_closure_analysis/move_closure.stderr119
-rw-r--r--tests/ui/closures/2229_closure_analysis/multilevel-path-1.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/multilevel-path-1.stderr9
-rw-r--r--tests/ui/closures/2229_closure_analysis/multilevel-path-2.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/multilevel-path-2.stderr9
-rw-r--r--tests/ui/closures/2229_closure_analysis/nested-closure.rs2
-rw-r--r--tests/ui/closures/2229_closure_analysis/nested-closure.stderr30
-rw-r--r--tests/ui/closures/2229_closure_analysis/optimization/edge_case.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/optimization/edge_case.stderr1
-rw-r--r--tests/ui/closures/2229_closure_analysis/path-with-array-access.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/path-with-array-access.stderr9
-rw-r--r--tests/ui/closures/2229_closure_analysis/preserve_field_drop_order.rs3
-rw-r--r--tests/ui/closures/2229_closure_analysis/preserve_field_drop_order.stderr67
-rw-r--r--tests/ui/closures/2229_closure_analysis/repr_packed.rs3
-rw-r--r--tests/ui/closures/2229_closure_analysis/repr_packed.stderr37
-rw-r--r--tests/ui/closures/2229_closure_analysis/simple-struct-min-capture.rs1
-rw-r--r--tests/ui/closures/2229_closure_analysis/simple-struct-min-capture.stderr11
-rw-r--r--tests/ui/closures/2229_closure_analysis/unsafe_ptr.rs2
-rw-r--r--tests/ui/closures/2229_closure_analysis/unsafe_ptr.stderr20
-rw-r--r--tests/ui/closures/2229_closure_analysis/wild_patterns.rs3
-rw-r--r--tests/ui/closures/2229_closure_analysis/wild_patterns.stderr31
-rw-r--r--tests/ui/closures/binder/disallow-const.stderr1
-rw-r--r--tests/ui/closures/binder/disallow-ty.stderr1
-rw-r--r--tests/ui/cmse-nonsecure/cmse-nonsecure-call/gate_test.stderr1
-rw-r--r--tests/ui/cmse-nonsecure/cmse-nonsecure-entry/gate_test.stderr1
-rw-r--r--tests/ui/conditional-compilation/cfg-attr-crate-2.stderr1
-rw-r--r--tests/ui/conditional-compilation/cfg-attr-multi-invalid-1.stderr1
-rw-r--r--tests/ui/conditional-compilation/cfg-attr-multi-invalid-2.stderr1
-rw-r--r--tests/ui/conditional-compilation/cfg-generic-params.stderr3
-rw-r--r--tests/ui/conditional-compilation/cfg_accessible-unstable.stderr1
-rw-r--r--tests/ui/const-generics/parser-error-recovery/issue-89013-no-kw.stderr1
-rw-r--r--tests/ui/const-generics/parser-error-recovery/issue-89013.stderr1
-rw-r--r--tests/ui/consts/async-block.without_feature.stderr2
-rw-r--r--tests/ui/consts/const-address-of-interior-mut.stderr4
-rw-r--r--tests/ui/consts/const-address-of-mut.stderr4
-rw-r--r--tests/ui/consts/const-eval/issue-114994-fail.stderr2
-rw-r--r--tests/ui/consts/const-eval/issue-65394.stderr1
-rw-r--r--tests/ui/consts/const-extern-fn/const-extern-fn-min-const-fn.stderr1
-rw-r--r--tests/ui/consts/const-extern-fn/feature-gate-const_extern_fn.stderr2
-rw-r--r--tests/ui/consts/const-fn-error.stderr2
-rw-r--r--tests/ui/consts/const-for-feature-gate.stderr1
-rw-r--r--tests/ui/consts/const-multi-ref.stderr2
-rw-r--r--tests/ui/consts/const-mut-refs/feature-gate-const_mut_refs.stderr1
-rw-r--r--tests/ui/consts/const-mut-refs/issue-76510.32bit.stderr1
-rw-r--r--tests/ui/consts/const-mut-refs/issue-76510.64bit.stderr1
-rw-r--r--tests/ui/consts/const-suggest-feature.stderr1
-rw-r--r--tests/ui/consts/const-try-feature-gate.stderr1
-rw-r--r--tests/ui/consts/const_fn_floating_point_arithmetic.stock.stderr5
-rw-r--r--tests/ui/consts/const_let_assign3.stderr3
-rw-r--r--tests/ui/consts/control-flow/loop.stderr2
-rw-r--r--tests/ui/consts/control-flow/try.stderr1
-rw-r--r--tests/ui/consts/gate-do-not-const-check.stderr1
-rw-r--r--tests/ui/consts/min_const_fn/address_of.stderr2
-rw-r--r--tests/ui/consts/min_const_fn/min_const_fn.stderr13
-rw-r--r--tests/ui/consts/min_const_fn/min_const_fn_unsafe_bad.stderr4
-rw-r--r--tests/ui/consts/min_const_fn/mutable_borrow.stderr2
-rw-r--r--tests/ui/consts/static_mut_containing_mut_ref2.stock.stderr1
-rw-r--r--tests/ui/consts/write_to_mut_ref_dest.stock.stderr2
-rw-r--r--tests/ui/coroutine/async_gen_fn.e2024.stderr1
-rw-r--r--tests/ui/coroutine/gen_block.e2024.stderr1
-rw-r--r--tests/ui/coroutine/gen_block.none.stderr2
-rw-r--r--tests/ui/coroutine/gen_fn.e2024.stderr1
-rw-r--r--tests/ui/deprecation/issue-66340-deprecated-attr-non-meta-grammar.rs2
-rw-r--r--tests/ui/deprecation/issue-66340-deprecated-attr-non-meta-grammar.stderr7
-rw-r--r--tests/ui/diagnostic_namespace/feature-gate-diagnostic_namespace.stderr2
-rw-r--r--tests/ui/diagnostic_namespace/on_unimplemented/feature-gate-diagnostic_on_unimplemented.stderr1
-rw-r--r--tests/ui/dyn-star/feature-gate-dyn_star.stderr1
-rw-r--r--tests/ui/dyn-star/gated-span.stderr1
-rw-r--r--tests/ui/dyn-star/no-explicit-dyn-star-cast.stderr2
-rw-r--r--tests/ui/error-codes/E0017.stderr1
-rw-r--r--tests/ui/error-codes/E0388.stderr1
-rw-r--r--tests/ui/error-codes/E0396.stderr5
-rw-r--r--tests/ui/error-codes/E0658.stderr1
-rw-r--r--tests/ui/explore-issue-38412.stderr7
-rw-r--r--tests/ui/expr/if/attrs/stmt-expr-gated.stderr1
-rw-r--r--tests/ui/extern/issue-112363-extern-item-where-clauses-debug-ice.stderr1
-rw-r--r--tests/ui/feature-gates/doc-rust-logo.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-abi-avr-interrupt.stderr14
-rw-r--r--tests/ui/feature-gates/feature-gate-abi-msp430-interrupt.stderr7
-rw-r--r--tests/ui/feature-gates/feature-gate-abi-riscv-interrupt.stderr6
-rw-r--r--tests/ui/feature-gates/feature-gate-abi-x86-interrupt.stderr7
-rw-r--r--tests/ui/feature-gates/feature-gate-abi.stderr19
-rw-r--r--tests/ui/feature-gates/feature-gate-abi_amdgpu_kernel.stderr7
-rw-r--r--tests/ui/feature-gates/feature-gate-abi_ptx.stderr7
-rw-r--r--tests/ui/feature-gates/feature-gate-abi_unadjusted.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-alloc-error-handler.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-allocator_internals.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-allow-internal-unsafe-nested-macro.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-allow-internal-unstable-nested-macro.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-allow-internal-unstable-struct.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-allow-internal-unstable.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-arbitrary-self-types.stderr3
-rw-r--r--tests/ui/feature-gates/feature-gate-arbitrary_self_types-raw-pointer.stderr3
-rw-r--r--tests/ui/feature-gates/feature-gate-asm_const.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-asm_experimental_arch.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-asm_unwind.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-assoc-type-defaults.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-associated_const_equality.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-associated_type_bounds.stderr13
-rw-r--r--tests/ui/feature-gates/feature-gate-auto-traits.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-box_patterns.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-builtin_syntax.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-c_variadic.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-cfg-relocation-model.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-cfg-sanitizer_cfi.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-cfg-target-abi.stderr4
-rw-r--r--tests/ui/feature-gates/feature-gate-cfg-target-compact.stderr4
-rw-r--r--tests/ui/feature-gates/feature-gate-cfg-target-has-atomic-equal-alignment.stderr6
-rw-r--r--tests/ui/feature-gates/feature-gate-cfg-target-has-atomic.stderr6
-rw-r--r--tests/ui/feature-gates/feature-gate-cfg-target-thread-local.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-cfg-version.stderr15
-rw-r--r--tests/ui/feature-gates/feature-gate-cfg_overflow_checks.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-cfg_sanitize.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-cfi_encoding.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-closure_lifetime_binder.stderr3
-rw-r--r--tests/ui/feature-gates/feature-gate-closure_track_caller.stderr3
-rw-r--r--tests/ui/feature-gates/feature-gate-collapse_debuginfo.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-compiler-builtins.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-concat_bytes.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-concat_idents.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-concat_idents2.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-concat_idents3.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-coroutines.e2024.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-coroutines.none.stderr6
-rw-r--r--tests/ui/feature-gates/feature-gate-coverage-attribute.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-custom_mir.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-custom_test_frameworks.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-decl_macro.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-deprecated_safe.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-doc_cfg.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-doc_masked.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-doc_notable_trait.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-exclusive-range-pattern.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-explicit_tail_calls.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-extern_types.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-ffi_const.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-ffi_pure.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-ffi_returns_twice.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-fn_align.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-fn_delegation.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-format_args_nl.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-fundamental.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-gen_blocks.e2024.stderr4
-rw-r--r--tests/ui/feature-gates/feature-gate-generic_arg_infer.normal.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-generic_associated_types_extended.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-impl_trait_in_assoc_type.stderr3
-rw-r--r--tests/ui/feature-gates/feature-gate-impl_trait_in_fn_trait_return.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-imported_main.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-inherent_associated_types.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-inline_const.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-inline_const_pat.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-intrinsics.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-is_sorted.stderr4
-rw-r--r--tests/ui/feature-gates/feature-gate-lang-items.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-large-assignments.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-link-arg-attribute.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-link_cfg.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-link_llvm_intrinsics.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-linkage.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-lint-reasons.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-log_syntax.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-log_syntax2.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-marker_trait_attr.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-may-dangle.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-more-qualified-paths.stderr3
-rw-r--r--tests/ui/feature-gates/feature-gate-multiple_supertrait_upcastable.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-naked_functions.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-native_link_modifiers_as_needed.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-needs-allocator.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-never_patterns.rs1
-rw-r--r--tests/ui/feature-gates/feature-gate-never_patterns.stderr43
-rw-r--r--tests/ui/feature-gates/feature-gate-never_type.stderr5
-rw-r--r--tests/ui/feature-gates/feature-gate-no_core.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-no_sanitize.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-non_exhaustive_omitted_patterns_lint.stderr6
-rw-r--r--tests/ui/feature-gates/feature-gate-non_lifetime_binders.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-offset-of-enum.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-omit-gdb-pretty-printer-section.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-optimize_attribute.stderr5
-rw-r--r--tests/ui/feature-gates/feature-gate-prelude_import.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-proc_macro_byte_character.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-proc_macro_c_str_literals.rs11
-rw-r--r--tests/ui/feature-gates/feature-gate-proc_macro_c_str_literals.stderr13
-rw-r--r--tests/ui/feature-gates/feature-gate-profiler-runtime.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-register_tool.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-repr-simd.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-repr128.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-return_type_notation.cfg.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-return_type_notation.no.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-rust_cold_cc.stderr7
-rw-r--r--tests/ui/feature-gates/feature-gate-rustc-allow-const-fn-unstable.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-rustc-attrs-1.stderr3
-rw-r--r--tests/ui/feature-gates/feature-gate-rustc-attrs.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-rustdoc_internals.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-simd.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-start.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-stmt_expr_attributes.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-strict_provenance.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-test_unstable_lint.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-thread_local.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-trace_macros.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-trait-alias.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-transparent_unions.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-try_blocks.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-type_ascription.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-type_privacy_lints.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.stderr7
-rw-r--r--tests/ui/feature-gates/feature-gate-unboxed-closures-method-calls.stderr3
-rw-r--r--tests/ui/feature-gates/feature-gate-unboxed-closures-ufcs-calls.stderr3
-rw-r--r--tests/ui/feature-gates/feature-gate-unboxed-closures.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-unix_sigpipe.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-unnamed_fields.stderr5
-rw-r--r--tests/ui/feature-gates/feature-gate-unsized_tuple_coercion.stderr1
-rw-r--r--tests/ui/feature-gates/feature-gate-used_with_arg.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-vectorcall.stderr7
-rw-r--r--tests/ui/feature-gates/feature-gate-wasm_abi.stderr7
-rw-r--r--tests/ui/feature-gates/feature-gate-yeet_expr-in-cfg.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gate-yeet_expr.stderr2
-rw-r--r--tests/ui/feature-gates/feature-gated-feature-in-macro-arg.stderr1
-rw-r--r--tests/ui/feature-gates/issue-43106-gating-of-builtin-attrs-error.rs1
-rw-r--r--tests/ui/feature-gates/issue-43106-gating-of-builtin-attrs-error.stderr73
-rw-r--r--tests/ui/feature-gates/issue-43106-gating-of-derive.stderr1
-rw-r--r--tests/ui/feature-gates/issue-49983-see-issue-0.stderr1
-rw-r--r--tests/ui/feature-gates/rustc-private.stderr1
-rw-r--r--tests/ui/feature-gates/soft-syntax-gates-with-errors.stderr2
-rw-r--r--tests/ui/feature-gates/soft-syntax-gates-without-errors.stderr2
-rw-r--r--tests/ui/feature-gates/trace_macros-gate.stderr4
-rw-r--r--tests/ui/generic-associated-types/issue-119942-unsatisified-gat-bound-during-assoc-ty-selection.rs33
-rw-r--r--tests/ui/generic-associated-types/issue-119942-unsatisified-gat-bound-during-assoc-ty-selection.stderr52
-rw-r--r--tests/ui/generic-const-items/feature-gate-generic_const_items.stderr8
-rw-r--r--tests/ui/half-open-range-patterns/feature-gate-half-open-range-patterns-in-slices.stderr1
-rw-r--r--tests/ui/half-open-range-patterns/range_pat_interactions1.stderr2
-rw-r--r--tests/ui/half-open-range-patterns/range_pat_interactions3.stderr5
-rw-r--r--tests/ui/half-open-range-patterns/slice_pattern_syntax_problem1.stderr3
-rw-r--r--tests/ui/higher-ranked/trait-bounds/hrtb-wrong-kind.stderr2
-rw-r--r--tests/ui/higher-ranked/trait-bounds/issue-59311.rs1
-rw-r--r--tests/ui/higher-ranked/trait-bounds/issue-59311.stderr11
-rw-r--r--tests/ui/impl-trait/issue-72911.rs1
-rw-r--r--tests/ui/impl-trait/issue-72911.stderr13
-rw-r--r--tests/ui/impl-trait/issues/issue-78722-2.stderr1
-rw-r--r--tests/ui/impl-trait/issues/issue-78722.stderr1
-rw-r--r--tests/ui/impl-trait/issues/issue-92305.rs1
-rw-r--r--tests/ui/impl-trait/issues/issue-92305.stderr16
-rw-r--r--tests/ui/impl-trait/where-allowed.stderr3
-rw-r--r--tests/ui/implied-bounds/implied-bounds-on-trait-hierarchy-1.rs (renamed from tests/ui/implied-bounds/implied-bounds-on-trait-hierarchy.rs)9
-rw-r--r--tests/ui/implied-bounds/implied-bounds-on-trait-hierarchy-1.stderr16
-rw-r--r--tests/ui/implied-bounds/implied-bounds-on-trait-hierarchy-2.rs45
-rw-r--r--tests/ui/imports/issue-37887.stderr1
-rw-r--r--tests/ui/inference/inference_unstable_forced.stderr1
-rw-r--r--tests/ui/internal/internal-unstable-noallow.stderr4
-rw-r--r--tests/ui/internal/internal-unstable-thread-local.stderr1
-rw-r--r--tests/ui/internal/internal-unstable.stderr5
-rw-r--r--tests/ui/intrinsics/feature-gate-safe-intrinsic.stderr1
-rw-r--r--tests/ui/intrinsics/unchecked_math_unstable.stderr3
-rw-r--r--tests/ui/issues/issue-20313.stderr1
-rw-r--r--tests/ui/issues/issue-23024.stderr1
-rw-r--r--tests/ui/issues/issue-32782.stderr1
-rw-r--r--tests/ui/issues/issue-50582.stderr1
-rw-r--r--tests/ui/issues/issue-50585.stderr1
-rw-r--r--tests/ui/issues/issue-52489.stderr1
-rw-r--r--tests/ui/lang-items/issue-83471.stderr2
-rw-r--r--tests/ui/lifetimes/lifetime-errors/issue_74400.rs2
-rw-r--r--tests/ui/lifetimes/lifetime-errors/issue_74400.stderr32
-rw-r--r--tests/ui/linkage-attr/linkage4.stderr1
-rw-r--r--tests/ui/lint/large_assignments/box_rc_arc_allowed.stderr4
-rw-r--r--tests/ui/lint/large_assignments/copy_into_fn.rs24
-rw-r--r--tests/ui/lint/large_assignments/copy_into_fn.stderr31
-rw-r--r--tests/ui/lint/lint-output-format.stderr4
-rw-r--r--tests/ui/lint/lint-stability-2.stderr32
-rw-r--r--tests/ui/lint/lint-stability-fields.stderr43
-rw-r--r--tests/ui/lint/lint-stability.stderr43
-rw-r--r--tests/ui/lint/must_not_suspend/feature-gate-must_not_suspend.stderr1
-rw-r--r--tests/ui/lint/must_not_suspend/gated.stderr1
-rw-r--r--tests/ui/lint/rfc-2383-lint-reason/expect_missing_feature_gate.stderr1
-rw-r--r--tests/ui/lint/unused/unused-doc-comments-edge-cases.stderr1
-rw-r--r--tests/ui/macros/issue-68060.rs1
-rw-r--r--tests/ui/macros/issue-68060.stderr1
-rw-r--r--tests/ui/macros/macro-stability.stderr3
-rw-r--r--tests/ui/macros/rfc-3086-metavar-expr/required-feature.stderr10
-rw-r--r--tests/ui/moves/move-fn-self-receiver.stderr14
-rw-r--r--tests/ui/never_type/issue-52443.stderr2
-rw-r--r--tests/ui/offset-of/offset-of-unstable.stderr8
-rw-r--r--tests/ui/on-unimplemented/feature-gate-on-unimplemented.stderr1
-rw-r--r--tests/ui/or-patterns/or-patterns-syntactic-pass.stderr1
-rw-r--r--tests/ui/panic-runtime/needs-gate.stderr2
-rw-r--r--tests/ui/parser/attribute/attr-unquoted-ident.fixed15
-rw-r--r--tests/ui/parser/attribute/attr-unquoted-ident.rs15
-rw-r--r--tests/ui/parser/attribute/attr-unquoted-ident.stderr24
-rw-r--r--tests/ui/parser/constraints-before-generic-args-syntactic-pass.stderr2
-rw-r--r--tests/ui/parser/impl-item-type-no-body-semantic-fail.stderr4
-rw-r--r--tests/ui/parser/issues/issue-118531-ice.stderr1
-rw-r--r--tests/ui/parser/recover/recover-assoc-const-constraint.stderr2
-rw-r--r--tests/ui/parser/recover/recover-quantified-closure.stderr2
-rw-r--r--tests/ui/pattern/never_patterns.rs28
-rw-r--r--tests/ui/pattern/never_patterns.stderr58
-rw-r--r--tests/ui/pattern/range-pattern-meant-to-be-slice-rest-pattern.stderr1
-rw-r--r--tests/ui/pattern/rest-pat-syntactic.stderr2
-rw-r--r--tests/ui/pattern/usefulness/issue-119493-type-error-ice.stderr1
-rw-r--r--tests/ui/pattern/usefulness/issue-119778-type-error-ice.stderr1
-rw-r--r--tests/ui/pin-macro/cant_access_internals.stderr1
-rw-r--r--tests/ui/proc-macro/attr-stmt-expr.stderr2
-rw-r--r--tests/ui/proc-macro/attributes-on-modules-fail.stderr4
-rw-r--r--tests/ui/proc-macro/auxiliary/api/mod.rs2
-rw-r--r--tests/ui/proc-macro/auxiliary/api/parse.rs7
-rw-r--r--tests/ui/proc-macro/expand-to-unstable.stderr1
-rw-r--r--tests/ui/proc-macro/inner-attr-non-inline-mod.stderr3
-rw-r--r--tests/ui/proc-macro/issue-83510.stderr1
-rw-r--r--tests/ui/proc-macro/proc-macro-gates.stderr8
-rw-r--r--tests/ui/proc-macro/test.rs1
-rw-r--r--tests/ui/raw-ref-op/feature-raw-ref-op.stderr6
-rw-r--r--tests/ui/repr/explicit-rust-repr-conflicts.stderr1
-rw-r--r--tests/ui/rfcs/rfc-0000-never_patterns/ICE-119271-never-arm-attr-in-guard.stderr2
-rw-r--r--tests/ui/rfcs/rfc-0000-never_patterns/bindings.rs46
-rw-r--r--tests/ui/rfcs/rfc-0000-never_patterns/bindings.stderr50
-rw-r--r--tests/ui/rfcs/rfc-0000-never_patterns/parse.rs1
-rw-r--r--tests/ui/rfcs/rfc-0000-never_patterns/parse.stderr8
-rw-r--r--tests/ui/rfcs/rfc-1445-restrict-constants-in-patterns/feature-gate.no_gate.stderr2
-rw-r--r--tests/ui/rfcs/rfc-2294-if-let-guard/feature-gate.stderr11
-rw-r--r--tests/ui/rfcs/rfc-2396-target_feature-11/feature-gate-target_feature_11.stderr1
-rw-r--r--tests/ui/rfcs/rfc-2397-do-not-recommend/unstable-feature.stderr1
-rw-r--r--tests/ui/rfcs/rfc-2497-if-let-chains/feature-gate.stderr8
-rw-r--r--tests/ui/rfcs/rfc-2497-if-let-chains/issue-93150.stderr2
-rw-r--r--tests/ui/rfcs/rfc-2528-type-changing-struct-update/feature-gate.stderr1
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage-0.qualified.stderr14
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage-0.rs24
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage-1.qualified.stderr14
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage-1.rs27
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage.rs15
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage.stderr22
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type.rs28
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type.stderr22
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/const_derives/derive-const-gate.stderr1
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/effects/ice-112822-expected-type-for-param.stderr1
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/feature-gate.stock.stderr6
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/gate.stderr2
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/hir-const-check.stderr1
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/mbe-const-trait-bound-theoretical-regression.stderr1
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/tilde-const-invalid-places.stderr29
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/tilde-const-trait-assoc-tys.rs18
-rw-r--r--tests/ui/rustdoc/feature-gate-doc_primitive.stderr1
-rw-r--r--tests/ui/self/arbitrary-self-from-method-substs.default.stderr1
-rw-r--r--tests/ui/span/gated-features-attr-spans.stderr1
-rw-r--r--tests/ui/specialization/allow_internal_unstable.rs18
-rw-r--r--tests/ui/specialization/defaultimpl/specialization-feature-gate-default.stderr1
-rw-r--r--tests/ui/specialization/specialization-feature-gate-default.stderr1
-rw-r--r--tests/ui/stability-attribute/accidental-stable-in-unstable.stderr1
-rw-r--r--tests/ui/stability-attribute/allow-unstable-reexport.stderr3
-rw-r--r--tests/ui/stability-attribute/allowed-through-unstable.stderr1
-rw-r--r--tests/ui/stability-attribute/default-body-stability-err.stderr4
-rw-r--r--tests/ui/stability-attribute/generics-default-stability-trait.stderr3
-rw-r--r--tests/ui/stability-attribute/generics-default-stability-where.stderr1
-rw-r--r--tests/ui/stability-attribute/generics-default-stability.stderr28
-rw-r--r--tests/ui/stability-attribute/issue-28075.stderr1
-rw-r--r--tests/ui/stability-attribute/issue-28388-3.stderr1
-rw-r--r--tests/ui/stability-attribute/stability-attribute-implies-no-feature.stderr2
-rw-r--r--tests/ui/stability-attribute/stability-attribute-issue.stderr2
-rw-r--r--tests/ui/stability-attribute/stable-in-unstable.stderr6
-rw-r--r--tests/ui/stability-attribute/suggest-vec-allocator-api.stderr4
-rw-r--r--tests/ui/stmt_expr_attrs_no_feature.stderr9
-rw-r--r--tests/ui/suggestions/fn-trait-notation.stderr3
-rw-r--r--tests/ui/suggestions/impl-trait-missing-lifetime-gated.stderr8
-rw-r--r--tests/ui/suggestions/missing-assoc-fn.stderr1
-rw-r--r--tests/ui/suggestions/type-ascription-instead-of-path-in-type.stderr1
-rw-r--r--tests/ui/target-feature/gate.stderr1
-rw-r--r--tests/ui/target-feature/invalid-attribute.rs2
-rw-r--r--tests/ui/target-feature/invalid-attribute.stderr32
-rw-r--r--tests/ui/thread-local/thread-local-static.stderr2
-rw-r--r--tests/ui/tool-attributes/diagnostic_item.stderr1
-rw-r--r--tests/ui/track-diagnostics/track6.stderr1
-rw-r--r--tests/ui/traits/alias/generic-default-in-dyn.stderr1
-rw-r--r--tests/ui/traits/default-method/rustc_must_implement_one_of_gated.stderr1
-rw-r--r--tests/ui/traits/issue-78372.stderr2
-rw-r--r--tests/ui/traits/method-argument-mismatch-variance-ice-119867.rs13
-rw-r--r--tests/ui/traits/method-argument-mismatch-variance-ice-119867.stderr24
-rw-r--r--tests/ui/traits/negative-impls/feature-gate-negative_impls.stderr1
-rw-r--r--tests/ui/traits/next-solver/dont-ice-on-assoc-projection.stderr1
-rw-r--r--tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response-2.current.stderr11
-rw-r--r--tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response-2.next.stderr11
-rw-r--r--tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response-2.rs23
-rw-r--r--tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response.current.stderr11
-rw-r--r--tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response.next.stderr11
-rw-r--r--tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response.rs27
-rw-r--r--tests/ui/transmutability/malformed-program-gracefulness/feature-missing.stderr2
-rw-r--r--tests/ui/type-alias-impl-trait/issue-60371.stderr1
-rw-r--r--tests/ui/type-alias-impl-trait/nested_inference_failure.rs28
-rw-r--r--tests/ui/type-alias-impl-trait/wf-nested.fail.stderr2
-rw-r--r--tests/ui/type-alias-impl-trait/wf-nested.pass_sound.stderr17
-rw-r--r--tests/ui/type-alias-impl-trait/wf-nested.rs4
-rw-r--r--tests/ui/typeck/issue-105946.stderr1
-rw-r--r--tests/ui/unboxed-closures/unboxed-closure-feature-gate.stderr1
-rw-r--r--tests/ui/unboxed-closures/unboxed-closure-sugar-not-used-on-fn.stderr2
-rw-r--r--tests/ui/unknown-unstable-lints/deny-unstable-lint-command-line.stderr1
-rw-r--r--tests/ui/unknown-unstable-lints/deny-unstable-lint-inline.stderr1
-rw-r--r--tests/ui/unknown-unstable-lints/warn-unknown-unstable-lint-command-line.stderr1
-rw-r--r--tests/ui/unknown-unstable-lints/warn-unknown-unstable-lint-inline.stderr1
-rw-r--r--tests/ui/unsafe/ranged_ints2_const.stderr3
-rw-r--r--tests/ui/unsafe/ranged_ints3_const.stderr2
-rw-r--r--tests/ui/wf/wf-associated-const.rs41
-rw-r--r--tests/ui/wf/wf-associated-const.stderr38
-rw-r--r--tests/ui/wf/wf-in-fn-type-implicit.rs37
-rw-r--r--tests/ui/wf/wf-static-method.rs13
-rw-r--r--tests/ui/wf/wf-static-method.stderr47
660 files changed, 5229 insertions, 1686 deletions
diff --git a/tests/codegen/debuginfo-inline-callsite-location.rs b/tests/codegen/debuginfo-inline-callsite-location.rs
index b1475ee7931..d529f9ccead 100644
--- a/tests/codegen/debuginfo-inline-callsite-location.rs
+++ b/tests/codegen/debuginfo-inline-callsite-location.rs
@@ -4,9 +4,9 @@
 // can correctly merge the debug info if it merges the inlined code (e.g., for merging of tail
 // calls to panic.
 
-// CHECK:       tail call void @_ZN4core9panicking5panic17h{{([0-9a-z]{16})}}E
+// CHECK:       tail call void @_ZN4core6option13unwrap_failed17h{{([0-9a-z]{16})}}E
 // CHECK-SAME:  !dbg ![[#first_dbg:]]
-// CHECK:       tail call void @_ZN4core9panicking5panic17h{{([0-9a-z]{16})}}E
+// CHECK:       tail call void @_ZN4core6option13unwrap_failed17h{{([0-9a-z]{16})}}E
 // CHECK-SAME:  !dbg ![[#second_dbg:]]
 
 // CHECK-DAG:   ![[#func_dbg:]] = distinct !DISubprogram(name: "unwrap<i32>"
diff --git a/tests/codegen/infallible-unwrap-in-opt-z.rs b/tests/codegen/infallible-unwrap-in-opt-z.rs
new file mode 100644
index 00000000000..5c57b41532f
--- /dev/null
+++ b/tests/codegen/infallible-unwrap-in-opt-z.rs
@@ -0,0 +1,26 @@
+// compile-flags: -C opt-level=z --edition=2021
+// ignore-debug
+
+#![crate_type = "lib"]
+
+// From <https://github.com/rust-lang/rust/issues/115463>
+
+// CHECK-LABEL: @read_up_to_8(
+#[no_mangle]
+pub fn read_up_to_8(buf: &[u8]) -> u64 {
+    // CHECK-NOT: unwrap_failed
+    if buf.len() < 4 {
+        // actual instance has more code.
+        return 0;
+    }
+    let lo = u32::from_le_bytes(buf[..4].try_into().unwrap()) as u64;
+    let hi = u32::from_le_bytes(buf[buf.len() - 4..][..4].try_into().unwrap()) as u64;
+    lo | (hi << 8 * (buf.len() as u64 - 4))
+}
+
+// CHECK-LABEL: @checking_unwrap_expectation(
+#[no_mangle]
+pub fn checking_unwrap_expectation(buf: &[u8]) -> &[u8; 4] {
+    // CHECK: call void @_ZN4core6result13unwrap_failed17h
+    buf.try_into().unwrap()
+}
diff --git a/tests/debuginfo/mutex.rs b/tests/debuginfo/mutex.rs
index 61ec6a81243..7a58c5c2224 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::windows::locks::mutex::Mutex]
+// cdb-check:    [...] inner            [Type: std::sys::pal::windows::locks::mutex::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 bc42f92f053..4ed1ebd0b37 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::windows::locks::rwlock::RwLock *]
+// cdb-check:    [...] inner_lock       : [...] [Type: std::sys::pal::windows::locks::rwlock::RwLock *]
 
 #[allow(unused_variables)]
 
diff --git a/tests/mir-opt/const_allocation.main.GVN.after.32bit.mir b/tests/mir-opt/const_allocation.main.GVN.after.32bit.mir
index f089c6741fe..10d99a13463 100644
--- a/tests/mir-opt/const_allocation.main.GVN.after.32bit.mir
+++ b/tests/mir-opt/const_allocation.main.GVN.after.32bit.mir
@@ -7,10 +7,10 @@ fn main() -> () {
 
     bb0: {
         StorageLive(_1);
-        nop;
+        StorageLive(_2);
         _2 = const {ALLOC9: &&[(Option<i32>, &[&str])]};
         _1 = (*_2);
-        nop;
+        StorageDead(_2);
         StorageDead(_1);
         _0 = const ();
         return;
diff --git a/tests/mir-opt/const_allocation.main.GVN.after.64bit.mir b/tests/mir-opt/const_allocation.main.GVN.after.64bit.mir
index 9cbbaf302be..2f23dbe9ee4 100644
--- a/tests/mir-opt/const_allocation.main.GVN.after.64bit.mir
+++ b/tests/mir-opt/const_allocation.main.GVN.after.64bit.mir
@@ -7,10 +7,10 @@ fn main() -> () {
 
     bb0: {
         StorageLive(_1);
-        nop;
+        StorageLive(_2);
         _2 = const {ALLOC9: &&[(Option<i32>, &[&str])]};
         _1 = (*_2);
-        nop;
+        StorageDead(_2);
         StorageDead(_1);
         _0 = const ();
         return;
diff --git a/tests/mir-opt/const_allocation2.main.GVN.after.32bit.mir b/tests/mir-opt/const_allocation2.main.GVN.after.32bit.mir
index dfa2d808128..6499e3676aa 100644
--- a/tests/mir-opt/const_allocation2.main.GVN.after.32bit.mir
+++ b/tests/mir-opt/const_allocation2.main.GVN.after.32bit.mir
@@ -7,10 +7,10 @@ fn main() -> () {
 
     bb0: {
         StorageLive(_1);
-        nop;
+        StorageLive(_2);
         _2 = const {ALLOC9: &&[(Option<i32>, &[&u8])]};
         _1 = (*_2);
-        nop;
+        StorageDead(_2);
         StorageDead(_1);
         _0 = const ();
         return;
diff --git a/tests/mir-opt/const_allocation2.main.GVN.after.64bit.mir b/tests/mir-opt/const_allocation2.main.GVN.after.64bit.mir
index 02b66987169..02f5ebab847 100644
--- a/tests/mir-opt/const_allocation2.main.GVN.after.64bit.mir
+++ b/tests/mir-opt/const_allocation2.main.GVN.after.64bit.mir
@@ -7,10 +7,10 @@ fn main() -> () {
 
     bb0: {
         StorageLive(_1);
-        nop;
+        StorageLive(_2);
         _2 = const {ALLOC9: &&[(Option<i32>, &[&u8])]};
         _1 = (*_2);
-        nop;
+        StorageDead(_2);
         StorageDead(_1);
         _0 = const ();
         return;
diff --git a/tests/mir-opt/const_allocation3.main.GVN.after.32bit.mir b/tests/mir-opt/const_allocation3.main.GVN.after.32bit.mir
index 386a55ee6fa..c95e696946a 100644
--- a/tests/mir-opt/const_allocation3.main.GVN.after.32bit.mir
+++ b/tests/mir-opt/const_allocation3.main.GVN.after.32bit.mir
@@ -7,10 +7,10 @@ fn main() -> () {
 
     bb0: {
         StorageLive(_1);
-        nop;
+        StorageLive(_2);
         _2 = const {ALLOC4: &&Packed};
         _1 = (*_2);
-        nop;
+        StorageDead(_2);
         StorageDead(_1);
         _0 = const ();
         return;
diff --git a/tests/mir-opt/const_allocation3.main.GVN.after.64bit.mir b/tests/mir-opt/const_allocation3.main.GVN.after.64bit.mir
index b9e98f8cd4c..198bc8bd07e 100644
--- a/tests/mir-opt/const_allocation3.main.GVN.after.64bit.mir
+++ b/tests/mir-opt/const_allocation3.main.GVN.after.64bit.mir
@@ -7,10 +7,10 @@ fn main() -> () {
 
     bb0: {
         StorageLive(_1);
-        nop;
+        StorageLive(_2);
         _2 = const {ALLOC2: &&Packed};
         _1 = (*_2);
-        nop;
+        StorageDead(_2);
         StorageDead(_1);
         _0 = const ();
         return;
diff --git a/tests/mir-opt/const_prop/address_of_pair.fn0.GVN.diff b/tests/mir-opt/const_prop/address_of_pair.fn0.GVN.diff
index 2285962fad1..a044cfc62e2 100644
--- a/tests/mir-opt/const_prop/address_of_pair.fn0.GVN.diff
+++ b/tests/mir-opt/const_prop/address_of_pair.fn0.GVN.diff
@@ -24,9 +24,8 @@
       bb0: {
           StorageLive(_2);
 -         _2 = (const 1_i32, const false);
--         StorageLive(_3);
 +         _2 = const (1_i32, false);
-+         nop;
+          StorageLive(_3);
           _3 = &raw mut (_2.1: bool);
 -         _2 = (const 1_i32, const false);
 +         _2 = const (1_i32, false);
@@ -42,9 +41,8 @@
           StorageDead(_6);
           _0 = _5;
 -         StorageDead(_5);
--         StorageDead(_3);
-+         nop;
 +         nop;
+          StorageDead(_3);
           StorageDead(_2);
           return;
       }
diff --git a/tests/mir-opt/const_prop/array_index.main.GVN.32bit.panic-abort.diff b/tests/mir-opt/const_prop/array_index.main.GVN.32bit.panic-abort.diff
index f9537661e8c..6d00dd5b212 100644
--- a/tests/mir-opt/const_prop/array_index.main.GVN.32bit.panic-abort.diff
+++ b/tests/mir-opt/const_prop/array_index.main.GVN.32bit.panic-abort.diff
@@ -18,11 +18,12 @@
           _2 = [const 0_u32, const 1_u32, const 2_u32, const 3_u32];
           StorageLive(_3);
           _3 = const 2_usize;
-          _4 = Len(_2);
+-         _4 = Len(_2);
 -         _5 = Lt(_3, _4);
 -         assert(move _5, "index out of bounds: the length is {} but the index is {}", move _4, _3) -> [success: bb1, unwind unreachable];
-+         _5 = Lt(const 2_usize, _4);
-+         assert(move _5, "index out of bounds: the length is {} but the index is {}", move _4, const 2_usize) -> [success: bb1, unwind unreachable];
++         _4 = const 4_usize;
++         _5 = const true;
++         assert(const true, "index out of bounds: the length is {} but the index is {}", const 4_usize, const 2_usize) -> [success: bb1, unwind unreachable];
       }
   
       bb1: {
diff --git a/tests/mir-opt/const_prop/array_index.main.GVN.32bit.panic-unwind.diff b/tests/mir-opt/const_prop/array_index.main.GVN.32bit.panic-unwind.diff
index 07886779fea..7e2f72ab31b 100644
--- a/tests/mir-opt/const_prop/array_index.main.GVN.32bit.panic-unwind.diff
+++ b/tests/mir-opt/const_prop/array_index.main.GVN.32bit.panic-unwind.diff
@@ -18,11 +18,12 @@
           _2 = [const 0_u32, const 1_u32, const 2_u32, const 3_u32];
           StorageLive(_3);
           _3 = const 2_usize;
-          _4 = Len(_2);
+-         _4 = Len(_2);
 -         _5 = Lt(_3, _4);
 -         assert(move _5, "index out of bounds: the length is {} but the index is {}", move _4, _3) -> [success: bb1, unwind continue];
-+         _5 = Lt(const 2_usize, _4);
-+         assert(move _5, "index out of bounds: the length is {} but the index is {}", move _4, const 2_usize) -> [success: bb1, unwind continue];
++         _4 = const 4_usize;
++         _5 = const true;
++         assert(const true, "index out of bounds: the length is {} but the index is {}", const 4_usize, const 2_usize) -> [success: bb1, unwind continue];
       }
   
       bb1: {
diff --git a/tests/mir-opt/const_prop/array_index.main.GVN.64bit.panic-abort.diff b/tests/mir-opt/const_prop/array_index.main.GVN.64bit.panic-abort.diff
index f9537661e8c..6d00dd5b212 100644
--- a/tests/mir-opt/const_prop/array_index.main.GVN.64bit.panic-abort.diff
+++ b/tests/mir-opt/const_prop/array_index.main.GVN.64bit.panic-abort.diff
@@ -18,11 +18,12 @@
           _2 = [const 0_u32, const 1_u32, const 2_u32, const 3_u32];
           StorageLive(_3);
           _3 = const 2_usize;
-          _4 = Len(_2);
+-         _4 = Len(_2);
 -         _5 = Lt(_3, _4);
 -         assert(move _5, "index out of bounds: the length is {} but the index is {}", move _4, _3) -> [success: bb1, unwind unreachable];
-+         _5 = Lt(const 2_usize, _4);
-+         assert(move _5, "index out of bounds: the length is {} but the index is {}", move _4, const 2_usize) -> [success: bb1, unwind unreachable];
++         _4 = const 4_usize;
++         _5 = const true;
++         assert(const true, "index out of bounds: the length is {} but the index is {}", const 4_usize, const 2_usize) -> [success: bb1, unwind unreachable];
       }
   
       bb1: {
diff --git a/tests/mir-opt/const_prop/array_index.main.GVN.64bit.panic-unwind.diff b/tests/mir-opt/const_prop/array_index.main.GVN.64bit.panic-unwind.diff
index 07886779fea..7e2f72ab31b 100644
--- a/tests/mir-opt/const_prop/array_index.main.GVN.64bit.panic-unwind.diff
+++ b/tests/mir-opt/const_prop/array_index.main.GVN.64bit.panic-unwind.diff
@@ -18,11 +18,12 @@
           _2 = [const 0_u32, const 1_u32, const 2_u32, const 3_u32];
           StorageLive(_3);
           _3 = const 2_usize;
-          _4 = Len(_2);
+-         _4 = Len(_2);
 -         _5 = Lt(_3, _4);
 -         assert(move _5, "index out of bounds: the length is {} but the index is {}", move _4, _3) -> [success: bb1, unwind continue];
-+         _5 = Lt(const 2_usize, _4);
-+         assert(move _5, "index out of bounds: the length is {} but the index is {}", move _4, const 2_usize) -> [success: bb1, unwind continue];
++         _4 = const 4_usize;
++         _5 = const true;
++         assert(const true, "index out of bounds: the length is {} but the index is {}", const 4_usize, const 2_usize) -> [success: bb1, unwind continue];
       }
   
       bb1: {
diff --git a/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-abort.diff b/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-abort.diff
index a42f9291324..e1a93e31446 100644
--- a/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-abort.diff
+++ b/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-abort.diff
@@ -22,18 +22,15 @@
       }
   
       bb0: {
--         StorageLive(_1);
-+         nop;
+          StorageLive(_1);
           StorageLive(_2);
--         StorageLive(_3);
-+         nop;
+          StorageLive(_3);
           _9 = const _;
           _3 = &(*_9);
           _2 = &raw const (*_3);
           _1 = move _2 as *const [i32] (PointerCoercion(Unsize));
           StorageDead(_2);
--         StorageDead(_3);
-+         nop;
+          StorageDead(_3);
           StorageLive(_5);
           StorageLive(_6);
           _6 = const 3_usize;
@@ -50,8 +47,7 @@
           StorageDead(_6);
           _0 = const ();
           StorageDead(_5);
--         StorageDead(_1);
-+         nop;
+          StorageDead(_1);
           return;
       }
   }
diff --git a/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-unwind.diff b/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-unwind.diff
index f2d6de6621b..91999145efb 100644
--- a/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-unwind.diff
+++ b/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-unwind.diff
@@ -22,18 +22,15 @@
       }
   
       bb0: {
--         StorageLive(_1);
-+         nop;
+          StorageLive(_1);
           StorageLive(_2);
--         StorageLive(_3);
-+         nop;
+          StorageLive(_3);
           _9 = const _;
           _3 = &(*_9);
           _2 = &raw const (*_3);
           _1 = move _2 as *const [i32] (PointerCoercion(Unsize));
           StorageDead(_2);
--         StorageDead(_3);
-+         nop;
+          StorageDead(_3);
           StorageLive(_5);
           StorageLive(_6);
           _6 = const 3_usize;
@@ -50,8 +47,7 @@
           StorageDead(_6);
           _0 = const ();
           StorageDead(_5);
--         StorageDead(_1);
-+         nop;
+          StorageDead(_1);
           return;
       }
   }
diff --git a/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-abort.diff b/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-abort.diff
index a42f9291324..e1a93e31446 100644
--- a/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-abort.diff
+++ b/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-abort.diff
@@ -22,18 +22,15 @@
       }
   
       bb0: {
--         StorageLive(_1);
-+         nop;
+          StorageLive(_1);
           StorageLive(_2);
--         StorageLive(_3);
-+         nop;
+          StorageLive(_3);
           _9 = const _;
           _3 = &(*_9);
           _2 = &raw const (*_3);
           _1 = move _2 as *const [i32] (PointerCoercion(Unsize));
           StorageDead(_2);
--         StorageDead(_3);
-+         nop;
+          StorageDead(_3);
           StorageLive(_5);
           StorageLive(_6);
           _6 = const 3_usize;
@@ -50,8 +47,7 @@
           StorageDead(_6);
           _0 = const ();
           StorageDead(_5);
--         StorageDead(_1);
-+         nop;
+          StorageDead(_1);
           return;
       }
   }
diff --git a/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-unwind.diff b/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-unwind.diff
index f2d6de6621b..91999145efb 100644
--- a/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-unwind.diff
+++ b/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-unwind.diff
@@ -22,18 +22,15 @@
       }
   
       bb0: {
--         StorageLive(_1);
-+         nop;
+          StorageLive(_1);
           StorageLive(_2);
--         StorageLive(_3);
-+         nop;
+          StorageLive(_3);
           _9 = const _;
           _3 = &(*_9);
           _2 = &raw const (*_3);
           _1 = move _2 as *const [i32] (PointerCoercion(Unsize));
           StorageDead(_2);
--         StorageDead(_3);
-+         nop;
+          StorageDead(_3);
           StorageLive(_5);
           StorageLive(_6);
           _6 = const 3_usize;
@@ -50,8 +47,7 @@
           StorageDead(_6);
           _0 = const ();
           StorageDead(_5);
--         StorageDead(_1);
-+         nop;
+          StorageDead(_1);
           return;
       }
   }
diff --git a/tests/mir-opt/const_prop/boolean_identities.rs b/tests/mir-opt/const_prop/boolean_identities.rs
index f6575ac8e54..3b7ea25ad46 100644
--- a/tests/mir-opt/const_prop/boolean_identities.rs
+++ b/tests/mir-opt/const_prop/boolean_identities.rs
@@ -5,10 +5,9 @@ pub fn test(x: bool, y: bool) -> bool {
     // CHECK-LABEL: fn test(
     // CHECK: debug a => [[a:_.*]];
     // CHECK: debug b => [[b:_.*]];
-    // FIXME(cjgillot) simplify algebraic identity
-    // CHECK-NOT: [[a]] = const true;
-    // CHECK-NOT: [[b]] = const false;
-    // CHECK-NOT: _0 = const false;
+    // CHECK: [[a]] = const true;
+    // CHECK: [[b]] = const false;
+    // CHECK: _0 = const false;
     let a = (y | true);
     let b = (x & false);
     a & b
diff --git a/tests/mir-opt/const_prop/boolean_identities.test.GVN.diff b/tests/mir-opt/const_prop/boolean_identities.test.GVN.diff
index eca87af7527..0bd8413289e 100644
--- a/tests/mir-opt/const_prop/boolean_identities.test.GVN.diff
+++ b/tests/mir-opt/const_prop/boolean_identities.test.GVN.diff
@@ -24,21 +24,23 @@
           StorageLive(_4);
           _4 = _2;
 -         _3 = BitOr(move _4, const true);
-+         _3 = BitOr(_2, const true);
++         _3 = const true;
           StorageDead(_4);
 -         StorageLive(_5);
 +         nop;
           StorageLive(_6);
           _6 = _1;
 -         _5 = BitAnd(move _6, const false);
-+         _5 = BitAnd(_1, const false);
++         _5 = const false;
           StorageDead(_6);
           StorageLive(_7);
-          _7 = _3;
+-         _7 = _3;
++         _7 = const true;
           StorageLive(_8);
-          _8 = _5;
+-         _8 = _5;
 -         _0 = BitAnd(move _7, move _8);
-+         _0 = BitAnd(_3, _5);
++         _8 = const false;
++         _0 = const false;
           StorageDead(_8);
           StorageDead(_7);
 -         StorageDead(_5);
diff --git a/tests/mir-opt/const_prop/boxes.main.GVN.panic-abort.diff b/tests/mir-opt/const_prop/boxes.main.GVN.panic-abort.diff
index b3fdaa5ee82..59ee38f5a2b 100644
--- a/tests/mir-opt/const_prop/boxes.main.GVN.panic-abort.diff
+++ b/tests/mir-opt/const_prop/boxes.main.GVN.panic-abort.diff
@@ -20,7 +20,8 @@
   
       bb0: {
           StorageLive(_1);
-          StorageLive(_2);
+-         StorageLive(_2);
++         nop;
           StorageLive(_3);
 -         _4 = SizeOf(i32);
 -         _5 = AlignOf(i32);
@@ -39,8 +40,10 @@
           StorageDead(_7);
           _9 = (((_3.0: std::ptr::Unique<i32>).0: std::ptr::NonNull<i32>).0: *const i32);
           _2 = (*_9);
-          _1 = Add(move _2, const 0_i32);
-          StorageDead(_2);
+-         _1 = Add(move _2, const 0_i32);
+-         StorageDead(_2);
++         _1 = _2;
++         nop;
           drop(_3) -> [return: bb2, unwind unreachable];
       }
   
diff --git a/tests/mir-opt/const_prop/boxes.main.GVN.panic-unwind.diff b/tests/mir-opt/const_prop/boxes.main.GVN.panic-unwind.diff
index d0350c97253..9d87bd809d1 100644
--- a/tests/mir-opt/const_prop/boxes.main.GVN.panic-unwind.diff
+++ b/tests/mir-opt/const_prop/boxes.main.GVN.panic-unwind.diff
@@ -20,7 +20,8 @@
   
       bb0: {
           StorageLive(_1);
-          StorageLive(_2);
+-         StorageLive(_2);
++         nop;
           StorageLive(_3);
 -         _4 = SizeOf(i32);
 -         _5 = AlignOf(i32);
@@ -39,8 +40,10 @@
           StorageDead(_7);
           _9 = (((_3.0: std::ptr::Unique<i32>).0: std::ptr::NonNull<i32>).0: *const i32);
           _2 = (*_9);
-          _1 = Add(move _2, const 0_i32);
-          StorageDead(_2);
+-         _1 = Add(move _2, const 0_i32);
+-         StorageDead(_2);
++         _1 = _2;
++         nop;
           drop(_3) -> [return: bb2, unwind: bb3];
       }
   
diff --git a/tests/mir-opt/const_prop/boxes.rs b/tests/mir-opt/const_prop/boxes.rs
index 5227d7b8b8b..d2d61f86d5e 100644
--- a/tests/mir-opt/const_prop/boxes.rs
+++ b/tests/mir-opt/const_prop/boxes.rs
@@ -12,7 +12,7 @@ fn main() {
     // CHECK: debug x => [[x:_.*]];
     // CHECK: (*{{_.*}}) = const 42_i32;
     // CHECK: [[tmp:_.*]] = (*{{_.*}});
-    // CHECK: [[x]] = Add(move [[tmp]], const 0_i32);
+    // CHECK: [[x]] = [[tmp]];
     let x = *(#[rustc_box]
     Box::new(42))
         + 0;
diff --git a/tests/mir-opt/const_prop/indirect_mutation.bar.GVN.diff b/tests/mir-opt/const_prop/indirect_mutation.bar.GVN.diff
index 7dd80d64360..b389080c497 100644
--- a/tests/mir-opt/const_prop/indirect_mutation.bar.GVN.diff
+++ b/tests/mir-opt/const_prop/indirect_mutation.bar.GVN.diff
@@ -22,12 +22,10 @@
 -         _1 = (const 1_i32,);
 +         _1 = const (1_i32,);
           StorageLive(_2);
--         StorageLive(_3);
-+         nop;
+          StorageLive(_3);
           _3 = &raw mut (_1.0: i32);
           (*_3) = const 5_i32;
--         StorageDead(_3);
-+         nop;
+          StorageDead(_3);
           _2 = const ();
           StorageDead(_2);
           StorageLive(_4);
diff --git a/tests/mir-opt/const_prop/indirect_mutation.foo.GVN.diff b/tests/mir-opt/const_prop/indirect_mutation.foo.GVN.diff
index c4b647d9d2d..c21869dece6 100644
--- a/tests/mir-opt/const_prop/indirect_mutation.foo.GVN.diff
+++ b/tests/mir-opt/const_prop/indirect_mutation.foo.GVN.diff
@@ -17,13 +17,11 @@
       bb0: {
           StorageLive(_1);
 -         _1 = (const 1_i32,);
--         StorageLive(_2);
 +         _1 = const (1_i32,);
-+         nop;
+          StorageLive(_2);
           _2 = &mut (_1.0: i32);
           (*_2) = const 5_i32;
--         StorageDead(_2);
-+         nop;
+          StorageDead(_2);
           StorageLive(_3);
           StorageLive(_4);
           _4 = (_1.0: i32);
diff --git a/tests/mir-opt/const_prop/issue_67019.main.GVN.panic-abort.diff b/tests/mir-opt/const_prop/issue_67019.main.GVN.panic-abort.diff
index fc0c8afd4cf..dfab4959516 100644
--- a/tests/mir-opt/const_prop/issue_67019.main.GVN.panic-abort.diff
+++ b/tests/mir-opt/const_prop/issue_67019.main.GVN.panic-abort.diff
@@ -34,9 +34,5 @@
 + 
 + ALLOC1 (size: 2, align: 1) {
 +     01 02                                           │ ..
-+ }
-+ 
-+ ALLOC2 (size: 2, align: 1) {
-+     01 02                                           │ ..
   }
   
diff --git a/tests/mir-opt/const_prop/issue_67019.main.GVN.panic-unwind.diff b/tests/mir-opt/const_prop/issue_67019.main.GVN.panic-unwind.diff
index cf4089598e7..b6d69732316 100644
--- a/tests/mir-opt/const_prop/issue_67019.main.GVN.panic-unwind.diff
+++ b/tests/mir-opt/const_prop/issue_67019.main.GVN.panic-unwind.diff
@@ -34,9 +34,5 @@
 + 
 + ALLOC1 (size: 2, align: 1) {
 +     01 02                                           │ ..
-+ }
-+ 
-+ ALLOC2 (size: 2, align: 1) {
-+     01 02                                           │ ..
   }
   
diff --git a/tests/mir-opt/const_prop/large_array_index.main.GVN.32bit.panic-abort.diff b/tests/mir-opt/const_prop/large_array_index.main.GVN.32bit.panic-abort.diff
index cf36109fdcb..bd987c01ab1 100644
--- a/tests/mir-opt/const_prop/large_array_index.main.GVN.32bit.panic-abort.diff
+++ b/tests/mir-opt/const_prop/large_array_index.main.GVN.32bit.panic-abort.diff
@@ -18,11 +18,12 @@
           _2 = [const 0_u8; 5000];
           StorageLive(_3);
           _3 = const 2_usize;
-          _4 = Len(_2);
+-         _4 = Len(_2);
 -         _5 = Lt(_3, _4);
 -         assert(move _5, "index out of bounds: the length is {} but the index is {}", move _4, _3) -> [success: bb1, unwind unreachable];
-+         _5 = Lt(const 2_usize, _4);
-+         assert(move _5, "index out of bounds: the length is {} but the index is {}", move _4, const 2_usize) -> [success: bb1, unwind unreachable];
++         _4 = const 5000_usize;
++         _5 = const true;
++         assert(const true, "index out of bounds: the length is {} but the index is {}", const 5000_usize, const 2_usize) -> [success: bb1, unwind unreachable];
       }
   
       bb1: {
diff --git a/tests/mir-opt/const_prop/large_array_index.main.GVN.32bit.panic-unwind.diff b/tests/mir-opt/const_prop/large_array_index.main.GVN.32bit.panic-unwind.diff
index 40ed9697180..e9ebef84ae0 100644
--- a/tests/mir-opt/const_prop/large_array_index.main.GVN.32bit.panic-unwind.diff
+++ b/tests/mir-opt/const_prop/large_array_index.main.GVN.32bit.panic-unwind.diff
@@ -18,11 +18,12 @@
           _2 = [const 0_u8; 5000];
           StorageLive(_3);
           _3 = const 2_usize;
-          _4 = Len(_2);
+-         _4 = Len(_2);
 -         _5 = Lt(_3, _4);
 -         assert(move _5, "index out of bounds: the length is {} but the index is {}", move _4, _3) -> [success: bb1, unwind continue];
-+         _5 = Lt(const 2_usize, _4);
-+         assert(move _5, "index out of bounds: the length is {} but the index is {}", move _4, const 2_usize) -> [success: bb1, unwind continue];
++         _4 = const 5000_usize;
++         _5 = const true;
++         assert(const true, "index out of bounds: the length is {} but the index is {}", const 5000_usize, const 2_usize) -> [success: bb1, unwind continue];
       }
   
       bb1: {
diff --git a/tests/mir-opt/const_prop/large_array_index.main.GVN.64bit.panic-abort.diff b/tests/mir-opt/const_prop/large_array_index.main.GVN.64bit.panic-abort.diff
index cf36109fdcb..bd987c01ab1 100644
--- a/tests/mir-opt/const_prop/large_array_index.main.GVN.64bit.panic-abort.diff
+++ b/tests/mir-opt/const_prop/large_array_index.main.GVN.64bit.panic-abort.diff
@@ -18,11 +18,12 @@
           _2 = [const 0_u8; 5000];
           StorageLive(_3);
           _3 = const 2_usize;
-          _4 = Len(_2);
+-         _4 = Len(_2);
 -         _5 = Lt(_3, _4);
 -         assert(move _5, "index out of bounds: the length is {} but the index is {}", move _4, _3) -> [success: bb1, unwind unreachable];
-+         _5 = Lt(const 2_usize, _4);
-+         assert(move _5, "index out of bounds: the length is {} but the index is {}", move _4, const 2_usize) -> [success: bb1, unwind unreachable];
++         _4 = const 5000_usize;
++         _5 = const true;
++         assert(const true, "index out of bounds: the length is {} but the index is {}", const 5000_usize, const 2_usize) -> [success: bb1, unwind unreachable];
       }
   
       bb1: {
diff --git a/tests/mir-opt/const_prop/large_array_index.main.GVN.64bit.panic-unwind.diff b/tests/mir-opt/const_prop/large_array_index.main.GVN.64bit.panic-unwind.diff
index 40ed9697180..e9ebef84ae0 100644
--- a/tests/mir-opt/const_prop/large_array_index.main.GVN.64bit.panic-unwind.diff
+++ b/tests/mir-opt/const_prop/large_array_index.main.GVN.64bit.panic-unwind.diff
@@ -18,11 +18,12 @@
           _2 = [const 0_u8; 5000];
           StorageLive(_3);
           _3 = const 2_usize;
-          _4 = Len(_2);
+-         _4 = Len(_2);
 -         _5 = Lt(_3, _4);
 -         assert(move _5, "index out of bounds: the length is {} but the index is {}", move _4, _3) -> [success: bb1, unwind continue];
-+         _5 = Lt(const 2_usize, _4);
-+         assert(move _5, "index out of bounds: the length is {} but the index is {}", move _4, const 2_usize) -> [success: bb1, unwind continue];
++         _4 = const 5000_usize;
++         _5 = const true;
++         assert(const true, "index out of bounds: the length is {} but the index is {}", const 5000_usize, const 2_usize) -> [success: bb1, unwind continue];
       }
   
       bb1: {
diff --git a/tests/mir-opt/const_prop/mult_by_zero.rs b/tests/mir-opt/const_prop/mult_by_zero.rs
index 2fdb75c3100..b8afaeef43f 100644
--- a/tests/mir-opt/const_prop/mult_by_zero.rs
+++ b/tests/mir-opt/const_prop/mult_by_zero.rs
@@ -3,8 +3,7 @@
 // EMIT_MIR mult_by_zero.test.GVN.diff
 fn test(x: i32) -> i32 {
     // CHECK: fn test(
-    // FIXME(cjgillot) simplify algebraic identity
-    // CHECK-NOT: _0 = const 0_i32;
+    // CHECK: _0 = const 0_i32;
     x * 0
 }
 
diff --git a/tests/mir-opt/const_prop/mult_by_zero.test.GVN.diff b/tests/mir-opt/const_prop/mult_by_zero.test.GVN.diff
index e9fb34749c1..6c2aab45d48 100644
--- a/tests/mir-opt/const_prop/mult_by_zero.test.GVN.diff
+++ b/tests/mir-opt/const_prop/mult_by_zero.test.GVN.diff
@@ -10,7 +10,7 @@
           StorageLive(_2);
           _2 = _1;
 -         _0 = Mul(move _2, const 0_i32);
-+         _0 = Mul(_1, const 0_i32);
++         _0 = const 0_i32;
           StorageDead(_2);
           return;
       }
diff --git a/tests/mir-opt/const_prop/mutable_variable_aggregate_mut_ref.main.GVN.diff b/tests/mir-opt/const_prop/mutable_variable_aggregate_mut_ref.main.GVN.diff
index bc60546cd19..4ed7c985147 100644
--- a/tests/mir-opt/const_prop/mutable_variable_aggregate_mut_ref.main.GVN.diff
+++ b/tests/mir-opt/const_prop/mutable_variable_aggregate_mut_ref.main.GVN.diff
@@ -19,17 +19,15 @@
       bb0: {
           StorageLive(_1);
 -         _1 = (const 42_i32, const 43_i32);
--         StorageLive(_2);
 +         _1 = const (42_i32, 43_i32);
-+         nop;
+          StorageLive(_2);
           _2 = &mut _1;
           ((*_2).1: i32) = const 99_i32;
           StorageLive(_3);
           _3 = _1;
           _0 = const ();
           StorageDead(_3);
--         StorageDead(_2);
-+         nop;
+          StorageDead(_2);
           StorageDead(_1);
           return;
       }
diff --git a/tests/mir-opt/const_prop/mutable_variable_no_prop.main.GVN.diff b/tests/mir-opt/const_prop/mutable_variable_no_prop.main.GVN.diff
index d02c392f6bd..e113f43a56e 100644
--- a/tests/mir-opt/const_prop/mutable_variable_no_prop.main.GVN.diff
+++ b/tests/mir-opt/const_prop/mutable_variable_no_prop.main.GVN.diff
@@ -22,14 +22,12 @@
           _1 = const 42_u32;
           StorageLive(_2);
           StorageLive(_3);
--         StorageLive(_4);
-+         nop;
+          StorageLive(_4);
           _4 = const {ALLOC0: *mut u32};
           _3 = (*_4);
           _1 = move _3;
           StorageDead(_3);
--         StorageDead(_4);
-+         nop;
+          StorageDead(_4);
           _2 = const ();
           StorageDead(_2);
           StorageLive(_5);
diff --git a/tests/mir-opt/const_prop/pointer_expose_address.main.GVN.panic-abort.diff b/tests/mir-opt/const_prop/pointer_expose_address.main.GVN.panic-abort.diff
index 425bc3ff6c1..4e79b3ad599 100644
--- a/tests/mir-opt/const_prop/pointer_expose_address.main.GVN.panic-abort.diff
+++ b/tests/mir-opt/const_prop/pointer_expose_address.main.GVN.panic-abort.diff
@@ -16,14 +16,12 @@
 -         StorageLive(_1);
 +         nop;
           StorageLive(_2);
--         StorageLive(_3);
-+         nop;
+          StorageLive(_3);
           _3 = const _;
           _2 = &raw const (*_3);
           _1 = move _2 as usize (PointerExposeAddress);
           StorageDead(_2);
--         StorageDead(_3);
-+         nop;
+          StorageDead(_3);
           StorageLive(_4);
           StorageLive(_5);
           _5 = _1;
diff --git a/tests/mir-opt/const_prop/pointer_expose_address.main.GVN.panic-unwind.diff b/tests/mir-opt/const_prop/pointer_expose_address.main.GVN.panic-unwind.diff
index e9360ab8d62..fdc459b457c 100644
--- a/tests/mir-opt/const_prop/pointer_expose_address.main.GVN.panic-unwind.diff
+++ b/tests/mir-opt/const_prop/pointer_expose_address.main.GVN.panic-unwind.diff
@@ -16,14 +16,12 @@
 -         StorageLive(_1);
 +         nop;
           StorageLive(_2);
--         StorageLive(_3);
-+         nop;
+          StorageLive(_3);
           _3 = const _;
           _2 = &raw const (*_3);
           _1 = move _2 as usize (PointerExposeAddress);
           StorageDead(_2);
--         StorageDead(_3);
-+         nop;
+          StorageDead(_3);
           StorageLive(_4);
           StorageLive(_5);
           _5 = _1;
diff --git a/tests/mir-opt/const_prop/ref_deref.main.GVN.diff b/tests/mir-opt/const_prop/ref_deref.main.GVN.diff
index 8f9aa20524d..56cbd00025e 100644
--- a/tests/mir-opt/const_prop/ref_deref.main.GVN.diff
+++ b/tests/mir-opt/const_prop/ref_deref.main.GVN.diff
@@ -13,14 +13,12 @@
   
       bb0: {
           StorageLive(_1);
--         StorageLive(_2);
-+         nop;
+          StorageLive(_2);
           _4 = const _;
           _2 = &(*_4);
 -         _1 = (*_2);
--         StorageDead(_2);
 +         _1 = const 4_i32;
-+         nop;
+          StorageDead(_2);
           _0 = const ();
           StorageDead(_1);
           return;
diff --git a/tests/mir-opt/const_prop/ref_deref_project.main.GVN.diff b/tests/mir-opt/const_prop/ref_deref_project.main.GVN.diff
index 8d38888b7d6..d75c0c3b286 100644
--- a/tests/mir-opt/const_prop/ref_deref_project.main.GVN.diff
+++ b/tests/mir-opt/const_prop/ref_deref_project.main.GVN.diff
@@ -13,14 +13,12 @@
   
       bb0: {
           StorageLive(_1);
--         StorageLive(_2);
-+         nop;
+          StorageLive(_2);
           _4 = const _;
           _2 = &((*_4).1: i32);
 -         _1 = (*_2);
--         StorageDead(_2);
 +         _1 = const 5_i32;
-+         nop;
+          StorageDead(_2);
           _0 = const ();
           StorageDead(_1);
           return;
diff --git a/tests/mir-opt/const_prop/repeat.main.GVN.32bit.panic-abort.diff b/tests/mir-opt/const_prop/repeat.main.GVN.32bit.panic-abort.diff
index a52e6e35483..71635b8e9c3 100644
--- a/tests/mir-opt/const_prop/repeat.main.GVN.32bit.panic-abort.diff
+++ b/tests/mir-opt/const_prop/repeat.main.GVN.32bit.panic-abort.diff
@@ -20,11 +20,12 @@
           _3 = [const 42_u32; 8];
           StorageLive(_4);
           _4 = const 2_usize;
-          _5 = Len(_3);
+-         _5 = Len(_3);
 -         _6 = Lt(_4, _5);
 -         assert(move _6, "index out of bounds: the length is {} but the index is {}", move _5, _4) -> [success: bb1, unwind unreachable];
-+         _6 = Lt(const 2_usize, _5);
-+         assert(move _6, "index out of bounds: the length is {} but the index is {}", move _5, const 2_usize) -> [success: bb1, unwind unreachable];
++         _5 = const 8_usize;
++         _6 = const true;
++         assert(const true, "index out of bounds: the length is {} but the index is {}", const 8_usize, const 2_usize) -> [success: bb1, unwind unreachable];
       }
   
       bb1: {
diff --git a/tests/mir-opt/const_prop/repeat.main.GVN.32bit.panic-unwind.diff b/tests/mir-opt/const_prop/repeat.main.GVN.32bit.panic-unwind.diff
index fe0acee71eb..84205028d6d 100644
--- a/tests/mir-opt/const_prop/repeat.main.GVN.32bit.panic-unwind.diff
+++ b/tests/mir-opt/const_prop/repeat.main.GVN.32bit.panic-unwind.diff
@@ -20,11 +20,12 @@
           _3 = [const 42_u32; 8];
           StorageLive(_4);
           _4 = const 2_usize;
-          _5 = Len(_3);
+-         _5 = Len(_3);
 -         _6 = Lt(_4, _5);
 -         assert(move _6, "index out of bounds: the length is {} but the index is {}", move _5, _4) -> [success: bb1, unwind continue];
-+         _6 = Lt(const 2_usize, _5);
-+         assert(move _6, "index out of bounds: the length is {} but the index is {}", move _5, const 2_usize) -> [success: bb1, unwind continue];
++         _5 = const 8_usize;
++         _6 = const true;
++         assert(const true, "index out of bounds: the length is {} but the index is {}", const 8_usize, const 2_usize) -> [success: bb1, unwind continue];
       }
   
       bb1: {
diff --git a/tests/mir-opt/const_prop/repeat.main.GVN.64bit.panic-abort.diff b/tests/mir-opt/const_prop/repeat.main.GVN.64bit.panic-abort.diff
index a52e6e35483..71635b8e9c3 100644
--- a/tests/mir-opt/const_prop/repeat.main.GVN.64bit.panic-abort.diff
+++ b/tests/mir-opt/const_prop/repeat.main.GVN.64bit.panic-abort.diff
@@ -20,11 +20,12 @@
           _3 = [const 42_u32; 8];
           StorageLive(_4);
           _4 = const 2_usize;
-          _5 = Len(_3);
+-         _5 = Len(_3);
 -         _6 = Lt(_4, _5);
 -         assert(move _6, "index out of bounds: the length is {} but the index is {}", move _5, _4) -> [success: bb1, unwind unreachable];
-+         _6 = Lt(const 2_usize, _5);
-+         assert(move _6, "index out of bounds: the length is {} but the index is {}", move _5, const 2_usize) -> [success: bb1, unwind unreachable];
++         _5 = const 8_usize;
++         _6 = const true;
++         assert(const true, "index out of bounds: the length is {} but the index is {}", const 8_usize, const 2_usize) -> [success: bb1, unwind unreachable];
       }
   
       bb1: {
diff --git a/tests/mir-opt/const_prop/repeat.main.GVN.64bit.panic-unwind.diff b/tests/mir-opt/const_prop/repeat.main.GVN.64bit.panic-unwind.diff
index fe0acee71eb..84205028d6d 100644
--- a/tests/mir-opt/const_prop/repeat.main.GVN.64bit.panic-unwind.diff
+++ b/tests/mir-opt/const_prop/repeat.main.GVN.64bit.panic-unwind.diff
@@ -20,11 +20,12 @@
           _3 = [const 42_u32; 8];
           StorageLive(_4);
           _4 = const 2_usize;
-          _5 = Len(_3);
+-         _5 = Len(_3);
 -         _6 = Lt(_4, _5);
 -         assert(move _6, "index out of bounds: the length is {} but the index is {}", move _5, _4) -> [success: bb1, unwind continue];
-+         _6 = Lt(const 2_usize, _5);
-+         assert(move _6, "index out of bounds: the length is {} but the index is {}", move _5, const 2_usize) -> [success: bb1, unwind continue];
++         _5 = const 8_usize;
++         _6 = const true;
++         assert(const true, "index out of bounds: the length is {} but the index is {}", const 8_usize, const 2_usize) -> [success: bb1, unwind continue];
       }
   
       bb1: {
diff --git a/tests/mir-opt/const_prop/slice_len.main.GVN.32bit.panic-abort.diff b/tests/mir-opt/const_prop/slice_len.main.GVN.32bit.panic-abort.diff
index 8b2411e50ab..803be994d9a 100644
--- a/tests/mir-opt/const_prop/slice_len.main.GVN.32bit.panic-abort.diff
+++ b/tests/mir-opt/const_prop/slice_len.main.GVN.32bit.panic-abort.diff
@@ -18,8 +18,7 @@
   
       bb0: {
           StorageLive(_1);
--         StorageLive(_2);
-+         nop;
+          StorageLive(_2);
           StorageLive(_3);
           StorageLive(_4);
           _9 = const _;
@@ -44,8 +43,7 @@
 +         _1 = (*_2)[1 of 2];
           StorageDead(_6);
           StorageDead(_4);
--         StorageDead(_2);
-+         nop;
+          StorageDead(_2);
           _0 = const ();
           StorageDead(_1);
           return;
diff --git a/tests/mir-opt/const_prop/slice_len.main.GVN.32bit.panic-unwind.diff b/tests/mir-opt/const_prop/slice_len.main.GVN.32bit.panic-unwind.diff
index 9b20d243f87..2a20e3eca59 100644
--- a/tests/mir-opt/const_prop/slice_len.main.GVN.32bit.panic-unwind.diff
+++ b/tests/mir-opt/const_prop/slice_len.main.GVN.32bit.panic-unwind.diff
@@ -18,8 +18,7 @@
   
       bb0: {
           StorageLive(_1);
--         StorageLive(_2);
-+         nop;
+          StorageLive(_2);
           StorageLive(_3);
           StorageLive(_4);
           _9 = const _;
@@ -44,8 +43,7 @@
 +         _1 = (*_2)[1 of 2];
           StorageDead(_6);
           StorageDead(_4);
--         StorageDead(_2);
-+         nop;
+          StorageDead(_2);
           _0 = const ();
           StorageDead(_1);
           return;
diff --git a/tests/mir-opt/const_prop/slice_len.main.GVN.64bit.panic-abort.diff b/tests/mir-opt/const_prop/slice_len.main.GVN.64bit.panic-abort.diff
index 8b2411e50ab..803be994d9a 100644
--- a/tests/mir-opt/const_prop/slice_len.main.GVN.64bit.panic-abort.diff
+++ b/tests/mir-opt/const_prop/slice_len.main.GVN.64bit.panic-abort.diff
@@ -18,8 +18,7 @@
   
       bb0: {
           StorageLive(_1);
--         StorageLive(_2);
-+         nop;
+          StorageLive(_2);
           StorageLive(_3);
           StorageLive(_4);
           _9 = const _;
@@ -44,8 +43,7 @@
 +         _1 = (*_2)[1 of 2];
           StorageDead(_6);
           StorageDead(_4);
--         StorageDead(_2);
-+         nop;
+          StorageDead(_2);
           _0 = const ();
           StorageDead(_1);
           return;
diff --git a/tests/mir-opt/const_prop/slice_len.main.GVN.64bit.panic-unwind.diff b/tests/mir-opt/const_prop/slice_len.main.GVN.64bit.panic-unwind.diff
index 9b20d243f87..2a20e3eca59 100644
--- a/tests/mir-opt/const_prop/slice_len.main.GVN.64bit.panic-unwind.diff
+++ b/tests/mir-opt/const_prop/slice_len.main.GVN.64bit.panic-unwind.diff
@@ -18,8 +18,7 @@
   
       bb0: {
           StorageLive(_1);
--         StorageLive(_2);
-+         nop;
+          StorageLive(_2);
           StorageLive(_3);
           StorageLive(_4);
           _9 = const _;
@@ -44,8 +43,7 @@
 +         _1 = (*_2)[1 of 2];
           StorageDead(_6);
           StorageDead(_4);
--         StorageDead(_2);
-+         nop;
+          StorageDead(_2);
           _0 = const ();
           StorageDead(_1);
           return;
diff --git a/tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.32bit.diff b/tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.32bit.diff
index 93dfef96cf1..0ff31b1a981 100644
--- a/tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.32bit.diff
+++ b/tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.32bit.diff
@@ -13,13 +13,12 @@
   
       bb0: {
           StorageLive(_1);
--         StorageLive(_2);
+          StorageLive(_2);
 -         _2 = const 1_usize as &mut Never (Transmute);
-+         nop;
+-         _1 = &mut (*_2);
 +         _2 = const {0x1 as &mut Never};
-          _1 = &mut (*_2);
--         StorageDead(_2);
-+         nop;
++         _1 = const {0x1 as &mut Never};
+          StorageDead(_2);
           unreachable;
       }
   }
diff --git a/tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.64bit.diff b/tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.64bit.diff
index 93dfef96cf1..0ff31b1a981 100644
--- a/tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.64bit.diff
+++ b/tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.64bit.diff
@@ -13,13 +13,12 @@
   
       bb0: {
           StorageLive(_1);
--         StorageLive(_2);
+          StorageLive(_2);
 -         _2 = const 1_usize as &mut Never (Transmute);
-+         nop;
+-         _1 = &mut (*_2);
 +         _2 = const {0x1 as &mut Never};
-          _1 = &mut (*_2);
--         StorageDead(_2);
-+         nop;
++         _1 = const {0x1 as &mut Never};
+          StorageDead(_2);
           unreachable;
       }
   }
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 6925fdb1e70..ffbd97bb545 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
@@ -25,20 +25,21 @@
                           scope 11 (inlined NonNull::<[bool; 0]>::new_unchecked) {
                               debug ptr => _6;
                               let mut _8: *const [bool; 0];
+                              let mut _9: *mut [bool; 0];
                               scope 12 {
                                   scope 13 (inlined NonNull::<T>::new_unchecked::runtime::<[bool; 0]>) {
-                                      debug ptr => _6;
+                                      debug ptr => _9;
                                       scope 14 (inlined std::ptr::mut_ptr::<impl *mut [bool; 0]>::is_null) {
-                                          debug self => _6;
-                                          let mut _9: *mut u8;
+                                          debug self => _9;
+                                          let mut _10: *mut u8;
                                           scope 15 {
                                               scope 16 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null::runtime_impl) {
-                                                  debug ptr => _9;
+                                                  debug ptr => _10;
                                                   scope 17 (inlined std::ptr::mut_ptr::<impl *mut u8>::addr) {
-                                                      debug self => _9;
+                                                      debug self => _10;
                                                       scope 18 {
                                                           scope 19 (inlined std::ptr::mut_ptr::<impl *mut u8>::cast::<()>) {
-                                                              debug self => _9;
+                                                              debug self => _10;
                                                           }
                                                       }
                                                   }
@@ -74,8 +75,10 @@
           StorageDead(_7);
           StorageLive(_8);
           StorageLive(_9);
+          StorageLive(_10);
           _8 = const {0x1 as *mut [bool; 0]} as *const [bool; 0] (PointerCoercion(MutToConstPointer));
           _5 = NonNull::<[bool; 0]> { pointer: _8 };
+          StorageDead(_10);
           StorageDead(_9);
           StorageDead(_8);
           StorageDead(_6);
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 82ad842505c..7b6dcf1972b 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
@@ -25,20 +25,21 @@
                           scope 11 (inlined NonNull::<[bool; 0]>::new_unchecked) {
                               debug ptr => _6;
                               let mut _8: *const [bool; 0];
+                              let mut _9: *mut [bool; 0];
                               scope 12 {
                                   scope 13 (inlined NonNull::<T>::new_unchecked::runtime::<[bool; 0]>) {
-                                      debug ptr => _6;
+                                      debug ptr => _9;
                                       scope 14 (inlined std::ptr::mut_ptr::<impl *mut [bool; 0]>::is_null) {
-                                          debug self => _6;
-                                          let mut _9: *mut u8;
+                                          debug self => _9;
+                                          let mut _10: *mut u8;
                                           scope 15 {
                                               scope 16 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null::runtime_impl) {
-                                                  debug ptr => _9;
+                                                  debug ptr => _10;
                                                   scope 17 (inlined std::ptr::mut_ptr::<impl *mut u8>::addr) {
-                                                      debug self => _9;
+                                                      debug self => _10;
                                                       scope 18 {
                                                           scope 19 (inlined std::ptr::mut_ptr::<impl *mut u8>::cast::<()>) {
-                                                              debug self => _9;
+                                                              debug self => _10;
                                                           }
                                                       }
                                                   }
@@ -74,8 +75,10 @@
           StorageDead(_7);
           StorageLive(_8);
           StorageLive(_9);
+          StorageLive(_10);
           _8 = const {0x1 as *mut [bool; 0]} as *const [bool; 0] (PointerCoercion(MutToConstPointer));
           _5 = NonNull::<[bool; 0]> { pointer: _8 };
+          StorageDead(_10);
           StorageDead(_9);
           StorageDead(_8);
           StorageDead(_6);
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 6925fdb1e70..ffbd97bb545 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
@@ -25,20 +25,21 @@
                           scope 11 (inlined NonNull::<[bool; 0]>::new_unchecked) {
                               debug ptr => _6;
                               let mut _8: *const [bool; 0];
+                              let mut _9: *mut [bool; 0];
                               scope 12 {
                                   scope 13 (inlined NonNull::<T>::new_unchecked::runtime::<[bool; 0]>) {
-                                      debug ptr => _6;
+                                      debug ptr => _9;
                                       scope 14 (inlined std::ptr::mut_ptr::<impl *mut [bool; 0]>::is_null) {
-                                          debug self => _6;
-                                          let mut _9: *mut u8;
+                                          debug self => _9;
+                                          let mut _10: *mut u8;
                                           scope 15 {
                                               scope 16 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null::runtime_impl) {
-                                                  debug ptr => _9;
+                                                  debug ptr => _10;
                                                   scope 17 (inlined std::ptr::mut_ptr::<impl *mut u8>::addr) {
-                                                      debug self => _9;
+                                                      debug self => _10;
                                                       scope 18 {
                                                           scope 19 (inlined std::ptr::mut_ptr::<impl *mut u8>::cast::<()>) {
-                                                              debug self => _9;
+                                                              debug self => _10;
                                                           }
                                                       }
                                                   }
@@ -74,8 +75,10 @@
           StorageDead(_7);
           StorageLive(_8);
           StorageLive(_9);
+          StorageLive(_10);
           _8 = const {0x1 as *mut [bool; 0]} as *const [bool; 0] (PointerCoercion(MutToConstPointer));
           _5 = NonNull::<[bool; 0]> { pointer: _8 };
+          StorageDead(_10);
           StorageDead(_9);
           StorageDead(_8);
           StorageDead(_6);
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 82ad842505c..7b6dcf1972b 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
@@ -25,20 +25,21 @@
                           scope 11 (inlined NonNull::<[bool; 0]>::new_unchecked) {
                               debug ptr => _6;
                               let mut _8: *const [bool; 0];
+                              let mut _9: *mut [bool; 0];
                               scope 12 {
                                   scope 13 (inlined NonNull::<T>::new_unchecked::runtime::<[bool; 0]>) {
-                                      debug ptr => _6;
+                                      debug ptr => _9;
                                       scope 14 (inlined std::ptr::mut_ptr::<impl *mut [bool; 0]>::is_null) {
-                                          debug self => _6;
-                                          let mut _9: *mut u8;
+                                          debug self => _9;
+                                          let mut _10: *mut u8;
                                           scope 15 {
                                               scope 16 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null::runtime_impl) {
-                                                  debug ptr => _9;
+                                                  debug ptr => _10;
                                                   scope 17 (inlined std::ptr::mut_ptr::<impl *mut u8>::addr) {
-                                                      debug self => _9;
+                                                      debug self => _10;
                                                       scope 18 {
                                                           scope 19 (inlined std::ptr::mut_ptr::<impl *mut u8>::cast::<()>) {
-                                                              debug self => _9;
+                                                              debug self => _10;
                                                           }
                                                       }
                                                   }
@@ -74,8 +75,10 @@
           StorageDead(_7);
           StorageLive(_8);
           StorageLive(_9);
+          StorageLive(_10);
           _8 = const {0x1 as *mut [bool; 0]} as *const [bool; 0] (PointerCoercion(MutToConstPointer));
           _5 = NonNull::<[bool; 0]> { pointer: _8 };
+          StorageDead(_10);
           StorageDead(_9);
           StorageDead(_8);
           StorageDead(_6);
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 13545aa464a..df68ce496fd 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
@@ -25,20 +25,21 @@
                           scope 11 (inlined NonNull::<[bool; 0]>::new_unchecked) {
                               debug ptr => _6;
                               let mut _8: *const [bool; 0];
+                              let mut _9: *mut [bool; 0];
                               scope 12 {
                                   scope 13 (inlined NonNull::<T>::new_unchecked::runtime::<[bool; 0]>) {
-                                      debug ptr => _6;
+                                      debug ptr => _9;
                                       scope 14 (inlined std::ptr::mut_ptr::<impl *mut [bool; 0]>::is_null) {
-                                          debug self => _6;
-                                          let mut _9: *mut u8;
+                                          debug self => _9;
+                                          let mut _10: *mut u8;
                                           scope 15 {
                                               scope 16 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null::runtime_impl) {
-                                                  debug ptr => _9;
+                                                  debug ptr => _10;
                                                   scope 17 (inlined std::ptr::mut_ptr::<impl *mut u8>::addr) {
-                                                      debug self => _9;
+                                                      debug self => _10;
                                                       scope 18 {
                                                           scope 19 (inlined std::ptr::mut_ptr::<impl *mut u8>::cast::<()>) {
-                                                              debug self => _9;
+                                                              debug self => _10;
                                                           }
                                                       }
                                                   }
@@ -76,9 +77,11 @@
           StorageDead(_7);
           StorageLive(_8);
           StorageLive(_9);
+          StorageLive(_10);
 -         _8 = _6 as *const [bool; 0] (PointerCoercion(MutToConstPointer));
 +         _8 = const {0x1 as *mut [bool; 0]} as *const [bool; 0] (PointerCoercion(MutToConstPointer));
           _5 = NonNull::<[bool; 0]> { pointer: _8 };
+          StorageDead(_10);
           StorageDead(_9);
           StorageDead(_8);
           StorageDead(_6);
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 bf326915381..e16ea22091e 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
@@ -25,20 +25,21 @@
                           scope 11 (inlined NonNull::<[bool; 0]>::new_unchecked) {
                               debug ptr => _6;
                               let mut _8: *const [bool; 0];
+                              let mut _9: *mut [bool; 0];
                               scope 12 {
                                   scope 13 (inlined NonNull::<T>::new_unchecked::runtime::<[bool; 0]>) {
-                                      debug ptr => _6;
+                                      debug ptr => _9;
                                       scope 14 (inlined std::ptr::mut_ptr::<impl *mut [bool; 0]>::is_null) {
-                                          debug self => _6;
-                                          let mut _9: *mut u8;
+                                          debug self => _9;
+                                          let mut _10: *mut u8;
                                           scope 15 {
                                               scope 16 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null::runtime_impl) {
-                                                  debug ptr => _9;
+                                                  debug ptr => _10;
                                                   scope 17 (inlined std::ptr::mut_ptr::<impl *mut u8>::addr) {
-                                                      debug self => _9;
+                                                      debug self => _10;
                                                       scope 18 {
                                                           scope 19 (inlined std::ptr::mut_ptr::<impl *mut u8>::cast::<()>) {
-                                                              debug self => _9;
+                                                              debug self => _10;
                                                           }
                                                       }
                                                   }
@@ -76,9 +77,11 @@
           StorageDead(_7);
           StorageLive(_8);
           StorageLive(_9);
+          StorageLive(_10);
 -         _8 = _6 as *const [bool; 0] (PointerCoercion(MutToConstPointer));
 +         _8 = const {0x1 as *mut [bool; 0]} as *const [bool; 0] (PointerCoercion(MutToConstPointer));
           _5 = NonNull::<[bool; 0]> { pointer: _8 };
+          StorageDead(_10);
           StorageDead(_9);
           StorageDead(_8);
           StorageDead(_6);
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 13545aa464a..df68ce496fd 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
@@ -25,20 +25,21 @@
                           scope 11 (inlined NonNull::<[bool; 0]>::new_unchecked) {
                               debug ptr => _6;
                               let mut _8: *const [bool; 0];
+                              let mut _9: *mut [bool; 0];
                               scope 12 {
                                   scope 13 (inlined NonNull::<T>::new_unchecked::runtime::<[bool; 0]>) {
-                                      debug ptr => _6;
+                                      debug ptr => _9;
                                       scope 14 (inlined std::ptr::mut_ptr::<impl *mut [bool; 0]>::is_null) {
-                                          debug self => _6;
-                                          let mut _9: *mut u8;
+                                          debug self => _9;
+                                          let mut _10: *mut u8;
                                           scope 15 {
                                               scope 16 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null::runtime_impl) {
-                                                  debug ptr => _9;
+                                                  debug ptr => _10;
                                                   scope 17 (inlined std::ptr::mut_ptr::<impl *mut u8>::addr) {
-                                                      debug self => _9;
+                                                      debug self => _10;
                                                       scope 18 {
                                                           scope 19 (inlined std::ptr::mut_ptr::<impl *mut u8>::cast::<()>) {
-                                                              debug self => _9;
+                                                              debug self => _10;
                                                           }
                                                       }
                                                   }
@@ -76,9 +77,11 @@
           StorageDead(_7);
           StorageLive(_8);
           StorageLive(_9);
+          StorageLive(_10);
 -         _8 = _6 as *const [bool; 0] (PointerCoercion(MutToConstPointer));
 +         _8 = const {0x1 as *mut [bool; 0]} as *const [bool; 0] (PointerCoercion(MutToConstPointer));
           _5 = NonNull::<[bool; 0]> { pointer: _8 };
+          StorageDead(_10);
           StorageDead(_9);
           StorageDead(_8);
           StorageDead(_6);
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 bf326915381..e16ea22091e 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
@@ -25,20 +25,21 @@
                           scope 11 (inlined NonNull::<[bool; 0]>::new_unchecked) {
                               debug ptr => _6;
                               let mut _8: *const [bool; 0];
+                              let mut _9: *mut [bool; 0];
                               scope 12 {
                                   scope 13 (inlined NonNull::<T>::new_unchecked::runtime::<[bool; 0]>) {
-                                      debug ptr => _6;
+                                      debug ptr => _9;
                                       scope 14 (inlined std::ptr::mut_ptr::<impl *mut [bool; 0]>::is_null) {
-                                          debug self => _6;
-                                          let mut _9: *mut u8;
+                                          debug self => _9;
+                                          let mut _10: *mut u8;
                                           scope 15 {
                                               scope 16 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null::runtime_impl) {
-                                                  debug ptr => _9;
+                                                  debug ptr => _10;
                                                   scope 17 (inlined std::ptr::mut_ptr::<impl *mut u8>::addr) {
-                                                      debug self => _9;
+                                                      debug self => _10;
                                                       scope 18 {
                                                           scope 19 (inlined std::ptr::mut_ptr::<impl *mut u8>::cast::<()>) {
-                                                              debug self => _9;
+                                                              debug self => _10;
                                                           }
                                                       }
                                                   }
@@ -76,9 +77,11 @@
           StorageDead(_7);
           StorageLive(_8);
           StorageLive(_9);
+          StorageLive(_10);
 -         _8 = _6 as *const [bool; 0] (PointerCoercion(MutToConstPointer));
 +         _8 = const {0x1 as *mut [bool; 0]} as *const [bool; 0] (PointerCoercion(MutToConstPointer));
           _5 = NonNull::<[bool; 0]> { pointer: _8 };
+          StorageDead(_10);
           StorageDead(_9);
           StorageDead(_8);
           StorageDead(_6);
diff --git a/tests/mir-opt/dead-store-elimination/call_arg_copy.move_packed.DeadStoreElimination.panic-abort.diff b/tests/mir-opt/dead-store-elimination/call_arg_copy.move_packed.DeadStoreElimination-final.panic-abort.diff
index dc0f9073416..07fb8301b9a 100644
--- a/tests/mir-opt/dead-store-elimination/call_arg_copy.move_packed.DeadStoreElimination.panic-abort.diff
+++ b/tests/mir-opt/dead-store-elimination/call_arg_copy.move_packed.DeadStoreElimination-final.panic-abort.diff
@@ -1,5 +1,5 @@
-- // MIR for `move_packed` before DeadStoreElimination
-+ // MIR for `move_packed` after DeadStoreElimination
+- // MIR for `move_packed` before DeadStoreElimination-final
++ // MIR for `move_packed` after DeadStoreElimination-final
   
   fn move_packed(_1: Packed) -> () {
       let mut _0: ();
diff --git a/tests/mir-opt/dead-store-elimination/call_arg_copy.move_packed.DeadStoreElimination.panic-unwind.diff b/tests/mir-opt/dead-store-elimination/call_arg_copy.move_packed.DeadStoreElimination-final.panic-unwind.diff
index 86ef026ec5c..cac3badfa67 100644
--- a/tests/mir-opt/dead-store-elimination/call_arg_copy.move_packed.DeadStoreElimination.panic-unwind.diff
+++ b/tests/mir-opt/dead-store-elimination/call_arg_copy.move_packed.DeadStoreElimination-final.panic-unwind.diff
@@ -1,5 +1,5 @@
-- // MIR for `move_packed` before DeadStoreElimination
-+ // MIR for `move_packed` after DeadStoreElimination
+- // MIR for `move_packed` before DeadStoreElimination-final
++ // MIR for `move_packed` after DeadStoreElimination-final
   
   fn move_packed(_1: Packed) -> () {
       let mut _0: ();
diff --git a/tests/mir-opt/dead-store-elimination/call_arg_copy.move_simple.DeadStoreElimination.panic-abort.diff b/tests/mir-opt/dead-store-elimination/call_arg_copy.move_simple.DeadStoreElimination-final.panic-abort.diff
index 8f799b33f45..f9bc9405d6a 100644
--- a/tests/mir-opt/dead-store-elimination/call_arg_copy.move_simple.DeadStoreElimination.panic-abort.diff
+++ b/tests/mir-opt/dead-store-elimination/call_arg_copy.move_simple.DeadStoreElimination-final.panic-abort.diff
@@ -1,12 +1,12 @@
-- // MIR for `move_simple` before DeadStoreElimination
-+ // MIR for `move_simple` after DeadStoreElimination
+- // MIR for `move_simple` before DeadStoreElimination-final
++ // MIR for `move_simple` after DeadStoreElimination-final
   
   fn move_simple(_1: i32) -> () {
       debug x => _1;
       let mut _0: ();
       let _2: ();
--     let mut _3: i32;
--     let mut _4: i32;
+      let mut _3: i32;
+      let mut _4: i32;
   
       bb0: {
           StorageLive(_2);
diff --git a/tests/mir-opt/dead-store-elimination/call_arg_copy.move_simple.DeadStoreElimination.panic-unwind.diff b/tests/mir-opt/dead-store-elimination/call_arg_copy.move_simple.DeadStoreElimination-final.panic-unwind.diff
index 0551d663b50..efe165422d9 100644
--- a/tests/mir-opt/dead-store-elimination/call_arg_copy.move_simple.DeadStoreElimination.panic-unwind.diff
+++ b/tests/mir-opt/dead-store-elimination/call_arg_copy.move_simple.DeadStoreElimination-final.panic-unwind.diff
@@ -1,12 +1,12 @@
-- // MIR for `move_simple` before DeadStoreElimination
-+ // MIR for `move_simple` after DeadStoreElimination
+- // MIR for `move_simple` before DeadStoreElimination-final
++ // MIR for `move_simple` after DeadStoreElimination-final
   
   fn move_simple(_1: i32) -> () {
       debug x => _1;
       let mut _0: ();
       let _2: ();
--     let mut _3: i32;
--     let mut _4: i32;
+      let mut _3: i32;
+      let mut _4: i32;
   
       bb0: {
           StorageLive(_2);
diff --git a/tests/mir-opt/dead-store-elimination/call_arg_copy.rs b/tests/mir-opt/dead-store-elimination/call_arg_copy.rs
index 490a4aa502c..37b3313f7d0 100644
--- a/tests/mir-opt/dead-store-elimination/call_arg_copy.rs
+++ b/tests/mir-opt/dead-store-elimination/call_arg_copy.rs
@@ -1,6 +1,5 @@
-// skip-filecheck
 // EMIT_MIR_FOR_EACH_PANIC_STRATEGY
-// unit-test: DeadStoreElimination
+// unit-test: DeadStoreElimination-final
 // compile-flags: -Zmir-enable-passes=+CopyProp
 
 #![feature(core_intrinsics)]
@@ -12,8 +11,10 @@ use std::intrinsics::mir::*;
 #[inline(never)]
 fn use_both(_: i32, _: i32) {}
 
-// EMIT_MIR call_arg_copy.move_simple.DeadStoreElimination.diff
+// EMIT_MIR call_arg_copy.move_simple.DeadStoreElimination-final.diff
 fn move_simple(x: i32) {
+    // CHECK-LABEL: fn move_simple(
+    // CHECK: = use_both(_1, move _1)
     use_both(x, x);
 }
 
@@ -23,11 +24,14 @@ struct Packed {
     y: i32,
 }
 
-// EMIT_MIR call_arg_copy.move_packed.DeadStoreElimination.diff
+// EMIT_MIR call_arg_copy.move_packed.DeadStoreElimination-final.diff
 #[custom_mir(dialect = "analysis")]
 fn move_packed(packed: Packed) {
+    // CHECK-LABEL: fn move_packed(
+    // CHECK: = use_both(const 0_i32, (_1.1: i32))
     mir!(
         {
+            // We have a packed struct, verify that the copy is not turned into a move.
             Call(RET = use_both(0, packed.y), ReturnTo(ret), UnwindContinue())
         }
         ret = {
diff --git a/tests/mir-opt/dead-store-elimination/cycle.cycle.DeadStoreElimination.diff b/tests/mir-opt/dead-store-elimination/cycle.cycle.DeadStoreElimination-initial.diff
index cf73358dc52..2766b6ce6a9 100644
--- a/tests/mir-opt/dead-store-elimination/cycle.cycle.DeadStoreElimination.diff
+++ b/tests/mir-opt/dead-store-elimination/cycle.cycle.DeadStoreElimination-initial.diff
@@ -1,10 +1,10 @@
-- // MIR for `cycle` before DeadStoreElimination
-+ // MIR for `cycle` after DeadStoreElimination
+- // MIR for `cycle` before DeadStoreElimination-initial
++ // MIR for `cycle` after DeadStoreElimination-initial
   
   fn cycle(_1: i32, _2: i32, _3: i32) -> () {
       let mut _0: ();
       let mut _4: bool;
--     let mut _5: i32;
+      let mut _5: i32;
   
       bb0: {
           _4 = cond() -> [return: bb1, unwind continue];
@@ -19,6 +19,10 @@
 -         _3 = _2;
 -         _2 = _1;
 -         _1 = _5;
++         nop;
++         nop;
++         nop;
++         nop;
           _4 = cond() -> [return: bb1, unwind continue];
       }
   
diff --git a/tests/mir-opt/dead-store-elimination/cycle.rs b/tests/mir-opt/dead-store-elimination/cycle.rs
index 13e5411275d..e8f566b4aa7 100644
--- a/tests/mir-opt/dead-store-elimination/cycle.rs
+++ b/tests/mir-opt/dead-store-elimination/cycle.rs
@@ -1,9 +1,8 @@
-// skip-filecheck
 // This example is interesting because the non-transitive version of `MaybeLiveLocals` would
 // report that *all* of these stores are live.
 //
 // needs-unwind
-// unit-test: DeadStoreElimination
+// unit-test: DeadStoreElimination-initial
 
 #![feature(core_intrinsics, custom_mir)]
 use std::intrinsics::mir::*;
@@ -13,9 +12,13 @@ fn cond() -> bool {
     false
 }
 
-// EMIT_MIR cycle.cycle.DeadStoreElimination.diff
+// EMIT_MIR cycle.cycle.DeadStoreElimination-initial.diff
 #[custom_mir(dialect = "runtime", phase = "post-cleanup")]
 fn cycle(mut x: i32, mut y: i32, mut z: i32) {
+    // CHECK-LABEL: fn cycle(
+    // CHECK-NOT: {{_.*}} = {{_.*}};
+    // CHECK-NOT: {{_.*}} = move {{_.*}};
+
     // We use custom MIR to avoid generating debuginfo, that would force to preserve writes.
     mir!(
         let condition: bool;
diff --git a/tests/mir-opt/dead-store-elimination/place_mention.main.DeadStoreElimination.diff b/tests/mir-opt/dead-store-elimination/place_mention.main.DeadStoreElimination-initial.diff
index 2130518771a..5a550285871 100644
--- a/tests/mir-opt/dead-store-elimination/place_mention.main.DeadStoreElimination.diff
+++ b/tests/mir-opt/dead-store-elimination/place_mention.main.DeadStoreElimination-initial.diff
@@ -1,5 +1,5 @@
-- // MIR for `main` before DeadStoreElimination
-+ // MIR for `main` after DeadStoreElimination
+- // MIR for `main` before DeadStoreElimination-initial
++ // MIR for `main` after DeadStoreElimination-initial
   
   fn main() -> () {
       let mut _0: ();
diff --git a/tests/mir-opt/dead-store-elimination/place_mention.rs b/tests/mir-opt/dead-store-elimination/place_mention.rs
index 4813cf7ee2b..ae75e622ff7 100644
--- a/tests/mir-opt/dead-store-elimination/place_mention.rs
+++ b/tests/mir-opt/dead-store-elimination/place_mention.rs
@@ -1,10 +1,15 @@
-// skip-filecheck
-// unit-test: DeadStoreElimination
+// Verify that we account for the `PlaceMention` statement as a use of the tuple,
+// and don't remove it as a dead store.
+//
+// unit-test: DeadStoreElimination-initial
 // compile-flags: -Zmir-keep-place-mention
 
-// EMIT_MIR place_mention.main.DeadStoreElimination.diff
+// EMIT_MIR place_mention.main.DeadStoreElimination-initial.diff
 fn main() {
-    // Verify that we account for the `PlaceMention` statement as a use of the tuple,
-    // and don't remove it as a dead store.
+    // CHECK-LABEL: fn main(
+    // CHECK-NOT: PlaceMention(
+    // CHECK: [[tmp:_.*]] =
+    // CHECK-NEXT: PlaceMention([[tmp:_.*]]);
+
     let (_, _) = ("Hello", "World");
 }
diff --git a/tests/mir-opt/dead-store-elimination/provenance_soundness.pointer_to_int.DeadStoreElimination.diff b/tests/mir-opt/dead-store-elimination/provenance_soundness.pointer_to_int.DeadStoreElimination-initial.diff
index 31f727e5fb3..9b0dc6b6af6 100644
--- a/tests/mir-opt/dead-store-elimination/provenance_soundness.pointer_to_int.DeadStoreElimination.diff
+++ b/tests/mir-opt/dead-store-elimination/provenance_soundness.pointer_to_int.DeadStoreElimination-initial.diff
@@ -1,5 +1,5 @@
-- // MIR for `pointer_to_int` before DeadStoreElimination
-+ // MIR for `pointer_to_int` after DeadStoreElimination
+- // MIR for `pointer_to_int` before DeadStoreElimination-initial
++ // MIR for `pointer_to_int` after DeadStoreElimination-initial
   
   fn pointer_to_int(_1: *mut i32) -> () {
       debug p => _1;
diff --git a/tests/mir-opt/dead-store-elimination/provenance_soundness.retags.DeadStoreElimination.diff b/tests/mir-opt/dead-store-elimination/provenance_soundness.retags.DeadStoreElimination-initial.diff
index e1ebc39aacc..ab74d2411bb 100644
--- a/tests/mir-opt/dead-store-elimination/provenance_soundness.retags.DeadStoreElimination.diff
+++ b/tests/mir-opt/dead-store-elimination/provenance_soundness.retags.DeadStoreElimination-initial.diff
@@ -1,5 +1,5 @@
-- // MIR for `retags` before DeadStoreElimination
-+ // MIR for `retags` after DeadStoreElimination
+- // MIR for `retags` before DeadStoreElimination-initial
++ // MIR for `retags` after DeadStoreElimination-initial
   
   fn retags(_1: &mut i32) -> () {
       debug _r => _1;
diff --git a/tests/mir-opt/dead-store-elimination/provenance_soundness.rs b/tests/mir-opt/dead-store-elimination/provenance_soundness.rs
index 24ffbe980eb..916c393b9de 100644
--- a/tests/mir-opt/dead-store-elimination/provenance_soundness.rs
+++ b/tests/mir-opt/dead-store-elimination/provenance_soundness.rs
@@ -1,17 +1,21 @@
-// skip-filecheck
-// unit-test: DeadStoreElimination
-// compile-flags: -Zmir-emit-retag
-
 // Test that we don't remove pointer to int casts or retags
+// unit-test: DeadStoreElimination-initial
+// compile-flags: -Zmir-emit-retag
 
-// EMIT_MIR provenance_soundness.pointer_to_int.DeadStoreElimination.diff
+// EMIT_MIR provenance_soundness.pointer_to_int.DeadStoreElimination-initial.diff
 fn pointer_to_int(p: *mut i32) {
+    // CHECK-LABEL: fn pointer_to_int(
+    // CHECK: {{_.*}} = {{.*}} as usize (PointerExposeAddress);
+    // CHECK: {{_.*}} = {{.*}} as isize (PointerExposeAddress);
     let _x = p as usize;
     let _y = p as isize;
 }
 
-// EMIT_MIR provenance_soundness.retags.DeadStoreElimination.diff
-fn retags(_r: &mut i32) {}
+// EMIT_MIR provenance_soundness.retags.DeadStoreElimination-initial.diff
+fn retags(_r: &mut i32) {
+    // CHECK-LABEL: fn retags(
+    // CHECK: Retag([fn entry] _1);
+}
 
 fn main() {
     pointer_to_int(&mut 5 as *mut _);
diff --git a/tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-abort.diff b/tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-abort.diff
index 993e0f1d1a6..0af3faf28f0 100644
--- a/tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-abort.diff
+++ b/tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-abort.diff
@@ -5,12 +5,13 @@
       let mut _0: ();
       let _1: main::Un;
       let mut _2: u32;
+      let mut _3: u32;
       scope 1 {
           debug un => _1;
           scope 2 {
           }
           scope 4 (inlined std::mem::drop::<u32>) {
-              debug _x => _2;
+              debug _x => _3;
           }
       }
       scope 3 (inlined val) {
@@ -18,10 +19,13 @@
   
       bb0: {
           StorageLive(_1);
-          _1 = Un { us: const 1_u32 };
           StorageLive(_2);
-          _2 = (_1.0: u32);
+          _2 = const 1_u32;
+          _1 = Un { us: const 1_u32 };
           StorageDead(_2);
+          StorageLive(_3);
+          _3 = (_1.0: u32);
+          StorageDead(_3);
           StorageDead(_1);
           return;
       }
diff --git a/tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-unwind.diff b/tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-unwind.diff
index 993e0f1d1a6..0af3faf28f0 100644
--- a/tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-unwind.diff
+++ b/tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-unwind.diff
@@ -5,12 +5,13 @@
       let mut _0: ();
       let _1: main::Un;
       let mut _2: u32;
+      let mut _3: u32;
       scope 1 {
           debug un => _1;
           scope 2 {
           }
           scope 4 (inlined std::mem::drop::<u32>) {
-              debug _x => _2;
+              debug _x => _3;
           }
       }
       scope 3 (inlined val) {
@@ -18,10 +19,13 @@
   
       bb0: {
           StorageLive(_1);
-          _1 = Un { us: const 1_u32 };
           StorageLive(_2);
-          _2 = (_1.0: u32);
+          _2 = const 1_u32;
+          _1 = Un { us: const 1_u32 };
           StorageDead(_2);
+          StorageLive(_3);
+          _3 = (_1.0: u32);
+          StorageDead(_3);
           StorageDead(_1);
           return;
       }
diff --git a/tests/mir-opt/funky_arms.float_to_exponential_common.GVN.panic-abort.diff b/tests/mir-opt/funky_arms.float_to_exponential_common.GVN.panic-abort.diff
index 0ba1bac0a03..080478ea884 100644
--- a/tests/mir-opt/funky_arms.float_to_exponential_common.GVN.panic-abort.diff
+++ b/tests/mir-opt/funky_arms.float_to_exponential_common.GVN.panic-abort.diff
@@ -73,31 +73,59 @@
       }
   
       bb4: {
+-         StorageLive(_8);
++         nop;
           _8 = ((_6 as Some).0: usize);
+          StorageLive(_9);
+          _9 = _1;
+          StorageLive(_10);
+          _10 = _2;
           StorageLive(_11);
           _11 = _5;
           StorageLive(_12);
           StorageLive(_13);
-          _13 = _8 as u32 (IntToInt);
+          StorageLive(_14);
+          _14 = _8;
+-         _13 = move _14 as u32 (IntToInt);
++         _13 = _8 as u32 (IntToInt);
+          StorageDead(_14);
           _12 = Add(move _13, const 1_u32);
           StorageDead(_13);
-          _0 = float_to_exponential_common_exact::<T>(_1, _2, move _11, move _12, _3) -> [return: bb5, unwind unreachable];
+          StorageLive(_15);
+          _15 = _3;
+-         _0 = float_to_exponential_common_exact::<T>(move _9, move _10, move _11, move _12, move _15) -> [return: bb5, unwind unreachable];
++         _0 = float_to_exponential_common_exact::<T>(_1, _2, move _11, move _12, _3) -> [return: bb5, unwind unreachable];
       }
   
       bb5: {
+          StorageDead(_15);
           StorageDead(_12);
           StorageDead(_11);
+          StorageDead(_10);
+          StorageDead(_9);
+-         StorageDead(_8);
++         nop;
           goto -> bb8;
       }
   
       bb6: {
+          StorageLive(_16);
+          _16 = _1;
+          StorageLive(_17);
+          _17 = _2;
           StorageLive(_18);
           _18 = _5;
-          _0 = float_to_exponential_common_shortest::<T>(_1, _2, move _18, _3) -> [return: bb7, unwind unreachable];
+          StorageLive(_19);
+          _19 = _3;
+-         _0 = float_to_exponential_common_shortest::<T>(move _16, move _17, move _18, move _19) -> [return: bb7, unwind unreachable];
++         _0 = float_to_exponential_common_shortest::<T>(_1, _2, move _18, _3) -> [return: bb7, unwind unreachable];
       }
   
       bb7: {
+          StorageDead(_19);
           StorageDead(_18);
+          StorageDead(_17);
+          StorageDead(_16);
           goto -> bb8;
       }
   
diff --git a/tests/mir-opt/funky_arms.float_to_exponential_common.GVN.panic-unwind.diff b/tests/mir-opt/funky_arms.float_to_exponential_common.GVN.panic-unwind.diff
index 27ea43ef12b..ff8933fca8b 100644
--- a/tests/mir-opt/funky_arms.float_to_exponential_common.GVN.panic-unwind.diff
+++ b/tests/mir-opt/funky_arms.float_to_exponential_common.GVN.panic-unwind.diff
@@ -73,31 +73,59 @@
       }
   
       bb4: {
+-         StorageLive(_8);
++         nop;
           _8 = ((_6 as Some).0: usize);
+          StorageLive(_9);
+          _9 = _1;
+          StorageLive(_10);
+          _10 = _2;
           StorageLive(_11);
           _11 = _5;
           StorageLive(_12);
           StorageLive(_13);
-          _13 = _8 as u32 (IntToInt);
+          StorageLive(_14);
+          _14 = _8;
+-         _13 = move _14 as u32 (IntToInt);
++         _13 = _8 as u32 (IntToInt);
+          StorageDead(_14);
           _12 = Add(move _13, const 1_u32);
           StorageDead(_13);
-          _0 = float_to_exponential_common_exact::<T>(_1, _2, move _11, move _12, _3) -> [return: bb5, unwind continue];
+          StorageLive(_15);
+          _15 = _3;
+-         _0 = float_to_exponential_common_exact::<T>(move _9, move _10, move _11, move _12, move _15) -> [return: bb5, unwind continue];
++         _0 = float_to_exponential_common_exact::<T>(_1, _2, move _11, move _12, _3) -> [return: bb5, unwind continue];
       }
   
       bb5: {
+          StorageDead(_15);
           StorageDead(_12);
           StorageDead(_11);
+          StorageDead(_10);
+          StorageDead(_9);
+-         StorageDead(_8);
++         nop;
           goto -> bb8;
       }
   
       bb6: {
+          StorageLive(_16);
+          _16 = _1;
+          StorageLive(_17);
+          _17 = _2;
           StorageLive(_18);
           _18 = _5;
-          _0 = float_to_exponential_common_shortest::<T>(_1, _2, move _18, _3) -> [return: bb7, unwind continue];
+          StorageLive(_19);
+          _19 = _3;
+-         _0 = float_to_exponential_common_shortest::<T>(move _16, move _17, move _18, move _19) -> [return: bb7, unwind continue];
++         _0 = float_to_exponential_common_shortest::<T>(_1, _2, move _18, _3) -> [return: bb7, unwind continue];
       }
   
       bb7: {
+          StorageDead(_19);
           StorageDead(_18);
+          StorageDead(_17);
+          StorageDead(_16);
           goto -> bb8;
       }
   
diff --git a/tests/mir-opt/gvn.arithmetic.GVN.panic-abort.diff b/tests/mir-opt/gvn.arithmetic.GVN.panic-abort.diff
index d524ad242fe..84eb6c5cfe8 100644
--- a/tests/mir-opt/gvn.arithmetic.GVN.panic-abort.diff
+++ b/tests/mir-opt/gvn.arithmetic.GVN.panic-abort.diff
@@ -13,13 +13,13 @@
       let _8: ();
       let mut _9: u64;
       let mut _10: u64;
-      let _11: ();
-      let mut _12: u64;
+      let mut _11: u64;
+      let _12: ();
       let mut _13: u64;
-      let _14: ();
-      let mut _15: u64;
+      let mut _14: u64;
+      let _15: ();
       let mut _16: u64;
-      let mut _17: bool;
+      let mut _17: u64;
       let _18: ();
       let mut _19: u64;
       let mut _20: u64;
@@ -51,18 +51,32 @@
       let _46: ();
       let mut _47: u64;
       let mut _48: u64;
-      let _49: ();
-      let mut _50: u64;
+      let mut _49: bool;
+      let _50: ();
       let mut _51: u64;
-      let _52: ();
-      let mut _53: u64;
+      let mut _52: u64;
+      let _53: ();
       let mut _54: u64;
-      let _55: ();
-      let mut _56: u64;
+      let mut _55: u64;
+      let _56: ();
       let mut _57: u64;
-      let _58: ();
-      let mut _59: u64;
+      let mut _58: u64;
+      let _59: ();
       let mut _60: u64;
+      let mut _61: u64;
+      let _62: ();
+      let mut _63: u64;
+      let mut _64: u64;
+      let _65: ();
+      let mut _66: u64;
+      let mut _67: u64;
+      let mut _68: u64;
+      let _69: ();
+      let mut _70: u64;
+      let mut _71: u64;
+      let _72: ();
+      let mut _73: u64;
+      let mut _74: u64;
   
       bb0: {
           StorageLive(_2);
@@ -70,9 +84,10 @@
           StorageLive(_4);
           _4 = _1;
 -         _3 = Add(move _4, const 0_u64);
-+         _3 = Add(_1, const 0_u64);
++         _3 = _1;
           StorageDead(_4);
-          _2 = opaque::<u64>(move _3) -> [return: bb1, unwind unreachable];
+-         _2 = opaque::<u64>(move _3) -> [return: bb1, unwind unreachable];
++         _2 = opaque::<u64>(_1) -> [return: bb1, unwind unreachable];
       }
   
       bb1: {
@@ -83,98 +98,101 @@
           StorageLive(_7);
           _7 = _1;
 -         _6 = Sub(move _7, const 0_u64);
-+         _6 = Sub(_1, const 0_u64);
++         _6 = _1;
           StorageDead(_7);
-          _5 = opaque::<u64>(move _6) -> [return: bb2, unwind unreachable];
+-         _5 = opaque::<u64>(move _6) -> [return: bb2, unwind unreachable];
++         _5 = opaque::<u64>(_1) -> [return: bb2, unwind unreachable];
       }
   
       bb2: {
           StorageDead(_6);
           StorageDead(_5);
           StorageLive(_8);
-          StorageLive(_9);
+-         StorageLive(_9);
++         nop;
           StorageLive(_10);
           _10 = _1;
--         _9 = Mul(move _10, const 0_u64);
-+         _9 = Mul(_1, const 0_u64);
+          StorageLive(_11);
+          _11 = _1;
+-         _9 = Sub(move _10, move _11);
++         _9 = const 0_u64;
+          StorageDead(_11);
           StorageDead(_10);
-          _8 = opaque::<u64>(move _9) -> [return: bb3, unwind unreachable];
+-         _8 = opaque::<u64>(move _9) -> [return: bb3, unwind unreachable];
++         _8 = opaque::<u64>(const 0_u64) -> [return: bb3, unwind unreachable];
       }
   
       bb3: {
-          StorageDead(_9);
+-         StorageDead(_9);
++         nop;
           StorageDead(_8);
-          StorageLive(_11);
           StorageLive(_12);
           StorageLive(_13);
-          _13 = _1;
--         _12 = Mul(move _13, const 1_u64);
-+         _12 = Mul(_1, const 1_u64);
-          StorageDead(_13);
-          _11 = opaque::<u64>(move _12) -> [return: bb4, unwind unreachable];
+          StorageLive(_14);
+          _14 = _1;
+-         _13 = Mul(move _14, const 0_u64);
++         _13 = const 0_u64;
+          StorageDead(_14);
+-         _12 = opaque::<u64>(move _13) -> [return: bb4, unwind unreachable];
++         _12 = opaque::<u64>(const 0_u64) -> [return: bb4, unwind unreachable];
       }
   
       bb4: {
+          StorageDead(_13);
           StorageDead(_12);
-          StorageDead(_11);
-          StorageLive(_14);
           StorageLive(_15);
           StorageLive(_16);
-          _16 = _1;
--         _17 = Eq(const 0_u64, const 0_u64);
--         assert(!move _17, "attempt to divide `{}` by zero", _16) -> [success: bb5, unwind unreachable];
-+         _17 = const true;
-+         assert(!const true, "attempt to divide `{}` by zero", _1) -> [success: bb5, unwind unreachable];
+          StorageLive(_17);
+          _17 = _1;
+-         _16 = Mul(move _17, const 1_u64);
++         _16 = _1;
+          StorageDead(_17);
+-         _15 = opaque::<u64>(move _16) -> [return: bb5, unwind unreachable];
++         _15 = opaque::<u64>(_1) -> [return: bb5, unwind unreachable];
       }
   
       bb5: {
--         _15 = Div(move _16, const 0_u64);
-+         _15 = Div(_1, const 0_u64);
           StorageDead(_16);
-          _14 = opaque::<u64>(move _15) -> [return: bb6, unwind unreachable];
-      }
-  
-      bb6: {
           StorageDead(_15);
-          StorageDead(_14);
           StorageLive(_18);
           StorageLive(_19);
           StorageLive(_20);
           _20 = _1;
--         _21 = Eq(const 1_u64, const 0_u64);
--         assert(!move _21, "attempt to divide `{}` by zero", _20) -> [success: bb7, unwind unreachable];
-+         _21 = const false;
-+         assert(!const false, "attempt to divide `{}` by zero", _1) -> [success: bb7, unwind unreachable];
+-         _21 = Eq(const 0_u64, const 0_u64);
+-         assert(!move _21, "attempt to divide `{}` by zero", _20) -> [success: bb6, unwind unreachable];
++         _21 = const true;
++         assert(!const true, "attempt to divide `{}` by zero", _1) -> [success: bb6, unwind unreachable];
       }
   
-      bb7: {
--         _19 = Div(move _20, const 1_u64);
-+         _19 = Div(_1, const 1_u64);
+      bb6: {
+-         _19 = Div(move _20, const 0_u64);
++         _19 = Div(_1, const 0_u64);
           StorageDead(_20);
-          _18 = opaque::<u64>(move _19) -> [return: bb8, unwind unreachable];
+          _18 = opaque::<u64>(move _19) -> [return: bb7, unwind unreachable];
       }
   
-      bb8: {
+      bb7: {
           StorageDead(_19);
           StorageDead(_18);
           StorageLive(_22);
           StorageLive(_23);
           StorageLive(_24);
           _24 = _1;
--         _25 = Eq(_24, const 0_u64);
--         assert(!move _25, "attempt to divide `{}` by zero", const 0_u64) -> [success: bb9, unwind unreachable];
-+         _25 = Eq(_1, const 0_u64);
-+         assert(!_25, "attempt to divide `{}` by zero", const 0_u64) -> [success: bb9, unwind unreachable];
+-         _25 = Eq(const 1_u64, const 0_u64);
+-         assert(!move _25, "attempt to divide `{}` by zero", _24) -> [success: bb8, unwind unreachable];
++         _25 = const false;
++         assert(!const false, "attempt to divide `{}` by zero", _1) -> [success: bb8, unwind unreachable];
       }
   
-      bb9: {
--         _23 = Div(const 0_u64, move _24);
-+         _23 = Div(const 0_u64, _1);
+      bb8: {
+-         _23 = Div(move _24, const 1_u64);
++         _23 = _1;
           StorageDead(_24);
-          _22 = opaque::<u64>(move _23) -> [return: bb10, unwind unreachable];
+-         _22 = opaque::<u64>(move _23) -> [return: bb9, unwind unreachable];
++         _22 = opaque::<u64>(_1) -> [return: bb9, unwind unreachable];
       }
   
-      bb10: {
+      bb9: {
           StorageDead(_23);
           StorageDead(_22);
           StorageLive(_26);
@@ -182,79 +200,81 @@
           StorageLive(_28);
           _28 = _1;
 -         _29 = Eq(_28, const 0_u64);
--         assert(!move _29, "attempt to divide `{}` by zero", const 1_u64) -> [success: bb11, unwind unreachable];
-+         _29 = _25;
-+         assert(!_25, "attempt to divide `{}` by zero", const 1_u64) -> [success: bb11, unwind unreachable];
+-         assert(!move _29, "attempt to divide `{}` by zero", const 0_u64) -> [success: bb10, unwind unreachable];
++         _29 = Eq(_1, const 0_u64);
++         assert(!_29, "attempt to divide `{}` by zero", const 0_u64) -> [success: bb10, unwind unreachable];
       }
   
-      bb11: {
--         _27 = Div(const 1_u64, move _28);
-+         _27 = Div(const 1_u64, _1);
+      bb10: {
+-         _27 = Div(const 0_u64, move _28);
++         _27 = const 0_u64;
           StorageDead(_28);
-          _26 = opaque::<u64>(move _27) -> [return: bb12, unwind unreachable];
+-         _26 = opaque::<u64>(move _27) -> [return: bb11, unwind unreachable];
++         _26 = opaque::<u64>(const 0_u64) -> [return: bb11, unwind unreachable];
       }
   
-      bb12: {
+      bb11: {
           StorageDead(_27);
           StorageDead(_26);
           StorageLive(_30);
           StorageLive(_31);
           StorageLive(_32);
           _32 = _1;
--         _33 = Eq(const 0_u64, const 0_u64);
--         assert(!move _33, "attempt to calculate the remainder of `{}` with a divisor of zero", _32) -> [success: bb13, unwind unreachable];
-+         _33 = const true;
-+         assert(!const true, "attempt to calculate the remainder of `{}` with a divisor of zero", _1) -> [success: bb13, unwind unreachable];
+-         _33 = Eq(_32, const 0_u64);
+-         assert(!move _33, "attempt to divide `{}` by zero", const 1_u64) -> [success: bb12, unwind unreachable];
++         _33 = _29;
++         assert(!_29, "attempt to divide `{}` by zero", const 1_u64) -> [success: bb12, unwind unreachable];
       }
   
-      bb13: {
--         _31 = Rem(move _32, const 0_u64);
-+         _31 = Rem(_1, const 0_u64);
+      bb12: {
+-         _31 = Div(const 1_u64, move _32);
++         _31 = Div(const 1_u64, _1);
           StorageDead(_32);
-          _30 = opaque::<u64>(move _31) -> [return: bb14, unwind unreachable];
+          _30 = opaque::<u64>(move _31) -> [return: bb13, unwind unreachable];
       }
   
-      bb14: {
+      bb13: {
           StorageDead(_31);
           StorageDead(_30);
           StorageLive(_34);
           StorageLive(_35);
           StorageLive(_36);
           _36 = _1;
--         _37 = Eq(const 1_u64, const 0_u64);
--         assert(!move _37, "attempt to calculate the remainder of `{}` with a divisor of zero", _36) -> [success: bb15, unwind unreachable];
-+         _37 = const false;
-+         assert(!const false, "attempt to calculate the remainder of `{}` with a divisor of zero", _1) -> [success: bb15, unwind unreachable];
+-         _37 = Eq(const 0_u64, const 0_u64);
+-         assert(!move _37, "attempt to calculate the remainder of `{}` with a divisor of zero", _36) -> [success: bb14, unwind unreachable];
++         _37 = const true;
++         assert(!const true, "attempt to calculate the remainder of `{}` with a divisor of zero", _1) -> [success: bb14, unwind unreachable];
       }
   
-      bb15: {
--         _35 = Rem(move _36, const 1_u64);
-+         _35 = Rem(_1, const 1_u64);
+      bb14: {
+-         _35 = Rem(move _36, const 0_u64);
++         _35 = Rem(_1, const 0_u64);
           StorageDead(_36);
-          _34 = opaque::<u64>(move _35) -> [return: bb16, unwind unreachable];
+          _34 = opaque::<u64>(move _35) -> [return: bb15, unwind unreachable];
       }
   
-      bb16: {
+      bb15: {
           StorageDead(_35);
           StorageDead(_34);
           StorageLive(_38);
           StorageLive(_39);
           StorageLive(_40);
           _40 = _1;
--         _41 = Eq(_40, const 0_u64);
--         assert(!move _41, "attempt to calculate the remainder of `{}` with a divisor of zero", const 0_u64) -> [success: bb17, unwind unreachable];
-+         _41 = _25;
-+         assert(!_25, "attempt to calculate the remainder of `{}` with a divisor of zero", const 0_u64) -> [success: bb17, unwind unreachable];
+-         _41 = Eq(const 1_u64, const 0_u64);
+-         assert(!move _41, "attempt to calculate the remainder of `{}` with a divisor of zero", _40) -> [success: bb16, unwind unreachable];
++         _41 = const false;
++         assert(!const false, "attempt to calculate the remainder of `{}` with a divisor of zero", _1) -> [success: bb16, unwind unreachable];
       }
   
-      bb17: {
--         _39 = Rem(const 0_u64, move _40);
-+         _39 = Rem(const 0_u64, _1);
+      bb16: {
+-         _39 = Rem(move _40, const 1_u64);
++         _39 = const 0_u64;
           StorageDead(_40);
-          _38 = opaque::<u64>(move _39) -> [return: bb18, unwind unreachable];
+-         _38 = opaque::<u64>(move _39) -> [return: bb17, unwind unreachable];
++         _38 = opaque::<u64>(const 0_u64) -> [return: bb17, unwind unreachable];
       }
   
-      bb18: {
+      bb17: {
           StorageDead(_39);
           StorageDead(_38);
           StorageLive(_42);
@@ -262,27 +282,35 @@
           StorageLive(_44);
           _44 = _1;
 -         _45 = Eq(_44, const 0_u64);
--         assert(!move _45, "attempt to calculate the remainder of `{}` with a divisor of zero", const 1_u64) -> [success: bb19, unwind unreachable];
-+         _45 = _25;
-+         assert(!_25, "attempt to calculate the remainder of `{}` with a divisor of zero", const 1_u64) -> [success: bb19, unwind unreachable];
+-         assert(!move _45, "attempt to calculate the remainder of `{}` with a divisor of zero", const 0_u64) -> [success: bb18, unwind unreachable];
++         _45 = _29;
++         assert(!_29, "attempt to calculate the remainder of `{}` with a divisor of zero", const 0_u64) -> [success: bb18, unwind unreachable];
       }
   
-      bb19: {
--         _43 = Rem(const 1_u64, move _44);
-+         _43 = Rem(const 1_u64, _1);
+      bb18: {
+-         _43 = Rem(const 0_u64, move _44);
++         _43 = const 0_u64;
           StorageDead(_44);
-          _42 = opaque::<u64>(move _43) -> [return: bb20, unwind unreachable];
+-         _42 = opaque::<u64>(move _43) -> [return: bb19, unwind unreachable];
++         _42 = opaque::<u64>(const 0_u64) -> [return: bb19, unwind unreachable];
       }
   
-      bb20: {
+      bb19: {
           StorageDead(_43);
           StorageDead(_42);
           StorageLive(_46);
           StorageLive(_47);
           StorageLive(_48);
           _48 = _1;
--         _47 = BitAnd(move _48, const 0_u64);
-+         _47 = BitAnd(_1, const 0_u64);
+-         _49 = Eq(_48, const 0_u64);
+-         assert(!move _49, "attempt to calculate the remainder of `{}` with a divisor of zero", const 1_u64) -> [success: bb20, unwind unreachable];
++         _49 = _29;
++         assert(!_29, "attempt to calculate the remainder of `{}` with a divisor of zero", const 1_u64) -> [success: bb20, unwind unreachable];
+      }
+  
+      bb20: {
+-         _47 = Rem(const 1_u64, move _48);
++         _47 = Rem(const 1_u64, _1);
           StorageDead(_48);
           _46 = opaque::<u64>(move _47) -> [return: bb21, unwind unreachable];
       }
@@ -290,58 +318,121 @@
       bb21: {
           StorageDead(_47);
           StorageDead(_46);
-          StorageLive(_49);
           StorageLive(_50);
           StorageLive(_51);
-          _51 = _1;
--         _50 = BitOr(move _51, const 0_u64);
-+         _50 = BitOr(_1, const 0_u64);
-          StorageDead(_51);
-          _49 = opaque::<u64>(move _50) -> [return: bb22, unwind unreachable];
+          StorageLive(_52);
+          _52 = _1;
+-         _51 = BitAnd(move _52, const 0_u64);
++         _51 = const 0_u64;
+          StorageDead(_52);
+-         _50 = opaque::<u64>(move _51) -> [return: bb22, unwind unreachable];
++         _50 = opaque::<u64>(const 0_u64) -> [return: bb22, unwind unreachable];
       }
   
       bb22: {
+          StorageDead(_51);
           StorageDead(_50);
-          StorageDead(_49);
-          StorageLive(_52);
           StorageLive(_53);
           StorageLive(_54);
-          _54 = _1;
--         _53 = BitXor(move _54, const 0_u64);
-+         _53 = BitXor(_1, const 0_u64);
-          StorageDead(_54);
-          _52 = opaque::<u64>(move _53) -> [return: bb23, unwind unreachable];
+          StorageLive(_55);
+          _55 = _1;
+-         _54 = BitAnd(move _55, const _);
++         _54 = _1;
+          StorageDead(_55);
+-         _53 = opaque::<u64>(move _54) -> [return: bb23, unwind unreachable];
++         _53 = opaque::<u64>(_1) -> [return: bb23, unwind unreachable];
       }
   
       bb23: {
+          StorageDead(_54);
           StorageDead(_53);
-          StorageDead(_52);
-          StorageLive(_55);
           StorageLive(_56);
           StorageLive(_57);
-          _57 = _1;
--         _56 = Shr(move _57, const 0_i32);
-+         _56 = Shr(_1, const 0_i32);
-          StorageDead(_57);
-          _55 = opaque::<u64>(move _56) -> [return: bb24, unwind unreachable];
+          StorageLive(_58);
+          _58 = _1;
+-         _57 = BitOr(move _58, const 0_u64);
++         _57 = _1;
+          StorageDead(_58);
+-         _56 = opaque::<u64>(move _57) -> [return: bb24, unwind unreachable];
++         _56 = opaque::<u64>(_1) -> [return: bb24, unwind unreachable];
       }
   
       bb24: {
+          StorageDead(_57);
           StorageDead(_56);
-          StorageDead(_55);
-          StorageLive(_58);
           StorageLive(_59);
           StorageLive(_60);
-          _60 = _1;
--         _59 = Shl(move _60, const 0_i32);
-+         _59 = Shl(_1, const 0_i32);
-          StorageDead(_60);
-          _58 = opaque::<u64>(move _59) -> [return: bb25, unwind unreachable];
+          StorageLive(_61);
+          _61 = _1;
+-         _60 = BitOr(move _61, const _);
++         _60 = const u64::MAX;
+          StorageDead(_61);
+-         _59 = opaque::<u64>(move _60) -> [return: bb25, unwind unreachable];
++         _59 = opaque::<u64>(const u64::MAX) -> [return: bb25, unwind unreachable];
       }
   
       bb25: {
+          StorageDead(_60);
           StorageDead(_59);
-          StorageDead(_58);
+          StorageLive(_62);
+          StorageLive(_63);
+          StorageLive(_64);
+          _64 = _1;
+-         _63 = BitXor(move _64, const 0_u64);
++         _63 = _1;
+          StorageDead(_64);
+-         _62 = opaque::<u64>(move _63) -> [return: bb26, unwind unreachable];
++         _62 = opaque::<u64>(_1) -> [return: bb26, unwind unreachable];
+      }
+  
+      bb26: {
+          StorageDead(_63);
+          StorageDead(_62);
+          StorageLive(_65);
+          StorageLive(_66);
+          StorageLive(_67);
+          _67 = _1;
+          StorageLive(_68);
+          _68 = _1;
+-         _66 = BitXor(move _67, move _68);
++         _66 = const 0_u64;
+          StorageDead(_68);
+          StorageDead(_67);
+-         _65 = opaque::<u64>(move _66) -> [return: bb27, unwind unreachable];
++         _65 = opaque::<u64>(const 0_u64) -> [return: bb27, unwind unreachable];
+      }
+  
+      bb27: {
+          StorageDead(_66);
+          StorageDead(_65);
+          StorageLive(_69);
+          StorageLive(_70);
+          StorageLive(_71);
+          _71 = _1;
+-         _70 = Shr(move _71, const 0_i32);
++         _70 = _1;
+          StorageDead(_71);
+-         _69 = opaque::<u64>(move _70) -> [return: bb28, unwind unreachable];
++         _69 = opaque::<u64>(_1) -> [return: bb28, unwind unreachable];
+      }
+  
+      bb28: {
+          StorageDead(_70);
+          StorageDead(_69);
+          StorageLive(_72);
+          StorageLive(_73);
+          StorageLive(_74);
+          _74 = _1;
+-         _73 = Shl(move _74, const 0_i32);
++         _73 = _1;
+          StorageDead(_74);
+-         _72 = opaque::<u64>(move _73) -> [return: bb29, unwind unreachable];
++         _72 = opaque::<u64>(_1) -> [return: bb29, unwind unreachable];
+      }
+  
+      bb29: {
+          StorageDead(_73);
+          StorageDead(_72);
           _0 = const ();
           return;
       }
diff --git a/tests/mir-opt/gvn.arithmetic.GVN.panic-unwind.diff b/tests/mir-opt/gvn.arithmetic.GVN.panic-unwind.diff
index 9d69353934c..98e92d2a310 100644
--- a/tests/mir-opt/gvn.arithmetic.GVN.panic-unwind.diff
+++ b/tests/mir-opt/gvn.arithmetic.GVN.panic-unwind.diff
@@ -13,13 +13,13 @@
       let _8: ();
       let mut _9: u64;
       let mut _10: u64;
-      let _11: ();
-      let mut _12: u64;
+      let mut _11: u64;
+      let _12: ();
       let mut _13: u64;
-      let _14: ();
-      let mut _15: u64;
+      let mut _14: u64;
+      let _15: ();
       let mut _16: u64;
-      let mut _17: bool;
+      let mut _17: u64;
       let _18: ();
       let mut _19: u64;
       let mut _20: u64;
@@ -51,18 +51,32 @@
       let _46: ();
       let mut _47: u64;
       let mut _48: u64;
-      let _49: ();
-      let mut _50: u64;
+      let mut _49: bool;
+      let _50: ();
       let mut _51: u64;
-      let _52: ();
-      let mut _53: u64;
+      let mut _52: u64;
+      let _53: ();
       let mut _54: u64;
-      let _55: ();
-      let mut _56: u64;
+      let mut _55: u64;
+      let _56: ();
       let mut _57: u64;
-      let _58: ();
-      let mut _59: u64;
+      let mut _58: u64;
+      let _59: ();
       let mut _60: u64;
+      let mut _61: u64;
+      let _62: ();
+      let mut _63: u64;
+      let mut _64: u64;
+      let _65: ();
+      let mut _66: u64;
+      let mut _67: u64;
+      let mut _68: u64;
+      let _69: ();
+      let mut _70: u64;
+      let mut _71: u64;
+      let _72: ();
+      let mut _73: u64;
+      let mut _74: u64;
   
       bb0: {
           StorageLive(_2);
@@ -70,9 +84,10 @@
           StorageLive(_4);
           _4 = _1;
 -         _3 = Add(move _4, const 0_u64);
-+         _3 = Add(_1, const 0_u64);
++         _3 = _1;
           StorageDead(_4);
-          _2 = opaque::<u64>(move _3) -> [return: bb1, unwind continue];
+-         _2 = opaque::<u64>(move _3) -> [return: bb1, unwind continue];
++         _2 = opaque::<u64>(_1) -> [return: bb1, unwind continue];
       }
   
       bb1: {
@@ -83,98 +98,101 @@
           StorageLive(_7);
           _7 = _1;
 -         _6 = Sub(move _7, const 0_u64);
-+         _6 = Sub(_1, const 0_u64);
++         _6 = _1;
           StorageDead(_7);
-          _5 = opaque::<u64>(move _6) -> [return: bb2, unwind continue];
+-         _5 = opaque::<u64>(move _6) -> [return: bb2, unwind continue];
++         _5 = opaque::<u64>(_1) -> [return: bb2, unwind continue];
       }
   
       bb2: {
           StorageDead(_6);
           StorageDead(_5);
           StorageLive(_8);
-          StorageLive(_9);
+-         StorageLive(_9);
++         nop;
           StorageLive(_10);
           _10 = _1;
--         _9 = Mul(move _10, const 0_u64);
-+         _9 = Mul(_1, const 0_u64);
+          StorageLive(_11);
+          _11 = _1;
+-         _9 = Sub(move _10, move _11);
++         _9 = const 0_u64;
+          StorageDead(_11);
           StorageDead(_10);
-          _8 = opaque::<u64>(move _9) -> [return: bb3, unwind continue];
+-         _8 = opaque::<u64>(move _9) -> [return: bb3, unwind continue];
++         _8 = opaque::<u64>(const 0_u64) -> [return: bb3, unwind continue];
       }
   
       bb3: {
-          StorageDead(_9);
+-         StorageDead(_9);
++         nop;
           StorageDead(_8);
-          StorageLive(_11);
           StorageLive(_12);
           StorageLive(_13);
-          _13 = _1;
--         _12 = Mul(move _13, const 1_u64);
-+         _12 = Mul(_1, const 1_u64);
-          StorageDead(_13);
-          _11 = opaque::<u64>(move _12) -> [return: bb4, unwind continue];
+          StorageLive(_14);
+          _14 = _1;
+-         _13 = Mul(move _14, const 0_u64);
++         _13 = const 0_u64;
+          StorageDead(_14);
+-         _12 = opaque::<u64>(move _13) -> [return: bb4, unwind continue];
++         _12 = opaque::<u64>(const 0_u64) -> [return: bb4, unwind continue];
       }
   
       bb4: {
+          StorageDead(_13);
           StorageDead(_12);
-          StorageDead(_11);
-          StorageLive(_14);
           StorageLive(_15);
           StorageLive(_16);
-          _16 = _1;
--         _17 = Eq(const 0_u64, const 0_u64);
--         assert(!move _17, "attempt to divide `{}` by zero", _16) -> [success: bb5, unwind continue];
-+         _17 = const true;
-+         assert(!const true, "attempt to divide `{}` by zero", _1) -> [success: bb5, unwind continue];
+          StorageLive(_17);
+          _17 = _1;
+-         _16 = Mul(move _17, const 1_u64);
++         _16 = _1;
+          StorageDead(_17);
+-         _15 = opaque::<u64>(move _16) -> [return: bb5, unwind continue];
++         _15 = opaque::<u64>(_1) -> [return: bb5, unwind continue];
       }
   
       bb5: {
--         _15 = Div(move _16, const 0_u64);
-+         _15 = Div(_1, const 0_u64);
           StorageDead(_16);
-          _14 = opaque::<u64>(move _15) -> [return: bb6, unwind continue];
-      }
-  
-      bb6: {
           StorageDead(_15);
-          StorageDead(_14);
           StorageLive(_18);
           StorageLive(_19);
           StorageLive(_20);
           _20 = _1;
--         _21 = Eq(const 1_u64, const 0_u64);
--         assert(!move _21, "attempt to divide `{}` by zero", _20) -> [success: bb7, unwind continue];
-+         _21 = const false;
-+         assert(!const false, "attempt to divide `{}` by zero", _1) -> [success: bb7, unwind continue];
+-         _21 = Eq(const 0_u64, const 0_u64);
+-         assert(!move _21, "attempt to divide `{}` by zero", _20) -> [success: bb6, unwind continue];
++         _21 = const true;
++         assert(!const true, "attempt to divide `{}` by zero", _1) -> [success: bb6, unwind continue];
       }
   
-      bb7: {
--         _19 = Div(move _20, const 1_u64);
-+         _19 = Div(_1, const 1_u64);
+      bb6: {
+-         _19 = Div(move _20, const 0_u64);
++         _19 = Div(_1, const 0_u64);
           StorageDead(_20);
-          _18 = opaque::<u64>(move _19) -> [return: bb8, unwind continue];
+          _18 = opaque::<u64>(move _19) -> [return: bb7, unwind continue];
       }
   
-      bb8: {
+      bb7: {
           StorageDead(_19);
           StorageDead(_18);
           StorageLive(_22);
           StorageLive(_23);
           StorageLive(_24);
           _24 = _1;
--         _25 = Eq(_24, const 0_u64);
--         assert(!move _25, "attempt to divide `{}` by zero", const 0_u64) -> [success: bb9, unwind continue];
-+         _25 = Eq(_1, const 0_u64);
-+         assert(!_25, "attempt to divide `{}` by zero", const 0_u64) -> [success: bb9, unwind continue];
+-         _25 = Eq(const 1_u64, const 0_u64);
+-         assert(!move _25, "attempt to divide `{}` by zero", _24) -> [success: bb8, unwind continue];
++         _25 = const false;
++         assert(!const false, "attempt to divide `{}` by zero", _1) -> [success: bb8, unwind continue];
       }
   
-      bb9: {
--         _23 = Div(const 0_u64, move _24);
-+         _23 = Div(const 0_u64, _1);
+      bb8: {
+-         _23 = Div(move _24, const 1_u64);
++         _23 = _1;
           StorageDead(_24);
-          _22 = opaque::<u64>(move _23) -> [return: bb10, unwind continue];
+-         _22 = opaque::<u64>(move _23) -> [return: bb9, unwind continue];
++         _22 = opaque::<u64>(_1) -> [return: bb9, unwind continue];
       }
   
-      bb10: {
+      bb9: {
           StorageDead(_23);
           StorageDead(_22);
           StorageLive(_26);
@@ -182,79 +200,81 @@
           StorageLive(_28);
           _28 = _1;
 -         _29 = Eq(_28, const 0_u64);
--         assert(!move _29, "attempt to divide `{}` by zero", const 1_u64) -> [success: bb11, unwind continue];
-+         _29 = _25;
-+         assert(!_25, "attempt to divide `{}` by zero", const 1_u64) -> [success: bb11, unwind continue];
+-         assert(!move _29, "attempt to divide `{}` by zero", const 0_u64) -> [success: bb10, unwind continue];
++         _29 = Eq(_1, const 0_u64);
++         assert(!_29, "attempt to divide `{}` by zero", const 0_u64) -> [success: bb10, unwind continue];
       }
   
-      bb11: {
--         _27 = Div(const 1_u64, move _28);
-+         _27 = Div(const 1_u64, _1);
+      bb10: {
+-         _27 = Div(const 0_u64, move _28);
++         _27 = const 0_u64;
           StorageDead(_28);
-          _26 = opaque::<u64>(move _27) -> [return: bb12, unwind continue];
+-         _26 = opaque::<u64>(move _27) -> [return: bb11, unwind continue];
++         _26 = opaque::<u64>(const 0_u64) -> [return: bb11, unwind continue];
       }
   
-      bb12: {
+      bb11: {
           StorageDead(_27);
           StorageDead(_26);
           StorageLive(_30);
           StorageLive(_31);
           StorageLive(_32);
           _32 = _1;
--         _33 = Eq(const 0_u64, const 0_u64);
--         assert(!move _33, "attempt to calculate the remainder of `{}` with a divisor of zero", _32) -> [success: bb13, unwind continue];
-+         _33 = const true;
-+         assert(!const true, "attempt to calculate the remainder of `{}` with a divisor of zero", _1) -> [success: bb13, unwind continue];
+-         _33 = Eq(_32, const 0_u64);
+-         assert(!move _33, "attempt to divide `{}` by zero", const 1_u64) -> [success: bb12, unwind continue];
++         _33 = _29;
++         assert(!_29, "attempt to divide `{}` by zero", const 1_u64) -> [success: bb12, unwind continue];
       }
   
-      bb13: {
--         _31 = Rem(move _32, const 0_u64);
-+         _31 = Rem(_1, const 0_u64);
+      bb12: {
+-         _31 = Div(const 1_u64, move _32);
++         _31 = Div(const 1_u64, _1);
           StorageDead(_32);
-          _30 = opaque::<u64>(move _31) -> [return: bb14, unwind continue];
+          _30 = opaque::<u64>(move _31) -> [return: bb13, unwind continue];
       }
   
-      bb14: {
+      bb13: {
           StorageDead(_31);
           StorageDead(_30);
           StorageLive(_34);
           StorageLive(_35);
           StorageLive(_36);
           _36 = _1;
--         _37 = Eq(const 1_u64, const 0_u64);
--         assert(!move _37, "attempt to calculate the remainder of `{}` with a divisor of zero", _36) -> [success: bb15, unwind continue];
-+         _37 = const false;
-+         assert(!const false, "attempt to calculate the remainder of `{}` with a divisor of zero", _1) -> [success: bb15, unwind continue];
+-         _37 = Eq(const 0_u64, const 0_u64);
+-         assert(!move _37, "attempt to calculate the remainder of `{}` with a divisor of zero", _36) -> [success: bb14, unwind continue];
++         _37 = const true;
++         assert(!const true, "attempt to calculate the remainder of `{}` with a divisor of zero", _1) -> [success: bb14, unwind continue];
       }
   
-      bb15: {
--         _35 = Rem(move _36, const 1_u64);
-+         _35 = Rem(_1, const 1_u64);
+      bb14: {
+-         _35 = Rem(move _36, const 0_u64);
++         _35 = Rem(_1, const 0_u64);
           StorageDead(_36);
-          _34 = opaque::<u64>(move _35) -> [return: bb16, unwind continue];
+          _34 = opaque::<u64>(move _35) -> [return: bb15, unwind continue];
       }
   
-      bb16: {
+      bb15: {
           StorageDead(_35);
           StorageDead(_34);
           StorageLive(_38);
           StorageLive(_39);
           StorageLive(_40);
           _40 = _1;
--         _41 = Eq(_40, const 0_u64);
--         assert(!move _41, "attempt to calculate the remainder of `{}` with a divisor of zero", const 0_u64) -> [success: bb17, unwind continue];
-+         _41 = _25;
-+         assert(!_25, "attempt to calculate the remainder of `{}` with a divisor of zero", const 0_u64) -> [success: bb17, unwind continue];
+-         _41 = Eq(const 1_u64, const 0_u64);
+-         assert(!move _41, "attempt to calculate the remainder of `{}` with a divisor of zero", _40) -> [success: bb16, unwind continue];
++         _41 = const false;
++         assert(!const false, "attempt to calculate the remainder of `{}` with a divisor of zero", _1) -> [success: bb16, unwind continue];
       }
   
-      bb17: {
--         _39 = Rem(const 0_u64, move _40);
-+         _39 = Rem(const 0_u64, _1);
+      bb16: {
+-         _39 = Rem(move _40, const 1_u64);
++         _39 = const 0_u64;
           StorageDead(_40);
-          _38 = opaque::<u64>(move _39) -> [return: bb18, unwind continue];
+-         _38 = opaque::<u64>(move _39) -> [return: bb17, unwind continue];
++         _38 = opaque::<u64>(const 0_u64) -> [return: bb17, unwind continue];
       }
   
-      bb18: {
+      bb17: {
           StorageDead(_39);
           StorageDead(_38);
           StorageLive(_42);
@@ -262,27 +282,35 @@
           StorageLive(_44);
           _44 = _1;
 -         _45 = Eq(_44, const 0_u64);
--         assert(!move _45, "attempt to calculate the remainder of `{}` with a divisor of zero", const 1_u64) -> [success: bb19, unwind continue];
-+         _45 = _25;
-+         assert(!_25, "attempt to calculate the remainder of `{}` with a divisor of zero", const 1_u64) -> [success: bb19, unwind continue];
+-         assert(!move _45, "attempt to calculate the remainder of `{}` with a divisor of zero", const 0_u64) -> [success: bb18, unwind continue];
++         _45 = _29;
++         assert(!_29, "attempt to calculate the remainder of `{}` with a divisor of zero", const 0_u64) -> [success: bb18, unwind continue];
       }
   
-      bb19: {
--         _43 = Rem(const 1_u64, move _44);
-+         _43 = Rem(const 1_u64, _1);
+      bb18: {
+-         _43 = Rem(const 0_u64, move _44);
++         _43 = const 0_u64;
           StorageDead(_44);
-          _42 = opaque::<u64>(move _43) -> [return: bb20, unwind continue];
+-         _42 = opaque::<u64>(move _43) -> [return: bb19, unwind continue];
++         _42 = opaque::<u64>(const 0_u64) -> [return: bb19, unwind continue];
       }
   
-      bb20: {
+      bb19: {
           StorageDead(_43);
           StorageDead(_42);
           StorageLive(_46);
           StorageLive(_47);
           StorageLive(_48);
           _48 = _1;
--         _47 = BitAnd(move _48, const 0_u64);
-+         _47 = BitAnd(_1, const 0_u64);
+-         _49 = Eq(_48, const 0_u64);
+-         assert(!move _49, "attempt to calculate the remainder of `{}` with a divisor of zero", const 1_u64) -> [success: bb20, unwind continue];
++         _49 = _29;
++         assert(!_29, "attempt to calculate the remainder of `{}` with a divisor of zero", const 1_u64) -> [success: bb20, unwind continue];
+      }
+  
+      bb20: {
+-         _47 = Rem(const 1_u64, move _48);
++         _47 = Rem(const 1_u64, _1);
           StorageDead(_48);
           _46 = opaque::<u64>(move _47) -> [return: bb21, unwind continue];
       }
@@ -290,58 +318,121 @@
       bb21: {
           StorageDead(_47);
           StorageDead(_46);
-          StorageLive(_49);
           StorageLive(_50);
           StorageLive(_51);
-          _51 = _1;
--         _50 = BitOr(move _51, const 0_u64);
-+         _50 = BitOr(_1, const 0_u64);
-          StorageDead(_51);
-          _49 = opaque::<u64>(move _50) -> [return: bb22, unwind continue];
+          StorageLive(_52);
+          _52 = _1;
+-         _51 = BitAnd(move _52, const 0_u64);
++         _51 = const 0_u64;
+          StorageDead(_52);
+-         _50 = opaque::<u64>(move _51) -> [return: bb22, unwind continue];
++         _50 = opaque::<u64>(const 0_u64) -> [return: bb22, unwind continue];
       }
   
       bb22: {
+          StorageDead(_51);
           StorageDead(_50);
-          StorageDead(_49);
-          StorageLive(_52);
           StorageLive(_53);
           StorageLive(_54);
-          _54 = _1;
--         _53 = BitXor(move _54, const 0_u64);
-+         _53 = BitXor(_1, const 0_u64);
-          StorageDead(_54);
-          _52 = opaque::<u64>(move _53) -> [return: bb23, unwind continue];
+          StorageLive(_55);
+          _55 = _1;
+-         _54 = BitAnd(move _55, const _);
++         _54 = _1;
+          StorageDead(_55);
+-         _53 = opaque::<u64>(move _54) -> [return: bb23, unwind continue];
++         _53 = opaque::<u64>(_1) -> [return: bb23, unwind continue];
       }
   
       bb23: {
+          StorageDead(_54);
           StorageDead(_53);
-          StorageDead(_52);
-          StorageLive(_55);
           StorageLive(_56);
           StorageLive(_57);
-          _57 = _1;
--         _56 = Shr(move _57, const 0_i32);
-+         _56 = Shr(_1, const 0_i32);
-          StorageDead(_57);
-          _55 = opaque::<u64>(move _56) -> [return: bb24, unwind continue];
+          StorageLive(_58);
+          _58 = _1;
+-         _57 = BitOr(move _58, const 0_u64);
++         _57 = _1;
+          StorageDead(_58);
+-         _56 = opaque::<u64>(move _57) -> [return: bb24, unwind continue];
++         _56 = opaque::<u64>(_1) -> [return: bb24, unwind continue];
       }
   
       bb24: {
+          StorageDead(_57);
           StorageDead(_56);
-          StorageDead(_55);
-          StorageLive(_58);
           StorageLive(_59);
           StorageLive(_60);
-          _60 = _1;
--         _59 = Shl(move _60, const 0_i32);
-+         _59 = Shl(_1, const 0_i32);
-          StorageDead(_60);
-          _58 = opaque::<u64>(move _59) -> [return: bb25, unwind continue];
+          StorageLive(_61);
+          _61 = _1;
+-         _60 = BitOr(move _61, const _);
++         _60 = const u64::MAX;
+          StorageDead(_61);
+-         _59 = opaque::<u64>(move _60) -> [return: bb25, unwind continue];
++         _59 = opaque::<u64>(const u64::MAX) -> [return: bb25, unwind continue];
       }
   
       bb25: {
+          StorageDead(_60);
           StorageDead(_59);
-          StorageDead(_58);
+          StorageLive(_62);
+          StorageLive(_63);
+          StorageLive(_64);
+          _64 = _1;
+-         _63 = BitXor(move _64, const 0_u64);
++         _63 = _1;
+          StorageDead(_64);
+-         _62 = opaque::<u64>(move _63) -> [return: bb26, unwind continue];
++         _62 = opaque::<u64>(_1) -> [return: bb26, unwind continue];
+      }
+  
+      bb26: {
+          StorageDead(_63);
+          StorageDead(_62);
+          StorageLive(_65);
+          StorageLive(_66);
+          StorageLive(_67);
+          _67 = _1;
+          StorageLive(_68);
+          _68 = _1;
+-         _66 = BitXor(move _67, move _68);
++         _66 = const 0_u64;
+          StorageDead(_68);
+          StorageDead(_67);
+-         _65 = opaque::<u64>(move _66) -> [return: bb27, unwind continue];
++         _65 = opaque::<u64>(const 0_u64) -> [return: bb27, unwind continue];
+      }
+  
+      bb27: {
+          StorageDead(_66);
+          StorageDead(_65);
+          StorageLive(_69);
+          StorageLive(_70);
+          StorageLive(_71);
+          _71 = _1;
+-         _70 = Shr(move _71, const 0_i32);
++         _70 = _1;
+          StorageDead(_71);
+-         _69 = opaque::<u64>(move _70) -> [return: bb28, unwind continue];
++         _69 = opaque::<u64>(_1) -> [return: bb28, unwind continue];
+      }
+  
+      bb28: {
+          StorageDead(_70);
+          StorageDead(_69);
+          StorageLive(_72);
+          StorageLive(_73);
+          StorageLive(_74);
+          _74 = _1;
+-         _73 = Shl(move _74, const 0_i32);
++         _73 = _1;
+          StorageDead(_74);
+-         _72 = opaque::<u64>(move _73) -> [return: bb29, unwind continue];
++         _72 = opaque::<u64>(_1) -> [return: bb29, unwind continue];
+      }
+  
+      bb29: {
+          StorageDead(_73);
+          StorageDead(_72);
           _0 = const ();
           return;
       }
diff --git a/tests/mir-opt/gvn.arithmetic_checked.GVN.panic-abort.diff b/tests/mir-opt/gvn.arithmetic_checked.GVN.panic-abort.diff
index 6633df3ae70..a45d9920a68 100644
--- a/tests/mir-opt/gvn.arithmetic_checked.GVN.panic-abort.diff
+++ b/tests/mir-opt/gvn.arithmetic_checked.GVN.panic-abort.diff
@@ -15,11 +15,16 @@
       let _10: ();
       let mut _11: u64;
       let mut _12: u64;
-      let mut _13: (u64, bool);
-      let _14: ();
-      let mut _15: u64;
+      let mut _13: u64;
+      let mut _14: (u64, bool);
+      let _15: ();
       let mut _16: u64;
-      let mut _17: (u64, bool);
+      let mut _17: u64;
+      let mut _18: (u64, bool);
+      let _19: ();
+      let mut _20: u64;
+      let mut _21: u64;
+      let mut _22: (u64, bool);
   
       bb0: {
           StorageLive(_2);
@@ -29,13 +34,15 @@
 -         _5 = CheckedAdd(_4, const 0_u64);
 -         assert(!move (_5.1: bool), "attempt to compute `{} + {}`, which would overflow", move _4, const 0_u64) -> [success: bb1, unwind unreachable];
 +         _5 = CheckedAdd(_1, const 0_u64);
-+         assert(!move (_5.1: bool), "attempt to compute `{} + {}`, which would overflow", _1, const 0_u64) -> [success: bb1, unwind unreachable];
++         assert(!const false, "attempt to compute `{} + {}`, which would overflow", _1, const 0_u64) -> [success: bb1, unwind unreachable];
       }
   
       bb1: {
-          _3 = move (_5.0: u64);
+-         _3 = move (_5.0: u64);
++         _3 = _1;
           StorageDead(_4);
-          _2 = opaque::<u64>(move _3) -> [return: bb2, unwind unreachable];
+-         _2 = opaque::<u64>(move _3) -> [return: bb2, unwind unreachable];
++         _2 = opaque::<u64>(_1) -> [return: bb2, unwind unreachable];
       }
   
       bb2: {
@@ -47,59 +54,95 @@
           _8 = _1;
 -         _9 = CheckedSub(_8, const 0_u64);
 -         assert(!move (_9.1: bool), "attempt to compute `{} - {}`, which would overflow", move _8, const 0_u64) -> [success: bb3, unwind unreachable];
-+         _9 = CheckedSub(_1, const 0_u64);
-+         assert(!move (_9.1: bool), "attempt to compute `{} - {}`, which would overflow", _1, const 0_u64) -> [success: bb3, unwind unreachable];
++         _9 = _5;
++         assert(!const false, "attempt to compute `{} - {}`, which would overflow", _1, const 0_u64) -> [success: bb3, unwind unreachable];
       }
   
       bb3: {
-          _7 = move (_9.0: u64);
+-         _7 = move (_9.0: u64);
++         _7 = _1;
           StorageDead(_8);
-          _6 = opaque::<u64>(move _7) -> [return: bb4, unwind unreachable];
+-         _6 = opaque::<u64>(move _7) -> [return: bb4, unwind unreachable];
++         _6 = opaque::<u64>(_1) -> [return: bb4, unwind unreachable];
       }
   
       bb4: {
           StorageDead(_7);
           StorageDead(_6);
           StorageLive(_10);
-          StorageLive(_11);
+-         StorageLive(_11);
++         nop;
           StorageLive(_12);
           _12 = _1;
--         _13 = CheckedMul(_12, const 0_u64);
--         assert(!move (_13.1: bool), "attempt to compute `{} * {}`, which would overflow", move _12, const 0_u64) -> [success: bb5, unwind unreachable];
-+         _13 = CheckedMul(_1, const 0_u64);
-+         assert(!move (_13.1: bool), "attempt to compute `{} * {}`, which would overflow", _1, const 0_u64) -> [success: bb5, unwind unreachable];
+          StorageLive(_13);
+          _13 = _1;
+-         _14 = CheckedSub(_12, _13);
+-         assert(!move (_14.1: bool), "attempt to compute `{} - {}`, which would overflow", move _12, move _13) -> [success: bb5, unwind unreachable];
++         _14 = const (0_u64, false);
++         assert(!const false, "attempt to compute `{} - {}`, which would overflow", _1, _1) -> [success: bb5, unwind unreachable];
       }
   
       bb5: {
-          _11 = move (_13.0: u64);
+-         _11 = move (_14.0: u64);
++         _11 = const 0_u64;
+          StorageDead(_13);
           StorageDead(_12);
-          _10 = opaque::<u64>(move _11) -> [return: bb6, unwind unreachable];
+-         _10 = opaque::<u64>(move _11) -> [return: bb6, unwind unreachable];
++         _10 = opaque::<u64>(const 0_u64) -> [return: bb6, unwind unreachable];
       }
   
       bb6: {
-          StorageDead(_11);
+-         StorageDead(_11);
++         nop;
           StorageDead(_10);
-          StorageLive(_14);
           StorageLive(_15);
           StorageLive(_16);
-          _16 = _1;
--         _17 = CheckedMul(_16, const 1_u64);
--         assert(!move (_17.1: bool), "attempt to compute `{} * {}`, which would overflow", move _16, const 1_u64) -> [success: bb7, unwind unreachable];
-+         _17 = CheckedMul(_1, const 1_u64);
-+         assert(!move (_17.1: bool), "attempt to compute `{} * {}`, which would overflow", _1, const 1_u64) -> [success: bb7, unwind unreachable];
+          StorageLive(_17);
+          _17 = _1;
+-         _18 = CheckedMul(_17, const 0_u64);
+-         assert(!move (_18.1: bool), "attempt to compute `{} * {}`, which would overflow", move _17, const 0_u64) -> [success: bb7, unwind unreachable];
++         _18 = const (0_u64, false);
++         assert(!const false, "attempt to compute `{} * {}`, which would overflow", _1, const 0_u64) -> [success: bb7, unwind unreachable];
       }
   
       bb7: {
-          _15 = move (_17.0: u64);
-          StorageDead(_16);
-          _14 = opaque::<u64>(move _15) -> [return: bb8, unwind unreachable];
+-         _16 = move (_18.0: u64);
++         _16 = const 0_u64;
+          StorageDead(_17);
+-         _15 = opaque::<u64>(move _16) -> [return: bb8, unwind unreachable];
++         _15 = opaque::<u64>(const 0_u64) -> [return: bb8, unwind unreachable];
       }
   
       bb8: {
+          StorageDead(_16);
           StorageDead(_15);
-          StorageDead(_14);
+          StorageLive(_19);
+          StorageLive(_20);
+          StorageLive(_21);
+          _21 = _1;
+-         _22 = CheckedMul(_21, const 1_u64);
+-         assert(!move (_22.1: bool), "attempt to compute `{} * {}`, which would overflow", move _21, const 1_u64) -> [success: bb9, unwind unreachable];
++         _22 = _5;
++         assert(!const false, "attempt to compute `{} * {}`, which would overflow", _1, const 1_u64) -> [success: bb9, unwind unreachable];
+      }
+  
+      bb9: {
+-         _20 = move (_22.0: u64);
++         _20 = _1;
+          StorageDead(_21);
+-         _19 = opaque::<u64>(move _20) -> [return: bb10, unwind unreachable];
++         _19 = opaque::<u64>(_1) -> [return: bb10, unwind unreachable];
+      }
+  
+      bb10: {
+          StorageDead(_20);
+          StorageDead(_19);
           _0 = const ();
           return;
       }
++ }
++ 
++ ALLOC0 (size: 16, align: 8) {
++     00 00 00 00 00 00 00 00 00 __ __ __ __ __ __ __ │ .........░░░░░░░
   }
   
diff --git a/tests/mir-opt/gvn.arithmetic_checked.GVN.panic-unwind.diff b/tests/mir-opt/gvn.arithmetic_checked.GVN.panic-unwind.diff
index d100a77fee5..9033b392bd4 100644
--- a/tests/mir-opt/gvn.arithmetic_checked.GVN.panic-unwind.diff
+++ b/tests/mir-opt/gvn.arithmetic_checked.GVN.panic-unwind.diff
@@ -15,11 +15,16 @@
       let _10: ();
       let mut _11: u64;
       let mut _12: u64;
-      let mut _13: (u64, bool);
-      let _14: ();
-      let mut _15: u64;
+      let mut _13: u64;
+      let mut _14: (u64, bool);
+      let _15: ();
       let mut _16: u64;
-      let mut _17: (u64, bool);
+      let mut _17: u64;
+      let mut _18: (u64, bool);
+      let _19: ();
+      let mut _20: u64;
+      let mut _21: u64;
+      let mut _22: (u64, bool);
   
       bb0: {
           StorageLive(_2);
@@ -29,13 +34,15 @@
 -         _5 = CheckedAdd(_4, const 0_u64);
 -         assert(!move (_5.1: bool), "attempt to compute `{} + {}`, which would overflow", move _4, const 0_u64) -> [success: bb1, unwind continue];
 +         _5 = CheckedAdd(_1, const 0_u64);
-+         assert(!move (_5.1: bool), "attempt to compute `{} + {}`, which would overflow", _1, const 0_u64) -> [success: bb1, unwind continue];
++         assert(!const false, "attempt to compute `{} + {}`, which would overflow", _1, const 0_u64) -> [success: bb1, unwind continue];
       }
   
       bb1: {
-          _3 = move (_5.0: u64);
+-         _3 = move (_5.0: u64);
++         _3 = _1;
           StorageDead(_4);
-          _2 = opaque::<u64>(move _3) -> [return: bb2, unwind continue];
+-         _2 = opaque::<u64>(move _3) -> [return: bb2, unwind continue];
++         _2 = opaque::<u64>(_1) -> [return: bb2, unwind continue];
       }
   
       bb2: {
@@ -47,59 +54,95 @@
           _8 = _1;
 -         _9 = CheckedSub(_8, const 0_u64);
 -         assert(!move (_9.1: bool), "attempt to compute `{} - {}`, which would overflow", move _8, const 0_u64) -> [success: bb3, unwind continue];
-+         _9 = CheckedSub(_1, const 0_u64);
-+         assert(!move (_9.1: bool), "attempt to compute `{} - {}`, which would overflow", _1, const 0_u64) -> [success: bb3, unwind continue];
++         _9 = _5;
++         assert(!const false, "attempt to compute `{} - {}`, which would overflow", _1, const 0_u64) -> [success: bb3, unwind continue];
       }
   
       bb3: {
-          _7 = move (_9.0: u64);
+-         _7 = move (_9.0: u64);
++         _7 = _1;
           StorageDead(_8);
-          _6 = opaque::<u64>(move _7) -> [return: bb4, unwind continue];
+-         _6 = opaque::<u64>(move _7) -> [return: bb4, unwind continue];
++         _6 = opaque::<u64>(_1) -> [return: bb4, unwind continue];
       }
   
       bb4: {
           StorageDead(_7);
           StorageDead(_6);
           StorageLive(_10);
-          StorageLive(_11);
+-         StorageLive(_11);
++         nop;
           StorageLive(_12);
           _12 = _1;
--         _13 = CheckedMul(_12, const 0_u64);
--         assert(!move (_13.1: bool), "attempt to compute `{} * {}`, which would overflow", move _12, const 0_u64) -> [success: bb5, unwind continue];
-+         _13 = CheckedMul(_1, const 0_u64);
-+         assert(!move (_13.1: bool), "attempt to compute `{} * {}`, which would overflow", _1, const 0_u64) -> [success: bb5, unwind continue];
+          StorageLive(_13);
+          _13 = _1;
+-         _14 = CheckedSub(_12, _13);
+-         assert(!move (_14.1: bool), "attempt to compute `{} - {}`, which would overflow", move _12, move _13) -> [success: bb5, unwind continue];
++         _14 = const (0_u64, false);
++         assert(!const false, "attempt to compute `{} - {}`, which would overflow", _1, _1) -> [success: bb5, unwind continue];
       }
   
       bb5: {
-          _11 = move (_13.0: u64);
+-         _11 = move (_14.0: u64);
++         _11 = const 0_u64;
+          StorageDead(_13);
           StorageDead(_12);
-          _10 = opaque::<u64>(move _11) -> [return: bb6, unwind continue];
+-         _10 = opaque::<u64>(move _11) -> [return: bb6, unwind continue];
++         _10 = opaque::<u64>(const 0_u64) -> [return: bb6, unwind continue];
       }
   
       bb6: {
-          StorageDead(_11);
+-         StorageDead(_11);
++         nop;
           StorageDead(_10);
-          StorageLive(_14);
           StorageLive(_15);
           StorageLive(_16);
-          _16 = _1;
--         _17 = CheckedMul(_16, const 1_u64);
--         assert(!move (_17.1: bool), "attempt to compute `{} * {}`, which would overflow", move _16, const 1_u64) -> [success: bb7, unwind continue];
-+         _17 = CheckedMul(_1, const 1_u64);
-+         assert(!move (_17.1: bool), "attempt to compute `{} * {}`, which would overflow", _1, const 1_u64) -> [success: bb7, unwind continue];
+          StorageLive(_17);
+          _17 = _1;
+-         _18 = CheckedMul(_17, const 0_u64);
+-         assert(!move (_18.1: bool), "attempt to compute `{} * {}`, which would overflow", move _17, const 0_u64) -> [success: bb7, unwind continue];
++         _18 = const (0_u64, false);
++         assert(!const false, "attempt to compute `{} * {}`, which would overflow", _1, const 0_u64) -> [success: bb7, unwind continue];
       }
   
       bb7: {
-          _15 = move (_17.0: u64);
-          StorageDead(_16);
-          _14 = opaque::<u64>(move _15) -> [return: bb8, unwind continue];
+-         _16 = move (_18.0: u64);
++         _16 = const 0_u64;
+          StorageDead(_17);
+-         _15 = opaque::<u64>(move _16) -> [return: bb8, unwind continue];
++         _15 = opaque::<u64>(const 0_u64) -> [return: bb8, unwind continue];
       }
   
       bb8: {
+          StorageDead(_16);
           StorageDead(_15);
-          StorageDead(_14);
+          StorageLive(_19);
+          StorageLive(_20);
+          StorageLive(_21);
+          _21 = _1;
+-         _22 = CheckedMul(_21, const 1_u64);
+-         assert(!move (_22.1: bool), "attempt to compute `{} * {}`, which would overflow", move _21, const 1_u64) -> [success: bb9, unwind continue];
++         _22 = _5;
++         assert(!const false, "attempt to compute `{} * {}`, which would overflow", _1, const 1_u64) -> [success: bb9, unwind continue];
+      }
+  
+      bb9: {
+-         _20 = move (_22.0: u64);
++         _20 = _1;
+          StorageDead(_21);
+-         _19 = opaque::<u64>(move _20) -> [return: bb10, unwind continue];
++         _19 = opaque::<u64>(_1) -> [return: bb10, unwind continue];
+      }
+  
+      bb10: {
+          StorageDead(_20);
+          StorageDead(_19);
           _0 = const ();
           return;
       }
++ }
++ 
++ ALLOC0 (size: 16, align: 8) {
++     00 00 00 00 00 00 00 00 00 __ __ __ __ __ __ __ │ .........░░░░░░░
   }
   
diff --git a/tests/mir-opt/gvn.comparison.GVN.panic-abort.diff b/tests/mir-opt/gvn.comparison.GVN.panic-abort.diff
index ee3b9da2122..fefdf14bddc 100644
--- a/tests/mir-opt/gvn.comparison.GVN.panic-abort.diff
+++ b/tests/mir-opt/gvn.comparison.GVN.panic-abort.diff
@@ -30,10 +30,11 @@
           StorageLive(_6);
           _6 = _1;
 -         _4 = Eq(move _5, move _6);
-+         _4 = Eq(_1, _1);
++         _4 = const true;
           StorageDead(_6);
           StorageDead(_5);
-          _3 = opaque::<bool>(move _4) -> [return: bb1, unwind unreachable];
+-         _3 = opaque::<bool>(move _4) -> [return: bb1, unwind unreachable];
++         _3 = opaque::<bool>(const true) -> [return: bb1, unwind unreachable];
       }
   
       bb1: {
@@ -46,10 +47,11 @@
           StorageLive(_10);
           _10 = _1;
 -         _8 = Ne(move _9, move _10);
-+         _8 = Ne(_1, _1);
++         _8 = const false;
           StorageDead(_10);
           StorageDead(_9);
-          _7 = opaque::<bool>(move _8) -> [return: bb2, unwind unreachable];
+-         _7 = opaque::<bool>(move _8) -> [return: bb2, unwind unreachable];
++         _7 = opaque::<bool>(const false) -> [return: bb2, unwind unreachable];
       }
   
       bb2: {
diff --git a/tests/mir-opt/gvn.comparison.GVN.panic-unwind.diff b/tests/mir-opt/gvn.comparison.GVN.panic-unwind.diff
index a1408fe3434..9f19b2b59fa 100644
--- a/tests/mir-opt/gvn.comparison.GVN.panic-unwind.diff
+++ b/tests/mir-opt/gvn.comparison.GVN.panic-unwind.diff
@@ -30,10 +30,11 @@
           StorageLive(_6);
           _6 = _1;
 -         _4 = Eq(move _5, move _6);
-+         _4 = Eq(_1, _1);
++         _4 = const true;
           StorageDead(_6);
           StorageDead(_5);
-          _3 = opaque::<bool>(move _4) -> [return: bb1, unwind continue];
+-         _3 = opaque::<bool>(move _4) -> [return: bb1, unwind continue];
++         _3 = opaque::<bool>(const true) -> [return: bb1, unwind continue];
       }
   
       bb1: {
@@ -46,10 +47,11 @@
           StorageLive(_10);
           _10 = _1;
 -         _8 = Ne(move _9, move _10);
-+         _8 = Ne(_1, _1);
++         _8 = const false;
           StorageDead(_10);
           StorageDead(_9);
-          _7 = opaque::<bool>(move _8) -> [return: bb2, unwind continue];
+-         _7 = opaque::<bool>(move _8) -> [return: bb2, unwind continue];
++         _7 = opaque::<bool>(const false) -> [return: bb2, unwind continue];
       }
   
       bb2: {
diff --git a/tests/mir-opt/gvn.dereferences.GVN.panic-abort.diff b/tests/mir-opt/gvn.dereferences.GVN.panic-abort.diff
index a587b1e6b1d..46bf13985da 100644
--- a/tests/mir-opt/gvn.dereferences.GVN.panic-abort.diff
+++ b/tests/mir-opt/gvn.dereferences.GVN.panic-abort.diff
@@ -72,8 +72,7 @@
       bb2: {
           StorageDead(_7);
           StorageDead(_6);
--         StorageLive(_8);
-+         nop;
+          StorageLive(_8);
           _8 = &raw const (*_1);
           StorageLive(_9);
           StorageLive(_10);
@@ -93,8 +92,7 @@
       bb4: {
           StorageDead(_12);
           StorageDead(_11);
--         StorageLive(_13);
-+         nop;
+          StorageLive(_13);
           _13 = &raw mut (*_1);
           StorageLive(_14);
           StorageLive(_15);
@@ -114,8 +112,7 @@
       bb6: {
           StorageDead(_17);
           StorageDead(_16);
--         StorageLive(_18);
-+         nop;
+          StorageLive(_18);
           _18 = &(*_1);
           StorageLive(_19);
 -         StorageLive(_20);
@@ -191,12 +188,9 @@
           StorageDead(_32);
           StorageDead(_31);
           _0 = const ();
--         StorageDead(_18);
--         StorageDead(_13);
--         StorageDead(_8);
-+         nop;
-+         nop;
-+         nop;
+          StorageDead(_18);
+          StorageDead(_13);
+          StorageDead(_8);
           return;
       }
   }
diff --git a/tests/mir-opt/gvn.dereferences.GVN.panic-unwind.diff b/tests/mir-opt/gvn.dereferences.GVN.panic-unwind.diff
index 6fdda5e9988..3e731ead859 100644
--- a/tests/mir-opt/gvn.dereferences.GVN.panic-unwind.diff
+++ b/tests/mir-opt/gvn.dereferences.GVN.panic-unwind.diff
@@ -72,8 +72,7 @@
       bb2: {
           StorageDead(_7);
           StorageDead(_6);
--         StorageLive(_8);
-+         nop;
+          StorageLive(_8);
           _8 = &raw const (*_1);
           StorageLive(_9);
           StorageLive(_10);
@@ -93,8 +92,7 @@
       bb4: {
           StorageDead(_12);
           StorageDead(_11);
--         StorageLive(_13);
-+         nop;
+          StorageLive(_13);
           _13 = &raw mut (*_1);
           StorageLive(_14);
           StorageLive(_15);
@@ -114,8 +112,7 @@
       bb6: {
           StorageDead(_17);
           StorageDead(_16);
--         StorageLive(_18);
-+         nop;
+          StorageLive(_18);
           _18 = &(*_1);
           StorageLive(_19);
 -         StorageLive(_20);
@@ -191,12 +188,9 @@
           StorageDead(_32);
           StorageDead(_31);
           _0 = const ();
--         StorageDead(_18);
--         StorageDead(_13);
--         StorageDead(_8);
-+         nop;
-+         nop;
-+         nop;
+          StorageDead(_18);
+          StorageDead(_13);
+          StorageDead(_8);
           return;
       }
   }
diff --git a/tests/mir-opt/gvn.fn_pointers.GVN.panic-abort.diff b/tests/mir-opt/gvn.fn_pointers.GVN.panic-abort.diff
index d8248d22d38..02bf95840da 100644
--- a/tests/mir-opt/gvn.fn_pointers.GVN.panic-abort.diff
+++ b/tests/mir-opt/gvn.fn_pointers.GVN.panic-abort.diff
@@ -8,10 +8,10 @@
       let mut _3: fn(u8) -> u8;
       let _5: ();
       let mut _6: fn(u8) -> u8;
-      let mut _9: {closure@$DIR/gvn.rs:591:19: 591:21};
+      let mut _9: {closure@$DIR/gvn.rs:610:19: 610:21};
       let _10: ();
       let mut _11: fn();
-      let mut _13: {closure@$DIR/gvn.rs:591:19: 591:21};
+      let mut _13: {closure@$DIR/gvn.rs:610:19: 610:21};
       let _14: ();
       let mut _15: fn();
       scope 1 {
@@ -19,7 +19,7 @@
           let _4: fn(u8) -> u8;
           scope 2 {
               debug g => _4;
-              let _7: {closure@$DIR/gvn.rs:591:19: 591:21};
+              let _7: {closure@$DIR/gvn.rs:610:19: 610:21};
               scope 3 {
                   debug closure => _7;
                   let _8: fn();
@@ -62,16 +62,16 @@
           StorageDead(_6);
           StorageDead(_5);
 -         StorageLive(_7);
--         _7 = {closure@$DIR/gvn.rs:591:19: 591:21};
+-         _7 = {closure@$DIR/gvn.rs:610:19: 610:21};
 -         StorageLive(_8);
 +         nop;
-+         _7 = const ZeroSized: {closure@$DIR/gvn.rs:591:19: 591:21};
++         _7 = const ZeroSized: {closure@$DIR/gvn.rs:610:19: 610:21};
 +         nop;
           StorageLive(_9);
 -         _9 = _7;
 -         _8 = move _9 as fn() (PointerCoercion(ClosureFnPointer(Normal)));
-+         _9 = const ZeroSized: {closure@$DIR/gvn.rs:591:19: 591:21};
-+         _8 = const ZeroSized: {closure@$DIR/gvn.rs:591:19: 591:21} as fn() (PointerCoercion(ClosureFnPointer(Normal)));
++         _9 = const ZeroSized: {closure@$DIR/gvn.rs:610:19: 610:21};
++         _8 = const ZeroSized: {closure@$DIR/gvn.rs:610:19: 610:21} as fn() (PointerCoercion(ClosureFnPointer(Normal)));
           StorageDead(_9);
           StorageLive(_10);
           StorageLive(_11);
@@ -88,8 +88,8 @@
           StorageLive(_13);
 -         _13 = _7;
 -         _12 = move _13 as fn() (PointerCoercion(ClosureFnPointer(Normal)));
-+         _13 = const ZeroSized: {closure@$DIR/gvn.rs:591:19: 591:21};
-+         _12 = const ZeroSized: {closure@$DIR/gvn.rs:591:19: 591:21} as fn() (PointerCoercion(ClosureFnPointer(Normal)));
++         _13 = const ZeroSized: {closure@$DIR/gvn.rs:610:19: 610:21};
++         _12 = const ZeroSized: {closure@$DIR/gvn.rs:610:19: 610:21} as fn() (PointerCoercion(ClosureFnPointer(Normal)));
           StorageDead(_13);
           StorageLive(_14);
           StorageLive(_15);
diff --git a/tests/mir-opt/gvn.fn_pointers.GVN.panic-unwind.diff b/tests/mir-opt/gvn.fn_pointers.GVN.panic-unwind.diff
index e38a3d85209..c5dcc8a8ec9 100644
--- a/tests/mir-opt/gvn.fn_pointers.GVN.panic-unwind.diff
+++ b/tests/mir-opt/gvn.fn_pointers.GVN.panic-unwind.diff
@@ -8,10 +8,10 @@
       let mut _3: fn(u8) -> u8;
       let _5: ();
       let mut _6: fn(u8) -> u8;
-      let mut _9: {closure@$DIR/gvn.rs:591:19: 591:21};
+      let mut _9: {closure@$DIR/gvn.rs:610:19: 610:21};
       let _10: ();
       let mut _11: fn();
-      let mut _13: {closure@$DIR/gvn.rs:591:19: 591:21};
+      let mut _13: {closure@$DIR/gvn.rs:610:19: 610:21};
       let _14: ();
       let mut _15: fn();
       scope 1 {
@@ -19,7 +19,7 @@
           let _4: fn(u8) -> u8;
           scope 2 {
               debug g => _4;
-              let _7: {closure@$DIR/gvn.rs:591:19: 591:21};
+              let _7: {closure@$DIR/gvn.rs:610:19: 610:21};
               scope 3 {
                   debug closure => _7;
                   let _8: fn();
@@ -62,16 +62,16 @@
           StorageDead(_6);
           StorageDead(_5);
 -         StorageLive(_7);
--         _7 = {closure@$DIR/gvn.rs:591:19: 591:21};
+-         _7 = {closure@$DIR/gvn.rs:610:19: 610:21};
 -         StorageLive(_8);
 +         nop;
-+         _7 = const ZeroSized: {closure@$DIR/gvn.rs:591:19: 591:21};
++         _7 = const ZeroSized: {closure@$DIR/gvn.rs:610:19: 610:21};
 +         nop;
           StorageLive(_9);
 -         _9 = _7;
 -         _8 = move _9 as fn() (PointerCoercion(ClosureFnPointer(Normal)));
-+         _9 = const ZeroSized: {closure@$DIR/gvn.rs:591:19: 591:21};
-+         _8 = const ZeroSized: {closure@$DIR/gvn.rs:591:19: 591:21} as fn() (PointerCoercion(ClosureFnPointer(Normal)));
++         _9 = const ZeroSized: {closure@$DIR/gvn.rs:610:19: 610:21};
++         _8 = const ZeroSized: {closure@$DIR/gvn.rs:610:19: 610:21} as fn() (PointerCoercion(ClosureFnPointer(Normal)));
           StorageDead(_9);
           StorageLive(_10);
           StorageLive(_11);
@@ -88,8 +88,8 @@
           StorageLive(_13);
 -         _13 = _7;
 -         _12 = move _13 as fn() (PointerCoercion(ClosureFnPointer(Normal)));
-+         _13 = const ZeroSized: {closure@$DIR/gvn.rs:591:19: 591:21};
-+         _12 = const ZeroSized: {closure@$DIR/gvn.rs:591:19: 591:21} as fn() (PointerCoercion(ClosureFnPointer(Normal)));
++         _13 = const ZeroSized: {closure@$DIR/gvn.rs:610:19: 610:21};
++         _12 = const ZeroSized: {closure@$DIR/gvn.rs:610:19: 610:21} as fn() (PointerCoercion(ClosureFnPointer(Normal)));
           StorageDead(_13);
           StorageLive(_14);
           StorageLive(_15);
diff --git a/tests/mir-opt/gvn.repeated_index.GVN.panic-abort.diff b/tests/mir-opt/gvn.repeated_index.GVN.panic-abort.diff
index d937902e891..8ce05c9b340 100644
--- a/tests/mir-opt/gvn.repeated_index.GVN.panic-abort.diff
+++ b/tests/mir-opt/gvn.repeated_index.GVN.panic-abort.diff
@@ -32,11 +32,12 @@
           StorageLive(_6);
           StorageLive(_7);
           _7 = const 0_usize;
-          _8 = Len(_3);
+-         _8 = Len(_3);
 -         _9 = Lt(_7, _8);
 -         assert(move _9, "index out of bounds: the length is {} but the index is {}", move _8, _7) -> [success: bb1, unwind unreachable];
-+         _9 = Lt(const 0_usize, _8);
-+         assert(move _9, "index out of bounds: the length is {} but the index is {}", _8, const 0_usize) -> [success: bb1, unwind unreachable];
++         _8 = const N;
++         _9 = Lt(const 0_usize, const N);
++         assert(move _9, "index out of bounds: the length is {} but the index is {}", const N, const 0_usize) -> [success: bb1, unwind unreachable];
       }
   
       bb1: {
@@ -57,9 +58,9 @@
 -         _13 = Len(_3);
 -         _14 = Lt(_12, _13);
 -         assert(move _14, "index out of bounds: the length is {} but the index is {}", move _13, _12) -> [success: bb3, unwind unreachable];
-+         _13 = _8;
-+         _14 = Lt(_2, _8);
-+         assert(move _14, "index out of bounds: the length is {} but the index is {}", _8, _2) -> [success: bb3, unwind unreachable];
++         _13 = const N;
++         _14 = Lt(_2, const N);
++         assert(move _14, "index out of bounds: the length is {} but the index is {}", const N, _2) -> [success: bb3, unwind unreachable];
       }
   
       bb3: {
diff --git a/tests/mir-opt/gvn.repeated_index.GVN.panic-unwind.diff b/tests/mir-opt/gvn.repeated_index.GVN.panic-unwind.diff
index dd4d24b12ea..7ed547eeb4a 100644
--- a/tests/mir-opt/gvn.repeated_index.GVN.panic-unwind.diff
+++ b/tests/mir-opt/gvn.repeated_index.GVN.panic-unwind.diff
@@ -32,11 +32,12 @@
           StorageLive(_6);
           StorageLive(_7);
           _7 = const 0_usize;
-          _8 = Len(_3);
+-         _8 = Len(_3);
 -         _9 = Lt(_7, _8);
 -         assert(move _9, "index out of bounds: the length is {} but the index is {}", move _8, _7) -> [success: bb1, unwind continue];
-+         _9 = Lt(const 0_usize, _8);
-+         assert(move _9, "index out of bounds: the length is {} but the index is {}", _8, const 0_usize) -> [success: bb1, unwind continue];
++         _8 = const N;
++         _9 = Lt(const 0_usize, const N);
++         assert(move _9, "index out of bounds: the length is {} but the index is {}", const N, const 0_usize) -> [success: bb1, unwind continue];
       }
   
       bb1: {
@@ -57,9 +58,9 @@
 -         _13 = Len(_3);
 -         _14 = Lt(_12, _13);
 -         assert(move _14, "index out of bounds: the length is {} but the index is {}", move _13, _12) -> [success: bb3, unwind continue];
-+         _13 = _8;
-+         _14 = Lt(_2, _8);
-+         assert(move _14, "index out of bounds: the length is {} but the index is {}", _8, _2) -> [success: bb3, unwind continue];
++         _13 = const N;
++         _14 = Lt(_2, const N);
++         assert(move _14, "index out of bounds: the length is {} but the index is {}", const N, _2) -> [success: bb3, unwind continue];
       }
   
       bb3: {
diff --git a/tests/mir-opt/gvn.rs b/tests/mir-opt/gvn.rs
index 23e33a0fa49..31ea237cbec 100644
--- a/tests/mir-opt/gvn.rs
+++ b/tests/mir-opt/gvn.rs
@@ -166,69 +166,89 @@ fn repeated_index<T: Copy, const N: usize>(x: T, idx: usize) {
     opaque(a[idx]);
 }
 
+fn unary(x: i64) {
+    // CHECK-LABEL: fn unary(
+    // CHECK: opaque::<i64>(_1)
+    opaque(--x); // This is `x`.
+
+    // CHECK: [[b:_.*]] = Lt(_1, const 13_i64);
+    // CHECK: opaque::<bool>([[b]])
+    let b = x < 13;
+    opaque(!!b); // This is `b`.
+
+    // Both lines should test the same thing.
+    // CHECK: [[c:_.*]] = Ne(_1, const 15_i64);
+    // CHECK: opaque::<bool>([[c]])
+    // CHECK: opaque::<bool>([[c]])
+    opaque(x != 15);
+    opaque(!(x == 15));
+
+    // Both lines should test the same thing.
+    // CHECK: [[d:_.*]] = Eq(_1, const 35_i64);
+    // CHECK: opaque::<bool>([[d]])
+    // CHECK: opaque::<bool>([[d]])
+    opaque(x == 35);
+    opaque(!(x != 35));
+}
+
 /// Verify symbolic integer arithmetic simplifications.
 fn arithmetic(x: u64) {
     // CHECK-LABEL: fn arithmetic(
-    // CHECK: [[add:_.*]] = Add(_1, const 0_u64);
-    // CHECK: opaque::<u64>(move [[add]])
+    // CHECK: opaque::<u64>(_1)
     opaque(x + 0);
-    // CHECK: [[sub:_.*]] = Sub(_1, const 0_u64);
-    // CHECK: opaque::<u64>(move [[sub]])
+    // CHECK: opaque::<u64>(_1)
     opaque(x - 0);
-    // CHECK: [[mul0:_.*]] = Mul(_1, const 0_u64);
-    // CHECK: opaque::<u64>(move [[mul0]])
+    // CHECK: opaque::<u64>(const 0_u64)
+    opaque(x - x);
+    // CHECK: opaque::<u64>(const 0_u64)
     opaque(x * 0);
-    // CHECK: [[mul1:_.*]] = Mul(_1, const 1_u64);
-    // CHECK: opaque::<u64>(move [[mul1]])
+    // CHECK: opaque::<u64>(_1)
     opaque(x * 1);
+    // CHECK: assert(!const true, "attempt to divide `{}` by zero",
     // CHECK: [[div0:_.*]] = Div(_1, const 0_u64);
     // CHECK: opaque::<u64>(move [[div0]])
     opaque(x / 0);
-    // CHECK: [[div1:_.*]] = Div(_1, const 1_u64);
-    // CHECK: opaque::<u64>(move [[div1]])
+    // CHECK: opaque::<u64>(_1)
     opaque(x / 1);
-    // CHECK: [[zdiv:_.*]] = Div(const 0_u64, _1);
-    // CHECK: opaque::<u64>(move [[zdiv]])
+    // CHECK: opaque::<u64>(const 0_u64)
     opaque(0 / x);
     // CHECK: [[odiv:_.*]] = Div(const 1_u64, _1);
     // CHECK: opaque::<u64>(move [[odiv]])
     opaque(1 / x);
+    // CHECK: assert(!const true, "attempt to calculate the remainder of `{}` with a divisor of zero"
     // CHECK: [[rem0:_.*]] = Rem(_1, const 0_u64);
     // CHECK: opaque::<u64>(move [[rem0]])
     opaque(x % 0);
-    // CHECK: [[rem1:_.*]] = Rem(_1, const 1_u64);
-    // CHECK: opaque::<u64>(move [[rem1]])
+    // CHECK: opaque::<u64>(const 0_u64)
     opaque(x % 1);
-    // CHECK: [[zrem:_.*]] = Rem(const 0_u64, _1);
-    // CHECK: opaque::<u64>(move [[zrem]])
+    // CHECK: opaque::<u64>(const 0_u64)
     opaque(0 % x);
     // CHECK: [[orem:_.*]] = Rem(const 1_u64, _1);
     // CHECK: opaque::<u64>(move [[orem]])
     opaque(1 % x);
-    // CHECK: [[and:_.*]] = BitAnd(_1, const 0_u64);
-    // CHECK: opaque::<u64>(move [[and]])
+    // CHECK: opaque::<u64>(const 0_u64)
     opaque(x & 0);
-    // CHECK: [[or:_.*]] = BitOr(_1, const 0_u64);
-    // CHECK: opaque::<u64>(move [[or]])
+    // CHECK: opaque::<u64>(_1)
+    opaque(x & u64::MAX);
+    // CHECK: opaque::<u64>(_1)
     opaque(x | 0);
-    // CHECK: [[xor:_.*]] = BitXor(_1, const 0_u64);
-    // CHECK: opaque::<u64>(move [[xor]])
+    // CHECK: opaque::<u64>(const u64::MAX)
+    opaque(x | u64::MAX);
+    // CHECK: opaque::<u64>(_1)
     opaque(x ^ 0);
-    // CHECK: [[shr:_.*]] = Shr(_1, const 0_i32);
-    // CHECK: opaque::<u64>(move [[shr]])
+    // CHECK: opaque::<u64>(const 0_u64)
+    opaque(x ^ x);
+    // CHECK: opaque::<u64>(_1)
     opaque(x >> 0);
-    // CHECK: [[shl:_.*]] = Shl(_1, const 0_i32);
-    // CHECK: opaque::<u64>(move [[shl]])
+    // CHECK: opaque::<u64>(_1)
     opaque(x << 0);
 }
 
 fn comparison(x: u64, y: u64) {
     // CHECK-LABEL: fn comparison(
-    // CHECK: [[eqxx:_.*]] = Eq(_1, _1);
-    // CHECK: opaque::<bool>(move [[eqxx]])
+    // CHECK: opaque::<bool>(const true)
     opaque(x == x);
-    // CHECK: [[nexx:_.*]] = Ne(_1, _1);
-    // CHECK: opaque::<bool>(move [[nexx]])
+    // CHECK: opaque::<bool>(const false)
     opaque(x != x);
     // CHECK: [[eqxy:_.*]] = Eq(_1, _2);
     // CHECK: opaque::<bool>(move [[eqxy]])
@@ -242,21 +262,20 @@ fn comparison(x: u64, y: u64) {
 #[rustc_inherit_overflow_checks]
 fn arithmetic_checked(x: u64) {
     // CHECK-LABEL: fn arithmetic_checked(
-    // CHECK: [[cadd:_.*]] = CheckedAdd(_1, const 0_u64);
-    // CHECK: [[add:_.*]] = move ([[cadd]].0: u64);
-    // CHECK: opaque::<u64>(move [[add]])
+    // CHECK: assert(!const false,
+    // CHECK: opaque::<u64>(_1)
     opaque(x + 0);
-    // CHECK: [[csub:_.*]] = CheckedSub(_1, const 0_u64);
-    // CHECK: [[sub:_.*]] = move ([[csub]].0: u64);
-    // CHECK: opaque::<u64>(move [[sub]])
+    // CHECK: assert(!const false,
+    // CHECK: opaque::<u64>(_1)
     opaque(x - 0);
-    // CHECK: [[cmul0:_.*]] = CheckedMul(_1, const 0_u64);
-    // CHECK: [[mul0:_.*]] = move ([[cmul0]].0: u64);
-    // CHECK: opaque::<u64>(move [[mul0]])
+    // CHECK: assert(!const false,
+    // CHECK: opaque::<u64>(const 0_u64)
+    opaque(x - x);
+    // CHECK: assert(!const false,
+    // CHECK: opaque::<u64>(const 0_u64)
     opaque(x * 0);
-    // CHECK: [[cmul1:_.*]] = CheckedMul(_1, const 1_u64);
-    // CHECK: [[mul1:_.*]] = move ([[cmul1]].0: u64);
-    // CHECK: opaque::<u64>(move [[mul1]])
+    // CHECK: assert(!const false,
+    // CHECK: opaque::<u64>(_1)
     opaque(x * 1);
 }
 
@@ -625,10 +644,32 @@ fn constant_index_overflow<T: Copy>(x: &[T]) {
     opaque(b)
 }
 
+fn wide_ptr_ops() {
+    let a: *const dyn Send = &1 as &dyn Send;
+    let b: *const dyn Send = &1 as &dyn Send;
+    let _val = a == b;
+    let _val = a != b;
+    let _val = a < b;
+    let _val = a <= b;
+    let _val = a > b;
+    let _val = a >= b;
+
+    let a: *const [u8] = unsafe { transmute((1usize, 1usize)) };
+    let b: *const [u8] = unsafe { transmute((1usize, 2usize)) };
+
+    opaque(!(a == b));
+    opaque(a != b);
+    opaque(a <= b);
+    opaque(a < b);
+    opaque(!(a >= b));
+    opaque(!(a > b));
+}
+
 fn main() {
     subexpression_elimination(2, 4, 5);
     wrap_unwrap(5);
     repeated_index::<u32, 7>(5, 3);
+    unary(i64::MIN);
     arithmetic(5);
     comparison(5, 6);
     arithmetic_checked(5);
@@ -644,6 +685,7 @@ fn main() {
     fn_pointers();
     indirect_static();
     constant_index_overflow(&[5, 3]);
+    wide_ptr_ops();
 }
 
 #[inline(never)]
@@ -657,6 +699,7 @@ fn identity<T>(x: T) -> T {
 // EMIT_MIR gvn.subexpression_elimination.GVN.diff
 // EMIT_MIR gvn.wrap_unwrap.GVN.diff
 // EMIT_MIR gvn.repeated_index.GVN.diff
+// EMIT_MIR gvn.unary.GVN.diff
 // EMIT_MIR gvn.arithmetic.GVN.diff
 // EMIT_MIR gvn.comparison.GVN.diff
 // EMIT_MIR gvn.arithmetic_checked.GVN.diff
@@ -671,3 +714,4 @@ fn identity<T>(x: T) -> T {
 // EMIT_MIR gvn.fn_pointers.GVN.diff
 // EMIT_MIR gvn.indirect_static.GVN.diff
 // EMIT_MIR gvn.constant_index_overflow.GVN.diff
+// EMIT_MIR gvn.wide_ptr_ops.GVN.diff
diff --git a/tests/mir-opt/gvn.slices.GVN.panic-abort.diff b/tests/mir-opt/gvn.slices.GVN.panic-abort.diff
index ec449980312..f3f9073909e 100644
--- a/tests/mir-opt/gvn.slices.GVN.panic-abort.diff
+++ b/tests/mir-opt/gvn.slices.GVN.panic-abort.diff
@@ -194,15 +194,13 @@
 -         _23 = move _21;
 +         _23 = const core::panicking::AssertKind::Eq;
           StorageLive(_24);
--         StorageLive(_25);
+          StorageLive(_25);
 -         _25 = &(*_15);
-+         nop;
 +         _25 = &(*_9);
           _24 = &(*_25);
           StorageLive(_26);
--         StorageLive(_27);
+          StorageLive(_27);
 -         _27 = &(*_16);
-+         nop;
 +         _27 = &(*_12);
           _26 = &(*_27);
           StorageLive(_28);
@@ -293,15 +291,13 @@
 -         _49 = move _47;
 +         _49 = const core::panicking::AssertKind::Eq;
           StorageLive(_50);
--         StorageLive(_51);
+          StorageLive(_51);
 -         _51 = &(*_41);
-+         nop;
 +         _51 = &(*_35);
           _50 = &(*_51);
           StorageLive(_52);
--         StorageLive(_53);
+          StorageLive(_53);
 -         _53 = &(*_42);
-+         nop;
 +         _53 = &(*_38);
           _52 = &(*_53);
           StorageLive(_54);
diff --git a/tests/mir-opt/gvn.slices.GVN.panic-unwind.diff b/tests/mir-opt/gvn.slices.GVN.panic-unwind.diff
index 56a78ca8694..383152cce5e 100644
--- a/tests/mir-opt/gvn.slices.GVN.panic-unwind.diff
+++ b/tests/mir-opt/gvn.slices.GVN.panic-unwind.diff
@@ -194,15 +194,13 @@
 -         _23 = move _21;
 +         _23 = const core::panicking::AssertKind::Eq;
           StorageLive(_24);
--         StorageLive(_25);
+          StorageLive(_25);
 -         _25 = &(*_15);
-+         nop;
 +         _25 = &(*_9);
           _24 = &(*_25);
           StorageLive(_26);
--         StorageLive(_27);
+          StorageLive(_27);
 -         _27 = &(*_16);
-+         nop;
 +         _27 = &(*_12);
           _26 = &(*_27);
           StorageLive(_28);
@@ -293,15 +291,13 @@
 -         _49 = move _47;
 +         _49 = const core::panicking::AssertKind::Eq;
           StorageLive(_50);
--         StorageLive(_51);
+          StorageLive(_51);
 -         _51 = &(*_41);
-+         nop;
 +         _51 = &(*_35);
           _50 = &(*_51);
           StorageLive(_52);
--         StorageLive(_53);
+          StorageLive(_53);
 -         _53 = &(*_42);
-+         nop;
 +         _53 = &(*_38);
           _52 = &(*_53);
           StorageLive(_54);
diff --git a/tests/mir-opt/gvn.subexpression_elimination.GVN.panic-abort.diff b/tests/mir-opt/gvn.subexpression_elimination.GVN.panic-abort.diff
index 0a747d3aef0..3ecd4650d81 100644
--- a/tests/mir-opt/gvn.subexpression_elimination.GVN.panic-abort.diff
+++ b/tests/mir-opt/gvn.subexpression_elimination.GVN.panic-abort.diff
@@ -757,8 +757,7 @@
       bb34: {
           StorageDead(_121);
           StorageDead(_120);
--         StorageLive(_126);
-+         nop;
+          StorageLive(_126);
           _126 = &_3;
           StorageLive(_127);
 -         StorageLive(_128);
@@ -799,8 +798,7 @@
       bb36: {
           StorageDead(_132);
           StorageDead(_131);
--         StorageLive(_135);
-+         nop;
+          StorageLive(_135);
           _135 = &mut _3;
           StorageLive(_136);
           StorageLive(_137);
@@ -835,8 +833,7 @@
           StorageDead(_141);
           StorageDead(_140);
           StorageLive(_144);
--         StorageLive(_145);
-+         nop;
+          StorageLive(_145);
           _145 = &raw const _3;
           StorageLive(_146);
           StorageLive(_147);
@@ -870,8 +867,7 @@
       bb40: {
           StorageDead(_151);
           StorageDead(_150);
--         StorageLive(_154);
-+         nop;
+          StorageLive(_154);
           _154 = &raw mut _3;
           StorageLive(_155);
           StorageLive(_156);
@@ -906,13 +902,10 @@
           StorageDead(_160);
           StorageDead(_159);
           _144 = const ();
--         StorageDead(_154);
--         StorageDead(_145);
-+         nop;
-+         nop;
+          StorageDead(_154);
+          StorageDead(_145);
           StorageDead(_144);
--         StorageLive(_163);
-+         nop;
+          StorageLive(_163);
           _163 = &_3;
           StorageLive(_164);
 -         StorageLive(_165);
@@ -954,12 +947,9 @@
           StorageDead(_169);
           StorageDead(_168);
           _0 = const ();
--         StorageDead(_163);
--         StorageDead(_135);
--         StorageDead(_126);
-+         nop;
-+         nop;
-+         nop;
+          StorageDead(_163);
+          StorageDead(_135);
+          StorageDead(_126);
           return;
       }
   }
diff --git a/tests/mir-opt/gvn.subexpression_elimination.GVN.panic-unwind.diff b/tests/mir-opt/gvn.subexpression_elimination.GVN.panic-unwind.diff
index 119a4d9bbe9..bf448280b1e 100644
--- a/tests/mir-opt/gvn.subexpression_elimination.GVN.panic-unwind.diff
+++ b/tests/mir-opt/gvn.subexpression_elimination.GVN.panic-unwind.diff
@@ -757,8 +757,7 @@
       bb34: {
           StorageDead(_121);
           StorageDead(_120);
--         StorageLive(_126);
-+         nop;
+          StorageLive(_126);
           _126 = &_3;
           StorageLive(_127);
 -         StorageLive(_128);
@@ -799,8 +798,7 @@
       bb36: {
           StorageDead(_132);
           StorageDead(_131);
--         StorageLive(_135);
-+         nop;
+          StorageLive(_135);
           _135 = &mut _3;
           StorageLive(_136);
           StorageLive(_137);
@@ -835,8 +833,7 @@
           StorageDead(_141);
           StorageDead(_140);
           StorageLive(_144);
--         StorageLive(_145);
-+         nop;
+          StorageLive(_145);
           _145 = &raw const _3;
           StorageLive(_146);
           StorageLive(_147);
@@ -870,8 +867,7 @@
       bb40: {
           StorageDead(_151);
           StorageDead(_150);
--         StorageLive(_154);
-+         nop;
+          StorageLive(_154);
           _154 = &raw mut _3;
           StorageLive(_155);
           StorageLive(_156);
@@ -906,13 +902,10 @@
           StorageDead(_160);
           StorageDead(_159);
           _144 = const ();
--         StorageDead(_154);
--         StorageDead(_145);
-+         nop;
-+         nop;
+          StorageDead(_154);
+          StorageDead(_145);
           StorageDead(_144);
--         StorageLive(_163);
-+         nop;
+          StorageLive(_163);
           _163 = &_3;
           StorageLive(_164);
 -         StorageLive(_165);
@@ -954,12 +947,9 @@
           StorageDead(_169);
           StorageDead(_168);
           _0 = const ();
--         StorageDead(_163);
--         StorageDead(_135);
--         StorageDead(_126);
-+         nop;
-+         nop;
-+         nop;
+          StorageDead(_163);
+          StorageDead(_135);
+          StorageDead(_126);
           return;
       }
   }
diff --git a/tests/mir-opt/gvn.unary.GVN.panic-abort.diff b/tests/mir-opt/gvn.unary.GVN.panic-abort.diff
new file mode 100644
index 00000000000..9469032f294
--- /dev/null
+++ b/tests/mir-opt/gvn.unary.GVN.panic-abort.diff
@@ -0,0 +1,153 @@
+- // MIR for `unary` before GVN
++ // MIR for `unary` after GVN
+  
+  fn unary(_1: i64) -> () {
+      debug x => _1;
+      let mut _0: ();
+      let _2: ();
+      let mut _3: i64;
+      let mut _4: i64;
+      let mut _5: i64;
+      let _6: bool;
+      let mut _7: i64;
+      let _8: ();
+      let mut _9: bool;
+      let mut _10: bool;
+      let mut _11: bool;
+      let _12: ();
+      let mut _13: bool;
+      let mut _14: i64;
+      let _15: ();
+      let mut _16: bool;
+      let mut _17: bool;
+      let mut _18: i64;
+      let _19: ();
+      let mut _20: bool;
+      let mut _21: i64;
+      let _22: ();
+      let mut _23: bool;
+      let mut _24: bool;
+      let mut _25: i64;
+      scope 1 {
+          debug b => _6;
+      }
+  
+      bb0: {
+          StorageLive(_2);
+          StorageLive(_3);
+          StorageLive(_4);
+          StorageLive(_5);
+          _5 = _1;
+-         _4 = Neg(move _5);
++         _4 = Neg(_1);
+          StorageDead(_5);
+-         _3 = Neg(move _4);
++         _3 = _1;
+          StorageDead(_4);
+-         _2 = opaque::<i64>(move _3) -> [return: bb1, unwind unreachable];
++         _2 = opaque::<i64>(_1) -> [return: bb1, unwind unreachable];
+      }
+  
+      bb1: {
+          StorageDead(_3);
+          StorageDead(_2);
+-         StorageLive(_6);
++         nop;
+          StorageLive(_7);
+          _7 = _1;
+-         _6 = Lt(move _7, const 13_i64);
++         _6 = Lt(_1, const 13_i64);
+          StorageDead(_7);
+          StorageLive(_8);
+          StorageLive(_9);
+          StorageLive(_10);
+          StorageLive(_11);
+          _11 = _6;
+-         _10 = Not(move _11);
++         _10 = Not(_6);
+          StorageDead(_11);
+-         _9 = Not(move _10);
++         _9 = _6;
+          StorageDead(_10);
+-         _8 = opaque::<bool>(move _9) -> [return: bb2, unwind unreachable];
++         _8 = opaque::<bool>(_6) -> [return: bb2, unwind unreachable];
+      }
+  
+      bb2: {
+          StorageDead(_9);
+          StorageDead(_8);
+          StorageLive(_12);
+-         StorageLive(_13);
++         nop;
+          StorageLive(_14);
+          _14 = _1;
+-         _13 = Ne(move _14, const 15_i64);
++         _13 = Ne(_1, const 15_i64);
+          StorageDead(_14);
+-         _12 = opaque::<bool>(move _13) -> [return: bb3, unwind unreachable];
++         _12 = opaque::<bool>(_13) -> [return: bb3, unwind unreachable];
+      }
+  
+      bb3: {
+-         StorageDead(_13);
++         nop;
+          StorageDead(_12);
+          StorageLive(_15);
+          StorageLive(_16);
+          StorageLive(_17);
+          StorageLive(_18);
+          _18 = _1;
+-         _17 = Eq(move _18, const 15_i64);
++         _17 = Eq(_1, const 15_i64);
+          StorageDead(_18);
+-         _16 = Not(move _17);
++         _16 = _13;
+          StorageDead(_17);
+-         _15 = opaque::<bool>(move _16) -> [return: bb4, unwind unreachable];
++         _15 = opaque::<bool>(_13) -> [return: bb4, unwind unreachable];
+      }
+  
+      bb4: {
+          StorageDead(_16);
+          StorageDead(_15);
+          StorageLive(_19);
+-         StorageLive(_20);
++         nop;
+          StorageLive(_21);
+          _21 = _1;
+-         _20 = Eq(move _21, const 35_i64);
++         _20 = Eq(_1, const 35_i64);
+          StorageDead(_21);
+-         _19 = opaque::<bool>(move _20) -> [return: bb5, unwind unreachable];
++         _19 = opaque::<bool>(_20) -> [return: bb5, unwind unreachable];
+      }
+  
+      bb5: {
+-         StorageDead(_20);
++         nop;
+          StorageDead(_19);
+          StorageLive(_22);
+          StorageLive(_23);
+          StorageLive(_24);
+          StorageLive(_25);
+          _25 = _1;
+-         _24 = Ne(move _25, const 35_i64);
++         _24 = Ne(_1, const 35_i64);
+          StorageDead(_25);
+-         _23 = Not(move _24);
++         _23 = _20;
+          StorageDead(_24);
+-         _22 = opaque::<bool>(move _23) -> [return: bb6, unwind unreachable];
++         _22 = opaque::<bool>(_20) -> [return: bb6, unwind unreachable];
+      }
+  
+      bb6: {
+          StorageDead(_23);
+          StorageDead(_22);
+          _0 = const ();
+-         StorageDead(_6);
++         nop;
+          return;
+      }
+  }
+  
diff --git a/tests/mir-opt/gvn.unary.GVN.panic-unwind.diff b/tests/mir-opt/gvn.unary.GVN.panic-unwind.diff
new file mode 100644
index 00000000000..e672f6fb6ba
--- /dev/null
+++ b/tests/mir-opt/gvn.unary.GVN.panic-unwind.diff
@@ -0,0 +1,153 @@
+- // MIR for `unary` before GVN
++ // MIR for `unary` after GVN
+  
+  fn unary(_1: i64) -> () {
+      debug x => _1;
+      let mut _0: ();
+      let _2: ();
+      let mut _3: i64;
+      let mut _4: i64;
+      let mut _5: i64;
+      let _6: bool;
+      let mut _7: i64;
+      let _8: ();
+      let mut _9: bool;
+      let mut _10: bool;
+      let mut _11: bool;
+      let _12: ();
+      let mut _13: bool;
+      let mut _14: i64;
+      let _15: ();
+      let mut _16: bool;
+      let mut _17: bool;
+      let mut _18: i64;
+      let _19: ();
+      let mut _20: bool;
+      let mut _21: i64;
+      let _22: ();
+      let mut _23: bool;
+      let mut _24: bool;
+      let mut _25: i64;
+      scope 1 {
+          debug b => _6;
+      }
+  
+      bb0: {
+          StorageLive(_2);
+          StorageLive(_3);
+          StorageLive(_4);
+          StorageLive(_5);
+          _5 = _1;
+-         _4 = Neg(move _5);
++         _4 = Neg(_1);
+          StorageDead(_5);
+-         _3 = Neg(move _4);
++         _3 = _1;
+          StorageDead(_4);
+-         _2 = opaque::<i64>(move _3) -> [return: bb1, unwind continue];
++         _2 = opaque::<i64>(_1) -> [return: bb1, unwind continue];
+      }
+  
+      bb1: {
+          StorageDead(_3);
+          StorageDead(_2);
+-         StorageLive(_6);
++         nop;
+          StorageLive(_7);
+          _7 = _1;
+-         _6 = Lt(move _7, const 13_i64);
++         _6 = Lt(_1, const 13_i64);
+          StorageDead(_7);
+          StorageLive(_8);
+          StorageLive(_9);
+          StorageLive(_10);
+          StorageLive(_11);
+          _11 = _6;
+-         _10 = Not(move _11);
++         _10 = Not(_6);
+          StorageDead(_11);
+-         _9 = Not(move _10);
++         _9 = _6;
+          StorageDead(_10);
+-         _8 = opaque::<bool>(move _9) -> [return: bb2, unwind continue];
++         _8 = opaque::<bool>(_6) -> [return: bb2, unwind continue];
+      }
+  
+      bb2: {
+          StorageDead(_9);
+          StorageDead(_8);
+          StorageLive(_12);
+-         StorageLive(_13);
++         nop;
+          StorageLive(_14);
+          _14 = _1;
+-         _13 = Ne(move _14, const 15_i64);
++         _13 = Ne(_1, const 15_i64);
+          StorageDead(_14);
+-         _12 = opaque::<bool>(move _13) -> [return: bb3, unwind continue];
++         _12 = opaque::<bool>(_13) -> [return: bb3, unwind continue];
+      }
+  
+      bb3: {
+-         StorageDead(_13);
++         nop;
+          StorageDead(_12);
+          StorageLive(_15);
+          StorageLive(_16);
+          StorageLive(_17);
+          StorageLive(_18);
+          _18 = _1;
+-         _17 = Eq(move _18, const 15_i64);
++         _17 = Eq(_1, const 15_i64);
+          StorageDead(_18);
+-         _16 = Not(move _17);
++         _16 = _13;
+          StorageDead(_17);
+-         _15 = opaque::<bool>(move _16) -> [return: bb4, unwind continue];
++         _15 = opaque::<bool>(_13) -> [return: bb4, unwind continue];
+      }
+  
+      bb4: {
+          StorageDead(_16);
+          StorageDead(_15);
+          StorageLive(_19);
+-         StorageLive(_20);
++         nop;
+          StorageLive(_21);
+          _21 = _1;
+-         _20 = Eq(move _21, const 35_i64);
++         _20 = Eq(_1, const 35_i64);
+          StorageDead(_21);
+-         _19 = opaque::<bool>(move _20) -> [return: bb5, unwind continue];
++         _19 = opaque::<bool>(_20) -> [return: bb5, unwind continue];
+      }
+  
+      bb5: {
+-         StorageDead(_20);
++         nop;
+          StorageDead(_19);
+          StorageLive(_22);
+          StorageLive(_23);
+          StorageLive(_24);
+          StorageLive(_25);
+          _25 = _1;
+-         _24 = Ne(move _25, const 35_i64);
++         _24 = Ne(_1, const 35_i64);
+          StorageDead(_25);
+-         _23 = Not(move _24);
++         _23 = _20;
+          StorageDead(_24);
+-         _22 = opaque::<bool>(move _23) -> [return: bb6, unwind continue];
++         _22 = opaque::<bool>(_20) -> [return: bb6, unwind continue];
+      }
+  
+      bb6: {
+          StorageDead(_23);
+          StorageDead(_22);
+          _0 = const ();
+-         StorageDead(_6);
++         nop;
+          return;
+      }
+  }
+  
diff --git a/tests/mir-opt/gvn.wide_ptr_ops.GVN.panic-abort.diff b/tests/mir-opt/gvn.wide_ptr_ops.GVN.panic-abort.diff
new file mode 100644
index 00000000000..e49d759b8fc
--- /dev/null
+++ b/tests/mir-opt/gvn.wide_ptr_ops.GVN.panic-abort.diff
@@ -0,0 +1,386 @@
+- // MIR for `wide_ptr_ops` before GVN
++ // MIR for `wide_ptr_ops` after GVN
+  
+  fn wide_ptr_ops() -> () {
+      let mut _0: ();
+      let _1: *const dyn std::marker::Send;
+      let mut _2: *const dyn std::marker::Send;
+      let _3: &dyn std::marker::Send;
+      let mut _4: &i32;
+      let _5: &i32;
+      let _6: i32;
+      let mut _8: *const dyn std::marker::Send;
+      let _9: &dyn std::marker::Send;
+      let mut _10: &i32;
+      let _11: &i32;
+      let _12: i32;
+      let mut _14: *const dyn std::marker::Send;
+      let mut _15: *const dyn std::marker::Send;
+      let mut _16: *const dyn std::marker::Send;
+      let mut _18: *const dyn std::marker::Send;
+      let mut _19: *const dyn std::marker::Send;
+      let mut _20: *const dyn std::marker::Send;
+      let mut _22: *const dyn std::marker::Send;
+      let mut _23: *const dyn std::marker::Send;
+      let mut _24: *const dyn std::marker::Send;
+      let mut _26: *const dyn std::marker::Send;
+      let mut _27: *const dyn std::marker::Send;
+      let mut _28: *const dyn std::marker::Send;
+      let mut _30: *const dyn std::marker::Send;
+      let mut _31: *const dyn std::marker::Send;
+      let mut _32: *const dyn std::marker::Send;
+      let mut _34: *const dyn std::marker::Send;
+      let mut _35: *const dyn std::marker::Send;
+      let mut _36: *const dyn std::marker::Send;
+      let mut _38: (usize, usize);
+      let mut _40: (usize, usize);
+      let _41: ();
+      let mut _42: bool;
+      let mut _43: bool;
+      let mut _44: *const [u8];
+      let mut _45: *const [u8];
+      let _46: ();
+      let mut _47: bool;
+      let mut _48: *const [u8];
+      let mut _49: *const [u8];
+      let _50: ();
+      let mut _51: bool;
+      let mut _52: *const [u8];
+      let mut _53: *const [u8];
+      let _54: ();
+      let mut _55: bool;
+      let mut _56: *const [u8];
+      let mut _57: *const [u8];
+      let _58: ();
+      let mut _59: bool;
+      let mut _60: bool;
+      let mut _61: *const [u8];
+      let mut _62: *const [u8];
+      let _63: ();
+      let mut _64: bool;
+      let mut _65: bool;
+      let mut _66: *const [u8];
+      let mut _67: *const [u8];
+      let mut _69: &i32;
+      scope 1 {
+          debug a => _1;
+          let _7: *const dyn std::marker::Send;
+          let mut _68: &i32;
+          scope 2 {
+              debug b => _7;
+              let _13: bool;
+              scope 3 {
+                  debug _val => _13;
+                  let _17: bool;
+                  scope 4 {
+                      debug _val => _17;
+                      let _21: bool;
+                      scope 5 {
+                          debug _val => _21;
+                          let _25: bool;
+                          scope 6 {
+                              debug _val => _25;
+                              let _29: bool;
+                              scope 7 {
+                                  debug _val => _29;
+                                  let _33: bool;
+                                  scope 8 {
+                                      debug _val => _33;
+                                      let _37: *const [u8];
+                                      scope 9 {
+                                          debug a => _37;
+                                          let _39: *const [u8];
+                                          scope 11 {
+                                              debug b => _39;
+                                          }
+                                          scope 12 {
+                                          }
+                                      }
+                                      scope 10 {
+                                      }
+                                  }
+                              }
+                          }
+                      }
+                  }
+              }
+          }
+      }
+  
+      bb0: {
+-         StorageLive(_1);
++         nop;
+          StorageLive(_2);
+          StorageLive(_3);
+          StorageLive(_4);
+          StorageLive(_5);
+          _69 = const _;
+          _5 = &(*_69);
+          _4 = &(*_5);
+          _3 = move _4 as &dyn std::marker::Send (PointerCoercion(Unsize));
+          StorageDead(_4);
+          _2 = &raw const (*_3);
+          _1 = move _2 as *const dyn std::marker::Send (PointerCoercion(Unsize));
+          StorageDead(_2);
+          StorageDead(_5);
+          StorageDead(_3);
+-         StorageLive(_7);
++         nop;
+          StorageLive(_8);
+          StorageLive(_9);
+          StorageLive(_10);
+          StorageLive(_11);
+          _68 = const _;
+          _11 = &(*_68);
+          _10 = &(*_11);
+          _9 = move _10 as &dyn std::marker::Send (PointerCoercion(Unsize));
+          StorageDead(_10);
+          _8 = &raw const (*_9);
+          _7 = move _8 as *const dyn std::marker::Send (PointerCoercion(Unsize));
+          StorageDead(_8);
+          StorageDead(_11);
+          StorageDead(_9);
+          StorageLive(_13);
+          StorageLive(_14);
+          _14 = _1;
+-         StorageLive(_15);
++         nop;
+          StorageLive(_16);
+          _16 = _7;
+-         _15 = move _16 as *const dyn std::marker::Send (PointerCoercion(Unsize));
++         _15 = _7 as *const dyn std::marker::Send (PointerCoercion(Unsize));
+          StorageDead(_16);
+-         _13 = Eq(move _14, move _15);
+-         StorageDead(_15);
++         _13 = Eq(_1, _15);
++         nop;
+          StorageDead(_14);
+          StorageLive(_17);
+          StorageLive(_18);
+          _18 = _1;
+          StorageLive(_19);
+          StorageLive(_20);
+          _20 = _7;
+-         _19 = move _20 as *const dyn std::marker::Send (PointerCoercion(Unsize));
++         _19 = _15;
+          StorageDead(_20);
+-         _17 = Ne(move _18, move _19);
++         _17 = Ne(_1, _15);
+          StorageDead(_19);
+          StorageDead(_18);
+          StorageLive(_21);
+          StorageLive(_22);
+          _22 = _1;
+          StorageLive(_23);
+          StorageLive(_24);
+          _24 = _7;
+-         _23 = move _24 as *const dyn std::marker::Send (PointerCoercion(Unsize));
++         _23 = _15;
+          StorageDead(_24);
+-         _21 = Lt(move _22, move _23);
++         _21 = Lt(_1, _15);
+          StorageDead(_23);
+          StorageDead(_22);
+          StorageLive(_25);
+          StorageLive(_26);
+          _26 = _1;
+          StorageLive(_27);
+          StorageLive(_28);
+          _28 = _7;
+-         _27 = move _28 as *const dyn std::marker::Send (PointerCoercion(Unsize));
++         _27 = _15;
+          StorageDead(_28);
+-         _25 = Le(move _26, move _27);
++         _25 = Le(_1, _15);
+          StorageDead(_27);
+          StorageDead(_26);
+          StorageLive(_29);
+          StorageLive(_30);
+          _30 = _1;
+          StorageLive(_31);
+          StorageLive(_32);
+          _32 = _7;
+-         _31 = move _32 as *const dyn std::marker::Send (PointerCoercion(Unsize));
++         _31 = _15;
+          StorageDead(_32);
+-         _29 = Gt(move _30, move _31);
++         _29 = Gt(_1, _15);
+          StorageDead(_31);
+          StorageDead(_30);
+          StorageLive(_33);
+          StorageLive(_34);
+          _34 = _1;
+          StorageLive(_35);
+          StorageLive(_36);
+          _36 = _7;
+-         _35 = move _36 as *const dyn std::marker::Send (PointerCoercion(Unsize));
++         _35 = _15;
+          StorageDead(_36);
+-         _33 = Ge(move _34, move _35);
++         _33 = Ge(_1, _15);
+          StorageDead(_35);
+          StorageDead(_34);
+-         StorageLive(_37);
++         nop;
+          StorageLive(_38);
+-         _38 = (const 1_usize, const 1_usize);
+-         _37 = move _38 as *const [u8] (Transmute);
++         _38 = const (1_usize, 1_usize);
++         _37 = const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8];
+          StorageDead(_38);
+-         StorageLive(_39);
++         nop;
+          StorageLive(_40);
+-         _40 = (const 1_usize, const 2_usize);
+-         _39 = move _40 as *const [u8] (Transmute);
++         _40 = const (1_usize, 2_usize);
++         _39 = const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8];
+          StorageDead(_40);
+          StorageLive(_41);
+-         StorageLive(_42);
++         nop;
+          StorageLive(_43);
+          StorageLive(_44);
+-         _44 = _37;
++         _44 = const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8];
+          StorageLive(_45);
+-         _45 = _39;
+-         _43 = Eq(move _44, move _45);
++         _45 = const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8];
++         _43 = Eq(const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8], const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8]);
+          StorageDead(_45);
+          StorageDead(_44);
+          _42 = Not(move _43);
+          StorageDead(_43);
+-         _41 = opaque::<bool>(move _42) -> [return: bb1, unwind unreachable];
++         _41 = opaque::<bool>(_42) -> [return: bb1, unwind unreachable];
+      }
+  
+      bb1: {
+-         StorageDead(_42);
++         nop;
+          StorageDead(_41);
+          StorageLive(_46);
+          StorageLive(_47);
+          StorageLive(_48);
+-         _48 = _37;
++         _48 = const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8];
+          StorageLive(_49);
+-         _49 = _39;
+-         _47 = Ne(move _48, move _49);
++         _49 = const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8];
++         _47 = _42;
+          StorageDead(_49);
+          StorageDead(_48);
+-         _46 = opaque::<bool>(move _47) -> [return: bb2, unwind unreachable];
++         _46 = opaque::<bool>(_42) -> [return: bb2, unwind unreachable];
+      }
+  
+      bb2: {
+          StorageDead(_47);
+          StorageDead(_46);
+          StorageLive(_50);
+          StorageLive(_51);
+          StorageLive(_52);
+-         _52 = _37;
++         _52 = const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8];
+          StorageLive(_53);
+-         _53 = _39;
+-         _51 = Le(move _52, move _53);
++         _53 = const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8];
++         _51 = Le(const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8], const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8]);
+          StorageDead(_53);
+          StorageDead(_52);
+          _50 = opaque::<bool>(move _51) -> [return: bb3, unwind unreachable];
+      }
+  
+      bb3: {
+          StorageDead(_51);
+          StorageDead(_50);
+          StorageLive(_54);
+          StorageLive(_55);
+          StorageLive(_56);
+-         _56 = _37;
++         _56 = const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8];
+          StorageLive(_57);
+-         _57 = _39;
+-         _55 = Lt(move _56, move _57);
++         _57 = const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8];
++         _55 = Lt(const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8], const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8]);
+          StorageDead(_57);
+          StorageDead(_56);
+          _54 = opaque::<bool>(move _55) -> [return: bb4, unwind unreachable];
+      }
+  
+      bb4: {
+          StorageDead(_55);
+          StorageDead(_54);
+          StorageLive(_58);
+          StorageLive(_59);
+          StorageLive(_60);
+          StorageLive(_61);
+-         _61 = _37;
++         _61 = const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8];
+          StorageLive(_62);
+-         _62 = _39;
+-         _60 = Ge(move _61, move _62);
++         _62 = const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8];
++         _60 = Ge(const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8], const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8]);
+          StorageDead(_62);
+          StorageDead(_61);
+          _59 = Not(move _60);
+          StorageDead(_60);
+          _58 = opaque::<bool>(move _59) -> [return: bb5, unwind unreachable];
+      }
+  
+      bb5: {
+          StorageDead(_59);
+          StorageDead(_58);
+          StorageLive(_63);
+          StorageLive(_64);
+          StorageLive(_65);
+          StorageLive(_66);
+-         _66 = _37;
++         _66 = const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8];
+          StorageLive(_67);
+-         _67 = _39;
+-         _65 = Gt(move _66, move _67);
++         _67 = const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8];
++         _65 = Gt(const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8], const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8]);
+          StorageDead(_67);
+          StorageDead(_66);
+          _64 = Not(move _65);
+          StorageDead(_65);
+          _63 = opaque::<bool>(move _64) -> [return: bb6, unwind unreachable];
+      }
+  
+      bb6: {
+          StorageDead(_64);
+          StorageDead(_63);
+          _0 = const ();
+-         StorageDead(_39);
+-         StorageDead(_37);
++         nop;
++         nop;
+          StorageDead(_33);
+          StorageDead(_29);
+          StorageDead(_25);
+          StorageDead(_21);
+          StorageDead(_17);
+          StorageDead(_13);
+-         StorageDead(_7);
+-         StorageDead(_1);
++         nop;
++         nop;
+          return;
+      }
++ }
++ 
++ ALLOC1 (size: 16, align: 8) {
++     01 00 00 00 00 00 00 00 02 00 00 00 00 00 00 00 │ ................
++ }
++ 
++ ALLOC0 (size: 16, align: 8) {
++     01 00 00 00 00 00 00 00 01 00 00 00 00 00 00 00 │ ................
+  }
+  
diff --git a/tests/mir-opt/gvn.wide_ptr_ops.GVN.panic-unwind.diff b/tests/mir-opt/gvn.wide_ptr_ops.GVN.panic-unwind.diff
new file mode 100644
index 00000000000..4e5608a4425
--- /dev/null
+++ b/tests/mir-opt/gvn.wide_ptr_ops.GVN.panic-unwind.diff
@@ -0,0 +1,386 @@
+- // MIR for `wide_ptr_ops` before GVN
++ // MIR for `wide_ptr_ops` after GVN
+  
+  fn wide_ptr_ops() -> () {
+      let mut _0: ();
+      let _1: *const dyn std::marker::Send;
+      let mut _2: *const dyn std::marker::Send;
+      let _3: &dyn std::marker::Send;
+      let mut _4: &i32;
+      let _5: &i32;
+      let _6: i32;
+      let mut _8: *const dyn std::marker::Send;
+      let _9: &dyn std::marker::Send;
+      let mut _10: &i32;
+      let _11: &i32;
+      let _12: i32;
+      let mut _14: *const dyn std::marker::Send;
+      let mut _15: *const dyn std::marker::Send;
+      let mut _16: *const dyn std::marker::Send;
+      let mut _18: *const dyn std::marker::Send;
+      let mut _19: *const dyn std::marker::Send;
+      let mut _20: *const dyn std::marker::Send;
+      let mut _22: *const dyn std::marker::Send;
+      let mut _23: *const dyn std::marker::Send;
+      let mut _24: *const dyn std::marker::Send;
+      let mut _26: *const dyn std::marker::Send;
+      let mut _27: *const dyn std::marker::Send;
+      let mut _28: *const dyn std::marker::Send;
+      let mut _30: *const dyn std::marker::Send;
+      let mut _31: *const dyn std::marker::Send;
+      let mut _32: *const dyn std::marker::Send;
+      let mut _34: *const dyn std::marker::Send;
+      let mut _35: *const dyn std::marker::Send;
+      let mut _36: *const dyn std::marker::Send;
+      let mut _38: (usize, usize);
+      let mut _40: (usize, usize);
+      let _41: ();
+      let mut _42: bool;
+      let mut _43: bool;
+      let mut _44: *const [u8];
+      let mut _45: *const [u8];
+      let _46: ();
+      let mut _47: bool;
+      let mut _48: *const [u8];
+      let mut _49: *const [u8];
+      let _50: ();
+      let mut _51: bool;
+      let mut _52: *const [u8];
+      let mut _53: *const [u8];
+      let _54: ();
+      let mut _55: bool;
+      let mut _56: *const [u8];
+      let mut _57: *const [u8];
+      let _58: ();
+      let mut _59: bool;
+      let mut _60: bool;
+      let mut _61: *const [u8];
+      let mut _62: *const [u8];
+      let _63: ();
+      let mut _64: bool;
+      let mut _65: bool;
+      let mut _66: *const [u8];
+      let mut _67: *const [u8];
+      let mut _69: &i32;
+      scope 1 {
+          debug a => _1;
+          let _7: *const dyn std::marker::Send;
+          let mut _68: &i32;
+          scope 2 {
+              debug b => _7;
+              let _13: bool;
+              scope 3 {
+                  debug _val => _13;
+                  let _17: bool;
+                  scope 4 {
+                      debug _val => _17;
+                      let _21: bool;
+                      scope 5 {
+                          debug _val => _21;
+                          let _25: bool;
+                          scope 6 {
+                              debug _val => _25;
+                              let _29: bool;
+                              scope 7 {
+                                  debug _val => _29;
+                                  let _33: bool;
+                                  scope 8 {
+                                      debug _val => _33;
+                                      let _37: *const [u8];
+                                      scope 9 {
+                                          debug a => _37;
+                                          let _39: *const [u8];
+                                          scope 11 {
+                                              debug b => _39;
+                                          }
+                                          scope 12 {
+                                          }
+                                      }
+                                      scope 10 {
+                                      }
+                                  }
+                              }
+                          }
+                      }
+                  }
+              }
+          }
+      }
+  
+      bb0: {
+-         StorageLive(_1);
++         nop;
+          StorageLive(_2);
+          StorageLive(_3);
+          StorageLive(_4);
+          StorageLive(_5);
+          _69 = const _;
+          _5 = &(*_69);
+          _4 = &(*_5);
+          _3 = move _4 as &dyn std::marker::Send (PointerCoercion(Unsize));
+          StorageDead(_4);
+          _2 = &raw const (*_3);
+          _1 = move _2 as *const dyn std::marker::Send (PointerCoercion(Unsize));
+          StorageDead(_2);
+          StorageDead(_5);
+          StorageDead(_3);
+-         StorageLive(_7);
++         nop;
+          StorageLive(_8);
+          StorageLive(_9);
+          StorageLive(_10);
+          StorageLive(_11);
+          _68 = const _;
+          _11 = &(*_68);
+          _10 = &(*_11);
+          _9 = move _10 as &dyn std::marker::Send (PointerCoercion(Unsize));
+          StorageDead(_10);
+          _8 = &raw const (*_9);
+          _7 = move _8 as *const dyn std::marker::Send (PointerCoercion(Unsize));
+          StorageDead(_8);
+          StorageDead(_11);
+          StorageDead(_9);
+          StorageLive(_13);
+          StorageLive(_14);
+          _14 = _1;
+-         StorageLive(_15);
++         nop;
+          StorageLive(_16);
+          _16 = _7;
+-         _15 = move _16 as *const dyn std::marker::Send (PointerCoercion(Unsize));
++         _15 = _7 as *const dyn std::marker::Send (PointerCoercion(Unsize));
+          StorageDead(_16);
+-         _13 = Eq(move _14, move _15);
+-         StorageDead(_15);
++         _13 = Eq(_1, _15);
++         nop;
+          StorageDead(_14);
+          StorageLive(_17);
+          StorageLive(_18);
+          _18 = _1;
+          StorageLive(_19);
+          StorageLive(_20);
+          _20 = _7;
+-         _19 = move _20 as *const dyn std::marker::Send (PointerCoercion(Unsize));
++         _19 = _15;
+          StorageDead(_20);
+-         _17 = Ne(move _18, move _19);
++         _17 = Ne(_1, _15);
+          StorageDead(_19);
+          StorageDead(_18);
+          StorageLive(_21);
+          StorageLive(_22);
+          _22 = _1;
+          StorageLive(_23);
+          StorageLive(_24);
+          _24 = _7;
+-         _23 = move _24 as *const dyn std::marker::Send (PointerCoercion(Unsize));
++         _23 = _15;
+          StorageDead(_24);
+-         _21 = Lt(move _22, move _23);
++         _21 = Lt(_1, _15);
+          StorageDead(_23);
+          StorageDead(_22);
+          StorageLive(_25);
+          StorageLive(_26);
+          _26 = _1;
+          StorageLive(_27);
+          StorageLive(_28);
+          _28 = _7;
+-         _27 = move _28 as *const dyn std::marker::Send (PointerCoercion(Unsize));
++         _27 = _15;
+          StorageDead(_28);
+-         _25 = Le(move _26, move _27);
++         _25 = Le(_1, _15);
+          StorageDead(_27);
+          StorageDead(_26);
+          StorageLive(_29);
+          StorageLive(_30);
+          _30 = _1;
+          StorageLive(_31);
+          StorageLive(_32);
+          _32 = _7;
+-         _31 = move _32 as *const dyn std::marker::Send (PointerCoercion(Unsize));
++         _31 = _15;
+          StorageDead(_32);
+-         _29 = Gt(move _30, move _31);
++         _29 = Gt(_1, _15);
+          StorageDead(_31);
+          StorageDead(_30);
+          StorageLive(_33);
+          StorageLive(_34);
+          _34 = _1;
+          StorageLive(_35);
+          StorageLive(_36);
+          _36 = _7;
+-         _35 = move _36 as *const dyn std::marker::Send (PointerCoercion(Unsize));
++         _35 = _15;
+          StorageDead(_36);
+-         _33 = Ge(move _34, move _35);
++         _33 = Ge(_1, _15);
+          StorageDead(_35);
+          StorageDead(_34);
+-         StorageLive(_37);
++         nop;
+          StorageLive(_38);
+-         _38 = (const 1_usize, const 1_usize);
+-         _37 = move _38 as *const [u8] (Transmute);
++         _38 = const (1_usize, 1_usize);
++         _37 = const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8];
+          StorageDead(_38);
+-         StorageLive(_39);
++         nop;
+          StorageLive(_40);
+-         _40 = (const 1_usize, const 2_usize);
+-         _39 = move _40 as *const [u8] (Transmute);
++         _40 = const (1_usize, 2_usize);
++         _39 = const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8];
+          StorageDead(_40);
+          StorageLive(_41);
+-         StorageLive(_42);
++         nop;
+          StorageLive(_43);
+          StorageLive(_44);
+-         _44 = _37;
++         _44 = const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8];
+          StorageLive(_45);
+-         _45 = _39;
+-         _43 = Eq(move _44, move _45);
++         _45 = const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8];
++         _43 = Eq(const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8], const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8]);
+          StorageDead(_45);
+          StorageDead(_44);
+          _42 = Not(move _43);
+          StorageDead(_43);
+-         _41 = opaque::<bool>(move _42) -> [return: bb1, unwind continue];
++         _41 = opaque::<bool>(_42) -> [return: bb1, unwind continue];
+      }
+  
+      bb1: {
+-         StorageDead(_42);
++         nop;
+          StorageDead(_41);
+          StorageLive(_46);
+          StorageLive(_47);
+          StorageLive(_48);
+-         _48 = _37;
++         _48 = const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8];
+          StorageLive(_49);
+-         _49 = _39;
+-         _47 = Ne(move _48, move _49);
++         _49 = const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8];
++         _47 = _42;
+          StorageDead(_49);
+          StorageDead(_48);
+-         _46 = opaque::<bool>(move _47) -> [return: bb2, unwind continue];
++         _46 = opaque::<bool>(_42) -> [return: bb2, unwind continue];
+      }
+  
+      bb2: {
+          StorageDead(_47);
+          StorageDead(_46);
+          StorageLive(_50);
+          StorageLive(_51);
+          StorageLive(_52);
+-         _52 = _37;
++         _52 = const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8];
+          StorageLive(_53);
+-         _53 = _39;
+-         _51 = Le(move _52, move _53);
++         _53 = const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8];
++         _51 = Le(const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8], const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8]);
+          StorageDead(_53);
+          StorageDead(_52);
+          _50 = opaque::<bool>(move _51) -> [return: bb3, unwind continue];
+      }
+  
+      bb3: {
+          StorageDead(_51);
+          StorageDead(_50);
+          StorageLive(_54);
+          StorageLive(_55);
+          StorageLive(_56);
+-         _56 = _37;
++         _56 = const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8];
+          StorageLive(_57);
+-         _57 = _39;
+-         _55 = Lt(move _56, move _57);
++         _57 = const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8];
++         _55 = Lt(const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8], const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8]);
+          StorageDead(_57);
+          StorageDead(_56);
+          _54 = opaque::<bool>(move _55) -> [return: bb4, unwind continue];
+      }
+  
+      bb4: {
+          StorageDead(_55);
+          StorageDead(_54);
+          StorageLive(_58);
+          StorageLive(_59);
+          StorageLive(_60);
+          StorageLive(_61);
+-         _61 = _37;
++         _61 = const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8];
+          StorageLive(_62);
+-         _62 = _39;
+-         _60 = Ge(move _61, move _62);
++         _62 = const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8];
++         _60 = Ge(const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8], const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8]);
+          StorageDead(_62);
+          StorageDead(_61);
+          _59 = Not(move _60);
+          StorageDead(_60);
+          _58 = opaque::<bool>(move _59) -> [return: bb5, unwind continue];
+      }
+  
+      bb5: {
+          StorageDead(_59);
+          StorageDead(_58);
+          StorageLive(_63);
+          StorageLive(_64);
+          StorageLive(_65);
+          StorageLive(_66);
+-         _66 = _37;
++         _66 = const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8];
+          StorageLive(_67);
+-         _67 = _39;
+-         _65 = Gt(move _66, move _67);
++         _67 = const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8];
++         _65 = Gt(const Indirect { alloc_id: ALLOC0, offset: Size(0 bytes) }: *const [u8], const Indirect { alloc_id: ALLOC1, offset: Size(0 bytes) }: *const [u8]);
+          StorageDead(_67);
+          StorageDead(_66);
+          _64 = Not(move _65);
+          StorageDead(_65);
+          _63 = opaque::<bool>(move _64) -> [return: bb6, unwind continue];
+      }
+  
+      bb6: {
+          StorageDead(_64);
+          StorageDead(_63);
+          _0 = const ();
+-         StorageDead(_39);
+-         StorageDead(_37);
++         nop;
++         nop;
+          StorageDead(_33);
+          StorageDead(_29);
+          StorageDead(_25);
+          StorageDead(_21);
+          StorageDead(_17);
+          StorageDead(_13);
+-         StorageDead(_7);
+-         StorageDead(_1);
++         nop;
++         nop;
+          return;
+      }
++ }
++ 
++ ALLOC1 (size: 16, align: 8) {
++     01 00 00 00 00 00 00 00 02 00 00 00 00 00 00 00 │ ................
++ }
++ 
++ ALLOC0 (size: 16, align: 8) {
++     01 00 00 00 00 00 00 00 01 00 00 00 00 00 00 00 │ ................
+  }
+  
diff --git a/tests/mir-opt/inline/inline_coroutine.main.Inline.panic-abort.diff b/tests/mir-opt/inline/inline_coroutine.main.Inline.panic-abort.diff
index 68c612314f6..8e53427e7e0 100644
--- a/tests/mir-opt/inline/inline_coroutine.main.Inline.panic-abort.diff
+++ b/tests/mir-opt/inline/inline_coroutine.main.Inline.panic-abort.diff
@@ -36,7 +36,7 @@
 -         _4 = g() -> [return: bb1, unwind unreachable];
 +         _4 = {coroutine@$DIR/inline_coroutine.rs:19:5: 19:8 (#0)};
 +         _3 = &mut _4;
-+         _2 = Pin::<&mut {coroutine@$DIR/inline_coroutine.rs:19:5: 19:8}> { pointer: move _3 };
++         _2 = Pin::<&mut {coroutine@$DIR/inline_coroutine.rs:19:5: 19:8}> { pointer: _3 };
 +         StorageDead(_3);
 +         StorageLive(_5);
 +         _5 = const false;
diff --git a/tests/mir-opt/inline/inline_coroutine.main.Inline.panic-unwind.diff b/tests/mir-opt/inline/inline_coroutine.main.Inline.panic-unwind.diff
index 1bf14e8c3b3..b06db41af9d 100644
--- a/tests/mir-opt/inline/inline_coroutine.main.Inline.panic-unwind.diff
+++ b/tests/mir-opt/inline/inline_coroutine.main.Inline.panic-unwind.diff
@@ -36,7 +36,7 @@
 -         _4 = g() -> [return: bb1, unwind continue];
 +         _4 = {coroutine@$DIR/inline_coroutine.rs:19:5: 19:8 (#0)};
 +         _3 = &mut _4;
-+         _2 = Pin::<&mut {coroutine@$DIR/inline_coroutine.rs:19:5: 19:8}> { pointer: move _3 };
++         _2 = Pin::<&mut {coroutine@$DIR/inline_coroutine.rs:19:5: 19:8}> { pointer: _3 };
 +         StorageDead(_3);
 +         StorageLive(_5);
 +         _5 = const false;
diff --git a/tests/mir-opt/inline/inline_diverging.h.Inline.panic-abort.diff b/tests/mir-opt/inline/inline_diverging.h.Inline.panic-abort.diff
index da45ebcb4d8..2bbb830fc77 100644
--- a/tests/mir-opt/inline/inline_diverging.h.Inline.panic-abort.diff
+++ b/tests/mir-opt/inline/inline_diverging.h.Inline.panic-abort.diff
@@ -40,7 +40,7 @@
 + 
 +     bb2: {
 +         StorageDead(_5);
-+         _1 = (move _4, move _6);
++         _1 = (_4, _6);
 +         drop(_2) -> [return: bb3, unwind unreachable];
 +     }
 + 
diff --git a/tests/mir-opt/inline/inline_diverging.h.Inline.panic-unwind.diff b/tests/mir-opt/inline/inline_diverging.h.Inline.panic-unwind.diff
index d65c65e5fd0..bc4f2d24df0 100644
--- a/tests/mir-opt/inline/inline_diverging.h.Inline.panic-unwind.diff
+++ b/tests/mir-opt/inline/inline_diverging.h.Inline.panic-unwind.diff
@@ -43,7 +43,7 @@
 +         StorageDead(_5);
 +         StorageLive(_7);
 +         _7 = move _4;
-+         _1 = (move _7, move _6);
++         _1 = (move _7, _6);
 +         StorageDead(_7);
 +         StorageDead(_4);
 +         drop(_2) -> [return: bb3, unwind continue];
diff --git a/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-abort.mir b/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-abort.mir
index aeb93bd334f..d6a608476df 100644
--- a/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-abort.mir
+++ b/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-abort.mir
@@ -31,7 +31,7 @@ fn unwrap_unchecked(_1: Option<T>) -> T {
         _2 = discriminant(_1);
         _3 = Eq(_2, const 1_isize);
         assume(move _3);
-        _0 = move ((_1 as Some).0: T);
+        _0 = ((_1 as Some).0: T);
         StorageDead(_3);
         StorageDead(_2);
         StorageDead(_4);
diff --git a/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-unwind.mir
index aeb93bd334f..d6a608476df 100644
--- a/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-unwind.mir
+++ b/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-unwind.mir
@@ -31,7 +31,7 @@ fn unwrap_unchecked(_1: Option<T>) -> T {
         _2 = discriminant(_1);
         _3 = Eq(_2, const 1_isize);
         assume(move _3);
-        _0 = move ((_1 as Some).0: T);
+        _0 = ((_1 as Some).0: T);
         StorageDead(_3);
         StorageDead(_2);
         StorageDead(_4);
diff --git a/tests/mir-opt/issue_101973.inner.GVN.panic-abort.diff b/tests/mir-opt/issue_101973.inner.GVN.panic-abort.diff
index d2db8f61916..187290785c0 100644
--- a/tests/mir-opt/issue_101973.inner.GVN.panic-abort.diff
+++ b/tests/mir-opt/issue_101973.inner.GVN.panic-abort.diff
@@ -17,9 +17,8 @@
       let mut _12: u32;
       let mut _13: bool;
       scope 1 (inlined imm8) {
-          debug x => _1;
+          debug x => _5;
           let mut _14: u32;
-          let mut _15: u32;
           scope 2 {
               debug out => _4;
           }
@@ -33,17 +32,23 @@
           StorageLive(_2);
           StorageLive(_3);
           StorageLive(_4);
+          StorageLive(_5);
+          _5 = _1;
           _4 = const 0_u32;
-          StorageLive(_15);
-          StorageLive(_14);
-          _14 = Shr(_1, const 0_i32);
-          _15 = BitAnd(move _14, const 255_u32);
-          StorageDead(_14);
-          _4 = BitOr(const 0_u32, move _15);
-          StorageDead(_15);
+-         StorageLive(_14);
+-         _14 = BitAnd(_5, const 255_u32);
+-         _4 = BitOr(const 0_u32, move _14);
+-         StorageDead(_14);
++         nop;
++         _14 = BitAnd(_1, const 255_u32);
++         _4 = _14;
++         nop;
+          StorageDead(_5);
           StorageLive(_6);
           StorageLive(_7);
           StorageLive(_8);
+          StorageLive(_9);
+          _9 = _1;
 -         _10 = const 8_i32 as u32 (IntToInt);
 -         _11 = Lt(move _10, const 32_u32);
 -         assert(move _11, "attempt to shift right by `{}`, which would overflow", const 8_i32) -> [success: bb1, unwind unreachable];
@@ -53,7 +58,9 @@
       }
   
       bb1: {
-          _8 = Shr(_1, const 8_i32);
+-         _8 = Shr(move _9, const 8_i32);
++         _8 = Shr(_1, const 8_i32);
+          StorageDead(_9);
           _7 = BitAnd(move _8, const 15_u32);
           StorageDead(_8);
 -         _12 = const 1_i32 as u32 (IntToInt);
diff --git a/tests/mir-opt/issue_101973.inner.GVN.panic-unwind.diff b/tests/mir-opt/issue_101973.inner.GVN.panic-unwind.diff
index 514183b3bc0..99350bac478 100644
--- a/tests/mir-opt/issue_101973.inner.GVN.panic-unwind.diff
+++ b/tests/mir-opt/issue_101973.inner.GVN.panic-unwind.diff
@@ -17,9 +17,8 @@
       let mut _12: u32;
       let mut _13: bool;
       scope 1 (inlined imm8) {
-          debug x => _1;
+          debug x => _5;
           let mut _14: u32;
-          let mut _15: u32;
           scope 2 {
               debug out => _4;
           }
@@ -33,17 +32,23 @@
           StorageLive(_2);
           StorageLive(_3);
           StorageLive(_4);
+          StorageLive(_5);
+          _5 = _1;
           _4 = const 0_u32;
-          StorageLive(_15);
-          StorageLive(_14);
-          _14 = Shr(_1, const 0_i32);
-          _15 = BitAnd(move _14, const 255_u32);
-          StorageDead(_14);
-          _4 = BitOr(const 0_u32, move _15);
-          StorageDead(_15);
+-         StorageLive(_14);
+-         _14 = BitAnd(_5, const 255_u32);
+-         _4 = BitOr(const 0_u32, move _14);
+-         StorageDead(_14);
++         nop;
++         _14 = BitAnd(_1, const 255_u32);
++         _4 = _14;
++         nop;
+          StorageDead(_5);
           StorageLive(_6);
           StorageLive(_7);
           StorageLive(_8);
+          StorageLive(_9);
+          _9 = _1;
 -         _10 = const 8_i32 as u32 (IntToInt);
 -         _11 = Lt(move _10, const 32_u32);
 -         assert(move _11, "attempt to shift right by `{}`, which would overflow", const 8_i32) -> [success: bb1, unwind continue];
@@ -53,7 +58,9 @@
       }
   
       bb1: {
-          _8 = Shr(_1, const 8_i32);
+-         _8 = Shr(move _9, const 8_i32);
++         _8 = Shr(_1, const 8_i32);
+          StorageDead(_9);
           _7 = BitAnd(move _8, const 15_u32);
           StorageDead(_8);
 -         _12 = const 1_i32 as u32 (IntToInt);
diff --git a/tests/mir-opt/issues/issue_59352.num_to_digit.PreCodegen.after.panic-abort.mir b/tests/mir-opt/issues/issue_59352.num_to_digit.PreCodegen.after.panic-abort.mir
index 5d25c655700..f7be8b75db7 100644
--- a/tests/mir-opt/issues/issue_59352.num_to_digit.PreCodegen.after.panic-abort.mir
+++ b/tests/mir-opt/issues/issue_59352.num_to_digit.PreCodegen.after.panic-abort.mir
@@ -51,7 +51,7 @@ fn num_to_digit(_1: char) -> u32 {
     }
 
     bb4: {
-        _7 = core::panicking::panic(const "called `Option::unwrap()` on a `None` value") -> unwind unreachable;
+        _7 = option::unwrap_failed() -> unwind unreachable;
     }
 
     bb5: {
diff --git a/tests/mir-opt/issues/issue_59352.num_to_digit.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/issues/issue_59352.num_to_digit.PreCodegen.after.panic-unwind.mir
index 4677c0108e3..e76fe992ac7 100644
--- a/tests/mir-opt/issues/issue_59352.num_to_digit.PreCodegen.after.panic-unwind.mir
+++ b/tests/mir-opt/issues/issue_59352.num_to_digit.PreCodegen.after.panic-unwind.mir
@@ -51,7 +51,7 @@ fn num_to_digit(_1: char) -> u32 {
     }
 
     bb4: {
-        _7 = core::panicking::panic(const "called `Option::unwrap()` on a `None` value") -> unwind continue;
+        _7 = option::unwrap_failed() -> unwind continue;
     }
 
     bb5: {
diff --git a/tests/mir-opt/jump_threading.identity.JumpThreading.panic-abort.diff b/tests/mir-opt/jump_threading.identity.JumpThreading.panic-abort.diff
index f04ca72dd6d..9cc4385f60b 100644
--- a/tests/mir-opt/jump_threading.identity.JumpThreading.panic-abort.diff
+++ b/tests/mir-opt/jump_threading.identity.JumpThreading.panic-abort.diff
@@ -110,7 +110,7 @@
       bb6: {
           _12 = move ((_4 as Err).0: i32);
           StorageLive(_13);
-          _13 = Result::<Infallible, i32>::Err(move _12);
+          _13 = Result::<Infallible, i32>::Err(_12);
           _3 = ControlFlow::<Result<Infallible, i32>, i32>::Break(move _13);
           StorageDead(_13);
 -         goto -> bb5;
@@ -119,7 +119,7 @@
   
       bb7: {
           _11 = move ((_4 as Ok).0: i32);
-          _3 = ControlFlow::<Result<Infallible, i32>, i32>::Continue(move _11);
+          _3 = ControlFlow::<Result<Infallible, i32>, i32>::Continue(_11);
           goto -> bb5;
 +     }
 + 
diff --git a/tests/mir-opt/jump_threading.identity.JumpThreading.panic-unwind.diff b/tests/mir-opt/jump_threading.identity.JumpThreading.panic-unwind.diff
index f04ca72dd6d..9cc4385f60b 100644
--- a/tests/mir-opt/jump_threading.identity.JumpThreading.panic-unwind.diff
+++ b/tests/mir-opt/jump_threading.identity.JumpThreading.panic-unwind.diff
@@ -110,7 +110,7 @@
       bb6: {
           _12 = move ((_4 as Err).0: i32);
           StorageLive(_13);
-          _13 = Result::<Infallible, i32>::Err(move _12);
+          _13 = Result::<Infallible, i32>::Err(_12);
           _3 = ControlFlow::<Result<Infallible, i32>, i32>::Break(move _13);
           StorageDead(_13);
 -         goto -> bb5;
@@ -119,7 +119,7 @@
   
       bb7: {
           _11 = move ((_4 as Ok).0: i32);
-          _3 = ControlFlow::<Result<Infallible, i32>, i32>::Continue(move _11);
+          _3 = ControlFlow::<Result<Infallible, i32>, i32>::Continue(_11);
           goto -> bb5;
 +     }
 + 
diff --git a/tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.32bit.panic-abort.diff b/tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.32bit.panic-abort.diff
index 47e0d402347..de9a1a075ad 100644
--- a/tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.32bit.panic-abort.diff
+++ b/tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.32bit.panic-abort.diff
@@ -19,7 +19,7 @@
           }
           scope 5 (inlined <std::alloc::Global as Allocator>::allocate) {
               debug self => _9;
-              debug layout => _1;
+              debug layout => _8;
           }
           scope 6 (inlined #[track_caller] Result::<NonNull<[u8]>, std::alloc::AllocError>::unwrap) {
               debug self => _6;
@@ -51,6 +51,8 @@
       }
   
       bb0: {
+-         StorageLive(_1);
++         nop;
           StorageLive(_2);
 -         _2 = Option::<Layout>::None;
 +         _2 = const Option::<Layout>::None;
@@ -62,7 +64,7 @@
       }
   
       bb1: {
-          _11 = core::panicking::panic(const "called `Option::unwrap()` on a `None` value") -> unwind unreachable;
+          _11 = option::unwrap_failed() -> unwind unreachable;
       }
   
       bb2: {
@@ -74,12 +76,20 @@
           StorageLive(_4);
           StorageLive(_5);
           StorageLive(_6);
+          StorageLive(_7);
           _9 = const _;
--         _6 = std::alloc::Global::alloc_impl(_9, _1, const false) -> [return: bb3, unwind unreachable];
+-         _7 = _9;
++         _7 = const {ALLOC1<imm>: &std::alloc::Global};
+          StorageLive(_8);
+-         _8 = _1;
+-         _6 = std::alloc::Global::alloc_impl(move _7, move _8, const false) -> [return: bb3, unwind unreachable];
++         _8 = const Layout {{ size: Indirect { alloc_id: ALLOC0, offset: Size(4 bytes) }: usize, align: std::ptr::Alignment(Scalar(0x00000000): std::ptr::alignment::AlignmentEnum32) }};
 +         _6 = std::alloc::Global::alloc_impl(const {ALLOC1<imm>: &std::alloc::Global}, const Layout {{ size: Indirect { alloc_id: ALLOC0, offset: Size(4 bytes) }: usize, align: std::ptr::Alignment(Scalar(0x00000000): std::ptr::alignment::AlignmentEnum32) }}, const false) -> [return: bb3, unwind unreachable];
       }
   
       bb3: {
+          StorageDead(_8);
+          StorageDead(_7);
           StorageLive(_12);
           StorageLive(_15);
           _12 = discriminant(_6);
@@ -109,6 +119,8 @@
           _3 = move _4 as *mut u8 (PtrToPtr);
           StorageDead(_4);
           StorageDead(_3);
+-         StorageDead(_1);
++         nop;
           return;
       }
   
diff --git a/tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.32bit.panic-unwind.diff b/tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.32bit.panic-unwind.diff
index dee57ce6c27..f784db0f409 100644
--- a/tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.32bit.panic-unwind.diff
+++ b/tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.32bit.panic-unwind.diff
@@ -19,7 +19,7 @@
           }
           scope 5 (inlined <std::alloc::Global as Allocator>::allocate) {
               debug self => _9;
-              debug layout => _1;
+              debug layout => _8;
           }
           scope 6 (inlined NonNull::<[u8]>::as_ptr) {
               debug self => _5;
@@ -36,6 +36,8 @@
       }
   
       bb0: {
+-         StorageLive(_1);
++         nop;
           StorageLive(_2);
 -         _2 = Option::<Layout>::None;
 +         _2 = const Option::<Layout>::None;
@@ -56,11 +58,13 @@
           _3 = move _4 as *mut u8 (PtrToPtr);
           StorageDead(_4);
           StorageDead(_3);
+-         StorageDead(_1);
++         nop;
           return;
       }
   
       bb2: {
-          _11 = core::panicking::panic(const "called `Option::unwrap()` on a `None` value") -> unwind continue;
+          _11 = option::unwrap_failed() -> unwind continue;
       }
   
       bb3: {
@@ -72,12 +76,20 @@
           StorageLive(_4);
           StorageLive(_5);
           StorageLive(_6);
+          StorageLive(_7);
           _9 = const _;
--         _6 = std::alloc::Global::alloc_impl(_9, _1, const false) -> [return: bb4, unwind continue];
+-         _7 = _9;
++         _7 = const {ALLOC1<imm>: &std::alloc::Global};
+          StorageLive(_8);
+-         _8 = _1;
+-         _6 = std::alloc::Global::alloc_impl(move _7, move _8, const false) -> [return: bb4, unwind continue];
++         _8 = const Layout {{ size: Indirect { alloc_id: ALLOC0, offset: Size(4 bytes) }: usize, align: std::ptr::Alignment(Scalar(0x00000000): std::ptr::alignment::AlignmentEnum32) }};
 +         _6 = std::alloc::Global::alloc_impl(const {ALLOC1<imm>: &std::alloc::Global}, const Layout {{ size: Indirect { alloc_id: ALLOC0, offset: Size(4 bytes) }: usize, align: std::ptr::Alignment(Scalar(0x00000000): std::ptr::alignment::AlignmentEnum32) }}, const false) -> [return: bb4, unwind continue];
       }
   
       bb4: {
+          StorageDead(_8);
+          StorageDead(_7);
           _5 = Result::<NonNull<[u8]>, std::alloc::AllocError>::unwrap(move _6) -> [return: bb1, unwind continue];
       }
   
diff --git a/tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.64bit.panic-abort.diff b/tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.64bit.panic-abort.diff
index a255b15920c..162b7fa4618 100644
--- a/tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.64bit.panic-abort.diff
+++ b/tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.64bit.panic-abort.diff
@@ -19,7 +19,7 @@
           }
           scope 5 (inlined <std::alloc::Global as Allocator>::allocate) {
               debug self => _9;
-              debug layout => _1;
+              debug layout => _8;
           }
           scope 6 (inlined #[track_caller] Result::<NonNull<[u8]>, std::alloc::AllocError>::unwrap) {
               debug self => _6;
@@ -51,6 +51,8 @@
       }
   
       bb0: {
+-         StorageLive(_1);
++         nop;
           StorageLive(_2);
 -         _2 = Option::<Layout>::None;
 +         _2 = const Option::<Layout>::None;
@@ -62,7 +64,7 @@
       }
   
       bb1: {
-          _11 = core::panicking::panic(const "called `Option::unwrap()` on a `None` value") -> unwind unreachable;
+          _11 = option::unwrap_failed() -> unwind unreachable;
       }
   
       bb2: {
@@ -74,12 +76,20 @@
           StorageLive(_4);
           StorageLive(_5);
           StorageLive(_6);
+          StorageLive(_7);
           _9 = const _;
--         _6 = std::alloc::Global::alloc_impl(_9, _1, const false) -> [return: bb3, unwind unreachable];
+-         _7 = _9;
++         _7 = const {ALLOC1<imm>: &std::alloc::Global};
+          StorageLive(_8);
+-         _8 = _1;
+-         _6 = std::alloc::Global::alloc_impl(move _7, move _8, const false) -> [return: bb3, unwind unreachable];
++         _8 = const Layout {{ size: Indirect { alloc_id: ALLOC0, offset: Size(8 bytes) }: usize, align: std::ptr::Alignment(Scalar(0x0000000000000000): std::ptr::alignment::AlignmentEnum64) }};
 +         _6 = std::alloc::Global::alloc_impl(const {ALLOC1<imm>: &std::alloc::Global}, const Layout {{ size: Indirect { alloc_id: ALLOC0, offset: Size(8 bytes) }: usize, align: std::ptr::Alignment(Scalar(0x0000000000000000): std::ptr::alignment::AlignmentEnum64) }}, const false) -> [return: bb3, unwind unreachable];
       }
   
       bb3: {
+          StorageDead(_8);
+          StorageDead(_7);
           StorageLive(_12);
           StorageLive(_15);
           _12 = discriminant(_6);
@@ -109,6 +119,8 @@
           _3 = move _4 as *mut u8 (PtrToPtr);
           StorageDead(_4);
           StorageDead(_3);
+-         StorageDead(_1);
++         nop;
           return;
       }
   
diff --git a/tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.64bit.panic-unwind.diff b/tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.64bit.panic-unwind.diff
index 192ffea2591..400aac6d64b 100644
--- a/tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.64bit.panic-unwind.diff
+++ b/tests/mir-opt/pre-codegen/issue_117368_print_invalid_constant.main.GVN.64bit.panic-unwind.diff
@@ -19,7 +19,7 @@
           }
           scope 5 (inlined <std::alloc::Global as Allocator>::allocate) {
               debug self => _9;
-              debug layout => _1;
+              debug layout => _8;
           }
           scope 6 (inlined NonNull::<[u8]>::as_ptr) {
               debug self => _5;
@@ -36,6 +36,8 @@
       }
   
       bb0: {
+-         StorageLive(_1);
++         nop;
           StorageLive(_2);
 -         _2 = Option::<Layout>::None;
 +         _2 = const Option::<Layout>::None;
@@ -56,11 +58,13 @@
           _3 = move _4 as *mut u8 (PtrToPtr);
           StorageDead(_4);
           StorageDead(_3);
+-         StorageDead(_1);
++         nop;
           return;
       }
   
       bb2: {
-          _11 = core::panicking::panic(const "called `Option::unwrap()` on a `None` value") -> unwind continue;
+          _11 = option::unwrap_failed() -> unwind continue;
       }
   
       bb3: {
@@ -72,12 +76,20 @@
           StorageLive(_4);
           StorageLive(_5);
           StorageLive(_6);
+          StorageLive(_7);
           _9 = const _;
--         _6 = std::alloc::Global::alloc_impl(_9, _1, const false) -> [return: bb4, unwind continue];
+-         _7 = _9;
++         _7 = const {ALLOC1<imm>: &std::alloc::Global};
+          StorageLive(_8);
+-         _8 = _1;
+-         _6 = std::alloc::Global::alloc_impl(move _7, move _8, const false) -> [return: bb4, unwind continue];
++         _8 = const Layout {{ size: Indirect { alloc_id: ALLOC0, offset: Size(8 bytes) }: usize, align: std::ptr::Alignment(Scalar(0x0000000000000000): std::ptr::alignment::AlignmentEnum64) }};
 +         _6 = std::alloc::Global::alloc_impl(const {ALLOC1<imm>: &std::alloc::Global}, const Layout {{ size: Indirect { alloc_id: ALLOC0, offset: Size(8 bytes) }: usize, align: std::ptr::Alignment(Scalar(0x0000000000000000): std::ptr::alignment::AlignmentEnum64) }}, const false) -> [return: bb4, unwind continue];
       }
   
       bb4: {
+          StorageDead(_8);
+          StorageDead(_7);
           _5 = Result::<NonNull<[u8]>, std::alloc::AllocError>::unwrap(move _6) -> [return: bb1, unwind continue];
       }
   
diff --git a/tests/mir-opt/pre-codegen/loops.filter_mapped.PreCodegen.after.mir b/tests/mir-opt/pre-codegen/loops.filter_mapped.PreCodegen.after.mir
index 8dbb688999a..8d182069adc 100644
--- a/tests/mir-opt/pre-codegen/loops.filter_mapped.PreCodegen.after.mir
+++ b/tests/mir-opt/pre-codegen/loops.filter_mapped.PreCodegen.after.mir
@@ -32,7 +32,7 @@ fn filter_mapped(_1: impl Iterator<Item = T>, _2: impl Fn(T) -> Option<U>) -> ()
 
     bb1: {
         StorageLive(_4);
-        _4 = move _3;
+        _4 = _3;
         goto -> bb2;
     }
 
diff --git a/tests/mir-opt/pre-codegen/loops.int_range.PreCodegen.after.mir b/tests/mir-opt/pre-codegen/loops.int_range.PreCodegen.after.mir
index 42c7eb3c6aa..e27e417ed4a 100644
--- a/tests/mir-opt/pre-codegen/loops.int_range.PreCodegen.after.mir
+++ b/tests/mir-opt/pre-codegen/loops.int_range.PreCodegen.after.mir
@@ -46,7 +46,7 @@ fn int_range(_1: usize, _2: usize) -> () {
     bb0: {
         _3 = std::ops::Range::<usize> { start: _1, end: _2 };
         StorageLive(_4);
-        _4 = move _3;
+        _4 = _3;
         goto -> bb1;
     }
 
diff --git a/tests/mir-opt/pre-codegen/loops.mapped.PreCodegen.after.mir b/tests/mir-opt/pre-codegen/loops.mapped.PreCodegen.after.mir
index 30bdc131090..b800a1be22b 100644
--- a/tests/mir-opt/pre-codegen/loops.mapped.PreCodegen.after.mir
+++ b/tests/mir-opt/pre-codegen/loops.mapped.PreCodegen.after.mir
@@ -27,7 +27,7 @@ fn mapped(_1: impl Iterator<Item = T>, _2: impl Fn(T) -> U) -> () {
 
     bb1: {
         StorageLive(_4);
-        _4 = move _3;
+        _4 = _3;
         goto -> bb2;
     }
 
diff --git a/tests/mir-opt/pre-codegen/mem_replace.mem_replace.PreCodegen.after.mir b/tests/mir-opt/pre-codegen/mem_replace.mem_replace.PreCodegen.after.mir
index 713d6cc558a..f0cb4ca31fe 100644
--- a/tests/mir-opt/pre-codegen/mem_replace.mem_replace.PreCodegen.after.mir
+++ b/tests/mir-opt/pre-codegen/mem_replace.mem_replace.PreCodegen.after.mir
@@ -19,22 +19,23 @@ fn mem_replace(_1: &mut u32, _2: u32) -> u32 {
             }
             scope 4 (inlined std::ptr::read::<u32>) {
                 debug src => _1;
+                let mut _3: *const u32;
                 scope 5 {
                     scope 6 (inlined std::ptr::read::runtime::<u32>) {
-                        debug src => _1;
+                        debug src => _3;
                         scope 7 (inlined intrinsics::is_aligned_and_not_null::<u32>) {
-                            debug ptr => _1;
+                            debug ptr => _3;
                             scope 8 (inlined std::ptr::const_ptr::<impl *const u32>::is_null) {
-                                debug self => _1;
-                                let mut _3: *const u8;
+                                debug self => _3;
+                                let mut _4: *const u8;
                                 scope 9 {
                                     scope 10 (inlined std::ptr::const_ptr::<impl *const T>::is_null::runtime_impl) {
-                                        debug ptr => _3;
+                                        debug ptr => _4;
                                         scope 11 (inlined std::ptr::const_ptr::<impl *const u8>::addr) {
-                                            debug self => _3;
+                                            debug self => _4;
                                             scope 12 {
                                                 scope 13 (inlined std::ptr::const_ptr::<impl *const u8>::cast::<()>) {
-                                                    debug self => _3;
+                                                    debug self => _4;
                                                 }
                                             }
                                         }
@@ -42,7 +43,7 @@ fn mem_replace(_1: &mut u32, _2: u32) -> u32 {
                                 }
                             }
                             scope 14 (inlined std::ptr::const_ptr::<impl *const u32>::is_aligned) {
-                                debug self => _1;
+                                debug self => _3;
                                 scope 15 (inlined align_of::<u32>) {
                                 }
                             }
@@ -55,7 +56,9 @@ fn mem_replace(_1: &mut u32, _2: u32) -> u32 {
 
     bb0: {
         StorageLive(_3);
+        StorageLive(_4);
         _0 = (*_1);
+        StorageDead(_4);
         StorageDead(_3);
         (*_1) = _2;
         return;
diff --git a/tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.32bit.panic-abort.diff b/tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.32bit.panic-abort.diff
index 4e34233a979..0e7e1f971ec 100644
--- a/tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.32bit.panic-abort.diff
+++ b/tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.32bit.panic-abort.diff
@@ -17,7 +17,7 @@
               debug y => _3;
               let _8: u32;
               scope 3 {
-                  debug z => _9;
+                  debug z => _8;
               }
           }
       }
@@ -50,7 +50,13 @@
 +         _3 = const 3_i32;
           StorageDead(_5);
           StorageDead(_4);
+          StorageLive(_8);
+          StorageLive(_9);
           _9 = const 42_u32;
+-         _8 = _9;
++         _8 = const 42_u32;
+          StorageDead(_9);
+          StorageDead(_8);
           StorageDead(_3);
           StorageDead(_1);
           return;
diff --git a/tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.32bit.panic-unwind.diff b/tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.32bit.panic-unwind.diff
index 275f17e52ae..9071a3339c0 100644
--- a/tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.32bit.panic-unwind.diff
+++ b/tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.32bit.panic-unwind.diff
@@ -17,7 +17,7 @@
               debug y => _3;
               let _8: u32;
               scope 3 {
-                  debug z => _9;
+                  debug z => _8;
               }
           }
       }
@@ -50,7 +50,13 @@
 +         _3 = const 3_i32;
           StorageDead(_5);
           StorageDead(_4);
+          StorageLive(_8);
+          StorageLive(_9);
           _9 = const 42_u32;
+-         _8 = _9;
++         _8 = const 42_u32;
+          StorageDead(_9);
+          StorageDead(_8);
           StorageDead(_3);
           StorageDead(_1);
           return;
diff --git a/tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.64bit.panic-abort.diff b/tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.64bit.panic-abort.diff
index 4e34233a979..0e7e1f971ec 100644
--- a/tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.64bit.panic-abort.diff
+++ b/tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.64bit.panic-abort.diff
@@ -17,7 +17,7 @@
               debug y => _3;
               let _8: u32;
               scope 3 {
-                  debug z => _9;
+                  debug z => _8;
               }
           }
       }
@@ -50,7 +50,13 @@
 +         _3 = const 3_i32;
           StorageDead(_5);
           StorageDead(_4);
+          StorageLive(_8);
+          StorageLive(_9);
           _9 = const 42_u32;
+-         _8 = _9;
++         _8 = const 42_u32;
+          StorageDead(_9);
+          StorageDead(_8);
           StorageDead(_3);
           StorageDead(_1);
           return;
diff --git a/tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.64bit.panic-unwind.diff b/tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.64bit.panic-unwind.diff
index 275f17e52ae..9071a3339c0 100644
--- a/tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.64bit.panic-unwind.diff
+++ b/tests/mir-opt/pre-codegen/optimizes_into_variable.main.GVN.64bit.panic-unwind.diff
@@ -17,7 +17,7 @@
               debug y => _3;
               let _8: u32;
               scope 3 {
-                  debug z => _9;
+                  debug z => _8;
               }
           }
       }
@@ -50,7 +50,13 @@
 +         _3 = const 3_i32;
           StorageDead(_5);
           StorageDead(_4);
+          StorageLive(_8);
+          StorageLive(_9);
           _9 = const 42_u32;
+-         _8 = _9;
++         _8 = const 42_u32;
+          StorageDead(_9);
+          StorageDead(_8);
           StorageDead(_3);
           StorageDead(_1);
           return;
diff --git a/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-abort.mir b/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-abort.mir
index e5940bd8201..99805da5669 100644
--- a/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-abort.mir
+++ b/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-abort.mir
@@ -49,7 +49,7 @@ fn forward_loop(_1: u32, _2: u32, _3: impl Fn(u32)) -> () {
     bb0: {
         _4 = std::ops::Range::<u32> { start: _1, end: _2 };
         StorageLive(_5);
-        _5 = move _4;
+        _5 = _4;
         goto -> bb1;
     }
 
diff --git a/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-unwind.mir
index 87e7485cb36..f40f1307175 100644
--- a/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-unwind.mir
+++ b/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-unwind.mir
@@ -49,7 +49,7 @@ fn forward_loop(_1: u32, _2: u32, _3: impl Fn(u32)) -> () {
     bb0: {
         _4 = std::ops::Range::<u32> { start: _1, end: _2 };
         StorageLive(_5);
-        _5 = move _4;
+        _5 = _4;
         goto -> bb1;
     }
 
diff --git a/tests/mir-opt/pre-codegen/range_iter.inclusive_loop.PreCodegen.after.panic-abort.mir b/tests/mir-opt/pre-codegen/range_iter.inclusive_loop.PreCodegen.after.panic-abort.mir
index 1b23e421368..0836600cb6e 100644
--- a/tests/mir-opt/pre-codegen/range_iter.inclusive_loop.PreCodegen.after.panic-abort.mir
+++ b/tests/mir-opt/pre-codegen/range_iter.inclusive_loop.PreCodegen.after.panic-abort.mir
@@ -34,7 +34,7 @@ fn inclusive_loop(_1: u32, _2: u32, _3: impl Fn(u32)) -> () {
     bb0: {
         _4 = RangeInclusive::<u32> { start: _1, end: _2, exhausted: const false };
         StorageLive(_5);
-        _5 = move _4;
+        _5 = _4;
         goto -> bb1;
     }
 
diff --git a/tests/mir-opt/pre-codegen/range_iter.inclusive_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/range_iter.inclusive_loop.PreCodegen.after.panic-unwind.mir
index a677e8b439f..8c1794de524 100644
--- a/tests/mir-opt/pre-codegen/range_iter.inclusive_loop.PreCodegen.after.panic-unwind.mir
+++ b/tests/mir-opt/pre-codegen/range_iter.inclusive_loop.PreCodegen.after.panic-unwind.mir
@@ -34,7 +34,7 @@ fn inclusive_loop(_1: u32, _2: u32, _3: impl Fn(u32)) -> () {
     bb0: {
         _4 = RangeInclusive::<u32> { start: _1, end: _2, exhausted: const false };
         StorageLive(_5);
-        _5 = move _4;
+        _5 = _4;
         goto -> bb1;
     }
 
diff --git a/tests/mir-opt/pre-codegen/slice_filter.variant_a-{closure#0}.PreCodegen.after.mir b/tests/mir-opt/pre-codegen/slice_filter.variant_a-{closure#0}.PreCodegen.after.mir
index cc009e45e7e..7370da5629c 100644
--- a/tests/mir-opt/pre-codegen/slice_filter.variant_a-{closure#0}.PreCodegen.after.mir
+++ b/tests/mir-opt/pre-codegen/slice_filter.variant_a-{closure#0}.PreCodegen.after.mir
@@ -94,6 +94,8 @@ fn variant_a::{closure#0}(_1: &mut {closure@$DIR/slice_filter.rs:8:25: 8:39}, _2
         StorageLive(_9);
         _9 = _6;
         _10 = &_9;
+        StorageLive(_11);
+        StorageLive(_12);
         _11 = _4;
         _12 = _9;
         StorageLive(_13);
@@ -103,6 +105,8 @@ fn variant_a::{closure#0}(_1: &mut {closure@$DIR/slice_filter.rs:8:25: 8:39}, _2
         _15 = Le(move _13, move _14);
         StorageDead(_14);
         StorageDead(_13);
+        StorageDead(_12);
+        StorageDead(_11);
         switchInt(move _15) -> [0: bb1, otherwise: bb2];
     }
 
@@ -124,6 +128,8 @@ fn variant_a::{closure#0}(_1: &mut {closure@$DIR/slice_filter.rs:8:25: 8:39}, _2
         StorageLive(_17);
         _17 = _5;
         _18 = &_17;
+        StorageLive(_19);
+        StorageLive(_20);
         _19 = _7;
         _20 = _17;
         StorageLive(_21);
@@ -133,6 +139,8 @@ fn variant_a::{closure#0}(_1: &mut {closure@$DIR/slice_filter.rs:8:25: 8:39}, _2
         _23 = Le(move _21, move _22);
         StorageDead(_22);
         StorageDead(_21);
+        StorageDead(_20);
+        StorageDead(_19);
         switchInt(move _23) -> [0: bb3, otherwise: bb8];
     }
 
@@ -151,6 +159,8 @@ fn variant_a::{closure#0}(_1: &mut {closure@$DIR/slice_filter.rs:8:25: 8:39}, _2
         StorageLive(_25);
         _25 = _4;
         _26 = &_25;
+        StorageLive(_27);
+        StorageLive(_28);
         _27 = _6;
         _28 = _25;
         StorageLive(_29);
@@ -160,6 +170,8 @@ fn variant_a::{closure#0}(_1: &mut {closure@$DIR/slice_filter.rs:8:25: 8:39}, _2
         _31 = Le(move _29, move _30);
         StorageDead(_30);
         StorageDead(_29);
+        StorageDead(_28);
+        StorageDead(_27);
         switchInt(move _31) -> [0: bb5, otherwise: bb6];
     }
 
@@ -181,6 +193,8 @@ fn variant_a::{closure#0}(_1: &mut {closure@$DIR/slice_filter.rs:8:25: 8:39}, _2
         StorageLive(_33);
         _33 = _7;
         _34 = &_33;
+        StorageLive(_35);
+        StorageLive(_36);
         _35 = _5;
         _36 = _33;
         StorageLive(_37);
@@ -190,6 +204,8 @@ fn variant_a::{closure#0}(_1: &mut {closure@$DIR/slice_filter.rs:8:25: 8:39}, _2
         _0 = Le(move _37, move _38);
         StorageDead(_38);
         StorageDead(_37);
+        StorageDead(_36);
+        StorageDead(_35);
         StorageDead(_33);
         StorageDead(_34);
         StorageDead(_32);
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 a12411a0413..bc7617bb6dd 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
@@ -20,7 +20,8 @@ fn slice_get_mut_usize(_1: &mut [u32], _2: usize) -> Option<&mut u32> {
                     debug self => _2;
                     debug slice => _5;
                     let mut _6: *mut u32;
-                    let mut _9: &[&str];
+                    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;
@@ -33,16 +34,16 @@ fn slice_get_mut_usize(_1: &mut [u32], _2: usize) -> Option<&mut u32> {
                         }
                     }
                     scope 6 (inlined std::ptr::mut_ptr::<impl *mut [u32]>::len) {
-                        debug self => _5;
-                        let mut _10: *const [u32];
+                        debug self => _9;
+                        let mut _11: *const [u32];
                         scope 7 (inlined std::ptr::metadata::<[u32]>) {
-                            debug ptr => _10;
+                            debug ptr => _11;
                             scope 8 {
                             }
                         }
                     }
                     scope 9 (inlined Arguments::<'_>::new_const) {
-                        debug pieces => _9;
+                        debug pieces => _10;
                     }
                 }
             }
@@ -50,6 +51,7 @@ fn slice_get_mut_usize(_1: &mut [u32], _2: usize) -> Option<&mut u32> {
     }
 
     bb0: {
+        StorageLive(_7);
         StorageLive(_4);
         StorageLive(_3);
         _3 = Len((*_1));
@@ -70,10 +72,12 @@ fn slice_get_mut_usize(_1: &mut [u32], _2: usize) -> Option<&mut u32> {
         _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);
@@ -85,6 +89,7 @@ fn slice_get_mut_usize(_1: &mut [u32], _2: usize) -> Option<&mut u32> {
 
     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 a12411a0413..bc7617bb6dd 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
@@ -20,7 +20,8 @@ fn slice_get_mut_usize(_1: &mut [u32], _2: usize) -> Option<&mut u32> {
                     debug self => _2;
                     debug slice => _5;
                     let mut _6: *mut u32;
-                    let mut _9: &[&str];
+                    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;
@@ -33,16 +34,16 @@ fn slice_get_mut_usize(_1: &mut [u32], _2: usize) -> Option<&mut u32> {
                         }
                     }
                     scope 6 (inlined std::ptr::mut_ptr::<impl *mut [u32]>::len) {
-                        debug self => _5;
-                        let mut _10: *const [u32];
+                        debug self => _9;
+                        let mut _11: *const [u32];
                         scope 7 (inlined std::ptr::metadata::<[u32]>) {
-                            debug ptr => _10;
+                            debug ptr => _11;
                             scope 8 {
                             }
                         }
                     }
                     scope 9 (inlined Arguments::<'_>::new_const) {
-                        debug pieces => _9;
+                        debug pieces => _10;
                     }
                 }
             }
@@ -50,6 +51,7 @@ fn slice_get_mut_usize(_1: &mut [u32], _2: usize) -> Option<&mut u32> {
     }
 
     bb0: {
+        StorageLive(_7);
         StorageLive(_4);
         StorageLive(_3);
         _3 = Len((*_1));
@@ -70,10 +72,12 @@ fn slice_get_mut_usize(_1: &mut [u32], _2: usize) -> Option<&mut u32> {
         _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);
@@ -85,6 +89,7 @@ fn slice_get_mut_usize(_1: &mut [u32], _2: usize) -> Option<&mut u32> {
 
     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 0d95f81c37c..36329f8fc68 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
@@ -19,7 +19,8 @@ fn slice_get_unchecked_mut_range(_1: &mut [u32], _2: std::ops::Range<usize>) ->
                 debug slice => _5;
                 let mut _7: *mut u32;
                 let mut _8: *mut u32;
-                let mut _14: &[&str];
+                let mut _14: *mut [u32];
+                let mut _15: &[&str];
                 scope 4 {
                     let _6: usize;
                     scope 5 {
@@ -53,16 +54,16 @@ fn slice_get_unchecked_mut_range(_1: &mut [u32], _2: std::ops::Range<usize>) ->
                     }
                 }
                 scope 6 (inlined std::ptr::mut_ptr::<impl *mut [u32]>::len) {
-                    debug self => _5;
-                    let mut _15: *const [u32];
+                    debug self => _14;
+                    let mut _16: *const [u32];
                     scope 7 (inlined std::ptr::metadata::<[u32]>) {
-                        debug ptr => _15;
+                        debug ptr => _16;
                         scope 8 {
                         }
                     }
                 }
                 scope 9 (inlined Arguments::<'_>::new_const) {
-                    debug pieces => _14;
+                    debug pieces => _15;
                 }
             }
         }
@@ -74,8 +75,9 @@ fn slice_get_unchecked_mut_range(_1: &mut [u32], _2: std::ops::Range<usize>) ->
         StorageLive(_5);
         _5 = &raw mut (*_1);
         StorageLive(_14);
-        StorageLive(_6);
         StorageLive(_15);
+        StorageLive(_6);
+        StorageLive(_16);
         _6 = SubUnchecked(_4, _3);
         StorageLive(_8);
         StorageLive(_7);
@@ -96,8 +98,9 @@ fn slice_get_unchecked_mut_range(_1: &mut [u32], _2: std::ops::Range<usize>) ->
         StorageDead(_12);
         StorageDead(_9);
         StorageDead(_8);
-        StorageDead(_15);
+        StorageDead(_16);
         StorageDead(_6);
+        StorageDead(_15);
         StorageDead(_14);
         StorageDead(_5);
         _0 = &mut (*_13);
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 0d95f81c37c..36329f8fc68 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
@@ -19,7 +19,8 @@ fn slice_get_unchecked_mut_range(_1: &mut [u32], _2: std::ops::Range<usize>) ->
                 debug slice => _5;
                 let mut _7: *mut u32;
                 let mut _8: *mut u32;
-                let mut _14: &[&str];
+                let mut _14: *mut [u32];
+                let mut _15: &[&str];
                 scope 4 {
                     let _6: usize;
                     scope 5 {
@@ -53,16 +54,16 @@ fn slice_get_unchecked_mut_range(_1: &mut [u32], _2: std::ops::Range<usize>) ->
                     }
                 }
                 scope 6 (inlined std::ptr::mut_ptr::<impl *mut [u32]>::len) {
-                    debug self => _5;
-                    let mut _15: *const [u32];
+                    debug self => _14;
+                    let mut _16: *const [u32];
                     scope 7 (inlined std::ptr::metadata::<[u32]>) {
-                        debug ptr => _15;
+                        debug ptr => _16;
                         scope 8 {
                         }
                     }
                 }
                 scope 9 (inlined Arguments::<'_>::new_const) {
-                    debug pieces => _14;
+                    debug pieces => _15;
                 }
             }
         }
@@ -74,8 +75,9 @@ fn slice_get_unchecked_mut_range(_1: &mut [u32], _2: std::ops::Range<usize>) ->
         StorageLive(_5);
         _5 = &raw mut (*_1);
         StorageLive(_14);
-        StorageLive(_6);
         StorageLive(_15);
+        StorageLive(_6);
+        StorageLive(_16);
         _6 = SubUnchecked(_4, _3);
         StorageLive(_8);
         StorageLive(_7);
@@ -96,8 +98,9 @@ fn slice_get_unchecked_mut_range(_1: &mut [u32], _2: std::ops::Range<usize>) ->
         StorageDead(_12);
         StorageDead(_9);
         StorageDead(_8);
-        StorageDead(_15);
+        StorageDead(_16);
         StorageDead(_6);
+        StorageDead(_15);
         StorageDead(_14);
         StorageDead(_5);
         _0 = &mut (*_13);
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 c58b630a0c3..26b2663fa35 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,20 +42,21 @@ fn enumerated_loop(_1: &[T], _2: impl Fn(usize, &T)) -> () {
                         scope 13 (inlined NonNull::<T>::new_unchecked) {
                             debug ptr => _9;
                             let mut _10: *const T;
+                            let mut _24: *mut T;
                             scope 14 {
                                 scope 15 (inlined NonNull::<T>::new_unchecked::runtime::<T>) {
-                                    debug ptr => _9;
+                                    debug ptr => _24;
                                     scope 16 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null) {
-                                        debug self => _9;
-                                        let mut _24: *mut u8;
+                                        debug self => _24;
+                                        let mut _25: *mut u8;
                                         scope 17 {
                                             scope 18 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null::runtime_impl) {
-                                                debug ptr => _24;
+                                                debug ptr => _25;
                                                 scope 19 (inlined std::ptr::mut_ptr::<impl *mut u8>::addr) {
-                                                    debug self => _24;
+                                                    debug self => _25;
                                                     scope 20 {
                                                         scope 21 (inlined std::ptr::mut_ptr::<impl *mut u8>::cast::<()>) {
-                                                            debug self => _24;
+                                                            debug self => _25;
                                                         }
                                                     }
                                                 }
@@ -131,8 +132,10 @@ fn enumerated_loop(_1: &[T], _2: impl Fn(usize, &T)) -> () {
         _9 = _4 as *mut T (PtrToPtr);
         StorageLive(_10);
         StorageLive(_24);
+        StorageLive(_25);
         _10 = _9 as *const T (PointerCoercion(MutToConstPointer));
         _11 = NonNull::<T> { pointer: _10 };
+        StorageDead(_25);
         StorageDead(_24);
         StorageDead(_10);
         StorageDead(_9);
@@ -143,10 +146,10 @@ fn enumerated_loop(_1: &[T], _2: impl Fn(usize, &T)) -> () {
         StorageDead(_11);
         StorageDead(_7);
         StorageDead(_4);
-        _14 = Enumerate::<std::slice::Iter<'_, T>> { iter: move _13, count: const 0_usize };
+        _14 = Enumerate::<std::slice::Iter<'_, T>> { iter: _13, count: const 0_usize };
         StorageDead(_13);
         StorageLive(_15);
-        _15 = move _14;
+        _15 = _14;
         goto -> bb4;
     }
 
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 1a805f0fd8d..a055612bd5f 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,20 +42,21 @@ fn enumerated_loop(_1: &[T], _2: impl Fn(usize, &T)) -> () {
                         scope 13 (inlined NonNull::<T>::new_unchecked) {
                             debug ptr => _9;
                             let mut _10: *const T;
+                            let mut _24: *mut T;
                             scope 14 {
                                 scope 15 (inlined NonNull::<T>::new_unchecked::runtime::<T>) {
-                                    debug ptr => _9;
+                                    debug ptr => _24;
                                     scope 16 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null) {
-                                        debug self => _9;
-                                        let mut _24: *mut u8;
+                                        debug self => _24;
+                                        let mut _25: *mut u8;
                                         scope 17 {
                                             scope 18 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null::runtime_impl) {
-                                                debug ptr => _24;
+                                                debug ptr => _25;
                                                 scope 19 (inlined std::ptr::mut_ptr::<impl *mut u8>::addr) {
-                                                    debug self => _24;
+                                                    debug self => _25;
                                                     scope 20 {
                                                         scope 21 (inlined std::ptr::mut_ptr::<impl *mut u8>::cast::<()>) {
-                                                            debug self => _24;
+                                                            debug self => _25;
                                                         }
                                                     }
                                                 }
@@ -131,8 +132,10 @@ fn enumerated_loop(_1: &[T], _2: impl Fn(usize, &T)) -> () {
         _9 = _4 as *mut T (PtrToPtr);
         StorageLive(_10);
         StorageLive(_24);
+        StorageLive(_25);
         _10 = _9 as *const T (PointerCoercion(MutToConstPointer));
         _11 = NonNull::<T> { pointer: _10 };
+        StorageDead(_25);
         StorageDead(_24);
         StorageDead(_10);
         StorageDead(_9);
@@ -143,10 +146,10 @@ fn enumerated_loop(_1: &[T], _2: impl Fn(usize, &T)) -> () {
         StorageDead(_11);
         StorageDead(_7);
         StorageDead(_4);
-        _14 = Enumerate::<std::slice::Iter<'_, T>> { iter: move _13, count: const 0_usize };
+        _14 = Enumerate::<std::slice::Iter<'_, T>> { iter: _13, count: const 0_usize };
         StorageDead(_13);
         StorageLive(_15);
-        _15 = move _14;
+        _15 = _14;
         goto -> bb4;
     }
 
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 09075eed6a9..471491108e0 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,20 +39,21 @@ fn forward_loop(_1: &[T], _2: impl Fn(&T)) -> () {
                         scope 13 (inlined NonNull::<T>::new_unchecked) {
                             debug ptr => _9;
                             let mut _10: *const T;
+                            let mut _22: *mut T;
                             scope 14 {
                                 scope 15 (inlined NonNull::<T>::new_unchecked::runtime::<T>) {
-                                    debug ptr => _9;
+                                    debug ptr => _22;
                                     scope 16 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null) {
-                                        debug self => _9;
-                                        let mut _22: *mut u8;
+                                        debug self => _22;
+                                        let mut _23: *mut u8;
                                         scope 17 {
                                             scope 18 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null::runtime_impl) {
-                                                debug ptr => _22;
+                                                debug ptr => _23;
                                                 scope 19 (inlined std::ptr::mut_ptr::<impl *mut u8>::addr) {
-                                                    debug self => _22;
+                                                    debug self => _23;
                                                     scope 20 {
                                                         scope 21 (inlined std::ptr::mut_ptr::<impl *mut u8>::cast::<()>) {
-                                                            debug self => _22;
+                                                            debug self => _23;
                                                         }
                                                     }
                                                 }
@@ -121,8 +122,10 @@ fn forward_loop(_1: &[T], _2: impl Fn(&T)) -> () {
         _9 = _4 as *mut T (PtrToPtr);
         StorageLive(_10);
         StorageLive(_22);
+        StorageLive(_23);
         _10 = _9 as *const T (PointerCoercion(MutToConstPointer));
         _11 = NonNull::<T> { pointer: _10 };
+        StorageDead(_23);
         StorageDead(_22);
         StorageDead(_10);
         StorageDead(_9);
@@ -134,7 +137,7 @@ fn forward_loop(_1: &[T], _2: impl Fn(&T)) -> () {
         StorageDead(_7);
         StorageDead(_4);
         StorageLive(_14);
-        _14 = move _13;
+        _14 = _13;
         goto -> bb4;
     }
 
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 47b84746468..bbf38aba91f 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,20 +39,21 @@ fn forward_loop(_1: &[T], _2: impl Fn(&T)) -> () {
                         scope 13 (inlined NonNull::<T>::new_unchecked) {
                             debug ptr => _9;
                             let mut _10: *const T;
+                            let mut _22: *mut T;
                             scope 14 {
                                 scope 15 (inlined NonNull::<T>::new_unchecked::runtime::<T>) {
-                                    debug ptr => _9;
+                                    debug ptr => _22;
                                     scope 16 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null) {
-                                        debug self => _9;
-                                        let mut _22: *mut u8;
+                                        debug self => _22;
+                                        let mut _23: *mut u8;
                                         scope 17 {
                                             scope 18 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null::runtime_impl) {
-                                                debug ptr => _22;
+                                                debug ptr => _23;
                                                 scope 19 (inlined std::ptr::mut_ptr::<impl *mut u8>::addr) {
-                                                    debug self => _22;
+                                                    debug self => _23;
                                                     scope 20 {
                                                         scope 21 (inlined std::ptr::mut_ptr::<impl *mut u8>::cast::<()>) {
-                                                            debug self => _22;
+                                                            debug self => _23;
                                                         }
                                                     }
                                                 }
@@ -121,8 +122,10 @@ fn forward_loop(_1: &[T], _2: impl Fn(&T)) -> () {
         _9 = _4 as *mut T (PtrToPtr);
         StorageLive(_10);
         StorageLive(_22);
+        StorageLive(_23);
         _10 = _9 as *const T (PointerCoercion(MutToConstPointer));
         _11 = NonNull::<T> { pointer: _10 };
+        StorageDead(_23);
         StorageDead(_22);
         StorageDead(_10);
         StorageDead(_9);
@@ -134,7 +137,7 @@ fn forward_loop(_1: &[T], _2: impl Fn(&T)) -> () {
         StorageDead(_7);
         StorageDead(_4);
         StorageLive(_14);
-        _14 = move _13;
+        _14 = _13;
         goto -> bb4;
     }
 
diff --git a/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-abort.mir b/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-abort.mir
index 6a99f15774f..83915d3c449 100644
--- a/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-abort.mir
+++ b/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-abort.mir
@@ -58,7 +58,7 @@ fn range_loop(_1: &[T], _2: impl Fn(usize, &T)) -> () {
         _4 = std::ops::Range::<usize> { start: const 0_usize, end: move _3 };
         StorageDead(_3);
         StorageLive(_5);
-        _5 = move _4;
+        _5 = _4;
         goto -> bb1;
     }
 
diff --git a/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-unwind.mir
index 4f028fa0a64..0a005a460e8 100644
--- a/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-unwind.mir
+++ b/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-unwind.mir
@@ -58,7 +58,7 @@ fn range_loop(_1: &[T], _2: impl Fn(usize, &T)) -> () {
         _4 = std::ops::Range::<usize> { start: const 0_usize, end: move _3 };
         StorageDead(_3);
         StorageLive(_5);
-        _5 = move _4;
+        _5 = _4;
         goto -> bb1;
     }
 
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 5ed7ca5e2b8..f9c8ab4db60 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,20 +44,21 @@ fn reverse_loop(_1: &[T], _2: impl Fn(&T)) -> () {
                         scope 13 (inlined NonNull::<T>::new_unchecked) {
                             debug ptr => _9;
                             let mut _10: *const T;
+                            let mut _24: *mut T;
                             scope 14 {
                                 scope 15 (inlined NonNull::<T>::new_unchecked::runtime::<T>) {
-                                    debug ptr => _9;
+                                    debug ptr => _24;
                                     scope 16 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null) {
-                                        debug self => _9;
-                                        let mut _24: *mut u8;
+                                        debug self => _24;
+                                        let mut _25: *mut u8;
                                         scope 17 {
                                             scope 18 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null::runtime_impl) {
-                                                debug ptr => _24;
+                                                debug ptr => _25;
                                                 scope 19 (inlined std::ptr::mut_ptr::<impl *mut u8>::addr) {
-                                                    debug self => _24;
+                                                    debug self => _25;
                                                     scope 20 {
                                                         scope 21 (inlined std::ptr::mut_ptr::<impl *mut u8>::cast::<()>) {
-                                                            debug self => _24;
+                                                            debug self => _25;
                                                         }
                                                     }
                                                 }
@@ -133,8 +134,10 @@ fn reverse_loop(_1: &[T], _2: impl Fn(&T)) -> () {
         _9 = _4 as *mut T (PtrToPtr);
         StorageLive(_10);
         StorageLive(_24);
+        StorageLive(_25);
         _10 = _9 as *const T (PointerCoercion(MutToConstPointer));
         _11 = NonNull::<T> { pointer: _10 };
+        StorageDead(_25);
         StorageDead(_24);
         StorageDead(_10);
         StorageDead(_9);
@@ -145,10 +148,10 @@ fn reverse_loop(_1: &[T], _2: impl Fn(&T)) -> () {
         StorageDead(_11);
         StorageDead(_7);
         StorageDead(_4);
-        _14 = Rev::<std::slice::Iter<'_, T>> { iter: move _13 };
+        _14 = Rev::<std::slice::Iter<'_, T>> { iter: _13 };
         StorageDead(_13);
         StorageLive(_15);
-        _15 = move _14;
+        _15 = _14;
         goto -> bb4;
     }
 
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 bbb979d23b3..65f423ac326 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,20 +44,21 @@ fn reverse_loop(_1: &[T], _2: impl Fn(&T)) -> () {
                         scope 13 (inlined NonNull::<T>::new_unchecked) {
                             debug ptr => _9;
                             let mut _10: *const T;
+                            let mut _24: *mut T;
                             scope 14 {
                                 scope 15 (inlined NonNull::<T>::new_unchecked::runtime::<T>) {
-                                    debug ptr => _9;
+                                    debug ptr => _24;
                                     scope 16 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null) {
-                                        debug self => _9;
-                                        let mut _24: *mut u8;
+                                        debug self => _24;
+                                        let mut _25: *mut u8;
                                         scope 17 {
                                             scope 18 (inlined std::ptr::mut_ptr::<impl *mut T>::is_null::runtime_impl) {
-                                                debug ptr => _24;
+                                                debug ptr => _25;
                                                 scope 19 (inlined std::ptr::mut_ptr::<impl *mut u8>::addr) {
-                                                    debug self => _24;
+                                                    debug self => _25;
                                                     scope 20 {
                                                         scope 21 (inlined std::ptr::mut_ptr::<impl *mut u8>::cast::<()>) {
-                                                            debug self => _24;
+                                                            debug self => _25;
                                                         }
                                                     }
                                                 }
@@ -133,8 +134,10 @@ fn reverse_loop(_1: &[T], _2: impl Fn(&T)) -> () {
         _9 = _4 as *mut T (PtrToPtr);
         StorageLive(_10);
         StorageLive(_24);
+        StorageLive(_25);
         _10 = _9 as *const T (PointerCoercion(MutToConstPointer));
         _11 = NonNull::<T> { pointer: _10 };
+        StorageDead(_25);
         StorageDead(_24);
         StorageDead(_10);
         StorageDead(_9);
@@ -145,10 +148,10 @@ fn reverse_loop(_1: &[T], _2: impl Fn(&T)) -> () {
         StorageDead(_11);
         StorageDead(_7);
         StorageDead(_4);
-        _14 = Rev::<std::slice::Iter<'_, T>> { iter: move _13 };
+        _14 = Rev::<std::slice::Iter<'_, T>> { iter: _13 };
         StorageDead(_13);
         StorageLive(_15);
-        _15 = move _14;
+        _15 = _14;
         goto -> bb4;
     }
 
diff --git a/tests/mir-opt/pre-codegen/try_identity.new.PreCodegen.after.mir b/tests/mir-opt/pre-codegen/try_identity.new.PreCodegen.after.mir
index 0bf4a267002..c1d4d4871d0 100644
--- a/tests/mir-opt/pre-codegen/try_identity.new.PreCodegen.after.mir
+++ b/tests/mir-opt/pre-codegen/try_identity.new.PreCodegen.after.mir
@@ -31,13 +31,13 @@ fn new(_1: Result<T, E>) -> Result<T, E> {
 
     bb1: {
         _3 = move ((_1 as Ok).0: T);
-        _4 = ControlFlow::<E, T>::Continue(move _3);
+        _4 = ControlFlow::<E, T>::Continue(_3);
         goto -> bb3;
     }
 
     bb2: {
         _5 = move ((_1 as Err).0: E);
-        _4 = ControlFlow::<E, T>::Break(move _5);
+        _4 = ControlFlow::<E, T>::Break(_5);
         goto -> bb3;
     }
 
@@ -48,14 +48,14 @@ fn new(_1: Result<T, E>) -> Result<T, E> {
 
     bb4: {
         _7 = move ((_4 as Continue).0: T);
-        _0 = Result::<T, E>::Ok(move _7);
+        _0 = Result::<T, E>::Ok(_7);
         StorageDead(_4);
         goto -> bb6;
     }
 
     bb5: {
         _8 = move ((_4 as Break).0: E);
-        _0 = Result::<T, E>::Err(move _8);
+        _0 = Result::<T, E>::Err(_8);
         StorageDead(_4);
         goto -> bb6;
     }
diff --git a/tests/mir-opt/pre-codegen/try_identity.old.PreCodegen.after.mir b/tests/mir-opt/pre-codegen/try_identity.old.PreCodegen.after.mir
index 7ccb8b0430d..d6883ac9fda 100644
--- a/tests/mir-opt/pre-codegen/try_identity.old.PreCodegen.after.mir
+++ b/tests/mir-opt/pre-codegen/try_identity.old.PreCodegen.after.mir
@@ -20,13 +20,13 @@ fn old(_1: Result<T, E>) -> Result<T, E> {
 
     bb1: {
         _3 = move ((_1 as Ok).0: T);
-        _0 = Result::<T, E>::Ok(move _3);
+        _0 = Result::<T, E>::Ok(_3);
         goto -> bb3;
     }
 
     bb2: {
         _4 = move ((_1 as Err).0: E);
-        _0 = Result::<T, E>::Err(move _4);
+        _0 = Result::<T, E>::Err(_4);
         goto -> bb3;
     }
 
diff --git a/tests/mir-opt/separate_const_switch.identity.SeparateConstSwitch.diff b/tests/mir-opt/separate_const_switch.identity.SeparateConstSwitch.diff
index a12db0a730c..e7280f14837 100644
--- a/tests/mir-opt/separate_const_switch.identity.SeparateConstSwitch.diff
+++ b/tests/mir-opt/separate_const_switch.identity.SeparateConstSwitch.diff
@@ -4,92 +4,96 @@
   fn identity(_1: Result<i32, i32>) -> Result<i32, i32> {
       debug x => _1;
       let mut _0: std::result::Result<i32, i32>;
-      let mut _2: i32;
-      let mut _3: std::ops::ControlFlow<std::result::Result<std::convert::Infallible, i32>, i32>;
-      let mut _4: std::result::Result<i32, i32>;
-      let mut _5: isize;
-      let _6: std::result::Result<std::convert::Infallible, i32>;
-      let mut _7: std::result::Result<std::convert::Infallible, i32>;
-      let _8: i32;
+      let mut _2: std::ops::ControlFlow<std::result::Result<std::convert::Infallible, i32>, i32>;
+      let mut _3: std::result::Result<i32, i32>;
+      let mut _4: isize;
+      let _5: std::result::Result<std::convert::Infallible, i32>;
+      let mut _6: std::result::Result<std::convert::Infallible, i32>;
+      let _7: i32;
       scope 1 {
-          debug residual => _6;
+          debug residual => _5;
           scope 2 {
               scope 8 (inlined #[track_caller] <Result<i32, i32> as FromResidual<Result<Infallible, i32>>>::from_residual) {
                   debug residual => _6;
-                  let _13: i32;
-                  let mut _14: i32;
+                  let _12: i32;
                   scope 9 {
-                      debug e => _13;
+                      debug e => _12;
                       scope 10 (inlined <i32 as From<i32>>::from) {
-                          debug t => _13;
+                          debug t => _12;
                       }
                   }
               }
           }
       }
       scope 3 {
-          debug val => _8;
+          debug val => _7;
           scope 4 {
           }
       }
       scope 5 (inlined <Result<i32, i32> as Try>::branch) {
-          debug self => _1;
-          let mut _9: isize;
+          debug self => _3;
+          let mut _8: isize;
+          let _9: i32;
           let _10: i32;
-          let _11: i32;
-          let mut _12: std::result::Result<std::convert::Infallible, i32>;
+          let mut _11: std::result::Result<std::convert::Infallible, i32>;
           scope 6 {
-              debug v => _10;
+              debug v => _9;
           }
           scope 7 {
-              debug e => _11;
+              debug e => _10;
           }
       }
   
       bb0: {
+          StorageLive(_2);
           StorageLive(_3);
+          _3 = _1;
+          StorageLive(_8);
           StorageLive(_9);
           StorageLive(_10);
-          StorageLive(_11);
-          _9 = discriminant(_1);
-          switchInt(move _9) -> [0: bb5, 1: bb4, otherwise: bb6];
+          _8 = discriminant(_1);
+          switchInt(move _8) -> [0: bb5, 1: bb4, otherwise: bb6];
       }
   
       bb1: {
-          _8 = ((_3 as Continue).0: i32);
-          _0 = Result::<i32, i32>::Ok(_8);
-          StorageDead(_3);
+          _7 = ((_2 as Continue).0: i32);
+          _0 = Result::<i32, i32>::Ok(_7);
+          StorageDead(_2);
           return;
       }
   
       bb2: {
-          _6 = ((_3 as Break).0: std::result::Result<std::convert::Infallible, i32>);
-          _13 = ((_6 as Err).0: i32);
-          _0 = Result::<i32, i32>::Err(move _13);
-          StorageDead(_3);
+          _5 = ((_2 as Break).0: std::result::Result<std::convert::Infallible, i32>);
+          StorageLive(_6);
+          _6 = _5;
+          _12 = move ((_5 as Err).0: i32);
+          _0 = Result::<i32, i32>::Err(_12);
+          StorageDead(_6);
+          StorageDead(_2);
           return;
       }
   
       bb3: {
-          StorageDead(_11);
           StorageDead(_10);
           StorageDead(_9);
-          _5 = discriminant(_3);
-          switchInt(move _5) -> [0: bb1, 1: bb2, otherwise: bb6];
+          StorageDead(_8);
+          StorageDead(_3);
+          _4 = discriminant(_2);
+          switchInt(move _4) -> [0: bb1, 1: bb2, otherwise: bb6];
       }
   
       bb4: {
-          _11 = ((_1 as Err).0: i32);
-          StorageLive(_12);
-          _12 = Result::<Infallible, i32>::Err(move _11);
-          _3 = ControlFlow::<Result<Infallible, i32>, i32>::Break(move _12);
-          StorageDead(_12);
+          _10 = move ((_1 as Err).0: i32);
+          StorageLive(_11);
+          _11 = Result::<Infallible, i32>::Err(_10);
+          _2 = ControlFlow::<Result<Infallible, i32>, i32>::Break(move _11);
+          StorageDead(_11);
           goto -> bb3;
       }
   
       bb5: {
-          _10 = ((_1 as Ok).0: i32);
-          _3 = ControlFlow::<Result<Infallible, i32>, i32>::Continue(move _10);
+          _9 = move ((_1 as Ok).0: i32);
+          _2 = ControlFlow::<Result<Infallible, i32>, i32>::Continue(_9);
           goto -> bb3;
       }
   
diff --git a/tests/mir-opt/separate_const_switch.too_complex.SeparateConstSwitch.diff b/tests/mir-opt/separate_const_switch.too_complex.SeparateConstSwitch.diff
index 80f40b86919..294bfa661cf 100644
--- a/tests/mir-opt/separate_const_switch.too_complex.SeparateConstSwitch.diff
+++ b/tests/mir-opt/separate_const_switch.too_complex.SeparateConstSwitch.diff
@@ -7,24 +7,21 @@
       let mut _2: std::ops::ControlFlow<usize, i32>;
       let mut _3: isize;
       let _4: i32;
-      let mut _5: i32;
-      let _6: usize;
-      let mut _7: usize;
-      let mut _8: isize;
-      let _9: i32;
-      let mut _10: i32;
-      let _11: usize;
+      let _5: usize;
+      let mut _6: isize;
+      let _7: i32;
+      let _8: usize;
       scope 1 {
           debug v => _4;
       }
       scope 2 {
-          debug r => _6;
+          debug r => _5;
       }
       scope 3 {
-          debug v => _9;
+          debug v => _7;
       }
       scope 4 {
-          debug r => _11;
+          debug r => _8;
       }
   
       bb0: {
@@ -34,8 +31,8 @@
       }
   
       bb1: {
-          _6 = ((_1 as Err).0: usize);
-          _2 = ControlFlow::<usize, i32>::Break(_6);
+          _5 = ((_1 as Err).0: usize);
+          _2 = ControlFlow::<usize, i32>::Break(_5);
           goto -> bb3;
       }
   
@@ -46,21 +43,21 @@
       }
   
       bb3: {
-          _8 = discriminant(_2);
-          switchInt(move _8) -> [0: bb5, 1: bb4, otherwise: bb7];
+          _6 = discriminant(_2);
+          switchInt(move _6) -> [0: bb5, 1: bb4, otherwise: bb7];
       }
   
       bb4: {
-          StorageLive(_11);
-          _11 = ((_2 as Break).0: usize);
-          _0 = Option::<i32>::None;
-          StorageDead(_11);
+          StorageLive(_8);
+          _8 = ((_2 as Break).0: usize);
+          _0 = const Option::<i32>::None;
+          StorageDead(_8);
           goto -> bb6;
       }
   
       bb5: {
-          _9 = ((_2 as Continue).0: i32);
-          _0 = Option::<i32>::Some(_9);
+          _7 = ((_2 as Continue).0: i32);
+          _0 = Option::<i32>::Some(_7);
           goto -> bb6;
       }
   
@@ -74,3 +71,7 @@
       }
   }
   
+  ALLOC0 (size: 8, align: 4) {
+      00 00 00 00 __ __ __ __                         │ ....░░░░
+  }
+  
diff --git a/tests/mir-opt/simplify_match.main.GVN.panic-abort.diff b/tests/mir-opt/simplify_match.main.GVN.panic-abort.diff
index d7ade041e4c..33b36f660cb 100644
--- a/tests/mir-opt/simplify_match.main.GVN.panic-abort.diff
+++ b/tests/mir-opt/simplify_match.main.GVN.panic-abort.diff
@@ -10,8 +10,15 @@
       }
   
       bb0: {
+          StorageLive(_1);
+-         StorageLive(_2);
++         nop;
           _2 = const false;
--         switchInt(_2) -> [0: bb2, otherwise: bb1];
+-         _1 = _2;
+-         StorageDead(_2);
+-         switchInt(_1) -> [0: bb2, otherwise: bb1];
++         _1 = const false;
++         nop;
 +         switchInt(const false) -> [0: bb2, otherwise: bb1];
       }
   
@@ -20,6 +27,7 @@
       }
   
       bb2: {
+          StorageDead(_1);
           return;
       }
   }
diff --git a/tests/mir-opt/simplify_match.main.GVN.panic-unwind.diff b/tests/mir-opt/simplify_match.main.GVN.panic-unwind.diff
index 931c5c43c4c..e5c3adff623 100644
--- a/tests/mir-opt/simplify_match.main.GVN.panic-unwind.diff
+++ b/tests/mir-opt/simplify_match.main.GVN.panic-unwind.diff
@@ -10,8 +10,15 @@
       }
   
       bb0: {
+          StorageLive(_1);
+-         StorageLive(_2);
++         nop;
           _2 = const false;
--         switchInt(_2) -> [0: bb2, otherwise: bb1];
+-         _1 = _2;
+-         StorageDead(_2);
+-         switchInt(_1) -> [0: bb2, otherwise: bb1];
++         _1 = const false;
++         nop;
 +         switchInt(const false) -> [0: bb2, otherwise: bb1];
       }
   
@@ -20,6 +27,7 @@
       }
   
       bb2: {
+          StorageDead(_1);
           return;
       }
   }
diff --git a/tests/rustdoc-ui/feature-gate-custom_code_classes_in_docs.rs b/tests/rustdoc-ui/feature-gate-custom_code_classes_in_docs.rs
index 99263a944f8..1e7cdfc9ba7 100644
--- a/tests/rustdoc-ui/feature-gate-custom_code_classes_in_docs.rs
+++ b/tests/rustdoc-ui/feature-gate-custom_code_classes_in_docs.rs
@@ -6,6 +6,7 @@
 //~^^^ WARNING custom classes in code blocks will change behaviour
 //~| NOTE found these custom classes: class=language-c
 //~| NOTE see issue #79483 <https://github.com/rust-lang/rust/issues/79483>
+//~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 //~| HELP add `#![feature(custom_code_classes_in_docs)]` to the crate attributes to enable
 pub struct Bar;
 
diff --git a/tests/rustdoc-ui/feature-gate-custom_code_classes_in_docs.stderr b/tests/rustdoc-ui/feature-gate-custom_code_classes_in_docs.stderr
index 1a2360d9b30..822806997c2 100644
--- a/tests/rustdoc-ui/feature-gate-custom_code_classes_in_docs.stderr
+++ b/tests/rustdoc-ui/feature-gate-custom_code_classes_in_docs.stderr
@@ -8,6 +8,7 @@ LL | | /// ```
    |
    = note: see issue #79483 <https://github.com/rust-lang/rust/issues/79483> for more information
    = help: add `#![feature(custom_code_classes_in_docs)]` 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: found these custom classes: class=language-c
 
 warning: 1 warning emitted
diff --git a/tests/rustdoc-ui/feature-gate-doc_cfg_hide.stderr b/tests/rustdoc-ui/feature-gate-doc_cfg_hide.stderr
index 0b982cd9fd3..55135986ffe 100644
--- a/tests/rustdoc-ui/feature-gate-doc_cfg_hide.stderr
+++ b/tests/rustdoc-ui/feature-gate-doc_cfg_hide.stderr
@@ -6,6 +6,7 @@ LL | #![doc(cfg_hide(test))]
    |
    = note: see issue #43781 <https://github.com/rust-lang/rust/issues/43781> for more information
    = help: add `#![feature(doc_cfg_hide)]` 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 1 previous error
 
diff --git a/tests/rustdoc/issue-52873.rs b/tests/rustdoc-ui/ice-blanket-impl-52873.rs
index 8000ce73bd4..2520957bd00 100644
--- a/tests/rustdoc/issue-52873.rs
+++ b/tests/rustdoc-ui/ice-blanket-impl-52873.rs
@@ -1,3 +1,7 @@
+// check-pass
+// https://github.com/rust-lang/rust/issues/52873
+#![crate_name="foo"]
+
 // Regression test for #52873. We used to ICE due to unexpected
 // overflows when checking for "blanket impl inclusion".
 
diff --git a/tests/rustdoc/issue-55001.rs b/tests/rustdoc-ui/ice-blanket-impl-selection-55001.rs
index f6c7f9a3d08..babcb3dda14 100644
--- a/tests/rustdoc/issue-55001.rs
+++ b/tests/rustdoc-ui/ice-blanket-impl-selection-55001.rs
@@ -1,3 +1,7 @@
+// check-pass
+// https://github.com/rust-lang/rust/issues/55001
+#![crate_name="foo"]
+
 // Regression test for issue #55001. Previously, we would incorrectly
 // cache certain trait selection results when checking for blanket impls,
 // resulting in an ICE when we tried to confirm the cached ParamCandidate
diff --git a/tests/rustdoc-ui/intra-doc/feature-gate-intra-doc-pointers.stderr b/tests/rustdoc-ui/intra-doc/feature-gate-intra-doc-pointers.stderr
index 2c946ed48db..1245bc15bb0 100644
--- a/tests/rustdoc-ui/intra-doc/feature-gate-intra-doc-pointers.stderr
+++ b/tests/rustdoc-ui/intra-doc/feature-gate-intra-doc-pointers.stderr
@@ -6,6 +6,7 @@ LL | //! [pointer::add]
    |
    = note: see issue #80896 <https://github.com/rust-lang/rust/issues/80896> for more information
    = help: add `#![feature(intra_doc_pointers)]` 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: rustdoc does not allow disambiguating between `*const` and `*mut`, and pointers are unstable until it does
 
 error[E0658]: linking to associated items of raw pointers is experimental
@@ -16,6 +17,7 @@ LL | //! [pointer::wrapping_add]
    |
    = note: see issue #80896 <https://github.com/rust-lang/rust/issues/80896> for more information
    = help: add `#![feature(intra_doc_pointers)]` 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: rustdoc does not allow disambiguating between `*const` and `*mut`, and pointers are unstable until it does
 
 error: aborting due to 2 previous errors
diff --git a/tests/rustdoc-ui/lints/feature-gate-rustdoc_missing_doc_code_examples.rs b/tests/rustdoc-ui/lints/feature-gate-rustdoc_missing_doc_code_examples.rs
index ce94a06c39e..832f129fab2 100644
--- a/tests/rustdoc-ui/lints/feature-gate-rustdoc_missing_doc_code_examples.rs
+++ b/tests/rustdoc-ui/lints/feature-gate-rustdoc_missing_doc_code_examples.rs
@@ -5,3 +5,4 @@
 //~^ ERROR unknown lint
 //~| NOTE lint is unstable
 //~| NOTE see issue
+//~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
diff --git a/tests/rustdoc-ui/lints/feature-gate-rustdoc_missing_doc_code_examples.stderr b/tests/rustdoc-ui/lints/feature-gate-rustdoc_missing_doc_code_examples.stderr
index f188240062d..67540949f4d 100644
--- a/tests/rustdoc-ui/lints/feature-gate-rustdoc_missing_doc_code_examples.stderr
+++ b/tests/rustdoc-ui/lints/feature-gate-rustdoc_missing_doc_code_examples.stderr
@@ -7,6 +7,7 @@ LL | #![allow(rustdoc::missing_doc_code_examples)]
    = note: the `rustdoc::missing_doc_code_examples` lint is unstable
    = note: see issue #101730 <https://github.com/rust-lang/rust/issues/101730> for more information
    = help: add `#![feature(rustdoc_missing_doc_code_examples)]` 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: the lint level is defined here
   --> $DIR/feature-gate-rustdoc_missing_doc_code_examples.rs:2:9
    |
diff --git a/tests/rustdoc/issue-50159.rs b/tests/rustdoc/auto-trait-bounds-by-associated-type-50159.rs
index 13bedd5dbb0..0663ed5fc81 100644
--- a/tests/rustdoc/issue-50159.rs
+++ b/tests/rustdoc/auto-trait-bounds-by-associated-type-50159.rs
@@ -1,3 +1,6 @@
+// https://github.com/rust-lang/rust/issues/50159
+#![crate_name="foo"]
+
 pub trait Signal {
     type Item;
 }
@@ -10,7 +13,7 @@ impl<B, C> Signal2 for B where B: Signal<Item = C> {
     type Item2 = C;
 }
 
-// @has issue_50159/struct.Switch.html
+// @has foo/struct.Switch.html
 // @has - '//h3[@class="code-header"]' 'impl<B> Send for Switch<B>where <B as Signal>::Item: Send'
 // @has - '//h3[@class="code-header"]' 'impl<B> Sync for Switch<B>where <B as Signal>::Item: Sync'
 // @count - '//*[@id="implementations-list"]//*[@class="impl"]' 0
diff --git a/tests/rustdoc/issue-54705.rs b/tests/rustdoc/auto-trait-bounds-inference-variables-54705.rs
index a886eb0de24..00be0042fb0 100644
--- a/tests/rustdoc/issue-54705.rs
+++ b/tests/rustdoc/auto-trait-bounds-inference-variables-54705.rs
@@ -1,6 +1,9 @@
+// https://github.com/rust-lang/rust/issues/54705
+#![crate_name="foo"]
+
 pub trait ScopeHandle<'scope> {}
 
-// @has issue_54705/struct.ScopeFutureContents.html
+// @has foo/struct.ScopeFutureContents.html
 // @has - '//*[@id="synthetic-implementations-list"]//*[@class="impl"]//h3[@class="code-header"]' \
 // "impl<'scope, S> Send for ScopeFutureContents<'scope, S>where S: Sync"
 //
diff --git a/tests/rustdoc/issue-51236.rs b/tests/rustdoc/auto-trait-bounds-where-51236.rs
index 04664805a88..30c81e79601 100644
--- a/tests/rustdoc/issue-51236.rs
+++ b/tests/rustdoc/auto-trait-bounds-where-51236.rs
@@ -1,3 +1,6 @@
+// https://github.com/rust-lang/rust/issues/51236
+#![crate_name="foo"]
+
 use std::marker::PhantomData;
 
 pub mod traits {
@@ -6,7 +9,7 @@ pub mod traits {
     }
 }
 
-// @has issue_51236/struct.Owned.html
+// @has foo/struct.Owned.html
 // @has - '//*[@id="synthetic-implementations-list"]//*[@class="impl"]//h3[@class="code-header"]' \
 // "impl<T> Send for Owned<T>where <T as Owned<'static>>::Reader: Send"
 pub struct Owned<T> where T: for<'a> ::traits::Owned<'a> {
diff --git a/tests/rustdoc/issue-55321.rs b/tests/rustdoc/auto-trait-negative-impl-55321.rs
index d3c2070d915..e9be1ff854e 100644
--- a/tests/rustdoc/issue-55321.rs
+++ b/tests/rustdoc/auto-trait-negative-impl-55321.rs
@@ -1,6 +1,9 @@
+// https://github.com/rust-lang/rust/issues/55321
+#![crate_name="foo"]
+
 #![feature(negative_impls)]
 
-// @has issue_55321/struct.A.html
+// @has foo/struct.A.html
 // @has - '//*[@id="trait-implementations-list"]//*[@class="impl"]//h3[@class="code-header"]' \
 // "impl !Send for A"
 // @has - '//*[@id="trait-implementations-list"]//*[@class="impl"]//h3[@class="code-header"]' \
@@ -10,7 +13,7 @@ pub struct A();
 impl !Send for A {}
 impl !Sync for A {}
 
-// @has issue_55321/struct.B.html
+// @has foo/struct.B.html
 // @has - '//*[@id="synthetic-implementations-list"]//*[@class="impl"]//h3[@class="code-header"]' \
 // "impl<T> !Send for B<T>"
 // @has - '//*[@id="synthetic-implementations-list"]//*[@class="impl"]//h3[@class="code-header"]' \
diff --git a/tests/rustdoc/blank-line-in-doc-block-47197.rs b/tests/rustdoc/blank-line-in-doc-block-47197.rs
new file mode 100644
index 00000000000..79492b4fa76
--- /dev/null
+++ b/tests/rustdoc/blank-line-in-doc-block-47197.rs
@@ -0,0 +1,11 @@
+// https://github.com/rust-lang/rust/issues/47197
+#![crate_name="foo"]
+
+// @has foo/fn.whose_woods_these_are_i_think_i_know.html
+
+/**
+* snow
+
+* ice
+*/
+pub fn whose_woods_these_are_i_think_i_know() {}
diff --git a/tests/rustdoc/issue-54478-demo-allocator.rs b/tests/rustdoc/demo-allocator-54478.rs
index 4811f363bc9..39acee36d88 100644
--- a/tests/rustdoc/issue-54478-demo-allocator.rs
+++ b/tests/rustdoc/demo-allocator-54478.rs
@@ -1,3 +1,6 @@
+// https://github.com/rust-lang/rust/issues/54478
+#![crate_name="foo"]
+
 // Issue #54478: regression test showing that we can demonstrate
 // `#[global_allocator]` in code blocks built by `rustdoc`.
 //
diff --git a/tests/rustdoc/issue-35169-2.rs b/tests/rustdoc/deref-mut-35169-2.rs
index f08466baf8b..c82323ddc6a 100644
--- a/tests/rustdoc/issue-35169-2.rs
+++ b/tests/rustdoc/deref-mut-35169-2.rs
@@ -1,3 +1,6 @@
+// https://github.com/rust-lang/rust/issues/35169
+#![crate_name="foo"]
+
 use std::ops::Deref;
 use std::ops::DerefMut;
 
@@ -23,7 +26,7 @@ impl DerefMut for Bar {
     fn deref_mut(&mut self) -> &mut Foo { loop {} }
 }
 
-// @has issue_35169_2/struct.Bar.html
+// @has foo/struct.Bar.html
 // @has - '//*[@id="method.by_ref"]//h4[@class="code-header"]' 'fn by_ref(&self)'
 // @has - '//*[@id="method.by_ref"]' 'fn by_ref(&self)'
 // @has - '//*[@id="method.by_explicit_ref"]//h4[@class="code-header"]' 'fn by_explicit_ref(self: &Foo)'
diff --git a/tests/rustdoc/issue-35169.rs b/tests/rustdoc/deref-mut-35169.rs
index 70a2265c806..44afaf2e903 100644
--- a/tests/rustdoc/issue-35169.rs
+++ b/tests/rustdoc/deref-mut-35169.rs
@@ -1,3 +1,6 @@
+// https://github.com/rust-lang/rust/issues/35169
+#![crate_name="foo"]
+
 use std::ops::Deref;
 
 pub struct Foo;
@@ -18,7 +21,7 @@ impl Deref for Bar {
     fn deref(&self) -> &Foo { loop {} }
 }
 
-// @has issue_35169/struct.Bar.html
+// @has foo/struct.Bar.html
 // @has - '//*[@id="method.by_ref"]//h4[@class="code-header"]' 'fn by_ref(&self)'
 // @has - '//*[@id="method.by_ref"]' 'fn by_ref(&self)'
 // @has - '//*[@id="method.by_explicit_ref"]//h4[@class="code-header"]' 'fn by_explicit_ref(self: &Foo)'
diff --git a/tests/rustdoc/issue-42760.rs b/tests/rustdoc/doc-attr-comment-mix-42760.rs
index a5394c7d92a..16c1705eb00 100644
--- a/tests/rustdoc/issue-42760.rs
+++ b/tests/rustdoc/doc-attr-comment-mix-42760.rs
@@ -1,6 +1,9 @@
+// https://github.com/rust-lang/rust/issues/42760
+#![crate_name="foo"]
+
 #![allow(rustdoc::invalid_rust_codeblocks)]
 
-// @has issue_42760/struct.NonGen.html
+// @has foo/struct.NonGen.html
 // @has - '//h2' 'Example'
 
 /// Item docs.
diff --git a/tests/rustdoc/issue-41783.codeblock.html b/tests/rustdoc/doctest/doctest-escape-boring-41783.codeblock.html
index 3bca4536cd5..3bca4536cd5 100644
--- a/tests/rustdoc/issue-41783.codeblock.html
+++ b/tests/rustdoc/doctest/doctest-escape-boring-41783.codeblock.html
diff --git a/tests/rustdoc/issue-41783.rs b/tests/rustdoc/doctest/doctest-escape-boring-41783.rs
index 7578d49daa5..7782e148fd9 100644
--- a/tests/rustdoc/issue-41783.rs
+++ b/tests/rustdoc/doctest/doctest-escape-boring-41783.rs
@@ -1,4 +1,7 @@
-// @has issue_41783/struct.Foo.html
+// https://github.com/rust-lang/rust/issues/41783
+#![crate_name="foo"]
+
+// @has foo/struct.Foo.html
 // @!hasraw - 'space'
 // @!hasraw - 'comment'
 // @hasraw - '<span class="attr">#[outer]'
diff --git a/tests/rustdoc/enum-variant-reexport-35488.rs b/tests/rustdoc/enum-variant-reexport-35488.rs
new file mode 100644
index 00000000000..ed955dcd770
--- /dev/null
+++ b/tests/rustdoc/enum-variant-reexport-35488.rs
@@ -0,0 +1,16 @@
+// https://github.com/rust-lang/rust/issues/35488
+#![crate_name="foo"]
+
+mod foo {
+    pub enum Foo {
+        Bar,
+    }
+    pub use self::Foo::*;
+}
+
+// @has 'foo/index.html' '//code' 'pub use self::Foo::*;'
+// @has 'foo/enum.Foo.html'
+pub use self::foo::*;
+
+// @has 'foo/index.html' '//code' 'pub use std::option::Option::None;'
+pub use std::option::Option::None;
diff --git a/tests/rustdoc/issue-53689.rs b/tests/rustdoc/impl-blanket-53689.rs
index 832140e061b..7c2edd01a60 100644
--- a/tests/rustdoc/issue-53689.rs
+++ b/tests/rustdoc/impl-blanket-53689.rs
@@ -1,3 +1,4 @@
+// https://github.com/rust-lang/rust/issues/53689
 // aux-build:issue-53689.rs
 
 #![crate_name = "foo"]
diff --git a/tests/rustdoc/issue-43869.rs b/tests/rustdoc/impl-trait-43869.rs
index 767d09d8558..9c4ed841f79 100644
--- a/tests/rustdoc/issue-43869.rs
+++ b/tests/rustdoc/impl-trait-43869.rs
@@ -1,3 +1,6 @@
+// https://github.com/rust-lang/rust/issues/43869
+#![crate_name="foo"]
+
 pub fn g() -> impl Iterator<Item=u8> {
     Some(1u8).into_iter()
 }
@@ -58,15 +61,15 @@ pub fn test_44731_4() -> Box<Iterator<Item=impl Clone>> {
     Box::new(g())
 }
 
-// @has issue_43869/fn.g.html
-// @has issue_43869/fn.h.html
-// @has issue_43869/fn.i.html
-// @has issue_43869/fn.j.html
-// @has issue_43869/fn.k.html
-// @has issue_43869/fn.l.html
-// @has issue_43869/fn.m.html
-// @has issue_43869/fn.n.html
-// @has issue_43869/fn.o.html
-// @has issue_43869/fn.test_44731_0.html
-// @has issue_43869/fn.test_44731_1.html
-// @has issue_43869/fn.test_44731_4.html
+// @has foo/fn.g.html
+// @has foo/fn.h.html
+// @has foo/fn.i.html
+// @has foo/fn.j.html
+// @has foo/fn.k.html
+// @has foo/fn.l.html
+// @has foo/fn.m.html
+// @has foo/fn.n.html
+// @has foo/fn.o.html
+// @has foo/fn.test_44731_0.html
+// @has foo/fn.test_44731_1.html
+// @has foo/fn.test_44731_4.html
diff --git a/tests/rustdoc/auxiliary/issue-46727.rs b/tests/rustdoc/inline_cross/auxiliary/issue-46727.rs
index 30dccfa77b5..30dccfa77b5 100644
--- a/tests/rustdoc/auxiliary/issue-46727.rs
+++ b/tests/rustdoc/inline_cross/auxiliary/issue-46727.rs
diff --git a/tests/rustdoc/issue-46727.rs b/tests/rustdoc/inline_cross/const-eval-46727.rs
index 8cfc4827a7f..d0ce9c34f51 100644
--- a/tests/rustdoc/issue-46727.rs
+++ b/tests/rustdoc/inline_cross/const-eval-46727.rs
@@ -1,7 +1,10 @@
+// https://github.com/rust-lang/rust/issues/46727
+#![crate_name="foo"]
+
 // aux-build:issue-46727.rs
 
 extern crate issue_46727;
 
-// @has issue_46727/trait.Foo.html
+// @has foo/trait.Foo.html
 // @has - '//h3[@class="code-header"]' 'impl<T> Foo for Bar<[T; 3]>'
 pub use issue_46727::{Foo, Bar};
diff --git a/tests/rustdoc/issue-55364.rs b/tests/rustdoc/intra-doc/module-scope-name-resolution-55364.rs
index 941cb3ce1ca..c07aba628c9 100644
--- a/tests/rustdoc/issue-55364.rs
+++ b/tests/rustdoc/intra-doc/module-scope-name-resolution-55364.rs
@@ -1,6 +1,9 @@
+// https://github.com/rust-lang/rust/issues/55364
+#![crate_name="foo"]
+
 // First a module with inner documentation
 
-// @has issue_55364/subone/index.html
+// @has foo/subone/index.html
 // These foo/bar links in the module's documentation should refer inside `subone`
 // @has - '//section[@id="main-content"]/details[@open=""]/div[@class="docblock"]//a[@href="fn.foo.html"]' 'foo'
 // @has - '//section[@id="main-content"]/details[@open=""]/div[@class="docblock"]//a[@href="fn.bar.html"]' 'bar'
@@ -8,12 +11,12 @@ pub mod subone {
     //! See either [foo] or [bar].
 
     // This should refer to subone's `bar`
-    // @has issue_55364/subone/fn.foo.html
+    // @has foo/subone/fn.foo.html
     // @has - '//section[@id="main-content"]/details/div[@class="docblock"]//a[@href="fn.bar.html"]' 'bar'
     /// See [bar]
     pub fn foo() {}
     // This should refer to subone's `foo`
-    // @has issue_55364/subone/fn.bar.html
+    // @has foo/subone/fn.bar.html
     // @has - '//section[@id="main-content"]/details/div[@class="docblock"]//a[@href="fn.foo.html"]' 'foo'
     /// See [foo]
     pub fn bar() {}
@@ -21,7 +24,7 @@ pub mod subone {
 
 // A module with outer documentation
 
-// @has issue_55364/subtwo/index.html
+// @has foo/subtwo/index.html
 // These foo/bar links in the module's documentation should not reference inside `subtwo`
 // @!has - '//section[@id="main-content"]/div[@class="docblock"]//a[@href="fn.foo.html"]' 'foo'
 // @!has - '//section[@id="main-content"]/div[@class="docblock"]//a[@href="fn.bar.html"]' 'bar'
@@ -36,13 +39,13 @@ pub mod subtwo {
 
     // Despite the module's docs referring to the top level foo/bar,
     // this should refer to subtwo's `bar`
-    // @has issue_55364/subtwo/fn.foo.html
+    // @has foo/subtwo/fn.foo.html
     // @has - '//section[@id="main-content"]/details/div[@class="docblock"]//a[@href="fn.bar.html"]' 'bar'
     /// See [bar]
     pub fn foo() {}
     // Despite the module's docs referring to the top level foo/bar,
     // this should refer to subtwo's `foo`
-    // @has issue_55364/subtwo/fn.bar.html
+    // @has foo/subtwo/fn.bar.html
     // @has - '//section[@id="main-content"]/details/div[@class="docblock"]//a[@href="fn.foo.html"]' 'foo'
     /// See [foo]
     pub fn bar() {}
@@ -57,7 +60,7 @@ pub fn bar() {}
 
 // This module refers to the outer foo/bar by means of `super::`
 
-// @has issue_55364/subthree/index.html
+// @has foo/subthree/index.html
 // This module should also refer to the top level foo/bar
 // @has - '//section[@id="main-content"]/details/div[@class="docblock"]//a[@href="../fn.foo.html"]' 'foo'
 // @has - '//section[@id="main-content"]/details/div[@class="docblock"]//a[@href="../fn.bar.html"]' 'bar'
@@ -67,7 +70,7 @@ pub mod subthree {
 
 // Next we go *deeper* - In order to ensure it's not just "this or parent"
 // we test `crate::` and a `super::super::...` chain
-// @has issue_55364/subfour/subfive/subsix/subseven/subeight/index.html
+// @has foo/subfour/subfive/subsix/subseven/subeight/index.html
 // @has - '//section[@id="main-content"]/ul[@class="item-table"]//div[@class="desc docblock-short"]//a[@href="../../../../../subone/fn.foo.html"]' 'other foo'
 // @has - '//section[@id="main-content"]/ul[@class="item-table"]//div[@class="desc docblock-short"]//a[@href="../../../../../subtwo/fn.bar.html"]' 'other bar'
 pub mod subfour {
diff --git a/tests/rustdoc/issue-35488.rs b/tests/rustdoc/issue-35488.rs
deleted file mode 100644
index c1bf9ceeac1..00000000000
--- a/tests/rustdoc/issue-35488.rs
+++ /dev/null
@@ -1,13 +0,0 @@
-mod foo {
-    pub enum Foo {
-        Bar,
-    }
-    pub use self::Foo::*;
-}
-
-// @has 'issue_35488/index.html' '//code' 'pub use self::Foo::*;'
-// @has 'issue_35488/enum.Foo.html'
-pub use self::foo::*;
-
-// @has 'issue_35488/index.html' '//code' 'pub use std::option::Option::None;'
-pub use std::option::Option::None;
diff --git a/tests/rustdoc/issue-46377.rs b/tests/rustdoc/issue-46377.rs
deleted file mode 100644
index 1311b4721e2..00000000000
--- a/tests/rustdoc/issue-46377.rs
+++ /dev/null
@@ -1,3 +0,0 @@
-// @has 'issue_46377/index.html' '//*[@class="desc docblock-short"]' 'Check out this struct!'
-/// # Check out this struct!
-pub struct SomeStruct;
diff --git a/tests/rustdoc/issue-47197-blank-line-in-doc-block.rs b/tests/rustdoc/issue-47197-blank-line-in-doc-block.rs
deleted file mode 100644
index 19994475de2..00000000000
--- a/tests/rustdoc/issue-47197-blank-line-in-doc-block.rs
+++ /dev/null
@@ -1,8 +0,0 @@
-// @has issue_47197_blank_line_in_doc_block/fn.whose_woods_these_are_i_think_i_know.html
-
-/**
-* snow
-
-* ice
-*/
-pub fn whose_woods_these_are_i_think_i_know() {}
diff --git a/tests/rustdoc/issue-46380-2.rs b/tests/rustdoc/public-impl-mention-private-generic-46380-2.rs
index 7004d18dc66..96ebd888eb5 100644
--- a/tests/rustdoc/issue-46380-2.rs
+++ b/tests/rustdoc/public-impl-mention-private-generic-46380-2.rs
@@ -1,6 +1,9 @@
+// https://github.com/rust-lang/rust/issues/46380
+#![crate_name="foo"]
+
 pub trait PublicTrait<T> {}
 
-// @has issue_46380_2/struct.PublicStruct.html
+// @has foo/struct.PublicStruct.html
 pub struct PublicStruct;
 
 // @!has - '//*[@class="impl"]' 'impl PublicTrait<PrivateStruct> for PublicStruct'
diff --git a/tests/rustdoc/issue-53812.rs b/tests/rustdoc/sort-53812.rs
index dc1eb304c3d..968ae035043 100644
--- a/tests/rustdoc/issue-53812.rs
+++ b/tests/rustdoc/sort-53812.rs
@@ -1,3 +1,6 @@
+// https://github.com/rust-lang/rust/issues/53812
+#![crate_name="foo"]
+
 pub trait MyIterator {}
 
 pub struct MyStruct<T>(T);
@@ -11,7 +14,7 @@ macro_rules! array_impls {
     }
 }
 
-// @has issue_53812/trait.MyIterator.html
+// @has foo/trait.MyIterator.html
 // @has - '//*[@id="implementors-list"]/*[@class="impl"][1]' 'MyStruct<[T; 0]>'
 // @has - '//*[@id="implementors-list"]/*[@class="impl"][2]' 'MyStruct<[T; 1]>'
 // @has - '//*[@id="implementors-list"]/*[@class="impl"][3]' 'MyStruct<[T; 2]>'
diff --git a/tests/rustdoc/summary-header-46377.rs b/tests/rustdoc/summary-header-46377.rs
new file mode 100644
index 00000000000..aec74f493d4
--- /dev/null
+++ b/tests/rustdoc/summary-header-46377.rs
@@ -0,0 +1,6 @@
+// https://github.com/rust-lang/rust/issues/46377
+#![crate_name="foo"]
+
+// @has 'foo/index.html' '//*[@class="desc docblock-short"]' 'Check out this struct!'
+/// # Check out this struct!
+pub struct SomeStruct;
diff --git a/tests/ui-fulldeps/hash-stable-is-unstable.rs b/tests/ui-fulldeps/hash-stable-is-unstable.rs
index 37d7472ec60..ab18f2c6415 100644
--- a/tests/ui-fulldeps/hash-stable-is-unstable.rs
+++ b/tests/ui-fulldeps/hash-stable-is-unstable.rs
@@ -1,16 +1,31 @@
+// ignore-stage1
 // compile-flags: -Zdeduplicate-diagnostics=yes
 extern crate rustc_data_structures;
 //~^ use of unstable library feature 'rustc_private'
+//~| NOTE: issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
+//~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 extern crate rustc_macros;
 //~^ use of unstable library feature 'rustc_private'
+//~| NOTE: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
+//~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 extern crate rustc_query_system;
 //~^ use of unstable library feature 'rustc_private'
+//~| NOTE: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
+//~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 use rustc_macros::HashStable;
 //~^ use of unstable library feature 'rustc_private'
+//~| NOTE: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
+//~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 #[derive(HashStable)]
 //~^ use of unstable library feature 'rustc_private'
+//~| NOTE: in this expansion of #[derive(HashStable)]
+//~| NOTE: in this expansion of #[derive(HashStable)]
+//~| NOTE: in this expansion of #[derive(HashStable)]
+//~| NOTE: in this expansion of #[derive(HashStable)]
+//~| NOTE: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
+//~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 struct Test;
 
 fn main() {}
diff --git a/tests/ui-fulldeps/hash-stable-is-unstable.stderr b/tests/ui-fulldeps/hash-stable-is-unstable.stderr
index 1a8994d722e..818bdaedcca 100644
--- a/tests/ui-fulldeps/hash-stable-is-unstable.stderr
+++ b/tests/ui-fulldeps/hash-stable-is-unstable.stderr
@@ -1,47 +1,52 @@
 error[E0658]: use of unstable library feature 'rustc_private': this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via `Cargo.toml` instead?
-  --> $DIR/hash-stable-is-unstable.rs:2:1
+  --> $DIR/hash-stable-is-unstable.rs:3:1
    |
 LL | extern crate rustc_data_structures;
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
    = help: add `#![feature(rustc_private)]` 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]: use of unstable library feature 'rustc_private': this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via `Cargo.toml` instead?
-  --> $DIR/hash-stable-is-unstable.rs:4:1
+  --> $DIR/hash-stable-is-unstable.rs:7:1
    |
 LL | extern crate rustc_macros;
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
    = help: add `#![feature(rustc_private)]` 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]: use of unstable library feature 'rustc_private': this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via `Cargo.toml` instead?
-  --> $DIR/hash-stable-is-unstable.rs:6:1
+  --> $DIR/hash-stable-is-unstable.rs:11:1
    |
 LL | extern crate rustc_query_system;
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
    = help: add `#![feature(rustc_private)]` 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]: use of unstable library feature 'rustc_private': this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via `Cargo.toml` instead?
-  --> $DIR/hash-stable-is-unstable.rs:9:5
+  --> $DIR/hash-stable-is-unstable.rs:16:5
    |
 LL | use rustc_macros::HashStable;
    |     ^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
    = help: add `#![feature(rustc_private)]` 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]: use of unstable library feature 'rustc_private': this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via `Cargo.toml` instead?
-  --> $DIR/hash-stable-is-unstable.rs:12:10
+  --> $DIR/hash-stable-is-unstable.rs:21:10
    |
 LL | #[derive(HashStable)]
    |          ^^^^^^^^^^
    |
    = note: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
    = help: add `#![feature(rustc_private)]` 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: this error originates in the derive macro `HashStable` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: aborting due to 5 previous errors
diff --git a/tests/ui-fulldeps/pathless-extern-unstable.rs b/tests/ui-fulldeps/pathless-extern-unstable.rs
index 7fba8343bc0..719ca3c5a65 100644
--- a/tests/ui-fulldeps/pathless-extern-unstable.rs
+++ b/tests/ui-fulldeps/pathless-extern-unstable.rs
@@ -1,4 +1,5 @@
 // edition:2018
+// ignore-stage1
 // compile-flags:--extern rustc_middle
 
 // Test that `--extern rustc_middle` fails with `rustc_private`.
diff --git a/tests/ui-fulldeps/pathless-extern-unstable.stderr b/tests/ui-fulldeps/pathless-extern-unstable.stderr
index cfd8669c45f..d13a0079213 100644
--- a/tests/ui-fulldeps/pathless-extern-unstable.stderr
+++ b/tests/ui-fulldeps/pathless-extern-unstable.stderr
@@ -1,11 +1,12 @@
 error[E0658]: use of unstable library feature 'rustc_private': this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via `Cargo.toml` instead?
-  --> $DIR/pathless-extern-unstable.rs:6:9
+  --> $DIR/pathless-extern-unstable.rs:7:9
    |
 LL | pub use rustc_middle;
    |         ^^^^^^^^^^^^
    |
    = note: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
    = help: add `#![feature(rustc_private)]` 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 1 previous error
 
diff --git a/tests/ui-fulldeps/stable-mir/check_allocation.rs b/tests/ui-fulldeps/stable-mir/check_allocation.rs
index 7ce3597206b..93def93127c 100644
--- a/tests/ui-fulldeps/stable-mir/check_allocation.rs
+++ b/tests/ui-fulldeps/stable-mir/check_allocation.rs
@@ -111,7 +111,7 @@ fn check_other_consts(item: CrateItem) {
     // Instance body will force constant evaluation.
     let body = Instance::try_from(item).unwrap().body().unwrap();
     let assigns = collect_consts(&body);
-    assert_eq!(assigns.len(), 9);
+    assert_eq!(assigns.len(), 8);
     for (name, alloc) in assigns {
         match name.as_str() {
             "_max_u128" => {
diff --git a/tests/ui/array-slice-vec/suggest-array-length.stderr b/tests/ui/array-slice-vec/suggest-array-length.stderr
index 16c90a04784..fdab7ba7064 100644
--- a/tests/ui/array-slice-vec/suggest-array-length.stderr
+++ b/tests/ui/array-slice-vec/suggest-array-length.stderr
@@ -48,6 +48,7 @@ LL |     const Foo: [i32; _] = [1, 2, 3];
    |
    = note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
    = help: add `#![feature(generic_arg_infer)]` 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]: using `_` for array lengths is unstable
   --> $DIR/suggest-array-length.rs:8:26
@@ -57,6 +58,7 @@ LL |     const REF_FOO: &[u8; _] = &[1];
    |
    = note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
    = help: add `#![feature(generic_arg_infer)]` 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]: using `_` for array lengths is unstable
   --> $DIR/suggest-array-length.rs:11:20
@@ -66,6 +68,7 @@ LL |     let foo: [i32; _] = [1, 2, 3];
    |
    = note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
    = help: add `#![feature(generic_arg_infer)]` 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]: using `_` for array lengths is unstable
   --> $DIR/suggest-array-length.rs:14:20
@@ -75,6 +78,7 @@ LL |     let bar: [i32; _] = [0; 3];
    |
    = note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
    = help: add `#![feature(generic_arg_infer)]` 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]: using `_` for array lengths is unstable
   --> $DIR/suggest-array-length.rs:17:25
@@ -84,6 +88,7 @@ LL |     let ref_foo: &[i32; _] = &[1, 2, 3];
    |
    = note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
    = help: add `#![feature(generic_arg_infer)]` 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]: using `_` for array lengths is unstable
   --> $DIR/suggest-array-length.rs:20:25
@@ -93,6 +98,7 @@ LL |     let ref_bar: &[i32; _] = &[0; 3];
    |
    = note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
    = help: add `#![feature(generic_arg_infer)]` 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]: using `_` for array lengths is unstable
   --> $DIR/suggest-array-length.rs:23:35
@@ -102,6 +108,7 @@ LL |     let multiple_ref_foo: &&[i32; _] = &&[1, 2, 3];
    |
    = note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
    = help: add `#![feature(generic_arg_infer)]` 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 14 previous errors
 
diff --git a/tests/ui/associated-consts/issue-105330.stderr b/tests/ui/associated-consts/issue-105330.stderr
index e1461fec296..b4c021d0f4f 100644
--- a/tests/ui/associated-consts/issue-105330.stderr
+++ b/tests/ui/associated-consts/issue-105330.stderr
@@ -23,6 +23,7 @@ LL | fn foo<A: TraitWAssocConst<A=32>>() {
    |
    = note: see issue #92827 <https://github.com/rust-lang/rust/issues/92827> for more information
    = help: add `#![feature(associated_const_equality)]` 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]: associated const equality is incomplete
   --> $DIR/issue-105330.rs:15:29
@@ -32,6 +33,7 @@ LL | fn main<A: TraitWAssocConst<A=32>>() {
    |
    = note: see issue #92827 <https://github.com/rust-lang/rust/issues/92827> for more information
    = help: add `#![feature(associated_const_equality)]` 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[E0562]: `impl Trait` is not allowed in impl headers
   --> $DIR/issue-105330.rs:6:27
diff --git a/tests/ui/associated-consts/issue-93835.stderr b/tests/ui/associated-consts/issue-93835.stderr
index be0573a1301..d3ce46f6f03 100644
--- a/tests/ui/associated-consts/issue-93835.stderr
+++ b/tests/ui/associated-consts/issue-93835.stderr
@@ -24,6 +24,7 @@ LL |     type_ascribe!(p, a<p:p<e=6>>);
    |
    = note: see issue #92827 <https://github.com/rust-lang/rust/issues/92827> for more information
    = help: add `#![feature(associated_const_equality)]` 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]: associated type bounds are unstable
   --> $DIR/issue-93835.rs:4:24
@@ -33,6 +34,7 @@ LL |     type_ascribe!(p, a<p:p<e=6>>);
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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 5 previous errors
 
diff --git a/tests/ui/associated-inherent-types/assoc-inherent-unstable.stderr b/tests/ui/associated-inherent-types/assoc-inherent-unstable.stderr
index cf2aee6ab53..ab8cdb6f80a 100644
--- a/tests/ui/associated-inherent-types/assoc-inherent-unstable.stderr
+++ b/tests/ui/associated-inherent-types/assoc-inherent-unstable.stderr
@@ -5,6 +5,7 @@ LL | type Data = aux::Owner::Data;
    |             ^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(data)]` 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 1 previous error
 
diff --git a/tests/ui/associated-inherent-types/dont-select-if-disabled.stderr b/tests/ui/associated-inherent-types/dont-select-if-disabled.stderr
index 87a3f35c968..edf54894cd4 100644
--- a/tests/ui/associated-inherent-types/dont-select-if-disabled.stderr
+++ b/tests/ui/associated-inherent-types/dont-select-if-disabled.stderr
@@ -17,6 +17,7 @@ LL | impl S { type P = (); }
    |
    = note: see issue #8995 <https://github.com/rust-lang/rust/issues/8995> for more information
    = help: add `#![feature(inherent_associated_types)]` 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 2 previous errors
 
diff --git a/tests/ui/associated-inherent-types/issue-109071.no_gate.stderr b/tests/ui/associated-inherent-types/issue-109071.no_gate.stderr
index e3eddf489b0..b8366b15a8a 100644
--- a/tests/ui/associated-inherent-types/issue-109071.no_gate.stderr
+++ b/tests/ui/associated-inherent-types/issue-109071.no_gate.stderr
@@ -28,6 +28,7 @@ LL |     type Item = &[T];
    |
    = note: see issue #8995 <https://github.com/rust-lang/rust/issues/8995> for more information
    = help: add `#![feature(inherent_associated_types)]` 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[E0223]: ambiguous associated type
   --> $DIR/issue-109071.rs:15:22
diff --git a/tests/ui/associated-inherent-types/issue-109768.stderr b/tests/ui/associated-inherent-types/issue-109768.stderr
index c489fd1ab9b..e960f4fb5d1 100644
--- a/tests/ui/associated-inherent-types/issue-109768.stderr
+++ b/tests/ui/associated-inherent-types/issue-109768.stderr
@@ -28,6 +28,7 @@ LL |     type AssocType3 = T;
    |
    = note: see issue #8995 <https://github.com/rust-lang/rust/issues/8995> for more information
    = help: add `#![feature(inherent_associated_types)]` 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[E0061]: this struct takes 1 argument but 0 arguments were supplied
   --> $DIR/issue-109768.rs:10:56
diff --git a/tests/ui/associated-type-bounds/issue-99828.stderr b/tests/ui/associated-type-bounds/issue-99828.stderr
index 8813baf84de..911f3ff0f5e 100644
--- a/tests/ui/associated-type-bounds/issue-99828.stderr
+++ b/tests/ui/associated-type-bounds/issue-99828.stderr
@@ -6,6 +6,7 @@ LL | fn get_iter(vec: &[i32]) -> impl Iterator<Item = {}> + '_ {
    |
    = note: see issue #92827 <https://github.com/rust-lang/rust/issues/92827> for more information
    = help: add `#![feature(associated_const_equality)]` 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: expected type, found constant
   --> $DIR/issue-99828.rs:1:50
diff --git a/tests/ui/associated-type-bounds/return-type-notation/bad-inputs-and-output.stderr b/tests/ui/associated-type-bounds/return-type-notation/bad-inputs-and-output.stderr
index 1714dac12db..02bec24c628 100644
--- a/tests/ui/associated-type-bounds/return-type-notation/bad-inputs-and-output.stderr
+++ b/tests/ui/associated-type-bounds/return-type-notation/bad-inputs-and-output.stderr
@@ -12,6 +12,7 @@ LL | fn foo<T: Trait<method(i32): Send>>() {}
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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]: associated type bounds are unstable
   --> $DIR/bad-inputs-and-output.rs:14:17
@@ -21,6 +22,7 @@ LL | fn bar<T: Trait<method() -> (): Send>>() {}
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: the feature `return_type_notation` is incomplete and may not be safe to use and/or cause compiler crashes
   --> $DIR/bad-inputs-and-output.rs:3:12
diff --git a/tests/ui/associated-type-bounds/return-type-notation/unpretty-parenthesized.stderr b/tests/ui/associated-type-bounds/return-type-notation/unpretty-parenthesized.stderr
index f27603e3719..3007240c3ab 100644
--- a/tests/ui/associated-type-bounds/return-type-notation/unpretty-parenthesized.stderr
+++ b/tests/ui/associated-type-bounds/return-type-notation/unpretty-parenthesized.stderr
@@ -6,6 +6,7 @@ LL | fn foo<T: Trait<method(i32): Send>>() {}
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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 1 previous error
 
diff --git a/tests/ui/async-await/feature-async-closure.stderr b/tests/ui/async-await/feature-async-closure.stderr
index c69a0dd9ed9..650500b4890 100644
--- a/tests/ui/async-await/feature-async-closure.stderr
+++ b/tests/ui/async-await/feature-async-closure.stderr
@@ -6,6 +6,7 @@ LL |     let _ = 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 1 previous error
diff --git a/tests/ui/async-await/feature-async-for-loop.stderr b/tests/ui/async-await/feature-async-for-loop.stderr
index 38f75821772..62ddc4222b8 100644
--- a/tests/ui/async-await/feature-async-for-loop.stderr
+++ b/tests/ui/async-await/feature-async-for-loop.stderr
@@ -6,6 +6,7 @@ LL |         for await _i in core::async_iter::from_iter(0..3) {
    |
    = note: see issue #118898 <https://github.com/rust-lang/rust/issues/118898> for more information
    = help: add `#![feature(async_for_loop)]` 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]: `for await` loops are experimental
   --> $DIR/feature-async-for-loop.rs:17:13
@@ -15,6 +16,7 @@ LL |         for await _i in core::async_iter::from_iter(0..3) {
    |
    = note: see issue #118898 <https://github.com/rust-lang/rust/issues/118898> for more information
    = help: add `#![feature(async_for_loop)]` 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 2 previous errors
 
diff --git a/tests/ui/async-await/issues/issue-65159.rs b/tests/ui/async-await/issues/issue-65159.rs
index aed111e2144..7197a4fb91a 100644
--- a/tests/ui/async-await/issues/issue-65159.rs
+++ b/tests/ui/async-await/issues/issue-65159.rs
@@ -5,7 +5,7 @@
 async fn copy() -> Result<()>
 //~^ ERROR enum takes 2 generic arguments
 {
-    Ok(()) //~ ERROR: type annotations needed
+    Ok(())
 }
 
-fn main() { }
+fn main() {}
diff --git a/tests/ui/async-await/issues/issue-65159.stderr b/tests/ui/async-await/issues/issue-65159.stderr
index 77a0ea5027c..19512116a66 100644
--- a/tests/ui/async-await/issues/issue-65159.stderr
+++ b/tests/ui/async-await/issues/issue-65159.stderr
@@ -11,18 +11,6 @@ help: add missing generic argument
 LL | async fn copy() -> Result<(), E>
    |                             +++
 
-error[E0282]: type annotations needed
-  --> $DIR/issue-65159.rs:8:5
-   |
-LL |     Ok(())
-   |     ^^ cannot infer type of the type parameter `E` declared on the enum `Result`
-   |
-help: consider specifying the generic arguments
-   |
-LL |     Ok::<(), E>(())
-   |       +++++++++
-
-error: aborting due to 2 previous errors
+error: aborting due to 1 previous error
 
-Some errors have detailed explanations: E0107, E0282.
-For more information about an error, try `rustc --explain E0107`.
+For more information about this error, try `rustc --explain E0107`.
diff --git a/tests/ui/async-await/issues/issue-95307.stderr b/tests/ui/async-await/issues/issue-95307.stderr
index fdc6d5de1a8..dd8fcd3690a 100644
--- a/tests/ui/async-await/issues/issue-95307.stderr
+++ b/tests/ui/async-await/issues/issue-95307.stderr
@@ -12,6 +12,7 @@ LL |     async fn new() -> [u8; _];
    |
    = note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
    = help: add `#![feature(generic_arg_infer)]` 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 2 previous errors
 
diff --git a/tests/ui/async-await/track-caller/async-block.afn.stderr b/tests/ui/async-await/track-caller/async-block.afn.stderr
index 2302722eecc..b6a7481a4d1 100644
--- a/tests/ui/async-await/track-caller/async-block.afn.stderr
+++ b/tests/ui/async-await/track-caller/async-block.afn.stderr
@@ -6,6 +6,7 @@ LL |     let _ = #[track_caller] async {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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]: `#[track_caller]` on closures is currently unstable
   --> $DIR/async-block.rs:15:13
@@ -15,6 +16,7 @@ LL |     let _ = #[track_caller] async {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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]: `#[track_caller]` on closures is currently unstable
   --> $DIR/async-block.rs:23:17
@@ -24,6 +26,7 @@ LL |         let _ = #[track_caller] async {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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
 
diff --git a/tests/ui/async-await/track-caller/async-block.nofeat.stderr b/tests/ui/async-await/track-caller/async-block.nofeat.stderr
index 2302722eecc..b6a7481a4d1 100644
--- a/tests/ui/async-await/track-caller/async-block.nofeat.stderr
+++ b/tests/ui/async-await/track-caller/async-block.nofeat.stderr
@@ -6,6 +6,7 @@ LL |     let _ = #[track_caller] async {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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]: `#[track_caller]` on closures is currently unstable
   --> $DIR/async-block.rs:15:13
@@ -15,6 +16,7 @@ LL |     let _ = #[track_caller] async {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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]: `#[track_caller]` on closures is currently unstable
   --> $DIR/async-block.rs:23:17
@@ -24,6 +26,7 @@ LL |         let _ = #[track_caller] async {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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
 
diff --git a/tests/ui/async-await/track-caller/async-closure-gate.afn.stderr b/tests/ui/async-await/track-caller/async-closure-gate.afn.stderr
index e23fc459358..92f38d5a796 100644
--- a/tests/ui/async-await/track-caller/async-closure-gate.afn.stderr
+++ b/tests/ui/async-await/track-caller/async-closure-gate.afn.stderr
@@ -6,6 +6,7 @@ LL |     let _ = #[track_caller] async || {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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]: `#[track_caller]` on closures is currently unstable
   --> $DIR/async-closure-gate.rs:15:13
@@ -15,6 +16,7 @@ LL |     let _ = #[track_caller] async || {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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]: `#[track_caller]` on closures is currently unstable
   --> $DIR/async-closure-gate.rs:21:13
@@ -24,6 +26,7 @@ LL |     let _ = #[track_caller] || {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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]: `#[track_caller]` on closures is currently unstable
   --> $DIR/async-closure-gate.rs:29:17
@@ -33,6 +36,7 @@ LL |         let _ = #[track_caller] || {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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]: `#[track_caller]` on closures is currently unstable
   --> $DIR/async-closure-gate.rs:37:9
@@ -42,6 +46,7 @@ LL |         #[track_caller] || {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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]: `#[track_caller]` on closures is currently unstable
   --> $DIR/async-closure-gate.rs:47:13
@@ -51,6 +56,7 @@ LL |             #[track_caller] || {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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[E0308]: mismatched types
   --> $DIR/async-closure-gate.rs:27:5
diff --git a/tests/ui/async-await/track-caller/async-closure-gate.nofeat.stderr b/tests/ui/async-await/track-caller/async-closure-gate.nofeat.stderr
index e23fc459358..92f38d5a796 100644
--- a/tests/ui/async-await/track-caller/async-closure-gate.nofeat.stderr
+++ b/tests/ui/async-await/track-caller/async-closure-gate.nofeat.stderr
@@ -6,6 +6,7 @@ LL |     let _ = #[track_caller] async || {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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]: `#[track_caller]` on closures is currently unstable
   --> $DIR/async-closure-gate.rs:15:13
@@ -15,6 +16,7 @@ LL |     let _ = #[track_caller] async || {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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]: `#[track_caller]` on closures is currently unstable
   --> $DIR/async-closure-gate.rs:21:13
@@ -24,6 +26,7 @@ LL |     let _ = #[track_caller] || {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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]: `#[track_caller]` on closures is currently unstable
   --> $DIR/async-closure-gate.rs:29:17
@@ -33,6 +36,7 @@ LL |         let _ = #[track_caller] || {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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]: `#[track_caller]` on closures is currently unstable
   --> $DIR/async-closure-gate.rs:37:9
@@ -42,6 +46,7 @@ LL |         #[track_caller] || {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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]: `#[track_caller]` on closures is currently unstable
   --> $DIR/async-closure-gate.rs:47:13
@@ -51,6 +56,7 @@ LL |             #[track_caller] || {
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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[E0308]: mismatched types
   --> $DIR/async-closure-gate.rs:27:5
diff --git a/tests/ui/async-await/track-caller/panic-track-caller.cls.stderr b/tests/ui/async-await/track-caller/panic-track-caller.cls.stderr
index f3090e3b9a6..464cbfba2ac 100644
--- a/tests/ui/async-await/track-caller/panic-track-caller.cls.stderr
+++ b/tests/ui/async-await/track-caller/panic-track-caller.cls.stderr
@@ -11,6 +11,7 @@ LL | | }
    |
    = note: see issue #110011 <https://github.com/rust-lang/rust/issues/110011> for more information
    = help: add `#![feature(async_fn_track_caller)]` 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: `#[warn(ungated_async_fn_track_caller)]` on by default
 
 warning: `#[track_caller]` on async functions is a no-op
@@ -26,6 +27,7 @@ LL | |     }
    |
    = note: see issue #110011 <https://github.com/rust-lang/rust/issues/110011> for more information
    = help: add `#![feature(async_fn_track_caller)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: 2 warnings emitted
 
diff --git a/tests/ui/async-await/track-caller/panic-track-caller.nofeat.stderr b/tests/ui/async-await/track-caller/panic-track-caller.nofeat.stderr
index f3090e3b9a6..464cbfba2ac 100644
--- a/tests/ui/async-await/track-caller/panic-track-caller.nofeat.stderr
+++ b/tests/ui/async-await/track-caller/panic-track-caller.nofeat.stderr
@@ -11,6 +11,7 @@ LL | | }
    |
    = note: see issue #110011 <https://github.com/rust-lang/rust/issues/110011> for more information
    = help: add `#![feature(async_fn_track_caller)]` 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: `#[warn(ungated_async_fn_track_caller)]` on by default
 
 warning: `#[track_caller]` on async functions is a no-op
@@ -26,6 +27,7 @@ LL | |     }
    |
    = note: see issue #110011 <https://github.com/rust-lang/rust/issues/110011> for more information
    = help: add `#![feature(async_fn_track_caller)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: 2 warnings emitted
 
diff --git a/tests/ui/auto-traits/issue-117789.stderr b/tests/ui/auto-traits/issue-117789.stderr
index 9a3a7efed3e..1f8880b1ef4 100644
--- a/tests/ui/auto-traits/issue-117789.stderr
+++ b/tests/ui/auto-traits/issue-117789.stderr
@@ -14,6 +14,7 @@ LL | auto trait Trait<P> {}
    |
    = note: see issue #13231 <https://github.com/rust-lang/rust/issues/13231> for more information
    = help: add `#![feature(auto_traits)]` 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 2 previous errors
 
diff --git a/tests/ui/auto-traits/pre-cfg.stderr b/tests/ui/auto-traits/pre-cfg.stderr
index 6efa05b4326..648f9464d61 100644
--- a/tests/ui/auto-traits/pre-cfg.stderr
+++ b/tests/ui/auto-traits/pre-cfg.stderr
@@ -6,6 +6,7 @@ LL | auto trait Foo {}
    |
    = note: see issue #13231 <https://github.com/rust-lang/rust/issues/13231> for more information
    = help: add `#![feature(auto_traits)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
    = warning: unstable syntax can change at any point in the future, causing a hard error!
    = note: for more information, see issue #65860 <https://github.com/rust-lang/rust/issues/65860>
 
diff --git a/tests/ui/binop/binary-op-suggest-deref.rs b/tests/ui/binop/binary-op-suggest-deref.rs
index 57f24a4c28e..ae442a0d0b4 100644
--- a/tests/ui/binop/binary-op-suggest-deref.rs
+++ b/tests/ui/binop/binary-op-suggest-deref.rs
@@ -72,4 +72,12 @@ fn baz() {
     //~^ERROR can't compare `str` with `&String` [E0277]
 }
 
+fn qux() {
+    // Issue #119352
+    const FOO: i32 = 42;
+    let _ = FOO & (*"Sized".to_string().into_boxed_str());
+    //~^ ERROR the size for values of type `str` cannot be known at compilation time
+    //~| ERROR no implementation for `i32 & str` [E0277]
+}
+
 fn main() {}
diff --git a/tests/ui/binop/binary-op-suggest-deref.stderr b/tests/ui/binop/binary-op-suggest-deref.stderr
index 68b5a24bf97..a98a2ab0706 100644
--- a/tests/ui/binop/binary-op-suggest-deref.stderr
+++ b/tests/ui/binop/binary-op-suggest-deref.stderr
@@ -295,7 +295,28 @@ help: consider dereferencing here
 LL |     _ = partial[..3] == *string_ref;
    |                         +
 
-error: aborting due to 22 previous errors
+error[E0277]: no implementation for `i32 & str`
+  --> $DIR/binary-op-suggest-deref.rs:78:17
+   |
+LL |     let _ = FOO & (*"Sized".to_string().into_boxed_str());
+   |                 ^ no implementation for `i32 & str`
+   |
+   = help: the trait `BitAnd<str>` is not implemented for `i32`
+   = help: the following other types implement trait `BitAnd<Rhs>`:
+             <i32 as BitAnd>
+             <i32 as BitAnd<&i32>>
+             <&'a i32 as BitAnd<i32>>
+             <&i32 as BitAnd<&i32>>
+
+error[E0277]: the size for values of type `str` cannot be known at compilation time
+  --> $DIR/binary-op-suggest-deref.rs:78:17
+   |
+LL |     let _ = FOO & (*"Sized".to_string().into_boxed_str());
+   |                 ^ doesn't have a size known at compile-time
+   |
+   = help: the trait `Sized` is not implemented for `str`
+
+error: aborting due to 24 previous errors
 
 Some errors have detailed explanations: E0277, E0308, E0369.
 For more information about an error, try `rustc --explain E0277`.
diff --git a/tests/ui/borrowck/fn-item-check-trait-ref.rs b/tests/ui/borrowck/fn-item-check-trait-ref.rs
new file mode 100644
index 00000000000..bdbb52e974f
--- /dev/null
+++ b/tests/ui/borrowck/fn-item-check-trait-ref.rs
@@ -0,0 +1,15 @@
+// The method `assert_static` should be callable only for static values,
+// because the impl has an implied bound `where T: 'static`.
+
+// check-fail
+
+trait AnyStatic<Witness>: Sized {
+    fn assert_static(self) {}
+}
+
+impl<T> AnyStatic<&'static T> for T {}
+
+fn main() {
+    (&String::new()).assert_static();
+    //~^ ERROR temporary value dropped while borrowed
+}
diff --git a/tests/ui/borrowck/fn-item-check-trait-ref.stderr b/tests/ui/borrowck/fn-item-check-trait-ref.stderr
new file mode 100644
index 00000000000..92fd67c316c
--- /dev/null
+++ b/tests/ui/borrowck/fn-item-check-trait-ref.stderr
@@ -0,0 +1,12 @@
+error[E0716]: temporary value dropped while borrowed
+  --> $DIR/fn-item-check-trait-ref.rs:13:7
+   |
+LL |     (&String::new()).assert_static();
+   |     --^^^^^^^^^^^^^------------------ temporary value is freed at the end of this statement
+   |     | |
+   |     | creates a temporary value which is freed while still in use
+   |     argument requires that borrow lasts for `'static`
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0716`.
diff --git a/tests/ui/borrowck/fn-item-check-type-params.rs b/tests/ui/borrowck/fn-item-check-type-params.rs
new file mode 100644
index 00000000000..805c0d00de5
--- /dev/null
+++ b/tests/ui/borrowck/fn-item-check-type-params.rs
@@ -0,0 +1,57 @@
+// Regression test for #104005.
+//
+// Previously, different borrowck implementations used to disagree here.
+// The status of each is documented on `fn test_*`.
+
+// check-fail
+
+use std::fmt::Display;
+
+trait Displayable {
+    fn display(self) -> Box<dyn Display>;
+}
+
+impl<T: Display> Displayable for (T, Option<&'static T>) {
+    fn display(self) -> Box<dyn Display> {
+        Box::new(self.0)
+    }
+}
+
+fn extend_lt<T, U>(val: T) -> Box<dyn Display>
+where
+    (T, Option<U>): Displayable,
+{
+    Displayable::display((val, None))
+}
+
+// AST: fail
+// HIR: pass
+// MIR: pass
+pub fn test_call<'a>(val: &'a str) {
+    extend_lt(val);
+    //~^ ERROR borrowed data escapes outside of function
+}
+
+// AST: fail
+// HIR: fail
+// MIR: pass
+pub fn test_coercion<'a>() {
+    let _: fn(&'a str) -> _ = extend_lt;
+    //~^ ERROR lifetime may not live long enough
+}
+
+// AST: fail
+// HIR: fail
+// MIR: fail
+pub fn test_arg() {
+    fn want<I, O>(_: I, _: impl Fn(I) -> O) {}
+    want(&String::new(), extend_lt);
+    //~^ ERROR temporary value dropped while borrowed
+}
+
+// An exploit of the unsoundness.
+fn main() {
+    let val = extend_lt(&String::from("blah blah blah"));
+    //~^ ERROR temporary value dropped while borrowed
+    println!("{}", val);
+}
diff --git a/tests/ui/borrowck/fn-item-check-type-params.stderr b/tests/ui/borrowck/fn-item-check-type-params.stderr
new file mode 100644
index 00000000000..3a29edc55c5
--- /dev/null
+++ b/tests/ui/borrowck/fn-item-check-type-params.stderr
@@ -0,0 +1,43 @@
+error[E0521]: borrowed data escapes outside of function
+  --> $DIR/fn-item-check-type-params.rs:31:5
+   |
+LL | pub fn test_call<'a>(val: &'a str) {
+   |                  --  --- `val` is a reference that is only valid in the function body
+   |                  |
+   |                  lifetime `'a` defined here
+LL |     extend_lt(val);
+   |     ^^^^^^^^^^^^^^
+   |     |
+   |     `val` escapes the function body here
+   |     argument requires that `'a` must outlive `'static`
+
+error: lifetime may not live long enough
+  --> $DIR/fn-item-check-type-params.rs:39:12
+   |
+LL | pub fn test_coercion<'a>() {
+   |                      -- lifetime `'a` defined here
+LL |     let _: fn(&'a str) -> _ = extend_lt;
+   |            ^^^^^^^^^^^^^^^^ type annotation requires that `'a` must outlive `'static`
+
+error[E0716]: temporary value dropped while borrowed
+  --> $DIR/fn-item-check-type-params.rs:48:11
+   |
+LL |     want(&String::new(), extend_lt);
+   |     ------^^^^^^^^^^^^^------------- temporary value is freed at the end of this statement
+   |     |     |
+   |     |     creates a temporary value which is freed while still in use
+   |     argument requires that borrow lasts for `'static`
+
+error[E0716]: temporary value dropped while borrowed
+  --> $DIR/fn-item-check-type-params.rs:54:26
+   |
+LL |     let val = extend_lt(&String::from("blah blah blah"));
+   |               -----------^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-- temporary value is freed at the end of this statement
+   |               |          |
+   |               |          creates a temporary value which is freed while still in use
+   |               argument requires that borrow lasts for `'static`
+
+error: aborting due to 4 previous errors
+
+Some errors have detailed explanations: E0521, E0716.
+For more information about an error, try `rustc --explain E0521`.
diff --git a/tests/ui/borrowck/issue-119915-bad-clone-suggestion.rs b/tests/ui/borrowck/issue-119915-bad-clone-suggestion.rs
new file mode 100644
index 00000000000..0b0ac9448db
--- /dev/null
+++ b/tests/ui/borrowck/issue-119915-bad-clone-suggestion.rs
@@ -0,0 +1,28 @@
+use std::marker::PhantomData;
+
+struct Example<E, FakeParam>(PhantomData<(fn(E), fn(FakeParam))>);
+
+struct NoLifetime;
+struct Immutable<'a>(PhantomData<&'a ()>);
+
+impl<'a, E: 'a> Copy for Example<E, Immutable<'a>> {}
+impl<'a, E: 'a> Clone for Example<E, Immutable<'a>> {
+    fn clone(&self) -> Self {
+        *self
+    }
+}
+
+impl<E, FakeParam> Example<E, FakeParam> {
+    unsafe fn change<NewFakeParam>(self) -> Example<E, NewFakeParam> {
+        Example(PhantomData)
+    }
+}
+
+impl<E> Example<E, NoLifetime> {
+    fn the_ice(&mut self) -> Example<E, Immutable<'_>> {
+        unsafe { self.change() }
+        //~^ ERROR cannot move out of `*self` which is behind a mutable reference
+    }
+}
+
+fn main() {}
diff --git a/tests/ui/borrowck/issue-119915-bad-clone-suggestion.stderr b/tests/ui/borrowck/issue-119915-bad-clone-suggestion.stderr
new file mode 100644
index 00000000000..ab42205d510
--- /dev/null
+++ b/tests/ui/borrowck/issue-119915-bad-clone-suggestion.stderr
@@ -0,0 +1,17 @@
+error[E0507]: cannot move out of `*self` which is behind a mutable reference
+  --> $DIR/issue-119915-bad-clone-suggestion.rs:23:18
+   |
+LL |         unsafe { self.change() }
+   |                  ^^^^ -------- `*self` moved due to this method call
+   |                  |
+   |                  move occurs because `*self` has type `Example<E, NoLifetime>`, which does not implement the `Copy` trait
+   |
+note: `Example::<E, FakeParam>::change` takes ownership of the receiver `self`, which moves `*self`
+  --> $DIR/issue-119915-bad-clone-suggestion.rs:16:36
+   |
+LL |     unsafe fn change<NewFakeParam>(self) -> Example<E, NewFakeParam> {
+   |                                    ^^^^
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0507`.
diff --git a/tests/ui/borrowck/issue-82126-mismatched-subst-and-hir.rs b/tests/ui/borrowck/issue-82126-mismatched-subst-and-hir.rs
index c10246eec64..b52939ffc11 100644
--- a/tests/ui/borrowck/issue-82126-mismatched-subst-and-hir.rs
+++ b/tests/ui/borrowck/issue-82126-mismatched-subst-and-hir.rs
@@ -17,7 +17,6 @@ async fn buy_lock(coroutine: &Mutex<MarketMultiplier>) -> LockedMarket<'_> {
     //~^ ERROR struct takes 0 lifetime arguments but 1 lifetime argument was supplied
     //~^^ ERROR struct takes 1 generic argument but 0 generic arguments were supplied
     LockedMarket(coroutine.lock().unwrap().buy())
-    //~^ ERROR: cannot return value referencing temporary value
 }
 
 struct LockedMarket<T>(T);
diff --git a/tests/ui/borrowck/issue-82126-mismatched-subst-and-hir.stderr b/tests/ui/borrowck/issue-82126-mismatched-subst-and-hir.stderr
index 2b10cf67d15..516c1d065e6 100644
--- a/tests/ui/borrowck/issue-82126-mismatched-subst-and-hir.stderr
+++ b/tests/ui/borrowck/issue-82126-mismatched-subst-and-hir.stderr
@@ -7,7 +7,7 @@ LL | async fn buy_lock(coroutine: &Mutex<MarketMultiplier>) -> LockedMarket<'_>
    |                                                           expected 0 lifetime arguments
    |
 note: struct defined here, with 0 lifetime parameters
-  --> $DIR/issue-82126-mismatched-subst-and-hir.rs:23:8
+  --> $DIR/issue-82126-mismatched-subst-and-hir.rs:22:8
    |
 LL | struct LockedMarket<T>(T);
    |        ^^^^^^^^^^^^
@@ -19,7 +19,7 @@ LL | async fn buy_lock(coroutine: &Mutex<MarketMultiplier>) -> LockedMarket<'_>
    |                                                           ^^^^^^^^^^^^ expected 1 generic argument
    |
 note: struct defined here, with 1 generic parameter: `T`
-  --> $DIR/issue-82126-mismatched-subst-and-hir.rs:23:8
+  --> $DIR/issue-82126-mismatched-subst-and-hir.rs:22:8
    |
 LL | struct LockedMarket<T>(T);
    |        ^^^^^^^^^^^^ -
@@ -28,16 +28,6 @@ help: add missing generic argument
 LL | async fn buy_lock(coroutine: &Mutex<MarketMultiplier>) -> LockedMarket<'_, T> {
    |                                                                          +++
 
-error[E0515]: cannot return value referencing temporary value
-  --> $DIR/issue-82126-mismatched-subst-and-hir.rs:19:5
-   |
-LL |     LockedMarket(coroutine.lock().unwrap().buy())
-   |     ^^^^^^^^^^^^^-------------------------^^^^^^^
-   |     |            |
-   |     |            temporary value created here
-   |     returns a value referencing data owned by the current function
-
-error: aborting due to 3 previous errors
+error: aborting due to 2 previous errors
 
-Some errors have detailed explanations: E0107, E0515.
-For more information about an error, try `rustc --explain E0107`.
+For more information about this error, try `rustc --explain E0107`.
diff --git a/tests/ui/borrowck/issue-85765-closure.rs b/tests/ui/borrowck/issue-85765-closure.rs
index edc9eeaffb5..f2d1dd0fbc3 100644
--- a/tests/ui/borrowck/issue-85765-closure.rs
+++ b/tests/ui/borrowck/issue-85765-closure.rs
@@ -3,7 +3,6 @@ fn main() {
         let mut test = Vec::new();
         let rofl: &Vec<Vec<i32>> = &mut test;
         //~^ HELP consider changing this binding's type
-        //~| HELP you can `clone` the `Vec<Vec<i32>>` value and consume it, but this might not be your desired behavior
         rofl.push(Vec::new());
         //~^ ERROR cannot borrow `*rofl` as mutable, as it is behind a `&` reference
         //~| NOTE `rofl` is a `&` reference, so the data it refers to cannot be borrowed as mutable
diff --git a/tests/ui/borrowck/issue-85765-closure.stderr b/tests/ui/borrowck/issue-85765-closure.stderr
index 4a6a0e94bec..936ddd67bcd 100644
--- a/tests/ui/borrowck/issue-85765-closure.stderr
+++ b/tests/ui/borrowck/issue-85765-closure.stderr
@@ -1,21 +1,16 @@
 error[E0596]: cannot borrow `*rofl` as mutable, as it is behind a `&` reference
-  --> $DIR/issue-85765-closure.rs:7:9
+  --> $DIR/issue-85765-closure.rs:6:9
    |
 LL |         rofl.push(Vec::new());
    |         ^^^^ `rofl` is a `&` reference, so the data it refers to cannot be borrowed as mutable
    |
-help: you can `clone` the `Vec<Vec<i32>>` value and consume it, but this might not be your desired behavior
-  --> $DIR/issue-85765-closure.rs:4:36
-   |
-LL |         let rofl: &Vec<Vec<i32>> = &mut test;
-   |                                    ^^^^^^^^^
 help: consider changing this binding's type
    |
 LL |         let rofl: &mut Vec<Vec<i32>> = &mut test;
    |                   ~~~~~~~~~~~~~~~~~~
 
 error[E0594]: cannot assign to `*r`, which is behind a `&` reference
-  --> $DIR/issue-85765-closure.rs:14:9
+  --> $DIR/issue-85765-closure.rs:13:9
    |
 LL |         *r = 0;
    |         ^^^^^^ `r` is a `&` reference, so the data it refers to cannot be written
@@ -26,7 +21,7 @@ LL |         let r = &mut mutvar;
    |                  +++
 
 error[E0594]: cannot assign to `*x`, which is behind a `&` reference
-  --> $DIR/issue-85765-closure.rs:21:9
+  --> $DIR/issue-85765-closure.rs:20:9
    |
 LL |         *x = 1;
    |         ^^^^^^ `x` is a `&` reference, so the data it refers to cannot be written
@@ -37,7 +32,7 @@ LL |         let x: &mut usize = &mut{0};
    |                ~~~~~~~~~~
 
 error[E0594]: cannot assign to `*y`, which is behind a `&` reference
-  --> $DIR/issue-85765-closure.rs:28:9
+  --> $DIR/issue-85765-closure.rs:27:9
    |
 LL |         *y = 1;
    |         ^^^^^^ `y` is a `&` reference, so the data it refers to cannot be written
diff --git a/tests/ui/borrowck/issue-85765.rs b/tests/ui/borrowck/issue-85765.rs
index ce5740bc0e7..76e0b517354 100644
--- a/tests/ui/borrowck/issue-85765.rs
+++ b/tests/ui/borrowck/issue-85765.rs
@@ -2,7 +2,6 @@ fn main() {
     let mut test = Vec::new();
     let rofl: &Vec<Vec<i32>> = &mut test;
     //~^ HELP consider changing this binding's type
-    //~| HELP you can `clone` the `Vec<Vec<i32>>` value and consume it, but this might not be your desired behavior
     rofl.push(Vec::new());
     //~^ ERROR cannot borrow `*rofl` as mutable, as it is behind a `&` reference
     //~| NOTE `rofl` is a `&` reference, so the data it refers to cannot be borrowed as mutable
diff --git a/tests/ui/borrowck/issue-85765.stderr b/tests/ui/borrowck/issue-85765.stderr
index 4889f774afa..57900bfb612 100644
--- a/tests/ui/borrowck/issue-85765.stderr
+++ b/tests/ui/borrowck/issue-85765.stderr
@@ -1,21 +1,16 @@
 error[E0596]: cannot borrow `*rofl` as mutable, as it is behind a `&` reference
-  --> $DIR/issue-85765.rs:6:5
+  --> $DIR/issue-85765.rs:5:5
    |
 LL |     rofl.push(Vec::new());
    |     ^^^^ `rofl` is a `&` reference, so the data it refers to cannot be borrowed as mutable
    |
-help: you can `clone` the `Vec<Vec<i32>>` value and consume it, but this might not be your desired behavior
-  --> $DIR/issue-85765.rs:3:32
-   |
-LL |     let rofl: &Vec<Vec<i32>> = &mut test;
-   |                                ^^^^^^^^^
 help: consider changing this binding's type
    |
 LL |     let rofl: &mut Vec<Vec<i32>> = &mut test;
    |               ~~~~~~~~~~~~~~~~~~
 
 error[E0594]: cannot assign to `*r`, which is behind a `&` reference
-  --> $DIR/issue-85765.rs:13:5
+  --> $DIR/issue-85765.rs:12:5
    |
 LL |     *r = 0;
    |     ^^^^^^ `r` is a `&` reference, so the data it refers to cannot be written
@@ -26,7 +21,7 @@ LL |     let r = &mut mutvar;
    |              +++
 
 error[E0594]: cannot assign to `*x`, which is behind a `&` reference
-  --> $DIR/issue-85765.rs:20:5
+  --> $DIR/issue-85765.rs:19:5
    |
 LL |     *x = 1;
    |     ^^^^^^ `x` is a `&` reference, so the data it refers to cannot be written
@@ -37,7 +32,7 @@ LL |     let x: &mut usize = &mut{0};
    |            ~~~~~~~~~~
 
 error[E0594]: cannot assign to `*y`, which is behind a `&` reference
-  --> $DIR/issue-85765.rs:27:5
+  --> $DIR/issue-85765.rs:26:5
    |
 LL |     *y = 1;
    |     ^^^^^^ `y` is a `&` reference, so the data it refers to cannot be written
diff --git a/tests/ui/borrowck/issue-91206.rs b/tests/ui/borrowck/issue-91206.rs
index c60ac62fa34..e062a253767 100644
--- a/tests/ui/borrowck/issue-91206.rs
+++ b/tests/ui/borrowck/issue-91206.rs
@@ -10,7 +10,6 @@ fn main() {
     let client = TestClient;
     let inner = client.get_inner_ref();
     //~^ HELP consider specifying this binding's type
-    //~| HELP you can `clone` the `Vec<usize>` value and consume it, but this might not be your desired behavior
     inner.clear();
     //~^ ERROR cannot borrow `*inner` as mutable, as it is behind a `&` reference [E0596]
     //~| NOTE `inner` is a `&` reference, so the data it refers to cannot be borrowed as mutable
diff --git a/tests/ui/borrowck/issue-91206.stderr b/tests/ui/borrowck/issue-91206.stderr
index e3dd65b6419..f96b0c7d9e1 100644
--- a/tests/ui/borrowck/issue-91206.stderr
+++ b/tests/ui/borrowck/issue-91206.stderr
@@ -1,14 +1,9 @@
 error[E0596]: cannot borrow `*inner` as mutable, as it is behind a `&` reference
-  --> $DIR/issue-91206.rs:14:5
+  --> $DIR/issue-91206.rs:13:5
    |
 LL |     inner.clear();
    |     ^^^^^ `inner` is a `&` reference, so the data it refers to cannot be borrowed as mutable
    |
-help: you can `clone` the `Vec<usize>` value and consume it, but this might not be your desired behavior
-  --> $DIR/issue-91206.rs:11:17
-   |
-LL |     let inner = client.get_inner_ref();
-   |                 ^^^^^^^^^^^^^^^^^^^^^^
 help: consider specifying this binding's type
    |
 LL |     let inner: &mut Vec<usize> = client.get_inner_ref();
diff --git a/tests/ui/bounds-lifetime.stderr b/tests/ui/bounds-lifetime.stderr
index de9b9e01242..01b314f3d1b 100644
--- a/tests/ui/bounds-lifetime.stderr
+++ b/tests/ui/bounds-lifetime.stderr
@@ -24,6 +24,7 @@ LL | type D = for<'a, T> fn();
    |
    = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
    = help: add `#![feature(non_lifetime_binders)]` 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]: only lifetime parameters can be used in this context
   --> $DIR/bounds-lifetime.rs:5:18
@@ -33,6 +34,7 @@ LL | type E = dyn for<T, U> Fn();
    |
    = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
    = help: add `#![feature(non_lifetime_binders)]` 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 5 previous errors
 
diff --git a/tests/ui/box/alloc-unstable-fail.stderr b/tests/ui/box/alloc-unstable-fail.stderr
index 352efce318f..9e1e12a2b6a 100644
--- a/tests/ui/box/alloc-unstable-fail.stderr
+++ b/tests/ui/box/alloc-unstable-fail.stderr
@@ -6,6 +6,7 @@ LL |     let _boxed: Box<u32, _> = Box::new(10);
    |
    = note: see issue #32838 <https://github.com/rust-lang/rust/issues/32838> for more information
    = help: add `#![feature(allocator_api)]` 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 1 previous error
 
diff --git a/tests/ui/c-variadic/feature-gate-extended_varargs_abi_support.stderr b/tests/ui/c-variadic/feature-gate-extended_varargs_abi_support.stderr
index 5b97b396fb1..94e9628f0f0 100644
--- a/tests/ui/c-variadic/feature-gate-extended_varargs_abi_support.stderr
+++ b/tests/ui/c-variadic/feature-gate-extended_varargs_abi_support.stderr
@@ -6,6 +6,7 @@ LL | fn efiapi(f: extern "efiapi" fn(usize, ...)) {
    |
    = note: see issue #100189 <https://github.com/rust-lang/rust/issues/100189> for more information
    = help: add `#![feature(extended_varargs_abi_support)]` 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[E0045]: C-variadic function must have a compatible calling convention, like `C` or `cdecl`
   --> $DIR/feature-gate-extended_varargs_abi_support.rs:1:14
@@ -21,6 +22,7 @@ LL | fn sysv(f: extern "sysv64" fn(usize, ...)) {
    |
    = note: see issue #100189 <https://github.com/rust-lang/rust/issues/100189> for more information
    = help: add `#![feature(extended_varargs_abi_support)]` 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[E0045]: C-variadic function must have a compatible calling convention, like `C` or `cdecl`
   --> $DIR/feature-gate-extended_varargs_abi_support.rs:6:12
@@ -36,6 +38,7 @@ LL | fn win(f: extern "win64" fn(usize, ...)) {
    |
    = note: see issue #100189 <https://github.com/rust-lang/rust/issues/100189> for more information
    = help: add `#![feature(extended_varargs_abi_support)]` 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[E0045]: C-variadic function must have a compatible calling convention, like `C` or `cdecl`
   --> $DIR/feature-gate-extended_varargs_abi_support.rs:11:11
diff --git a/tests/ui/c-variadic/variadic-ffi-2.rs b/tests/ui/c-variadic/variadic-ffi-2.rs
index 67a0a9a1dec..a412a58d7c5 100644
--- a/tests/ui/c-variadic/variadic-ffi-2.rs
+++ b/tests/ui/c-variadic/variadic-ffi-2.rs
@@ -3,10 +3,13 @@
 
 fn baz(f: extern "stdcall" fn(usize, ...)) {
     //~^ ERROR: C-variadic function must have a compatible calling convention,
-    // like C, cdecl, aapcs, win64, sysv64 or efiapi
+    // like C, cdecl, system, aapcs, win64, sysv64 or efiapi
     f(22, 44);
 }
 
+fn system(f: extern "system" fn(usize, ...)) {
+    f(22, 44);
+}
 fn aapcs(f: extern "aapcs" fn(usize, ...)) {
     f(22, 44);
 }
diff --git a/tests/ui/c-variadic/variadic-ffi-2.stderr b/tests/ui/c-variadic/variadic-ffi-2.stderr
index d0ca7034ba1..fbf273b1f1d 100644
--- a/tests/ui/c-variadic/variadic-ffi-2.stderr
+++ b/tests/ui/c-variadic/variadic-ffi-2.stderr
@@ -1,4 +1,4 @@
-error[E0045]: C-variadic function must have a compatible calling convention, like `C`, `cdecl`, `aapcs`, `win64`, `sysv64` or `efiapi`
+error[E0045]: C-variadic function must have a compatible calling convention, like `C`, `cdecl`, `system`, `aapcs`, `win64`, `sysv64` or `efiapi`
   --> $DIR/variadic-ffi-2.rs:4:11
    |
 LL | fn baz(f: extern "stdcall" fn(usize, ...)) {
diff --git a/tests/ui/cfg/cfg-false-feature.stderr b/tests/ui/cfg/cfg-false-feature.stderr
index 34093036205..9309b59ca59 100644
--- a/tests/ui/cfg/cfg-false-feature.stderr
+++ b/tests/ui/cfg/cfg-false-feature.stderr
@@ -6,6 +6,7 @@ LL | trait A = Clone;
    |
    = note: see issue #41517 <https://github.com/rust-lang/rust/issues/41517> for more information
    = help: add `#![feature(trait_alias)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
    = warning: unstable syntax can change at any point in the future, causing a hard error!
    = note: for more information, see issue #65860 <https://github.com/rust-lang/rust/issues/65860>
 
@@ -17,6 +18,7 @@ LL |     let box _ = Box::new(0);
    |
    = note: see issue #29641 <https://github.com/rust-lang/rust/issues/29641> for more information
    = help: add `#![feature(box_patterns)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
    = warning: unstable syntax can change at any point in the future, causing a hard error!
    = note: for more information, see issue #65860 <https://github.com/rust-lang/rust/issues/65860>
 
diff --git a/tests/ui/cfg/diagnostics-cross-crate.rs b/tests/ui/cfg/diagnostics-cross-crate.rs
index d2725c94b08..ad4e47b7b2e 100644
--- a/tests/ui/cfg/diagnostics-cross-crate.rs
+++ b/tests/ui/cfg/diagnostics-cross-crate.rs
@@ -14,9 +14,9 @@ fn main() {
 
     // The module isn't found - we would like to get a diagnostic, but currently don't due to
     // the awkward way the resolver diagnostics are currently implemented.
-    // FIXME(Nilstrieb): Also add a note to the cfg diagnostic here
     cfged_out::inner::doesnt_exist::hello(); //~ ERROR failed to resolve
     //~^ NOTE could not find `doesnt_exist` in `inner`
+    //~| NOTE found an item that was configured out
 
     // It should find the one in the right module, not the wrong one.
     cfged_out::inner::right::meow(); //~ ERROR cannot find function
diff --git a/tests/ui/cfg/diagnostics-cross-crate.stderr b/tests/ui/cfg/diagnostics-cross-crate.stderr
index 046929bc260..8a238f36404 100644
--- a/tests/ui/cfg/diagnostics-cross-crate.stderr
+++ b/tests/ui/cfg/diagnostics-cross-crate.stderr
@@ -1,8 +1,14 @@
 error[E0433]: failed to resolve: could not find `doesnt_exist` in `inner`
-  --> $DIR/diagnostics-cross-crate.rs:18:23
+  --> $DIR/diagnostics-cross-crate.rs:17:23
    |
 LL |     cfged_out::inner::doesnt_exist::hello();
    |                       ^^^^^^^^^^^^ could not find `doesnt_exist` in `inner`
+   |
+note: found an item that was configured out
+  --> $DIR/auxiliary/cfged_out.rs:6:13
+   |
+LL |     pub mod doesnt_exist {
+   |             ^^^^^^^^^^^^
 
 error[E0425]: cannot find function `uwu` in crate `cfged_out`
   --> $DIR/diagnostics-cross-crate.rs:7:16
diff --git a/tests/ui/cfg/diagnostics-same-crate.rs b/tests/ui/cfg/diagnostics-same-crate.rs
index f76ace06a76..2d0907c6dfb 100644
--- a/tests/ui/cfg/diagnostics-same-crate.rs
+++ b/tests/ui/cfg/diagnostics-same-crate.rs
@@ -4,7 +4,7 @@ pub mod inner {
     //~^ NOTE found an item that was configured out
 
     #[cfg(FALSE)]
-    pub mod doesnt_exist {
+    pub mod doesnt_exist { //~ NOTE found an item that was configured out
         pub fn hello() {}
     }
 
@@ -34,7 +34,6 @@ fn main() {
 
     // The module isn't found - we would like to get a diagnostic, but currently don't due to
     // the awkward way the resolver diagnostics are currently implemented.
-    // FIXME(Nilstrieb): Also add a note to the cfg diagnostic here
     inner::doesnt_exist::hello(); //~ ERROR failed to resolve
     //~| NOTE could not find `doesnt_exist` in `inner`
 
diff --git a/tests/ui/cfg/diagnostics-same-crate.stderr b/tests/ui/cfg/diagnostics-same-crate.stderr
index 30ee6479bd2..62a9d132de0 100644
--- a/tests/ui/cfg/diagnostics-same-crate.stderr
+++ b/tests/ui/cfg/diagnostics-same-crate.stderr
@@ -1,8 +1,14 @@
 error[E0433]: failed to resolve: could not find `doesnt_exist` in `inner`
-  --> $DIR/diagnostics-same-crate.rs:38:12
+  --> $DIR/diagnostics-same-crate.rs:37:12
    |
 LL |     inner::doesnt_exist::hello();
    |            ^^^^^^^^^^^^ could not find `doesnt_exist` in `inner`
+   |
+note: found an item that was configured out
+  --> $DIR/diagnostics-same-crate.rs:7:13
+   |
+LL |     pub mod doesnt_exist {
+   |             ^^^^^^^^^^^^
 
 error[E0425]: cannot find function `uwu` in module `inner`
   --> $DIR/diagnostics-same-crate.rs:32:12
@@ -17,7 +23,7 @@ LL |     pub fn uwu() {}
    |            ^^^
 
 error[E0425]: cannot find function `meow` in module `inner::right`
-  --> $DIR/diagnostics-same-crate.rs:42:19
+  --> $DIR/diagnostics-same-crate.rs:41:19
    |
 LL |     inner::right::meow();
    |                   ^^^^ not found in `inner::right`
@@ -36,7 +42,7 @@ LL |     uwu();
    |     ^^^ not found in this scope
 
 error[E0425]: cannot find function `vanished` in this scope
-  --> $DIR/diagnostics-same-crate.rs:49:5
+  --> $DIR/diagnostics-same-crate.rs:48:5
    |
 LL |     vanished();
    |     ^^^^^^^^ not found in this scope
diff --git a/tests/ui/closures/2229_closure_analysis/arrays-completely-captured.rs b/tests/ui/closures/2229_closure_analysis/arrays-completely-captured.rs
index 2bcbd792e3a..191cb4c7236 100644
--- a/tests/ui/closures/2229_closure_analysis/arrays-completely-captured.rs
+++ b/tests/ui/closures/2229_closure_analysis/arrays-completely-captured.rs
@@ -8,6 +8,7 @@ fn main() {
     let mut c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/arrays-completely-captured.stderr b/tests/ui/closures/2229_closure_analysis/arrays-completely-captured.stderr
index 129b26456ce..d7582dcfcc7 100644
--- a/tests/ui/closures/2229_closure_analysis/arrays-completely-captured.stderr
+++ b/tests/ui/closures/2229_closure_analysis/arrays-completely-captured.stderr
@@ -6,9 +6,10 @@ LL |     let mut c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/arrays-completely-captured.rs:11:5
+  --> $DIR/arrays-completely-captured.rs:12:5
    |
 LL | /     || {
 LL | |
@@ -20,18 +21,18 @@ LL | |     };
    | |_____^
    |
 note: Capturing m[] -> MutBorrow
-  --> $DIR/arrays-completely-captured.rs:14:9
+  --> $DIR/arrays-completely-captured.rs:15:9
    |
 LL |         m[0] += 10;
    |         ^
 note: Capturing m[] -> MutBorrow
-  --> $DIR/arrays-completely-captured.rs:17:9
+  --> $DIR/arrays-completely-captured.rs:18:9
    |
 LL |         m[1] += 40;
    |         ^
 
 error: Min Capture analysis includes:
-  --> $DIR/arrays-completely-captured.rs:11:5
+  --> $DIR/arrays-completely-captured.rs:12:5
    |
 LL | /     || {
 LL | |
@@ -43,7 +44,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture m[] -> MutBorrow
-  --> $DIR/arrays-completely-captured.rs:14:9
+  --> $DIR/arrays-completely-captured.rs:15:9
    |
 LL |         m[0] += 10;
    |         ^
diff --git a/tests/ui/closures/2229_closure_analysis/by_value.rs b/tests/ui/closures/2229_closure_analysis/by_value.rs
index d8d3bbee200..d3bde3cea63 100644
--- a/tests/ui/closures/2229_closure_analysis/by_value.rs
+++ b/tests/ui/closures/2229_closure_analysis/by_value.rs
@@ -18,6 +18,7 @@ fn big_box() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ First Pass analysis includes:
     //~| Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/by_value.stderr b/tests/ui/closures/2229_closure_analysis/by_value.stderr
index 097462253aa..0dd9991cf84 100644
--- a/tests/ui/closures/2229_closure_analysis/by_value.stderr
+++ b/tests/ui/closures/2229_closure_analysis/by_value.stderr
@@ -6,9 +6,10 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/by_value.rs:21:5
+  --> $DIR/by_value.rs:22:5
    |
 LL | /     || {
 LL | |
@@ -20,18 +21,18 @@ LL | |     };
    | |_____^
    |
 note: Capturing t[(0, 0),Deref,(0, 0)] -> ByValue
-  --> $DIR/by_value.rs:24:17
+  --> $DIR/by_value.rs:25:17
    |
 LL |         let p = t.0.0;
    |                 ^^^^^
 note: Capturing t[(1, 0)] -> ImmBorrow
-  --> $DIR/by_value.rs:27:29
+  --> $DIR/by_value.rs:28:29
    |
 LL |         println!("{} {:?}", t.1, p);
    |                             ^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/by_value.rs:21:5
+  --> $DIR/by_value.rs:22:5
    |
 LL | /     || {
 LL | |
@@ -43,12 +44,12 @@ LL | |     };
    | |_____^
    |
 note: Min Capture t[(0, 0)] -> ByValue
-  --> $DIR/by_value.rs:24:17
+  --> $DIR/by_value.rs:25:17
    |
 LL |         let p = t.0.0;
    |                 ^^^^^
 note: Min Capture t[(1, 0)] -> ImmBorrow
-  --> $DIR/by_value.rs:27:29
+  --> $DIR/by_value.rs:28:29
    |
 LL |         println!("{} {:?}", t.1, p);
    |                             ^^^
diff --git a/tests/ui/closures/2229_closure_analysis/capture-analysis-1.rs b/tests/ui/closures/2229_closure_analysis/capture-analysis-1.rs
index dc53b31768e..1a800b6b7f2 100644
--- a/tests/ui/closures/2229_closure_analysis/capture-analysis-1.rs
+++ b/tests/ui/closures/2229_closure_analysis/capture-analysis-1.rs
@@ -15,6 +15,7 @@ fn main() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ First Pass analysis includes:
     //~| Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/capture-analysis-1.stderr b/tests/ui/closures/2229_closure_analysis/capture-analysis-1.stderr
index fceafb9c84e..d2409c9367c 100644
--- a/tests/ui/closures/2229_closure_analysis/capture-analysis-1.stderr
+++ b/tests/ui/closures/2229_closure_analysis/capture-analysis-1.stderr
@@ -6,9 +6,10 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/capture-analysis-1.rs:18:5
+  --> $DIR/capture-analysis-1.rs:19:5
    |
 LL | /     || {
 LL | |
@@ -20,28 +21,28 @@ LL | |     };
    | |_____^
    |
 note: Capturing p[] -> ImmBorrow
-  --> $DIR/capture-analysis-1.rs:21:26
+  --> $DIR/capture-analysis-1.rs:22:26
    |
 LL |         println!("{:?}", p);
    |                          ^
 note: Capturing p[(0, 0)] -> ImmBorrow
-  --> $DIR/capture-analysis-1.rs:24:26
+  --> $DIR/capture-analysis-1.rs:25:26
    |
 LL |         println!("{:?}", p.x);
    |                          ^^^
 note: Capturing q[(0, 0)] -> ImmBorrow
-  --> $DIR/capture-analysis-1.rs:27:26
+  --> $DIR/capture-analysis-1.rs:28:26
    |
 LL |         println!("{:?}", q.x);
    |                          ^^^
 note: Capturing q[] -> ImmBorrow
-  --> $DIR/capture-analysis-1.rs:29:26
+  --> $DIR/capture-analysis-1.rs:30:26
    |
 LL |         println!("{:?}", q);
    |                          ^
 
 error: Min Capture analysis includes:
-  --> $DIR/capture-analysis-1.rs:18:5
+  --> $DIR/capture-analysis-1.rs:19:5
    |
 LL | /     || {
 LL | |
@@ -53,12 +54,12 @@ LL | |     };
    | |_____^
    |
 note: Min Capture p[] -> ImmBorrow
-  --> $DIR/capture-analysis-1.rs:21:26
+  --> $DIR/capture-analysis-1.rs:22:26
    |
 LL |         println!("{:?}", p);
    |                          ^
 note: Min Capture q[] -> ImmBorrow
-  --> $DIR/capture-analysis-1.rs:29:26
+  --> $DIR/capture-analysis-1.rs:30:26
    |
 LL |         println!("{:?}", q);
    |                          ^
diff --git a/tests/ui/closures/2229_closure_analysis/capture-analysis-2.rs b/tests/ui/closures/2229_closure_analysis/capture-analysis-2.rs
index 99d12f8d8f1..9b1825e9042 100644
--- a/tests/ui/closures/2229_closure_analysis/capture-analysis-2.rs
+++ b/tests/ui/closures/2229_closure_analysis/capture-analysis-2.rs
@@ -14,6 +14,7 @@ fn main() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ First Pass analysis includes:
     //~| Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/capture-analysis-2.stderr b/tests/ui/closures/2229_closure_analysis/capture-analysis-2.stderr
index cb44ca26652..7049c708bb8 100644
--- a/tests/ui/closures/2229_closure_analysis/capture-analysis-2.stderr
+++ b/tests/ui/closures/2229_closure_analysis/capture-analysis-2.stderr
@@ -6,9 +6,10 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/capture-analysis-2.rs:17:5
+  --> $DIR/capture-analysis-2.rs:18:5
    |
 LL | /     || {
 LL | |
@@ -20,18 +21,18 @@ LL | |     };
    | |_____^
    |
 note: Capturing p[(0, 0)] -> ByValue
-  --> $DIR/capture-analysis-2.rs:20:18
+  --> $DIR/capture-analysis-2.rs:21:18
    |
 LL |         let _x = p.x;
    |                  ^^^
 note: Capturing p[] -> ImmBorrow
-  --> $DIR/capture-analysis-2.rs:23:26
+  --> $DIR/capture-analysis-2.rs:24:26
    |
 LL |         println!("{:?}", p);
    |                          ^
 
 error: Min Capture analysis includes:
-  --> $DIR/capture-analysis-2.rs:17:5
+  --> $DIR/capture-analysis-2.rs:18:5
    |
 LL | /     || {
 LL | |
@@ -43,7 +44,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture p[] -> ByValue
-  --> $DIR/capture-analysis-2.rs:20:18
+  --> $DIR/capture-analysis-2.rs:21:18
    |
 LL |         let _x = p.x;
    |                  ^^^ p[] captured as ByValue here
diff --git a/tests/ui/closures/2229_closure_analysis/capture-analysis-3.rs b/tests/ui/closures/2229_closure_analysis/capture-analysis-3.rs
index 3f337097dbd..e9923a81bf6 100644
--- a/tests/ui/closures/2229_closure_analysis/capture-analysis-3.rs
+++ b/tests/ui/closures/2229_closure_analysis/capture-analysis-3.rs
@@ -19,6 +19,7 @@ fn main() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ First Pass analysis includes:
     //~| Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/capture-analysis-3.stderr b/tests/ui/closures/2229_closure_analysis/capture-analysis-3.stderr
index 71e7bdc354f..698b51a4fdb 100644
--- a/tests/ui/closures/2229_closure_analysis/capture-analysis-3.stderr
+++ b/tests/ui/closures/2229_closure_analysis/capture-analysis-3.stderr
@@ -6,9 +6,10 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/capture-analysis-3.rs:22:5
+  --> $DIR/capture-analysis-3.rs:23:5
    |
 LL | /     || {
 LL | |
@@ -20,18 +21,18 @@ LL | |     };
    | |_____^
    |
 note: Capturing a[(0, 0),(0, 0)] -> ByValue
-  --> $DIR/capture-analysis-3.rs:25:18
+  --> $DIR/capture-analysis-3.rs:26:18
    |
 LL |         let _x = a.b.c;
    |                  ^^^^^
 note: Capturing a[(0, 0)] -> ImmBorrow
-  --> $DIR/capture-analysis-3.rs:28:26
+  --> $DIR/capture-analysis-3.rs:29:26
    |
 LL |         println!("{:?}", a.b);
    |                          ^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/capture-analysis-3.rs:22:5
+  --> $DIR/capture-analysis-3.rs:23:5
    |
 LL | /     || {
 LL | |
@@ -43,7 +44,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture a[(0, 0)] -> ByValue
-  --> $DIR/capture-analysis-3.rs:25:18
+  --> $DIR/capture-analysis-3.rs:26:18
    |
 LL |         let _x = a.b.c;
    |                  ^^^^^ a[(0, 0)] captured as ByValue here
diff --git a/tests/ui/closures/2229_closure_analysis/capture-analysis-4.rs b/tests/ui/closures/2229_closure_analysis/capture-analysis-4.rs
index bc46ec99736..8c1963455a5 100644
--- a/tests/ui/closures/2229_closure_analysis/capture-analysis-4.rs
+++ b/tests/ui/closures/2229_closure_analysis/capture-analysis-4.rs
@@ -19,6 +19,7 @@ fn main() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ First Pass analysis includes:
     //~| Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/capture-analysis-4.stderr b/tests/ui/closures/2229_closure_analysis/capture-analysis-4.stderr
index 7e6e625bc7d..9cd0dcf720e 100644
--- a/tests/ui/closures/2229_closure_analysis/capture-analysis-4.stderr
+++ b/tests/ui/closures/2229_closure_analysis/capture-analysis-4.stderr
@@ -6,9 +6,10 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/capture-analysis-4.rs:22:5
+  --> $DIR/capture-analysis-4.rs:23:5
    |
 LL | /     || {
 LL | |
@@ -20,18 +21,18 @@ LL | |     };
    | |_____^
    |
 note: Capturing a[(0, 0)] -> ByValue
-  --> $DIR/capture-analysis-4.rs:25:18
+  --> $DIR/capture-analysis-4.rs:26:18
    |
 LL |         let _x = a.b;
    |                  ^^^
 note: Capturing a[(0, 0),(0, 0)] -> ImmBorrow
-  --> $DIR/capture-analysis-4.rs:28:26
+  --> $DIR/capture-analysis-4.rs:29:26
    |
 LL |         println!("{:?}", a.b.c);
    |                          ^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/capture-analysis-4.rs:22:5
+  --> $DIR/capture-analysis-4.rs:23:5
    |
 LL | /     || {
 LL | |
@@ -43,7 +44,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture a[(0, 0)] -> ByValue
-  --> $DIR/capture-analysis-4.rs:25:18
+  --> $DIR/capture-analysis-4.rs:26:18
    |
 LL |         let _x = a.b;
    |                  ^^^
diff --git a/tests/ui/closures/2229_closure_analysis/capture-disjoint-field-struct.rs b/tests/ui/closures/2229_closure_analysis/capture-disjoint-field-struct.rs
index 6fd15155331..2bf127ed5e8 100644
--- a/tests/ui/closures/2229_closure_analysis/capture-disjoint-field-struct.rs
+++ b/tests/ui/closures/2229_closure_analysis/capture-disjoint-field-struct.rs
@@ -13,6 +13,7 @@ fn main() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ First Pass analysis includes:
     //~| Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/capture-disjoint-field-struct.stderr b/tests/ui/closures/2229_closure_analysis/capture-disjoint-field-struct.stderr
index 0f64ecf3a0c..92a719d6098 100644
--- a/tests/ui/closures/2229_closure_analysis/capture-disjoint-field-struct.stderr
+++ b/tests/ui/closures/2229_closure_analysis/capture-disjoint-field-struct.stderr
@@ -6,9 +6,10 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/capture-disjoint-field-struct.rs:16:5
+  --> $DIR/capture-disjoint-field-struct.rs:17:5
    |
 LL | /     || {
 LL | |
@@ -20,13 +21,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing p[(0, 0)] -> ImmBorrow
-  --> $DIR/capture-disjoint-field-struct.rs:19:24
+  --> $DIR/capture-disjoint-field-struct.rs:20:24
    |
 LL |         println!("{}", p.x);
    |                        ^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/capture-disjoint-field-struct.rs:16:5
+  --> $DIR/capture-disjoint-field-struct.rs:17:5
    |
 LL | /     || {
 LL | |
@@ -38,7 +39,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture p[(0, 0)] -> ImmBorrow
-  --> $DIR/capture-disjoint-field-struct.rs:19:24
+  --> $DIR/capture-disjoint-field-struct.rs:20:24
    |
 LL |         println!("{}", p.x);
    |                        ^^^
diff --git a/tests/ui/closures/2229_closure_analysis/capture-disjoint-field-tuple.rs b/tests/ui/closures/2229_closure_analysis/capture-disjoint-field-tuple.rs
index 8d3bb3262fb..bf36de634a9 100644
--- a/tests/ui/closures/2229_closure_analysis/capture-disjoint-field-tuple.rs
+++ b/tests/ui/closures/2229_closure_analysis/capture-disjoint-field-tuple.rs
@@ -8,6 +8,7 @@ fn main() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ First Pass analysis includes:
     //~| Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/capture-disjoint-field-tuple.stderr b/tests/ui/closures/2229_closure_analysis/capture-disjoint-field-tuple.stderr
index a8ca9622a6a..d5333bf71db 100644
--- a/tests/ui/closures/2229_closure_analysis/capture-disjoint-field-tuple.stderr
+++ b/tests/ui/closures/2229_closure_analysis/capture-disjoint-field-tuple.stderr
@@ -6,9 +6,10 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/capture-disjoint-field-tuple.rs:11:5
+  --> $DIR/capture-disjoint-field-tuple.rs:12:5
    |
 LL | /     || {
 LL | |
@@ -20,13 +21,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing t[(0, 0)] -> ImmBorrow
-  --> $DIR/capture-disjoint-field-tuple.rs:14:24
+  --> $DIR/capture-disjoint-field-tuple.rs:15:24
    |
 LL |         println!("{}", t.0);
    |                        ^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/capture-disjoint-field-tuple.rs:11:5
+  --> $DIR/capture-disjoint-field-tuple.rs:12:5
    |
 LL | /     || {
 LL | |
@@ -38,7 +39,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture t[(0, 0)] -> ImmBorrow
-  --> $DIR/capture-disjoint-field-tuple.rs:14:24
+  --> $DIR/capture-disjoint-field-tuple.rs:15:24
    |
 LL |         println!("{}", t.0);
    |                        ^^^
diff --git a/tests/ui/closures/2229_closure_analysis/capture-enums.rs b/tests/ui/closures/2229_closure_analysis/capture-enums.rs
index 322ae99b861..47926e27f0c 100644
--- a/tests/ui/closures/2229_closure_analysis/capture-enums.rs
+++ b/tests/ui/closures/2229_closure_analysis/capture-enums.rs
@@ -16,6 +16,7 @@ fn multi_variant_enum() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ First Pass analysis includes:
     //~| Min Capture analysis includes:
@@ -47,6 +48,7 @@ fn single_variant_enum() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ First Pass analysis includes:
     //~| Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/capture-enums.stderr b/tests/ui/closures/2229_closure_analysis/capture-enums.stderr
index 8a6ba8444a8..8b258569d95 100644
--- a/tests/ui/closures/2229_closure_analysis/capture-enums.stderr
+++ b/tests/ui/closures/2229_closure_analysis/capture-enums.stderr
@@ -6,18 +6,20 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/capture-enums.rs:47:13
+  --> $DIR/capture-enums.rs:48:13
    |
 LL |     let c = #[rustc_capture_analysis]
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/capture-enums.rs:19:5
+  --> $DIR/capture-enums.rs:20:5
    |
 LL | /     || {
 LL | |
@@ -29,28 +31,28 @@ LL | |     };
    | |_____^
    |
 note: Capturing point[] -> ImmBorrow
-  --> $DIR/capture-enums.rs:22:41
+  --> $DIR/capture-enums.rs:23:41
    |
 LL |         if let Info::Point(_, _, str) = point {
    |                                         ^^^^^
 note: Capturing point[(2, 0)] -> ByValue
-  --> $DIR/capture-enums.rs:22:41
+  --> $DIR/capture-enums.rs:23:41
    |
 LL |         if let Info::Point(_, _, str) = point {
    |                                         ^^^^^
 note: Capturing meta[] -> ImmBorrow
-  --> $DIR/capture-enums.rs:29:35
+  --> $DIR/capture-enums.rs:30:35
    |
 LL |         if let Info::Meta(_, v) = meta {
    |                                   ^^^^
 note: Capturing meta[(1, 1)] -> ByValue
-  --> $DIR/capture-enums.rs:29:35
+  --> $DIR/capture-enums.rs:30:35
    |
 LL |         if let Info::Meta(_, v) = meta {
    |                                   ^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/capture-enums.rs:19:5
+  --> $DIR/capture-enums.rs:20:5
    |
 LL | /     || {
 LL | |
@@ -62,18 +64,18 @@ LL | |     };
    | |_____^
    |
 note: Min Capture point[] -> ByValue
-  --> $DIR/capture-enums.rs:22:41
+  --> $DIR/capture-enums.rs:23:41
    |
 LL |         if let Info::Point(_, _, str) = point {
    |                                         ^^^^^
 note: Min Capture meta[] -> ByValue
-  --> $DIR/capture-enums.rs:29:35
+  --> $DIR/capture-enums.rs:30:35
    |
 LL |         if let Info::Meta(_, v) = meta {
    |                                   ^^^^
 
 error: First Pass analysis includes:
-  --> $DIR/capture-enums.rs:50:5
+  --> $DIR/capture-enums.rs:52:5
    |
 LL | /     || {
 LL | |
@@ -85,13 +87,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing point[(2, 0)] -> ByValue
-  --> $DIR/capture-enums.rs:53:47
+  --> $DIR/capture-enums.rs:55:47
    |
 LL |         let SingleVariant::Point(_, _, str) = point;
    |                                               ^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/capture-enums.rs:50:5
+  --> $DIR/capture-enums.rs:52:5
    |
 LL | /     || {
 LL | |
@@ -103,7 +105,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture point[(2, 0)] -> ByValue
-  --> $DIR/capture-enums.rs:53:47
+  --> $DIR/capture-enums.rs:55:47
    |
 LL |         let SingleVariant::Point(_, _, str) = point;
    |                                               ^^^^^
diff --git a/tests/ui/closures/2229_closure_analysis/deep-multilevel-struct.rs b/tests/ui/closures/2229_closure_analysis/deep-multilevel-struct.rs
index 3341166e22b..18697a79cff 100644
--- a/tests/ui/closures/2229_closure_analysis/deep-multilevel-struct.rs
+++ b/tests/ui/closures/2229_closure_analysis/deep-multilevel-struct.rs
@@ -34,6 +34,7 @@ fn main() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/deep-multilevel-struct.stderr b/tests/ui/closures/2229_closure_analysis/deep-multilevel-struct.stderr
index 29e1af0431e..55ba416dfd9 100644
--- a/tests/ui/closures/2229_closure_analysis/deep-multilevel-struct.stderr
+++ b/tests/ui/closures/2229_closure_analysis/deep-multilevel-struct.stderr
@@ -6,9 +6,10 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/deep-multilevel-struct.rs:37:5
+  --> $DIR/deep-multilevel-struct.rs:38:5
    |
 LL | /     || {
 LL | |
@@ -20,23 +21,23 @@ LL | |     };
    | |_____^
    |
 note: Capturing p[(0, 0),(0, 0),(0, 0)] -> ImmBorrow
-  --> $DIR/deep-multilevel-struct.rs:40:18
+  --> $DIR/deep-multilevel-struct.rs:41:18
    |
 LL |         let x = &p.a.p.x;
    |                  ^^^^^^^
 note: Capturing p[(1, 0),(1, 0),(1, 0)] -> MutBorrow
-  --> $DIR/deep-multilevel-struct.rs:42:9
+  --> $DIR/deep-multilevel-struct.rs:43:9
    |
 LL |         p.b.q.y = 9;
    |         ^^^^^^^
 note: Capturing p[] -> ImmBorrow
-  --> $DIR/deep-multilevel-struct.rs:45:26
+  --> $DIR/deep-multilevel-struct.rs:46:26
    |
 LL |         println!("{:?}", p);
    |                          ^
 
 error: Min Capture analysis includes:
-  --> $DIR/deep-multilevel-struct.rs:37:5
+  --> $DIR/deep-multilevel-struct.rs:38:5
    |
 LL | /     || {
 LL | |
@@ -48,7 +49,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture p[] -> MutBorrow
-  --> $DIR/deep-multilevel-struct.rs:42:9
+  --> $DIR/deep-multilevel-struct.rs:43:9
    |
 LL |         p.b.q.y = 9;
    |         ^^^^^^^ p[] captured as MutBorrow here
diff --git a/tests/ui/closures/2229_closure_analysis/deep-multilevel-tuple.rs b/tests/ui/closures/2229_closure_analysis/deep-multilevel-tuple.rs
index 34b0132f3cb..2f899f8c60a 100644
--- a/tests/ui/closures/2229_closure_analysis/deep-multilevel-tuple.rs
+++ b/tests/ui/closures/2229_closure_analysis/deep-multilevel-tuple.rs
@@ -8,6 +8,7 @@ fn main() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/deep-multilevel-tuple.stderr b/tests/ui/closures/2229_closure_analysis/deep-multilevel-tuple.stderr
index e917516765c..5e45fe1ca8b 100644
--- a/tests/ui/closures/2229_closure_analysis/deep-multilevel-tuple.stderr
+++ b/tests/ui/closures/2229_closure_analysis/deep-multilevel-tuple.stderr
@@ -6,9 +6,10 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/deep-multilevel-tuple.rs:11:5
+  --> $DIR/deep-multilevel-tuple.rs:12:5
    |
 LL | /     || {
 LL | |
@@ -20,23 +21,23 @@ LL | |     };
    | |_____^
    |
 note: Capturing t[(0, 0),(0, 0),(0, 0)] -> ImmBorrow
-  --> $DIR/deep-multilevel-tuple.rs:14:18
+  --> $DIR/deep-multilevel-tuple.rs:15:18
    |
 LL |         let x = &t.0.0.0;
    |                  ^^^^^^^
 note: Capturing t[(1, 0),(1, 0),(1, 0)] -> MutBorrow
-  --> $DIR/deep-multilevel-tuple.rs:16:9
+  --> $DIR/deep-multilevel-tuple.rs:17:9
    |
 LL |         t.1.1.1 = 9;
    |         ^^^^^^^
 note: Capturing t[] -> ImmBorrow
-  --> $DIR/deep-multilevel-tuple.rs:19:26
+  --> $DIR/deep-multilevel-tuple.rs:20:26
    |
 LL |         println!("{:?}", t);
    |                          ^
 
 error: Min Capture analysis includes:
-  --> $DIR/deep-multilevel-tuple.rs:11:5
+  --> $DIR/deep-multilevel-tuple.rs:12:5
    |
 LL | /     || {
 LL | |
@@ -48,7 +49,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture t[] -> MutBorrow
-  --> $DIR/deep-multilevel-tuple.rs:16:9
+  --> $DIR/deep-multilevel-tuple.rs:17:9
    |
 LL |         t.1.1.1 = 9;
    |         ^^^^^^^ t[] captured as MutBorrow here
diff --git a/tests/ui/closures/2229_closure_analysis/destructure_patterns.rs b/tests/ui/closures/2229_closure_analysis/destructure_patterns.rs
index 6c65a7bf87b..a0b949e1351 100644
--- a/tests/ui/closures/2229_closure_analysis/destructure_patterns.rs
+++ b/tests/ui/closures/2229_closure_analysis/destructure_patterns.rs
@@ -10,6 +10,7 @@ fn arrays() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
@@ -38,6 +39,7 @@ fn structs() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
@@ -58,6 +60,7 @@ fn tuples() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/destructure_patterns.stderr b/tests/ui/closures/2229_closure_analysis/destructure_patterns.stderr
index 44fbe6d8158..7fc85de499f 100644
--- a/tests/ui/closures/2229_closure_analysis/destructure_patterns.stderr
+++ b/tests/ui/closures/2229_closure_analysis/destructure_patterns.stderr
@@ -6,27 +6,30 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/destructure_patterns.rs:38:13
+  --> $DIR/destructure_patterns.rs:39:13
    |
 LL |     let c = #[rustc_capture_analysis]
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/destructure_patterns.rs:58:13
+  --> $DIR/destructure_patterns.rs:60:13
    |
 LL |     let c = #[rustc_capture_analysis]
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/destructure_patterns.rs:13:5
+  --> $DIR/destructure_patterns.rs:14:5
    |
 LL | /     || {
 LL | |
@@ -38,23 +41,23 @@ LL | |     };
    | |_____^
    |
 note: Capturing arr[Index] -> ByValue
-  --> $DIR/destructure_patterns.rs:16:29
+  --> $DIR/destructure_patterns.rs:17:29
    |
 LL |         let [a, b, .., e] = arr;
    |                             ^^^
 note: Capturing arr[Index] -> ByValue
-  --> $DIR/destructure_patterns.rs:16:29
+  --> $DIR/destructure_patterns.rs:17:29
    |
 LL |         let [a, b, .., e] = arr;
    |                             ^^^
 note: Capturing arr[Index] -> ByValue
-  --> $DIR/destructure_patterns.rs:16:29
+  --> $DIR/destructure_patterns.rs:17:29
    |
 LL |         let [a, b, .., e] = arr;
    |                             ^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/destructure_patterns.rs:13:5
+  --> $DIR/destructure_patterns.rs:14:5
    |
 LL | /     || {
 LL | |
@@ -66,13 +69,13 @@ LL | |     };
    | |_____^
    |
 note: Min Capture arr[] -> ByValue
-  --> $DIR/destructure_patterns.rs:16:29
+  --> $DIR/destructure_patterns.rs:17:29
    |
 LL |         let [a, b, .., e] = arr;
    |                             ^^^
 
 error: First Pass analysis includes:
-  --> $DIR/destructure_patterns.rs:41:5
+  --> $DIR/destructure_patterns.rs:43:5
    |
 LL | /     || {
 LL | |
@@ -84,18 +87,18 @@ LL | |     };
    | |_____^
    |
 note: Capturing p[(0, 0)] -> MutBorrow
-  --> $DIR/destructure_patterns.rs:44:58
+  --> $DIR/destructure_patterns.rs:46:58
    |
 LL |         let Point { x: ref mut x, y: _, id: moved_id } = p;
    |                                                          ^
 note: Capturing p[(2, 0)] -> ByValue
-  --> $DIR/destructure_patterns.rs:44:58
+  --> $DIR/destructure_patterns.rs:46:58
    |
 LL |         let Point { x: ref mut x, y: _, id: moved_id } = p;
    |                                                          ^
 
 error: Min Capture analysis includes:
-  --> $DIR/destructure_patterns.rs:41:5
+  --> $DIR/destructure_patterns.rs:43:5
    |
 LL | /     || {
 LL | |
@@ -107,18 +110,18 @@ LL | |     };
    | |_____^
    |
 note: Min Capture p[(0, 0)] -> MutBorrow
-  --> $DIR/destructure_patterns.rs:44:58
+  --> $DIR/destructure_patterns.rs:46:58
    |
 LL |         let Point { x: ref mut x, y: _, id: moved_id } = p;
    |                                                          ^
 note: Min Capture p[(2, 0)] -> ByValue
-  --> $DIR/destructure_patterns.rs:44:58
+  --> $DIR/destructure_patterns.rs:46:58
    |
 LL |         let Point { x: ref mut x, y: _, id: moved_id } = p;
    |                                                          ^
 
 error: First Pass analysis includes:
-  --> $DIR/destructure_patterns.rs:61:5
+  --> $DIR/destructure_patterns.rs:64:5
    |
 LL | /     || {
 LL | |
@@ -130,23 +133,23 @@ LL | |     };
    | |_____^
    |
 note: Capturing t[(0, 0)] -> MutBorrow
-  --> $DIR/destructure_patterns.rs:64:54
+  --> $DIR/destructure_patterns.rs:67:54
    |
 LL |         let (ref mut x, ref ref_str, (moved_s, _)) = t;
    |                                                      ^
 note: Capturing t[(1, 0)] -> ImmBorrow
-  --> $DIR/destructure_patterns.rs:64:54
+  --> $DIR/destructure_patterns.rs:67:54
    |
 LL |         let (ref mut x, ref ref_str, (moved_s, _)) = t;
    |                                                      ^
 note: Capturing t[(2, 0),(0, 0)] -> ByValue
-  --> $DIR/destructure_patterns.rs:64:54
+  --> $DIR/destructure_patterns.rs:67:54
    |
 LL |         let (ref mut x, ref ref_str, (moved_s, _)) = t;
    |                                                      ^
 
 error: Min Capture analysis includes:
-  --> $DIR/destructure_patterns.rs:61:5
+  --> $DIR/destructure_patterns.rs:64:5
    |
 LL | /     || {
 LL | |
@@ -158,17 +161,17 @@ LL | |     };
    | |_____^
    |
 note: Min Capture t[(0, 0)] -> MutBorrow
-  --> $DIR/destructure_patterns.rs:64:54
+  --> $DIR/destructure_patterns.rs:67:54
    |
 LL |         let (ref mut x, ref ref_str, (moved_s, _)) = t;
    |                                                      ^
 note: Min Capture t[(1, 0)] -> ImmBorrow
-  --> $DIR/destructure_patterns.rs:64:54
+  --> $DIR/destructure_patterns.rs:67:54
    |
 LL |         let (ref mut x, ref ref_str, (moved_s, _)) = t;
    |                                                      ^
 note: Min Capture t[(2, 0),(0, 0)] -> ByValue
-  --> $DIR/destructure_patterns.rs:64:54
+  --> $DIR/destructure_patterns.rs:67:54
    |
 LL |         let (ref mut x, ref ref_str, (moved_s, _)) = t;
    |                                                      ^
diff --git a/tests/ui/closures/2229_closure_analysis/feature-gate-capture_disjoint_fields.rs b/tests/ui/closures/2229_closure_analysis/feature-gate-capture_disjoint_fields.rs
index 269cf76e673..26990b4305f 100644
--- a/tests/ui/closures/2229_closure_analysis/feature-gate-capture_disjoint_fields.rs
+++ b/tests/ui/closures/2229_closure_analysis/feature-gate-capture_disjoint_fields.rs
@@ -8,6 +8,7 @@ fn main() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/feature-gate-capture_disjoint_fields.stderr b/tests/ui/closures/2229_closure_analysis/feature-gate-capture_disjoint_fields.stderr
index b936c5ee35a..4e76070dcf7 100644
--- a/tests/ui/closures/2229_closure_analysis/feature-gate-capture_disjoint_fields.stderr
+++ b/tests/ui/closures/2229_closure_analysis/feature-gate-capture_disjoint_fields.stderr
@@ -6,9 +6,10 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/feature-gate-capture_disjoint_fields.rs:11:5
+  --> $DIR/feature-gate-capture_disjoint_fields.rs:12:5
    |
 LL | /     || {
 LL | |
@@ -20,13 +21,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing s[] -> ImmBorrow
-  --> $DIR/feature-gate-capture_disjoint_fields.rs:14:69
+  --> $DIR/feature-gate-capture_disjoint_fields.rs:15:69
    |
 LL |         println!("This uses new capture analyysis to capture s={}", s);
    |                                                                     ^
 
 error: Min Capture analysis includes:
-  --> $DIR/feature-gate-capture_disjoint_fields.rs:11:5
+  --> $DIR/feature-gate-capture_disjoint_fields.rs:12:5
    |
 LL | /     || {
 LL | |
@@ -38,7 +39,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture s[] -> ImmBorrow
-  --> $DIR/feature-gate-capture_disjoint_fields.rs:14:69
+  --> $DIR/feature-gate-capture_disjoint_fields.rs:15:69
    |
 LL |         println!("This uses new capture analyysis to capture s={}", s);
    |                                                                     ^
diff --git a/tests/ui/closures/2229_closure_analysis/issue-87378.rs b/tests/ui/closures/2229_closure_analysis/issue-87378.rs
index 75901a5718b..f0707b51bbb 100644
--- a/tests/ui/closures/2229_closure_analysis/issue-87378.rs
+++ b/tests/ui/closures/2229_closure_analysis/issue-87378.rs
@@ -14,6 +14,7 @@ fn main() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/issue-87378.stderr b/tests/ui/closures/2229_closure_analysis/issue-87378.stderr
index 16c3f7c976d..19c0c59170b 100644
--- a/tests/ui/closures/2229_closure_analysis/issue-87378.stderr
+++ b/tests/ui/closures/2229_closure_analysis/issue-87378.stderr
@@ -6,9 +6,10 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/issue-87378.rs:17:5
+  --> $DIR/issue-87378.rs:18:5
    |
 LL | /     || {
 LL | |
@@ -20,13 +21,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing u[(0, 0)] -> ImmBorrow
-  --> $DIR/issue-87378.rs:20:17
+  --> $DIR/issue-87378.rs:21:17
    |
 LL |        unsafe { u.value }
    |                 ^^^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/issue-87378.rs:17:5
+  --> $DIR/issue-87378.rs:18:5
    |
 LL | /     || {
 LL | |
@@ -38,7 +39,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture u[] -> ImmBorrow
-  --> $DIR/issue-87378.rs:20:17
+  --> $DIR/issue-87378.rs:21:17
    |
 LL |        unsafe { u.value }
    |                 ^^^^^^^
diff --git a/tests/ui/closures/2229_closure_analysis/issue-88476.rs b/tests/ui/closures/2229_closure_analysis/issue-88476.rs
index f5906d30600..58d86283f90 100644
--- a/tests/ui/closures/2229_closure_analysis/issue-88476.rs
+++ b/tests/ui/closures/2229_closure_analysis/issue-88476.rs
@@ -20,6 +20,7 @@ pub fn test1() {
     let x = #[rustc_capture_analysis] move || {
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     //~| ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
         println!("{:?}", f.0);
@@ -47,6 +48,7 @@ fn test2() {
     let c = #[rustc_capture_analysis] move || {
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     //~| ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
         println!("{}", character.hp)
diff --git a/tests/ui/closures/2229_closure_analysis/issue-88476.stderr b/tests/ui/closures/2229_closure_analysis/issue-88476.stderr
index c7c9ecbbb0e..d0201757157 100644
--- a/tests/ui/closures/2229_closure_analysis/issue-88476.stderr
+++ b/tests/ui/closures/2229_closure_analysis/issue-88476.stderr
@@ -6,15 +6,17 @@ LL |     let x = #[rustc_capture_analysis] move || {
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/issue-88476.rs:47:13
+  --> $DIR/issue-88476.rs:48:13
    |
 LL |     let c = #[rustc_capture_analysis] move || {
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
   --> $DIR/issue-88476.rs:20:39
@@ -30,7 +32,7 @@ LL | |     };
    | |_____^
    |
 note: Capturing f[(0, 0)] -> ImmBorrow
-  --> $DIR/issue-88476.rs:25:26
+  --> $DIR/issue-88476.rs:26:26
    |
 LL |         println!("{:?}", f.0);
    |                          ^^^
@@ -49,13 +51,13 @@ LL | |     };
    | |_____^
    |
 note: Min Capture f[] -> ByValue
-  --> $DIR/issue-88476.rs:25:26
+  --> $DIR/issue-88476.rs:26:26
    |
 LL |         println!("{:?}", f.0);
    |                          ^^^
 
 error: First Pass analysis includes:
-  --> $DIR/issue-88476.rs:47:39
+  --> $DIR/issue-88476.rs:48:39
    |
 LL |       let c = #[rustc_capture_analysis] move || {
    |  _______________________________________^
@@ -68,13 +70,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing character[(0, 0)] -> ImmBorrow
-  --> $DIR/issue-88476.rs:52:24
+  --> $DIR/issue-88476.rs:54:24
    |
 LL |         println!("{}", character.hp)
    |                        ^^^^^^^^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/issue-88476.rs:47:39
+  --> $DIR/issue-88476.rs:48:39
    |
 LL |       let c = #[rustc_capture_analysis] move || {
    |  _______________________________________^
@@ -87,7 +89,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture character[(0, 0)] -> ByValue
-  --> $DIR/issue-88476.rs:52:24
+  --> $DIR/issue-88476.rs:54:24
    |
 LL |         println!("{}", character.hp)
    |                        ^^^^^^^^^^^^
diff --git a/tests/ui/closures/2229_closure_analysis/move_closure.rs b/tests/ui/closures/2229_closure_analysis/move_closure.rs
index b542fa2430c..31e04fa6d5c 100644
--- a/tests/ui/closures/2229_closure_analysis/move_closure.rs
+++ b/tests/ui/closures/2229_closure_analysis/move_closure.rs
@@ -12,6 +12,7 @@ fn simple_move_closure() {
     let mut c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     move || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
@@ -30,6 +31,7 @@ fn simple_ref() {
     let mut c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     move || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
@@ -51,6 +53,7 @@ fn struct_contains_ref_to_another_struct_1() {
     let mut c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     move || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
@@ -74,6 +77,7 @@ fn struct_contains_ref_to_another_struct_2() {
     let mut c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     move || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
@@ -96,6 +100,7 @@ fn struct_contains_ref_to_another_struct_3() {
     let mut c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     move || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
@@ -117,6 +122,7 @@ fn truncate_box_derefs() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     move || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
@@ -133,6 +139,7 @@ fn truncate_box_derefs() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     move || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
@@ -150,6 +157,7 @@ fn truncate_box_derefs() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     move || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
@@ -172,6 +180,7 @@ fn box_mut_1() {
     let c = #[rustc_capture_analysis] move || box_p_foo.x += 10;
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     //~| First Pass analysis includes:
     //~| NOTE: Capturing box_p_foo[Deref,Deref,(0, 0)] -> MutBorrow
     //~| Min Capture analysis includes:
@@ -189,6 +198,7 @@ fn box_mut_2() {
     let c = #[rustc_capture_analysis] move || p_foo.x += 10;
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     //~| First Pass analysis includes:
     //~| NOTE: Capturing p_foo[Deref,Deref,(0, 0)] -> MutBorrow
     //~| Min Capture analysis includes:
@@ -202,6 +212,7 @@ fn returned_closure_owns_copy_type_data() -> impl Fn() -> i32 {
     let c = #[rustc_capture_analysis] move || x;
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     //~| First Pass analysis includes:
     //~| NOTE: Capturing x[] -> ImmBorrow
     //~| Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/move_closure.stderr b/tests/ui/closures/2229_closure_analysis/move_closure.stderr
index fd80e05c689..7e9e3c5fed3 100644
--- a/tests/ui/closures/2229_closure_analysis/move_closure.stderr
+++ b/tests/ui/closures/2229_closure_analysis/move_closure.stderr
@@ -6,123 +6,134 @@ LL |     let mut c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/move_closure.rs:30:17
+  --> $DIR/move_closure.rs:31:17
    |
 LL |     let mut c = #[rustc_capture_analysis]
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/move_closure.rs:51:17
+  --> $DIR/move_closure.rs:53:17
    |
 LL |     let mut c = #[rustc_capture_analysis]
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/move_closure.rs:74:17
+  --> $DIR/move_closure.rs:77:17
    |
 LL |     let mut c = #[rustc_capture_analysis]
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/move_closure.rs:96:17
+  --> $DIR/move_closure.rs:100:17
    |
 LL |     let mut c = #[rustc_capture_analysis]
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/move_closure.rs:117:13
+  --> $DIR/move_closure.rs:122:13
    |
 LL |     let c = #[rustc_capture_analysis]
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/move_closure.rs:133:13
+  --> $DIR/move_closure.rs:139:13
    |
 LL |     let c = #[rustc_capture_analysis]
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/move_closure.rs:150:13
+  --> $DIR/move_closure.rs:157:13
    |
 LL |     let c = #[rustc_capture_analysis]
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/move_closure.rs:172:13
+  --> $DIR/move_closure.rs:180:13
    |
 LL |     let c = #[rustc_capture_analysis] move || box_p_foo.x += 10;
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/move_closure.rs:189:13
+  --> $DIR/move_closure.rs:198:13
    |
 LL |     let c = #[rustc_capture_analysis] move || p_foo.x += 10;
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/move_closure.rs:202:13
+  --> $DIR/move_closure.rs:212:13
    |
 LL |     let c = #[rustc_capture_analysis] move || x;
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/move_closure.rs:202:39
+  --> $DIR/move_closure.rs:212:39
    |
 LL |     let c = #[rustc_capture_analysis] move || x;
    |                                       ^^^^^^^^^
    |
 note: Capturing x[] -> ImmBorrow
-  --> $DIR/move_closure.rs:202:47
+  --> $DIR/move_closure.rs:212:47
    |
 LL |     let c = #[rustc_capture_analysis] move || x;
    |                                               ^
 
 error: Min Capture analysis includes:
-  --> $DIR/move_closure.rs:202:39
+  --> $DIR/move_closure.rs:212:39
    |
 LL |     let c = #[rustc_capture_analysis] move || x;
    |                                       ^^^^^^^^^
    |
 note: Min Capture x[] -> ByValue
-  --> $DIR/move_closure.rs:202:47
+  --> $DIR/move_closure.rs:212:47
    |
 LL |     let c = #[rustc_capture_analysis] move || x;
    |                                               ^
 
 error: First Pass analysis includes:
-  --> $DIR/move_closure.rs:15:5
+  --> $DIR/move_closure.rs:16:5
    |
 LL | /     move || {
 LL | |
@@ -134,13 +145,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing t[(0, 0),(0, 0)] -> MutBorrow
-  --> $DIR/move_closure.rs:18:9
+  --> $DIR/move_closure.rs:19:9
    |
 LL |         t.0.0 = "new S".into();
    |         ^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/move_closure.rs:15:5
+  --> $DIR/move_closure.rs:16:5
    |
 LL | /     move || {
 LL | |
@@ -152,13 +163,13 @@ LL | |     };
    | |_____^
    |
 note: Min Capture t[(0, 0),(0, 0)] -> ByValue
-  --> $DIR/move_closure.rs:18:9
+  --> $DIR/move_closure.rs:19:9
    |
 LL |         t.0.0 = "new S".into();
    |         ^^^^^
 
 error: First Pass analysis includes:
-  --> $DIR/move_closure.rs:33:5
+  --> $DIR/move_closure.rs:35:5
    |
 LL | /     move || {
 LL | |
@@ -170,13 +181,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing ref_s[Deref] -> MutBorrow
-  --> $DIR/move_closure.rs:36:9
+  --> $DIR/move_closure.rs:38:9
    |
 LL |         *ref_s += 10;
    |         ^^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/move_closure.rs:33:5
+  --> $DIR/move_closure.rs:35:5
    |
 LL | /     move || {
 LL | |
@@ -188,13 +199,13 @@ LL | |     };
    | |_____^
    |
 note: Min Capture ref_s[] -> ByValue
-  --> $DIR/move_closure.rs:36:9
+  --> $DIR/move_closure.rs:38:9
    |
 LL |         *ref_s += 10;
    |         ^^^^^^
 
 error: First Pass analysis includes:
-  --> $DIR/move_closure.rs:54:5
+  --> $DIR/move_closure.rs:57:5
    |
 LL | /     move || {
 LL | |
@@ -206,13 +217,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing t[(0, 0),Deref,(0, 0)] -> MutBorrow
-  --> $DIR/move_closure.rs:57:9
+  --> $DIR/move_closure.rs:60:9
    |
 LL |         t.0.0 = "new s".into();
    |         ^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/move_closure.rs:54:5
+  --> $DIR/move_closure.rs:57:5
    |
 LL | /     move || {
 LL | |
@@ -224,13 +235,13 @@ LL | |     };
    | |_____^
    |
 note: Min Capture t[(0, 0)] -> ByValue
-  --> $DIR/move_closure.rs:57:9
+  --> $DIR/move_closure.rs:60:9
    |
 LL |         t.0.0 = "new s".into();
    |         ^^^^^
 
 error: First Pass analysis includes:
-  --> $DIR/move_closure.rs:77:5
+  --> $DIR/move_closure.rs:81:5
    |
 LL | /     move || {
 LL | |
@@ -242,13 +253,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing t[(0, 0),Deref,(0, 0)] -> ImmBorrow
-  --> $DIR/move_closure.rs:80:18
+  --> $DIR/move_closure.rs:84:18
    |
 LL |         let _t = t.0.0;
    |                  ^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/move_closure.rs:77:5
+  --> $DIR/move_closure.rs:81:5
    |
 LL | /     move || {
 LL | |
@@ -260,13 +271,13 @@ LL | |     };
    | |_____^
    |
 note: Min Capture t[(0, 0)] -> ByValue
-  --> $DIR/move_closure.rs:80:18
+  --> $DIR/move_closure.rs:84:18
    |
 LL |         let _t = t.0.0;
    |                  ^^^^^
 
 error: First Pass analysis includes:
-  --> $DIR/move_closure.rs:99:5
+  --> $DIR/move_closure.rs:104:5
    |
 LL | /     move || {
 LL | |
@@ -278,13 +289,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing t[(0, 0),Deref,(0, 0)] -> ByValue
-  --> $DIR/move_closure.rs:102:18
+  --> $DIR/move_closure.rs:107:18
    |
 LL |         let _t = t.0.0;
    |                  ^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/move_closure.rs:99:5
+  --> $DIR/move_closure.rs:104:5
    |
 LL | /     move || {
 LL | |
@@ -296,13 +307,13 @@ LL | |     };
    | |_____^
    |
 note: Min Capture t[(0, 0)] -> ByValue
-  --> $DIR/move_closure.rs:102:18
+  --> $DIR/move_closure.rs:107:18
    |
 LL |         let _t = t.0.0;
    |                  ^^^^^
 
 error: First Pass analysis includes:
-  --> $DIR/move_closure.rs:120:5
+  --> $DIR/move_closure.rs:126:5
    |
 LL | /     move || {
 LL | |
@@ -314,13 +325,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing b[Deref,(0, 0)] -> ImmBorrow
-  --> $DIR/move_closure.rs:123:18
+  --> $DIR/move_closure.rs:129:18
    |
 LL |         let _t = b.0;
    |                  ^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/move_closure.rs:120:5
+  --> $DIR/move_closure.rs:126:5
    |
 LL | /     move || {
 LL | |
@@ -332,13 +343,13 @@ LL | |     };
    | |_____^
    |
 note: Min Capture b[] -> ByValue
-  --> $DIR/move_closure.rs:123:18
+  --> $DIR/move_closure.rs:129:18
    |
 LL |         let _t = b.0;
    |                  ^^^
 
 error: First Pass analysis includes:
-  --> $DIR/move_closure.rs:136:5
+  --> $DIR/move_closure.rs:143:5
    |
 LL | /     move || {
 LL | |
@@ -350,13 +361,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing b[Deref,(0, 0)] -> ImmBorrow
-  --> $DIR/move_closure.rs:139:24
+  --> $DIR/move_closure.rs:146:24
    |
 LL |         println!("{}", b.0);
    |                        ^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/move_closure.rs:136:5
+  --> $DIR/move_closure.rs:143:5
    |
 LL | /     move || {
 LL | |
@@ -368,13 +379,13 @@ LL | |     };
    | |_____^
    |
 note: Min Capture b[] -> ByValue
-  --> $DIR/move_closure.rs:139:24
+  --> $DIR/move_closure.rs:146:24
    |
 LL |         println!("{}", b.0);
    |                        ^^^
 
 error: First Pass analysis includes:
-  --> $DIR/move_closure.rs:153:5
+  --> $DIR/move_closure.rs:161:5
    |
 LL | /     move || {
 LL | |
@@ -386,13 +397,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing t[(1, 0),Deref,(0, 0)] -> ImmBorrow
-  --> $DIR/move_closure.rs:156:24
+  --> $DIR/move_closure.rs:164:24
    |
 LL |         println!("{}", t.1.0);
    |                        ^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/move_closure.rs:153:5
+  --> $DIR/move_closure.rs:161:5
    |
 LL | /     move || {
 LL | |
@@ -404,55 +415,55 @@ LL | |     };
    | |_____^
    |
 note: Min Capture t[(1, 0)] -> ByValue
-  --> $DIR/move_closure.rs:156:24
+  --> $DIR/move_closure.rs:164:24
    |
 LL |         println!("{}", t.1.0);
    |                        ^^^^^
 
 error: First Pass analysis includes:
-  --> $DIR/move_closure.rs:172:39
+  --> $DIR/move_closure.rs:180:39
    |
 LL |     let c = #[rustc_capture_analysis] move || box_p_foo.x += 10;
    |                                       ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
 note: Capturing box_p_foo[Deref,Deref,(0, 0)] -> MutBorrow
-  --> $DIR/move_closure.rs:172:47
+  --> $DIR/move_closure.rs:180:47
    |
 LL |     let c = #[rustc_capture_analysis] move || box_p_foo.x += 10;
    |                                               ^^^^^^^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/move_closure.rs:172:39
+  --> $DIR/move_closure.rs:180:39
    |
 LL |     let c = #[rustc_capture_analysis] move || box_p_foo.x += 10;
    |                                       ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
 note: Min Capture box_p_foo[] -> ByValue
-  --> $DIR/move_closure.rs:172:47
+  --> $DIR/move_closure.rs:180:47
    |
 LL |     let c = #[rustc_capture_analysis] move || box_p_foo.x += 10;
    |                                               ^^^^^^^^^^^
 
 error: First Pass analysis includes:
-  --> $DIR/move_closure.rs:189:39
+  --> $DIR/move_closure.rs:198:39
    |
 LL |     let c = #[rustc_capture_analysis] move || p_foo.x += 10;
    |                                       ^^^^^^^^^^^^^^^^^^^^^
    |
 note: Capturing p_foo[Deref,Deref,(0, 0)] -> MutBorrow
-  --> $DIR/move_closure.rs:189:47
+  --> $DIR/move_closure.rs:198:47
    |
 LL |     let c = #[rustc_capture_analysis] move || p_foo.x += 10;
    |                                               ^^^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/move_closure.rs:189:39
+  --> $DIR/move_closure.rs:198:39
    |
 LL |     let c = #[rustc_capture_analysis] move || p_foo.x += 10;
    |                                       ^^^^^^^^^^^^^^^^^^^^^
    |
 note: Min Capture p_foo[] -> ByValue
-  --> $DIR/move_closure.rs:189:47
+  --> $DIR/move_closure.rs:198:47
    |
 LL |     let c = #[rustc_capture_analysis] move || p_foo.x += 10;
    |                                               ^^^^^^^
diff --git a/tests/ui/closures/2229_closure_analysis/multilevel-path-1.rs b/tests/ui/closures/2229_closure_analysis/multilevel-path-1.rs
index a8a2acfa78d..8a6ecfbb9be 100644
--- a/tests/ui/closures/2229_closure_analysis/multilevel-path-1.rs
+++ b/tests/ui/closures/2229_closure_analysis/multilevel-path-1.rs
@@ -22,6 +22,7 @@ fn main() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/multilevel-path-1.stderr b/tests/ui/closures/2229_closure_analysis/multilevel-path-1.stderr
index 29ad1c59198..118a7dacec6 100644
--- a/tests/ui/closures/2229_closure_analysis/multilevel-path-1.stderr
+++ b/tests/ui/closures/2229_closure_analysis/multilevel-path-1.stderr
@@ -6,9 +6,10 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/multilevel-path-1.rs:25:5
+  --> $DIR/multilevel-path-1.rs:26:5
    |
 LL | /     || {
 LL | |
@@ -20,13 +21,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing w[(0, 0)] -> ImmBorrow
-  --> $DIR/multilevel-path-1.rs:28:19
+  --> $DIR/multilevel-path-1.rs:29:19
    |
 LL |         let wp = &w.p;
    |                   ^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/multilevel-path-1.rs:25:5
+  --> $DIR/multilevel-path-1.rs:26:5
    |
 LL | /     || {
 LL | |
@@ -38,7 +39,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture w[(0, 0)] -> ImmBorrow
-  --> $DIR/multilevel-path-1.rs:28:19
+  --> $DIR/multilevel-path-1.rs:29:19
    |
 LL |         let wp = &w.p;
    |                   ^^^
diff --git a/tests/ui/closures/2229_closure_analysis/multilevel-path-2.rs b/tests/ui/closures/2229_closure_analysis/multilevel-path-2.rs
index e21fe318cd1..fff80f9c855 100644
--- a/tests/ui/closures/2229_closure_analysis/multilevel-path-2.rs
+++ b/tests/ui/closures/2229_closure_analysis/multilevel-path-2.rs
@@ -17,6 +17,7 @@ fn main() {
     let c = #[rustc_capture_analysis]
         //~^ ERROR: attributes on expressions are experimental
         //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+        //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/multilevel-path-2.stderr b/tests/ui/closures/2229_closure_analysis/multilevel-path-2.stderr
index 929cba11314..a7112531d9a 100644
--- a/tests/ui/closures/2229_closure_analysis/multilevel-path-2.stderr
+++ b/tests/ui/closures/2229_closure_analysis/multilevel-path-2.stderr
@@ -6,9 +6,10 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/multilevel-path-2.rs:20:5
+  --> $DIR/multilevel-path-2.rs:21:5
    |
 LL | /     || {
 LL | |
@@ -20,13 +21,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing w[(0, 0),(0, 0)] -> ImmBorrow
-  --> $DIR/multilevel-path-2.rs:23:24
+  --> $DIR/multilevel-path-2.rs:24:24
    |
 LL |         println!("{}", w.p.x);
    |                        ^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/multilevel-path-2.rs:20:5
+  --> $DIR/multilevel-path-2.rs:21:5
    |
 LL | /     || {
 LL | |
@@ -38,7 +39,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture w[(0, 0),(0, 0)] -> ImmBorrow
-  --> $DIR/multilevel-path-2.rs:23:24
+  --> $DIR/multilevel-path-2.rs:24:24
    |
 LL |         println!("{}", w.p.x);
    |                        ^^^^^
diff --git a/tests/ui/closures/2229_closure_analysis/nested-closure.rs b/tests/ui/closures/2229_closure_analysis/nested-closure.rs
index 22eae744b80..a7e3ef3b39c 100644
--- a/tests/ui/closures/2229_closure_analysis/nested-closure.rs
+++ b/tests/ui/closures/2229_closure_analysis/nested-closure.rs
@@ -19,6 +19,7 @@ fn main() {
     let mut c1 = #[rustc_capture_analysis]
         //~^ ERROR: attributes on expressions are experimental
         //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+        //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
@@ -29,6 +30,7 @@ fn main() {
         let mut c2 = #[rustc_capture_analysis]
         //~^ ERROR: attributes on expressions are experimental
         //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+        //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
         || p.y += incr;
         //~^ ERROR: First Pass analysis includes:
         //~| ERROR: Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/nested-closure.stderr b/tests/ui/closures/2229_closure_analysis/nested-closure.stderr
index a50d0c6a182..256bfd58597 100644
--- a/tests/ui/closures/2229_closure_analysis/nested-closure.stderr
+++ b/tests/ui/closures/2229_closure_analysis/nested-closure.stderr
@@ -6,52 +6,54 @@ LL |     let mut c1 = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/nested-closure.rs:29:22
+  --> $DIR/nested-closure.rs:30:22
    |
 LL |         let mut c2 = #[rustc_capture_analysis]
    |                      ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/nested-closure.rs:32:9
+  --> $DIR/nested-closure.rs:34:9
    |
 LL |         || p.y += incr;
    |         ^^^^^^^^^^^^^^
    |
 note: Capturing p[(1, 0)] -> MutBorrow
-  --> $DIR/nested-closure.rs:32:12
+  --> $DIR/nested-closure.rs:34:12
    |
 LL |         || p.y += incr;
    |            ^^^
 note: Capturing incr[] -> ImmBorrow
-  --> $DIR/nested-closure.rs:32:19
+  --> $DIR/nested-closure.rs:34:19
    |
 LL |         || p.y += incr;
    |                   ^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/nested-closure.rs:32:9
+  --> $DIR/nested-closure.rs:34:9
    |
 LL |         || p.y += incr;
    |         ^^^^^^^^^^^^^^
    |
 note: Min Capture p[(1, 0)] -> MutBorrow
-  --> $DIR/nested-closure.rs:32:12
+  --> $DIR/nested-closure.rs:34:12
    |
 LL |         || p.y += incr;
    |            ^^^
 note: Min Capture incr[] -> ImmBorrow
-  --> $DIR/nested-closure.rs:32:19
+  --> $DIR/nested-closure.rs:34:19
    |
 LL |         || p.y += incr;
    |                   ^^^^
 
 error: First Pass analysis includes:
-  --> $DIR/nested-closure.rs:22:5
+  --> $DIR/nested-closure.rs:23:5
    |
 LL | /     || {
 LL | |
@@ -63,23 +65,23 @@ LL | |     };
    | |_____^
    |
 note: Capturing p[(0, 0)] -> ImmBorrow
-  --> $DIR/nested-closure.rs:25:24
+  --> $DIR/nested-closure.rs:26:24
    |
 LL |         println!("{}", p.x);
    |                        ^^^
 note: Capturing p[(1, 0)] -> MutBorrow
-  --> $DIR/nested-closure.rs:32:12
+  --> $DIR/nested-closure.rs:34:12
    |
 LL |         || p.y += incr;
    |            ^^^
 note: Capturing p[(1, 0)] -> ImmBorrow
-  --> $DIR/nested-closure.rs:42:24
+  --> $DIR/nested-closure.rs:44:24
    |
 LL |         println!("{}", p.y);
    |                        ^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/nested-closure.rs:22:5
+  --> $DIR/nested-closure.rs:23:5
    |
 LL | /     || {
 LL | |
@@ -91,12 +93,12 @@ LL | |     };
    | |_____^
    |
 note: Min Capture p[(0, 0)] -> ImmBorrow
-  --> $DIR/nested-closure.rs:25:24
+  --> $DIR/nested-closure.rs:26:24
    |
 LL |         println!("{}", p.x);
    |                        ^^^
 note: Min Capture p[(1, 0)] -> MutBorrow
-  --> $DIR/nested-closure.rs:32:12
+  --> $DIR/nested-closure.rs:34:12
    |
 LL |         || p.y += incr;
    |            ^^^
diff --git a/tests/ui/closures/2229_closure_analysis/optimization/edge_case.rs b/tests/ui/closures/2229_closure_analysis/optimization/edge_case.rs
index e7edc0bbce3..a7686f3b08f 100644
--- a/tests/ui/closures/2229_closure_analysis/optimization/edge_case.rs
+++ b/tests/ui/closures/2229_closure_analysis/optimization/edge_case.rs
@@ -20,6 +20,7 @@ fn foo<'a, 'b>(m: &'a MyStruct<'b>) -> impl FnMut() + 'static {
     let c = #[rustc_capture_analysis] || drop(&m.a.0);
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     //~| ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
     //~| NOTE: Capturing m[Deref,(0, 0),Deref,(0, 0)] -> ImmBorrow
diff --git a/tests/ui/closures/2229_closure_analysis/optimization/edge_case.stderr b/tests/ui/closures/2229_closure_analysis/optimization/edge_case.stderr
index 87d5d5bee07..99159ab58a2 100644
--- a/tests/ui/closures/2229_closure_analysis/optimization/edge_case.stderr
+++ b/tests/ui/closures/2229_closure_analysis/optimization/edge_case.stderr
@@ -6,6 +6,7 @@ LL |     let c = #[rustc_capture_analysis] || drop(&m.a.0);
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
   --> $DIR/edge_case.rs:20:39
diff --git a/tests/ui/closures/2229_closure_analysis/path-with-array-access.rs b/tests/ui/closures/2229_closure_analysis/path-with-array-access.rs
index 0c10319314a..b8e2d6651a7 100644
--- a/tests/ui/closures/2229_closure_analysis/path-with-array-access.rs
+++ b/tests/ui/closures/2229_closure_analysis/path-with-array-access.rs
@@ -23,6 +23,7 @@ fn main() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/path-with-array-access.stderr b/tests/ui/closures/2229_closure_analysis/path-with-array-access.stderr
index 124b7bf6fe2..22bd13617c1 100644
--- a/tests/ui/closures/2229_closure_analysis/path-with-array-access.stderr
+++ b/tests/ui/closures/2229_closure_analysis/path-with-array-access.stderr
@@ -6,9 +6,10 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/path-with-array-access.rs:26:5
+  --> $DIR/path-with-array-access.rs:27:5
    |
 LL | /     || {
 LL | |
@@ -20,13 +21,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing pent[(0, 0)] -> ImmBorrow
-  --> $DIR/path-with-array-access.rs:29:24
+  --> $DIR/path-with-array-access.rs:30:24
    |
 LL |         println!("{}", pent.points[5].x);
    |                        ^^^^^^^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/path-with-array-access.rs:26:5
+  --> $DIR/path-with-array-access.rs:27:5
    |
 LL | /     || {
 LL | |
@@ -38,7 +39,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture pent[(0, 0)] -> ImmBorrow
-  --> $DIR/path-with-array-access.rs:29:24
+  --> $DIR/path-with-array-access.rs:30:24
    |
 LL |         println!("{}", pent.points[5].x);
    |                        ^^^^^^^^^^^
diff --git a/tests/ui/closures/2229_closure_analysis/preserve_field_drop_order.rs b/tests/ui/closures/2229_closure_analysis/preserve_field_drop_order.rs
index 2f8cddc06ba..26c227a1edd 100644
--- a/tests/ui/closures/2229_closure_analysis/preserve_field_drop_order.rs
+++ b/tests/ui/closures/2229_closure_analysis/preserve_field_drop_order.rs
@@ -23,6 +23,7 @@ fn test_one() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
         //~^ ERROR: Min Capture analysis includes:
         //~| ERROR
@@ -49,6 +50,7 @@ fn test_two() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
         //~^ ERROR: Min Capture analysis includes:
         //~| ERROR
@@ -75,6 +77,7 @@ fn test_three() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
         //~^ ERROR: Min Capture analysis includes:
         //~| ERROR
diff --git a/tests/ui/closures/2229_closure_analysis/preserve_field_drop_order.stderr b/tests/ui/closures/2229_closure_analysis/preserve_field_drop_order.stderr
index 2d1dc8727c2..82f770eafed 100644
--- a/tests/ui/closures/2229_closure_analysis/preserve_field_drop_order.stderr
+++ b/tests/ui/closures/2229_closure_analysis/preserve_field_drop_order.stderr
@@ -6,27 +6,30 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/preserve_field_drop_order.rs:49:13
+  --> $DIR/preserve_field_drop_order.rs:50:13
    |
 LL |     let c = #[rustc_capture_analysis]
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/preserve_field_drop_order.rs:75:13
+  --> $DIR/preserve_field_drop_order.rs:77:13
    |
 LL |     let c = #[rustc_capture_analysis]
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/preserve_field_drop_order.rs:26:5
+  --> $DIR/preserve_field_drop_order.rs:27:5
    |
 LL | /     || {
 LL | |
@@ -38,28 +41,28 @@ LL | |     };
    | |_____^
    |
 note: Capturing a[(0, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:29:26
+  --> $DIR/preserve_field_drop_order.rs:30:26
    |
 LL |         println!("{:?}", a.0);
    |                          ^^^
 note: Capturing a[(1, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:32:26
+  --> $DIR/preserve_field_drop_order.rs:33:26
    |
 LL |         println!("{:?}", a.1);
    |                          ^^^
 note: Capturing b[(0, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:36:26
+  --> $DIR/preserve_field_drop_order.rs:37:26
    |
 LL |         println!("{:?}", b.0);
    |                          ^^^
 note: Capturing b[(1, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:39:26
+  --> $DIR/preserve_field_drop_order.rs:40:26
    |
 LL |         println!("{:?}", b.1);
    |                          ^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/preserve_field_drop_order.rs:26:5
+  --> $DIR/preserve_field_drop_order.rs:27:5
    |
 LL | /     || {
 LL | |
@@ -71,28 +74,28 @@ LL | |     };
    | |_____^
    |
 note: Min Capture a[(0, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:29:26
+  --> $DIR/preserve_field_drop_order.rs:30:26
    |
 LL |         println!("{:?}", a.0);
    |                          ^^^
 note: Min Capture a[(1, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:32:26
+  --> $DIR/preserve_field_drop_order.rs:33:26
    |
 LL |         println!("{:?}", a.1);
    |                          ^^^
 note: Min Capture b[(0, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:36:26
+  --> $DIR/preserve_field_drop_order.rs:37:26
    |
 LL |         println!("{:?}", b.0);
    |                          ^^^
 note: Min Capture b[(1, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:39:26
+  --> $DIR/preserve_field_drop_order.rs:40:26
    |
 LL |         println!("{:?}", b.1);
    |                          ^^^
 
 error: First Pass analysis includes:
-  --> $DIR/preserve_field_drop_order.rs:52:5
+  --> $DIR/preserve_field_drop_order.rs:54:5
    |
 LL | /     || {
 LL | |
@@ -104,28 +107,28 @@ LL | |     };
    | |_____^
    |
 note: Capturing a[(1, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:55:26
+  --> $DIR/preserve_field_drop_order.rs:57:26
    |
 LL |         println!("{:?}", a.1);
    |                          ^^^
 note: Capturing a[(0, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:58:26
+  --> $DIR/preserve_field_drop_order.rs:60:26
    |
 LL |         println!("{:?}", a.0);
    |                          ^^^
 note: Capturing b[(1, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:62:26
+  --> $DIR/preserve_field_drop_order.rs:64:26
    |
 LL |         println!("{:?}", b.1);
    |                          ^^^
 note: Capturing b[(0, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:65:26
+  --> $DIR/preserve_field_drop_order.rs:67:26
    |
 LL |         println!("{:?}", b.0);
    |                          ^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/preserve_field_drop_order.rs:52:5
+  --> $DIR/preserve_field_drop_order.rs:54:5
    |
 LL | /     || {
 LL | |
@@ -137,28 +140,28 @@ LL | |     };
    | |_____^
    |
 note: Min Capture a[(0, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:58:26
+  --> $DIR/preserve_field_drop_order.rs:60:26
    |
 LL |         println!("{:?}", a.0);
    |                          ^^^
 note: Min Capture a[(1, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:55:26
+  --> $DIR/preserve_field_drop_order.rs:57:26
    |
 LL |         println!("{:?}", a.1);
    |                          ^^^
 note: Min Capture b[(0, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:65:26
+  --> $DIR/preserve_field_drop_order.rs:67:26
    |
 LL |         println!("{:?}", b.0);
    |                          ^^^
 note: Min Capture b[(1, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:62:26
+  --> $DIR/preserve_field_drop_order.rs:64:26
    |
 LL |         println!("{:?}", b.1);
    |                          ^^^
 
 error: First Pass analysis includes:
-  --> $DIR/preserve_field_drop_order.rs:78:5
+  --> $DIR/preserve_field_drop_order.rs:81:5
    |
 LL | /     || {
 LL | |
@@ -170,28 +173,28 @@ LL | |     };
    | |_____^
    |
 note: Capturing b[(1, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:81:26
+  --> $DIR/preserve_field_drop_order.rs:84:26
    |
 LL |         println!("{:?}", b.1);
    |                          ^^^
 note: Capturing a[(1, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:84:26
+  --> $DIR/preserve_field_drop_order.rs:87:26
    |
 LL |         println!("{:?}", a.1);
    |                          ^^^
 note: Capturing a[(0, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:87:26
+  --> $DIR/preserve_field_drop_order.rs:90:26
    |
 LL |         println!("{:?}", a.0);
    |                          ^^^
 note: Capturing b[(0, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:91:26
+  --> $DIR/preserve_field_drop_order.rs:94:26
    |
 LL |         println!("{:?}", b.0);
    |                          ^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/preserve_field_drop_order.rs:78:5
+  --> $DIR/preserve_field_drop_order.rs:81:5
    |
 LL | /     || {
 LL | |
@@ -203,22 +206,22 @@ LL | |     };
    | |_____^
    |
 note: Min Capture b[(0, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:91:26
+  --> $DIR/preserve_field_drop_order.rs:94:26
    |
 LL |         println!("{:?}", b.0);
    |                          ^^^
 note: Min Capture b[(1, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:81:26
+  --> $DIR/preserve_field_drop_order.rs:84:26
    |
 LL |         println!("{:?}", b.1);
    |                          ^^^
 note: Min Capture a[(0, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:87:26
+  --> $DIR/preserve_field_drop_order.rs:90:26
    |
 LL |         println!("{:?}", a.0);
    |                          ^^^
 note: Min Capture a[(1, 0)] -> ImmBorrow
-  --> $DIR/preserve_field_drop_order.rs:84:26
+  --> $DIR/preserve_field_drop_order.rs:87:26
    |
 LL |         println!("{:?}", a.1);
    |                          ^^^
diff --git a/tests/ui/closures/2229_closure_analysis/repr_packed.rs b/tests/ui/closures/2229_closure_analysis/repr_packed.rs
index 8c23454fae9..3ed8587783e 100644
--- a/tests/ui/closures/2229_closure_analysis/repr_packed.rs
+++ b/tests/ui/closures/2229_closure_analysis/repr_packed.rs
@@ -14,6 +14,7 @@ fn test_alignment_not_affected() {
     let mut c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
@@ -44,6 +45,7 @@ fn test_alignment_affected() {
     let mut c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
@@ -79,6 +81,7 @@ fn test_truncation_when_ref_and_move() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/repr_packed.stderr b/tests/ui/closures/2229_closure_analysis/repr_packed.stderr
index 32b3d844c6e..3bac41d60d5 100644
--- a/tests/ui/closures/2229_closure_analysis/repr_packed.stderr
+++ b/tests/ui/closures/2229_closure_analysis/repr_packed.stderr
@@ -6,27 +6,30 @@ LL |     let mut c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/repr_packed.rs:44:17
+  --> $DIR/repr_packed.rs:45:17
    |
 LL |     let mut c = #[rustc_capture_analysis]
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/repr_packed.rs:79:13
+  --> $DIR/repr_packed.rs:81:13
    |
 LL |     let c = #[rustc_capture_analysis]
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/repr_packed.rs:17:5
+  --> $DIR/repr_packed.rs:18:5
    |
 LL | /     || {
 LL | |
@@ -38,18 +41,18 @@ LL | |     };
    | |_____^
    |
 note: Capturing foo[] -> ImmBorrow
-  --> $DIR/repr_packed.rs:20:24
+  --> $DIR/repr_packed.rs:21:24
    |
 LL |         let z1: &u8 = &foo.x;
    |                        ^^^^^
 note: Capturing foo[] -> MutBorrow
-  --> $DIR/repr_packed.rs:22:32
+  --> $DIR/repr_packed.rs:23:32
    |
 LL |         let z2: &mut u8 = &mut foo.y;
    |                                ^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/repr_packed.rs:17:5
+  --> $DIR/repr_packed.rs:18:5
    |
 LL | /     || {
 LL | |
@@ -61,13 +64,13 @@ LL | |     };
    | |_____^
    |
 note: Min Capture foo[] -> MutBorrow
-  --> $DIR/repr_packed.rs:22:32
+  --> $DIR/repr_packed.rs:23:32
    |
 LL |         let z2: &mut u8 = &mut foo.y;
    |                                ^^^^^
 
 error: First Pass analysis includes:
-  --> $DIR/repr_packed.rs:47:5
+  --> $DIR/repr_packed.rs:49:5
    |
 LL | /     || {
 LL | |
@@ -79,18 +82,18 @@ LL | |     };
    | |_____^
    |
 note: Capturing foo[] -> ImmBorrow
-  --> $DIR/repr_packed.rs:50:28
+  --> $DIR/repr_packed.rs:52:28
    |
 LL |         let z1: &String = &foo.x;
    |                            ^^^^^
 note: Capturing foo[] -> MutBorrow
-  --> $DIR/repr_packed.rs:52:33
+  --> $DIR/repr_packed.rs:54:33
    |
 LL |         let z2: &mut u16 = &mut foo.y;
    |                                 ^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/repr_packed.rs:47:5
+  --> $DIR/repr_packed.rs:49:5
    |
 LL | /     || {
 LL | |
@@ -102,13 +105,13 @@ LL | |     };
    | |_____^
    |
 note: Min Capture foo[] -> MutBorrow
-  --> $DIR/repr_packed.rs:52:33
+  --> $DIR/repr_packed.rs:54:33
    |
 LL |         let z2: &mut u16 = &mut foo.y;
    |                                 ^^^^^
 
 error: First Pass analysis includes:
-  --> $DIR/repr_packed.rs:82:5
+  --> $DIR/repr_packed.rs:85:5
    |
 LL | /     || {
 LL | |
@@ -120,18 +123,18 @@ LL | |     };
    | |_____^
    |
 note: Capturing foo[] -> ImmBorrow
-  --> $DIR/repr_packed.rs:85:24
+  --> $DIR/repr_packed.rs:88:24
    |
 LL |         println!("{}", foo.x);
    |                        ^^^^^
 note: Capturing foo[(0, 0)] -> ByValue
-  --> $DIR/repr_packed.rs:89:18
+  --> $DIR/repr_packed.rs:92:18
    |
 LL |         let _z = foo.x;
    |                  ^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/repr_packed.rs:82:5
+  --> $DIR/repr_packed.rs:85:5
    |
 LL | /     || {
 LL | |
@@ -143,7 +146,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture foo[] -> ByValue
-  --> $DIR/repr_packed.rs:85:24
+  --> $DIR/repr_packed.rs:88:24
    |
 LL |         println!("{}", foo.x);
    |                        ^^^^^ foo[] used here
diff --git a/tests/ui/closures/2229_closure_analysis/simple-struct-min-capture.rs b/tests/ui/closures/2229_closure_analysis/simple-struct-min-capture.rs
index 563095d440d..03b70383e54 100644
--- a/tests/ui/closures/2229_closure_analysis/simple-struct-min-capture.rs
+++ b/tests/ui/closures/2229_closure_analysis/simple-struct-min-capture.rs
@@ -23,6 +23,7 @@ fn main() {
     let mut c = #[rustc_capture_analysis]
         //~^ ERROR: attributes on expressions are experimental
         //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+        //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/simple-struct-min-capture.stderr b/tests/ui/closures/2229_closure_analysis/simple-struct-min-capture.stderr
index 05d79797ab3..247dcbe94bc 100644
--- a/tests/ui/closures/2229_closure_analysis/simple-struct-min-capture.stderr
+++ b/tests/ui/closures/2229_closure_analysis/simple-struct-min-capture.stderr
@@ -6,9 +6,10 @@ LL |     let mut c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/simple-struct-min-capture.rs:26:5
+  --> $DIR/simple-struct-min-capture.rs:27:5
    |
 LL | /     || {
 LL | |
@@ -20,18 +21,18 @@ LL | |     };
    | |_____^
    |
 note: Capturing p[(0, 0)] -> MutBorrow
-  --> $DIR/simple-struct-min-capture.rs:29:9
+  --> $DIR/simple-struct-min-capture.rs:30:9
    |
 LL |         p.x += 10;
    |         ^^^
 note: Capturing p[] -> ImmBorrow
-  --> $DIR/simple-struct-min-capture.rs:32:26
+  --> $DIR/simple-struct-min-capture.rs:33:26
    |
 LL |         println!("{:?}", p);
    |                          ^
 
 error: Min Capture analysis includes:
-  --> $DIR/simple-struct-min-capture.rs:26:5
+  --> $DIR/simple-struct-min-capture.rs:27:5
    |
 LL | /     || {
 LL | |
@@ -43,7 +44,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture p[] -> MutBorrow
-  --> $DIR/simple-struct-min-capture.rs:29:9
+  --> $DIR/simple-struct-min-capture.rs:30:9
    |
 LL |         p.x += 10;
    |         ^^^ p[] captured as MutBorrow here
diff --git a/tests/ui/closures/2229_closure_analysis/unsafe_ptr.rs b/tests/ui/closures/2229_closure_analysis/unsafe_ptr.rs
index eab9f9d08a9..1f87c9b9992 100644
--- a/tests/ui/closures/2229_closure_analysis/unsafe_ptr.rs
+++ b/tests/ui/closures/2229_closure_analysis/unsafe_ptr.rs
@@ -25,6 +25,7 @@ fn unsafe_imm() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
      || unsafe {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
@@ -45,6 +46,7 @@ fn unsafe_mut() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/unsafe_ptr.stderr b/tests/ui/closures/2229_closure_analysis/unsafe_ptr.stderr
index e740a4d2d6b..4f3de075054 100644
--- a/tests/ui/closures/2229_closure_analysis/unsafe_ptr.stderr
+++ b/tests/ui/closures/2229_closure_analysis/unsafe_ptr.stderr
@@ -6,18 +6,20 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/unsafe_ptr.rs:45:13
+  --> $DIR/unsafe_ptr.rs:46:13
    |
 LL |     let c = #[rustc_capture_analysis]
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/unsafe_ptr.rs:28:6
+  --> $DIR/unsafe_ptr.rs:29:6
    |
 LL | /      || unsafe {
 LL | |
@@ -29,13 +31,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing t[(0, 0),Deref,(0, 0)] -> ImmBorrow
-  --> $DIR/unsafe_ptr.rs:31:26
+  --> $DIR/unsafe_ptr.rs:32:26
    |
 LL |         println!("{:?}", (*t.0).s);
    |                          ^^^^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/unsafe_ptr.rs:28:6
+  --> $DIR/unsafe_ptr.rs:29:6
    |
 LL | /      || unsafe {
 LL | |
@@ -47,13 +49,13 @@ LL | |     };
    | |_____^
    |
 note: Min Capture t[(0, 0)] -> ImmBorrow
-  --> $DIR/unsafe_ptr.rs:31:26
+  --> $DIR/unsafe_ptr.rs:32:26
    |
 LL |         println!("{:?}", (*t.0).s);
    |                          ^^^^^^^^
 
 error: First Pass analysis includes:
-  --> $DIR/unsafe_ptr.rs:48:5
+  --> $DIR/unsafe_ptr.rs:50:5
    |
 LL | /     || {
 LL | |
@@ -65,13 +67,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing p[Deref,(0, 0)] -> ImmBorrow
-  --> $DIR/unsafe_ptr.rs:51:31
+  --> $DIR/unsafe_ptr.rs:53:31
    |
 LL |         let x = unsafe { &mut (*p).s };
    |                               ^^^^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/unsafe_ptr.rs:48:5
+  --> $DIR/unsafe_ptr.rs:50:5
    |
 LL | /     || {
 LL | |
@@ -83,7 +85,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture p[] -> ImmBorrow
-  --> $DIR/unsafe_ptr.rs:51:31
+  --> $DIR/unsafe_ptr.rs:53:31
    |
 LL |         let x = unsafe { &mut (*p).s };
    |                               ^^^^^^
diff --git a/tests/ui/closures/2229_closure_analysis/wild_patterns.rs b/tests/ui/closures/2229_closure_analysis/wild_patterns.rs
index a795088a1d9..12695929fce 100644
--- a/tests/ui/closures/2229_closure_analysis/wild_patterns.rs
+++ b/tests/ui/closures/2229_closure_analysis/wild_patterns.rs
@@ -22,6 +22,7 @@ fn wild_struct() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
@@ -40,6 +41,7 @@ fn wild_tuple() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
@@ -58,6 +60,7 @@ fn wild_arr() {
     let c = #[rustc_capture_analysis]
     //~^ ERROR: attributes on expressions are experimental
     //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     || {
     //~^ ERROR: First Pass analysis includes:
     //~| ERROR: Min Capture analysis includes:
diff --git a/tests/ui/closures/2229_closure_analysis/wild_patterns.stderr b/tests/ui/closures/2229_closure_analysis/wild_patterns.stderr
index c64378091e6..88b48aaaf8c 100644
--- a/tests/ui/closures/2229_closure_analysis/wild_patterns.stderr
+++ b/tests/ui/closures/2229_closure_analysis/wild_patterns.stderr
@@ -6,27 +6,30 @@ LL |     let c = #[rustc_capture_analysis]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/wild_patterns.rs:40:13
+  --> $DIR/wild_patterns.rs:41:13
    |
 LL |     let c = #[rustc_capture_analysis]
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
-  --> $DIR/wild_patterns.rs:58:13
+  --> $DIR/wild_patterns.rs:60:13
    |
 LL |     let c = #[rustc_capture_analysis]
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: First Pass analysis includes:
-  --> $DIR/wild_patterns.rs:25:5
+  --> $DIR/wild_patterns.rs:26:5
    |
 LL | /     || {
 LL | |
@@ -38,13 +41,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing p[(0, 0)] -> ImmBorrow
-  --> $DIR/wild_patterns.rs:29:37
+  --> $DIR/wild_patterns.rs:30:37
    |
 LL |         let Point { x: _x, y: _ } = p;
    |                                     ^
 
 error: Min Capture analysis includes:
-  --> $DIR/wild_patterns.rs:25:5
+  --> $DIR/wild_patterns.rs:26:5
    |
 LL | /     || {
 LL | |
@@ -56,13 +59,13 @@ LL | |     };
    | |_____^
    |
 note: Min Capture p[(0, 0)] -> ImmBorrow
-  --> $DIR/wild_patterns.rs:29:37
+  --> $DIR/wild_patterns.rs:30:37
    |
 LL |         let Point { x: _x, y: _ } = p;
    |                                     ^
 
 error: First Pass analysis includes:
-  --> $DIR/wild_patterns.rs:43:5
+  --> $DIR/wild_patterns.rs:45:5
    |
 LL | /     || {
 LL | |
@@ -74,13 +77,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing t[(0, 0)] -> ByValue
-  --> $DIR/wild_patterns.rs:47:23
+  --> $DIR/wild_patterns.rs:49:23
    |
 LL |         let (_x, _) = t;
    |                       ^
 
 error: Min Capture analysis includes:
-  --> $DIR/wild_patterns.rs:43:5
+  --> $DIR/wild_patterns.rs:45:5
    |
 LL | /     || {
 LL | |
@@ -92,13 +95,13 @@ LL | |     };
    | |_____^
    |
 note: Min Capture t[(0, 0)] -> ByValue
-  --> $DIR/wild_patterns.rs:47:23
+  --> $DIR/wild_patterns.rs:49:23
    |
 LL |         let (_x, _) = t;
    |                       ^
 
 error: First Pass analysis includes:
-  --> $DIR/wild_patterns.rs:61:5
+  --> $DIR/wild_patterns.rs:64:5
    |
 LL | /     || {
 LL | |
@@ -110,13 +113,13 @@ LL | |     };
    | |_____^
    |
 note: Capturing arr[Index] -> ByValue
-  --> $DIR/wild_patterns.rs:65:23
+  --> $DIR/wild_patterns.rs:68:23
    |
 LL |         let [_x, _] = arr;
    |                       ^^^
 
 error: Min Capture analysis includes:
-  --> $DIR/wild_patterns.rs:61:5
+  --> $DIR/wild_patterns.rs:64:5
    |
 LL | /     || {
 LL | |
@@ -128,7 +131,7 @@ LL | |     };
    | |_____^
    |
 note: Min Capture arr[] -> ByValue
-  --> $DIR/wild_patterns.rs:65:23
+  --> $DIR/wild_patterns.rs:68:23
    |
 LL |         let [_x, _] = arr;
    |                       ^^^
diff --git a/tests/ui/closures/binder/disallow-const.stderr b/tests/ui/closures/binder/disallow-const.stderr
index d38b233d99a..fa56ec86312 100644
--- a/tests/ui/closures/binder/disallow-const.stderr
+++ b/tests/ui/closures/binder/disallow-const.stderr
@@ -6,6 +6,7 @@ LL |     for<const N: i32> || -> () {};
    |
    = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
    = help: add `#![feature(non_lifetime_binders)]` 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 1 previous error
 
diff --git a/tests/ui/closures/binder/disallow-ty.stderr b/tests/ui/closures/binder/disallow-ty.stderr
index bc6696ad36b..f8a33e08f75 100644
--- a/tests/ui/closures/binder/disallow-ty.stderr
+++ b/tests/ui/closures/binder/disallow-ty.stderr
@@ -6,6 +6,7 @@ LL |     for<T> || -> () {};
    |
    = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
    = help: add `#![feature(non_lifetime_binders)]` 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 1 previous error
 
diff --git a/tests/ui/cmse-nonsecure/cmse-nonsecure-call/gate_test.stderr b/tests/ui/cmse-nonsecure/cmse-nonsecure-call/gate_test.stderr
index 0a5884d38f7..64e9b7cc639 100644
--- a/tests/ui/cmse-nonsecure/cmse-nonsecure-call/gate_test.stderr
+++ b/tests/ui/cmse-nonsecure/cmse-nonsecure-call/gate_test.stderr
@@ -6,6 +6,7 @@ LL |         core::mem::transmute::<usize, extern "C-cmse-nonsecure-call" fn(i32
    |
    = note: see issue #81391 <https://github.com/rust-lang/rust/issues/81391> for more information
    = help: add `#![feature(abi_c_cmse_nonsecure_call)]` 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 1 previous error
 
diff --git a/tests/ui/cmse-nonsecure/cmse-nonsecure-entry/gate_test.stderr b/tests/ui/cmse-nonsecure/cmse-nonsecure-entry/gate_test.stderr
index 75a29b317df..beb9716d590 100644
--- a/tests/ui/cmse-nonsecure/cmse-nonsecure-entry/gate_test.stderr
+++ b/tests/ui/cmse-nonsecure/cmse-nonsecure-entry/gate_test.stderr
@@ -6,6 +6,7 @@ LL | #[cmse_nonsecure_entry]
    |
    = note: see issue #75835 <https://github.com/rust-lang/rust/issues/75835> for more information
    = help: add `#![feature(cmse_nonsecure_entry)]` 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[E0775]: `#[cmse_nonsecure_entry]` is only valid for targets with the TrustZone-M extension
   --> $DIR/gate_test.rs:4:1
diff --git a/tests/ui/conditional-compilation/cfg-attr-crate-2.stderr b/tests/ui/conditional-compilation/cfg-attr-crate-2.stderr
index 82dc4361999..742764fe0ef 100644
--- a/tests/ui/conditional-compilation/cfg-attr-crate-2.stderr
+++ b/tests/ui/conditional-compilation/cfg-attr-crate-2.stderr
@@ -6,6 +6,7 @@ LL | #![cfg_attr(broken, no_core)]
    |
    = note: see issue #29639 <https://github.com/rust-lang/rust/issues/29639> for more information
    = help: add `#![feature(no_core)]` 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 1 previous error
 
diff --git a/tests/ui/conditional-compilation/cfg-attr-multi-invalid-1.stderr b/tests/ui/conditional-compilation/cfg-attr-multi-invalid-1.stderr
index daba4eb1a63..7827552096c 100644
--- a/tests/ui/conditional-compilation/cfg-attr-multi-invalid-1.stderr
+++ b/tests/ui/conditional-compilation/cfg-attr-multi-invalid-1.stderr
@@ -6,6 +6,7 @@ LL | #![cfg_attr(broken, no_core, no_std)]
    |
    = note: see issue #29639 <https://github.com/rust-lang/rust/issues/29639> for more information
    = help: add `#![feature(no_core)]` 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 1 previous error
 
diff --git a/tests/ui/conditional-compilation/cfg-attr-multi-invalid-2.stderr b/tests/ui/conditional-compilation/cfg-attr-multi-invalid-2.stderr
index 675792d2e32..d8768c3f310 100644
--- a/tests/ui/conditional-compilation/cfg-attr-multi-invalid-2.stderr
+++ b/tests/ui/conditional-compilation/cfg-attr-multi-invalid-2.stderr
@@ -6,6 +6,7 @@ LL | #![cfg_attr(broken, no_std, no_core)]
    |
    = note: see issue #29639 <https://github.com/rust-lang/rust/issues/29639> for more information
    = help: add `#![feature(no_core)]` 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 1 previous error
 
diff --git a/tests/ui/conditional-compilation/cfg-generic-params.stderr b/tests/ui/conditional-compilation/cfg-generic-params.stderr
index f733c09c22e..4143e2019ae 100644
--- a/tests/ui/conditional-compilation/cfg-generic-params.stderr
+++ b/tests/ui/conditional-compilation/cfg-generic-params.stderr
@@ -36,6 +36,7 @@ LL | type FnBad = for<#[cfg(no)] 'a, #[cfg(yes)] T> fn();
    |
    = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
    = help: add `#![feature(non_lifetime_binders)]` 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]: only lifetime parameters can be used in this context
   --> $DIR/cfg-generic-params.rs:11:51
@@ -45,6 +46,7 @@ LL | type PolyBad = dyn for<#[cfg(no)] 'a, #[cfg(yes)] T> Copy;
    |
    = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
    = help: add `#![feature(non_lifetime_binders)]` 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]: only lifetime parameters can be used in this context
   --> $DIR/cfg-generic-params.rs:15:54
@@ -54,6 +56,7 @@ LL | struct WhereBad where for<#[cfg(no)] 'a, #[cfg(yes)] T> u8: Copy;
    |
    = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
    = help: add `#![feature(non_lifetime_binders)]` 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 8 previous errors
 
diff --git a/tests/ui/conditional-compilation/cfg_accessible-unstable.stderr b/tests/ui/conditional-compilation/cfg_accessible-unstable.stderr
index f0344190976..201f6a13f1f 100644
--- a/tests/ui/conditional-compilation/cfg_accessible-unstable.stderr
+++ b/tests/ui/conditional-compilation/cfg_accessible-unstable.stderr
@@ -6,6 +6,7 @@ LL | #[cfg_accessible(std)]
    |
    = note: see issue #64797 <https://github.com/rust-lang/rust/issues/64797> for more information
    = help: add `#![feature(cfg_accessible)]` 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 1 previous error
 
diff --git a/tests/ui/const-generics/parser-error-recovery/issue-89013-no-kw.stderr b/tests/ui/const-generics/parser-error-recovery/issue-89013-no-kw.stderr
index 4f4e1aa3a04..92dedd74feb 100644
--- a/tests/ui/const-generics/parser-error-recovery/issue-89013-no-kw.stderr
+++ b/tests/ui/const-generics/parser-error-recovery/issue-89013-no-kw.stderr
@@ -6,6 +6,7 @@ LL | impl Foo<N = 3> for Bar {
    |
    = note: see issue #92827 <https://github.com/rust-lang/rust/issues/92827> for more information
    = help: add `#![feature(associated_const_equality)]` 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[E0107]: trait takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/issue-89013-no-kw.rs:9:6
diff --git a/tests/ui/const-generics/parser-error-recovery/issue-89013.stderr b/tests/ui/const-generics/parser-error-recovery/issue-89013.stderr
index 3d2b98feb39..801d14b3950 100644
--- a/tests/ui/const-generics/parser-error-recovery/issue-89013.stderr
+++ b/tests/ui/const-generics/parser-error-recovery/issue-89013.stderr
@@ -18,6 +18,7 @@ LL | impl Foo<N = const 3> for Bar {
    |
    = note: see issue #92827 <https://github.com/rust-lang/rust/issues/92827> for more information
    = help: add `#![feature(associated_const_equality)]` 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[E0107]: trait takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/issue-89013.rs:9:6
diff --git a/tests/ui/consts/async-block.without_feature.stderr b/tests/ui/consts/async-block.without_feature.stderr
index 751627c5226..d31e88724bb 100644
--- a/tests/ui/consts/async-block.without_feature.stderr
+++ b/tests/ui/consts/async-block.without_feature.stderr
@@ -6,6 +6,7 @@ LL | const _: i32 = { core::mem::ManuallyDrop::new(async { 0 }); 4 };
    |
    = note: see issue #85368 <https://github.com/rust-lang/rust/issues/85368> for more information
    = help: add `#![feature(const_async_blocks)]` 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]: `async` blocks are not allowed in statics
   --> $DIR/async-block.rs:15:51
@@ -15,6 +16,7 @@ LL | static _FUT: &(dyn Future<Output = ()> + Sync) = &async {};
    |
    = note: see issue #85368 <https://github.com/rust-lang/rust/issues/85368> for more information
    = help: add `#![feature(const_async_blocks)]` 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 2 previous errors
 
diff --git a/tests/ui/consts/const-address-of-interior-mut.stderr b/tests/ui/consts/const-address-of-interior-mut.stderr
index 93120753b1a..12c8917d740 100644
--- a/tests/ui/consts/const-address-of-interior-mut.stderr
+++ b/tests/ui/consts/const-address-of-interior-mut.stderr
@@ -6,6 +6,7 @@ LL | const A: () = { let x = Cell::new(2); &raw const x; };
    |
    = note: see issue #80384 <https://github.com/rust-lang/rust/issues/80384> for more information
    = help: add `#![feature(const_refs_to_cell)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0658]: cannot borrow here, since the borrowed element may contain interior mutability
   --> $DIR/const-address-of-interior-mut.rs:7:40
@@ -15,6 +16,7 @@ LL | static B: () = { let x = Cell::new(2); &raw const x; };
    |
    = note: see issue #80384 <https://github.com/rust-lang/rust/issues/80384> for more information
    = help: add `#![feature(const_refs_to_cell)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0658]: cannot borrow here, since the borrowed element may contain interior mutability
   --> $DIR/const-address-of-interior-mut.rs:9:44
@@ -24,6 +26,7 @@ LL | static mut C: () = { let x = Cell::new(2); &raw const x; };
    |
    = note: see issue #80384 <https://github.com/rust-lang/rust/issues/80384> for more information
    = help: add `#![feature(const_refs_to_cell)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0658]: cannot borrow here, since the borrowed element may contain interior mutability
   --> $DIR/const-address-of-interior-mut.rs:13:13
@@ -33,6 +36,7 @@ LL |     let y = &raw const x;
    |
    = note: see issue #80384 <https://github.com/rust-lang/rust/issues/80384> for more information
    = help: add `#![feature(const_refs_to_cell)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error: aborting due to 4 previous errors
 
diff --git a/tests/ui/consts/const-address-of-mut.stderr b/tests/ui/consts/const-address-of-mut.stderr
index 60cdcc7df74..2a69bb8be97 100644
--- a/tests/ui/consts/const-address-of-mut.stderr
+++ b/tests/ui/consts/const-address-of-mut.stderr
@@ -6,6 +6,7 @@ LL | const A: () = { let mut x = 2; &raw mut x; };
    |
    = 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]: raw mutable references are not allowed in statics
   --> $DIR/const-address-of-mut.rs:5:33
@@ -15,6 +16,7 @@ LL | static B: () = { let mut x = 2; &raw mut x; };
    |
    = 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]: raw mutable references are not allowed in statics
   --> $DIR/const-address-of-mut.rs:7:37
@@ -24,6 +26,7 @@ LL | static mut C: () = { let mut x = 2; &raw mut x; };
    |
    = 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]: raw mutable references are not allowed in constant functions
   --> $DIR/const-address-of-mut.rs:11:13
@@ -33,6 +36,7 @@ LL |     let y = &raw mut x;
    |
    = 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: aborting due to 4 previous errors
 
diff --git a/tests/ui/consts/const-eval/issue-114994-fail.stderr b/tests/ui/consts/const-eval/issue-114994-fail.stderr
index 4dae8ea9bca..70b224b9b4c 100644
--- a/tests/ui/consts/const-eval/issue-114994-fail.stderr
+++ b/tests/ui/consts/const-eval/issue-114994-fail.stderr
@@ -6,6 +6,7 @@ LL | const fn use_mut_const_fn(_f: &mut fn(&mut String)) {
    |
    = 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 constant functions
   --> $DIR/issue-114994-fail.rs:10:33
@@ -15,6 +16,7 @@ LL | const fn use_mut_const_tuple_fn(_f: (fn(), &mut 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
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error: aborting due to 2 previous errors
 
diff --git a/tests/ui/consts/const-eval/issue-65394.stderr b/tests/ui/consts/const-eval/issue-65394.stderr
index ae6f0e93716..1fa4da4a78b 100644
--- a/tests/ui/consts/const-eval/issue-65394.stderr
+++ b/tests/ui/consts/const-eval/issue-65394.stderr
@@ -6,6 +6,7 @@ LL |     let r = &mut x;
    |
    = 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[E0493]: destructor of `Vec<i32>` cannot be evaluated at compile-time
   --> $DIR/issue-65394.rs:7:9
diff --git a/tests/ui/consts/const-extern-fn/const-extern-fn-min-const-fn.stderr b/tests/ui/consts/const-extern-fn/const-extern-fn-min-const-fn.stderr
index 4bab466fb95..29fa90d611c 100644
--- a/tests/ui/consts/const-extern-fn/const-extern-fn-min-const-fn.stderr
+++ b/tests/ui/consts/const-extern-fn/const-extern-fn-min-const-fn.stderr
@@ -6,6 +6,7 @@ LL | const unsafe extern "C" fn use_float() { 1.0 + 1.0; }
    |
    = note: see issue #57241 <https://github.com/rust-lang/rust/issues/57241> for more information
    = help: add `#![feature(const_fn_floating_point_arithmetic)]` 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: pointers cannot be cast to integers during const eval
   --> $DIR/const-extern-fn-min-const-fn.rs:7:48
diff --git a/tests/ui/consts/const-extern-fn/feature-gate-const_extern_fn.stderr b/tests/ui/consts/const-extern-fn/feature-gate-const_extern_fn.stderr
index f8c3107bd22..81fb62e10a7 100644
--- a/tests/ui/consts/const-extern-fn/feature-gate-const_extern_fn.stderr
+++ b/tests/ui/consts/const-extern-fn/feature-gate-const_extern_fn.stderr
@@ -6,6 +6,7 @@ LL | const extern "cdecl" fn foo4() {}
    |
    = note: see issue #64926 <https://github.com/rust-lang/rust/issues/64926> for more information
    = help: add `#![feature(const_extern_fn)]` 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]: `cdecl` as a `const fn` ABI is unstable
   --> $DIR/feature-gate-const_extern_fn.rs:11:21
@@ -15,6 +16,7 @@ LL | const unsafe extern "cdecl" fn bar4() {}
    |
    = note: see issue #64926 <https://github.com/rust-lang/rust/issues/64926> for more information
    = help: add `#![feature(const_extern_fn)]` 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 2 previous errors
 
diff --git a/tests/ui/consts/const-fn-error.stderr b/tests/ui/consts/const-fn-error.stderr
index f735b3d53ce..68c335c71d9 100644
--- a/tests/ui/consts/const-fn-error.stderr
+++ b/tests/ui/consts/const-fn-error.stderr
@@ -12,6 +12,7 @@ LL | |     }
    |
    = note: see issue #87575 <https://github.com/rust-lang/rust/issues/87575> for more information
    = help: add `#![feature(const_for)]` 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[E0015]: cannot convert `std::ops::Range<usize>` into an iterator in constant functions
   --> $DIR/const-fn-error.rs:5:14
@@ -32,6 +33,7 @@ LL |     for i in 0..x {
    |
    = 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[E0015]: cannot call non-const fn `<std::ops::Range<usize> as Iterator>::next` in constant functions
   --> $DIR/const-fn-error.rs:5:14
diff --git a/tests/ui/consts/const-for-feature-gate.stderr b/tests/ui/consts/const-for-feature-gate.stderr
index 0c24bbad7dd..df79c00f024 100644
--- a/tests/ui/consts/const-for-feature-gate.stderr
+++ b/tests/ui/consts/const-for-feature-gate.stderr
@@ -6,6 +6,7 @@ LL |     for _ in 0..5 {}
    |
    = note: see issue #87575 <https://github.com/rust-lang/rust/issues/87575> for more information
    = help: add `#![feature(const_for)]` 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 1 previous error
 
diff --git a/tests/ui/consts/const-multi-ref.stderr b/tests/ui/consts/const-multi-ref.stderr
index dd5cadfe295..516162194cd 100644
--- a/tests/ui/consts/const-multi-ref.stderr
+++ b/tests/ui/consts/const-multi-ref.stderr
@@ -6,6 +6,7 @@ LL |     let p = &mut a;
    |
    = 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]: cannot borrow here, since the borrowed element may contain interior mutability
   --> $DIR/const-multi-ref.rs:16:13
@@ -15,6 +16,7 @@ LL |     let p = &a;
    |
    = note: see issue #80384 <https://github.com/rust-lang/rust/issues/80384> for more information
    = help: add `#![feature(const_refs_to_cell)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error: aborting due to 2 previous errors
 
diff --git a/tests/ui/consts/const-mut-refs/feature-gate-const_mut_refs.stderr b/tests/ui/consts/const-mut-refs/feature-gate-const_mut_refs.stderr
index 7d8d062dbbe..212d172fe13 100644
--- a/tests/ui/consts/const-mut-refs/feature-gate-const_mut_refs.stderr
+++ b/tests/ui/consts/const-mut-refs/feature-gate-const_mut_refs.stderr
@@ -6,6 +6,7 @@ LL | const fn foo(x: &mut i32) -> i32 {
    |
    = 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: aborting due to 1 previous error
 
diff --git a/tests/ui/consts/const-mut-refs/issue-76510.32bit.stderr b/tests/ui/consts/const-mut-refs/issue-76510.32bit.stderr
index 61b00be345f..dc04d85770e 100644
--- a/tests/ui/consts/const-mut-refs/issue-76510.32bit.stderr
+++ b/tests/ui/consts/const-mut-refs/issue-76510.32bit.stderr
@@ -12,6 +12,7 @@ LL | const S: &'static mut str = &mut " hello ";
    |
    = 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[E0596]: cannot borrow data in a `&` reference as mutable
   --> $DIR/issue-76510.rs:5:29
diff --git a/tests/ui/consts/const-mut-refs/issue-76510.64bit.stderr b/tests/ui/consts/const-mut-refs/issue-76510.64bit.stderr
index 61b00be345f..dc04d85770e 100644
--- a/tests/ui/consts/const-mut-refs/issue-76510.64bit.stderr
+++ b/tests/ui/consts/const-mut-refs/issue-76510.64bit.stderr
@@ -12,6 +12,7 @@ LL | const S: &'static mut str = &mut " hello ";
    |
    = 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[E0596]: cannot borrow data in a `&` reference as mutable
   --> $DIR/issue-76510.rs:5:29
diff --git a/tests/ui/consts/const-suggest-feature.stderr b/tests/ui/consts/const-suggest-feature.stderr
index d4a42a880e3..faa1226ca25 100644
--- a/tests/ui/consts/const-suggest-feature.stderr
+++ b/tests/ui/consts/const-suggest-feature.stderr
@@ -6,6 +6,7 @@ LL |     *std::ptr::null_mut() = 0;
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error: aborting due to 1 previous error
 
diff --git a/tests/ui/consts/const-try-feature-gate.stderr b/tests/ui/consts/const-try-feature-gate.stderr
index 79c6ec108b9..c5aeed3317c 100644
--- a/tests/ui/consts/const-try-feature-gate.stderr
+++ b/tests/ui/consts/const-try-feature-gate.stderr
@@ -6,6 +6,7 @@ LL |     Some(())?;
    |
    = note: see issue #74935 <https://github.com/rust-lang/rust/issues/74935> for more information
    = help: add `#![feature(const_try)]` 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 1 previous error
 
diff --git a/tests/ui/consts/const_fn_floating_point_arithmetic.stock.stderr b/tests/ui/consts/const_fn_floating_point_arithmetic.stock.stderr
index ef7a60faf3f..b5b94786ebb 100644
--- a/tests/ui/consts/const_fn_floating_point_arithmetic.stock.stderr
+++ b/tests/ui/consts/const_fn_floating_point_arithmetic.stock.stderr
@@ -6,6 +6,7 @@ LL | const fn add(f: f32) -> f32 { f + 2.0 }
    |
    = note: see issue #57241 <https://github.com/rust-lang/rust/issues/57241> for more information
    = help: add `#![feature(const_fn_floating_point_arithmetic)]` 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]: floating point arithmetic is not allowed in constant functions
   --> $DIR/const_fn_floating_point_arithmetic.rs:10:31
@@ -15,6 +16,7 @@ LL | const fn sub(f: f32) -> f32 { 2.0 - f }
    |
    = note: see issue #57241 <https://github.com/rust-lang/rust/issues/57241> for more information
    = help: add `#![feature(const_fn_floating_point_arithmetic)]` 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]: floating point arithmetic is not allowed in constant functions
   --> $DIR/const_fn_floating_point_arithmetic.rs:12:39
@@ -24,6 +26,7 @@ LL | const fn mul(f: f32, g: f32) -> f32 { f * g }
    |
    = note: see issue #57241 <https://github.com/rust-lang/rust/issues/57241> for more information
    = help: add `#![feature(const_fn_floating_point_arithmetic)]` 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]: floating point arithmetic is not allowed in constant functions
   --> $DIR/const_fn_floating_point_arithmetic.rs:14:39
@@ -33,6 +36,7 @@ LL | const fn div(f: f32, g: f32) -> f32 { f / g }
    |
    = note: see issue #57241 <https://github.com/rust-lang/rust/issues/57241> for more information
    = help: add `#![feature(const_fn_floating_point_arithmetic)]` 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]: floating point arithmetic is not allowed in constant functions
   --> $DIR/const_fn_floating_point_arithmetic.rs:16:31
@@ -42,6 +46,7 @@ LL | const fn neg(f: f32) -> f32 { -f }
    |
    = note: see issue #57241 <https://github.com/rust-lang/rust/issues/57241> for more information
    = help: add `#![feature(const_fn_floating_point_arithmetic)]` 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 5 previous errors
 
diff --git a/tests/ui/consts/const_let_assign3.stderr b/tests/ui/consts/const_let_assign3.stderr
index 89073f975e8..40c11acee5c 100644
--- a/tests/ui/consts/const_let_assign3.stderr
+++ b/tests/ui/consts/const_let_assign3.stderr
@@ -6,6 +6,7 @@ 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
+   = 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
@@ -15,6 +16,7 @@ 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:20:13
@@ -24,6 +26,7 @@ LL |     let y = &mut x;
    |
    = 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: aborting due to 3 previous errors
 
diff --git a/tests/ui/consts/control-flow/loop.stderr b/tests/ui/consts/control-flow/loop.stderr
index 5f6ad8c105d..725adf72339 100644
--- a/tests/ui/consts/control-flow/loop.stderr
+++ b/tests/ui/consts/control-flow/loop.stderr
@@ -8,6 +8,7 @@ LL | |     }
    |
    = note: see issue #87575 <https://github.com/rust-lang/rust/issues/87575> for more information
    = help: add `#![feature(const_for)]` 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]: `for` is not allowed in a `const`
   --> $DIR/loop.rs:57:5
@@ -19,6 +20,7 @@ LL | |     }
    |
    = note: see issue #87575 <https://github.com/rust-lang/rust/issues/87575> for more information
    = help: add `#![feature(const_for)]` 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 2 previous errors
 
diff --git a/tests/ui/consts/control-flow/try.stderr b/tests/ui/consts/control-flow/try.stderr
index 7351f5c0a6f..f4b88de9dfa 100644
--- a/tests/ui/consts/control-flow/try.stderr
+++ b/tests/ui/consts/control-flow/try.stderr
@@ -6,6 +6,7 @@ LL |     x?;
    |
    = note: see issue #74935 <https://github.com/rust-lang/rust/issues/74935> for more information
    = help: add `#![feature(const_try)]` 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 1 previous error
 
diff --git a/tests/ui/consts/gate-do-not-const-check.stderr b/tests/ui/consts/gate-do-not-const-check.stderr
index 27a2c23a678..74ea71c4ed8 100644
--- a/tests/ui/consts/gate-do-not-const-check.stderr
+++ b/tests/ui/consts/gate-do-not-const-check.stderr
@@ -5,6 +5,7 @@ LL | #[rustc_do_not_const_check]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(rustc_attrs)]` 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 1 previous error
 
diff --git a/tests/ui/consts/min_const_fn/address_of.stderr b/tests/ui/consts/min_const_fn/address_of.stderr
index facc566513c..4c23ba6cd51 100644
--- a/tests/ui/consts/min_const_fn/address_of.stderr
+++ b/tests/ui/consts/min_const_fn/address_of.stderr
@@ -6,6 +6,7 @@ LL |     let b = &raw mut a;
    |
    = 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]: raw mutable references are not allowed in constant functions
   --> $DIR/address_of.rs:13:17
@@ -15,6 +16,7 @@ LL |         let b = &raw mut a;
    |
    = 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: aborting due to 2 previous errors
 
diff --git a/tests/ui/consts/min_const_fn/min_const_fn.stderr b/tests/ui/consts/min_const_fn/min_const_fn.stderr
index 11c79e8e2d6..d646c7de8da 100644
--- a/tests/ui/consts/min_const_fn/min_const_fn.stderr
+++ b/tests/ui/consts/min_const_fn/min_const_fn.stderr
@@ -14,6 +14,7 @@ LL |     const fn get_mut(&mut self) -> &mut T { &mut self.0 }
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = 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 constant functions
   --> $DIR/min_const_fn.rs:39:36
@@ -23,6 +24,7 @@ LL |     const fn get_mut(&mut self) -> &mut T { &mut self.0 }
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = 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 constant functions
   --> $DIR/min_const_fn.rs:39:45
@@ -32,6 +34,7 @@ LL |     const fn get_mut(&mut self) -> &mut T { &mut self.0 }
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0493]: destructor of `Foo<T>` cannot be evaluated at compile-time
   --> $DIR/min_const_fn.rs:46:28
@@ -49,6 +52,7 @@ LL |     const fn get_mut_lt(&'a mut self) -> &mut T { &mut self.0 }
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = 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 constant functions
   --> $DIR/min_const_fn.rs:48:42
@@ -58,6 +62,7 @@ LL |     const fn get_mut_lt(&'a mut self) -> &mut T { &mut self.0 }
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = 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 constant functions
   --> $DIR/min_const_fn.rs:48:51
@@ -67,6 +72,7 @@ LL |     const fn get_mut_lt(&'a mut self) -> &mut T { &mut self.0 }
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0493]: destructor of `Foo<T>` cannot be evaluated at compile-time
   --> $DIR/min_const_fn.rs:55:27
@@ -84,6 +90,7 @@ LL |     const fn get_mut_s(&mut self) -> &mut T { &mut self.0 }
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = 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 constant functions
   --> $DIR/min_const_fn.rs:57:38
@@ -93,6 +100,7 @@ LL |     const fn get_mut_s(&mut self) -> &mut T { &mut self.0 }
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = 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 constant functions
   --> $DIR/min_const_fn.rs:57:47
@@ -102,6 +110,7 @@ LL |     const fn get_mut_s(&mut self) -> &mut T { &mut self.0 }
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = 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 constant functions
   --> $DIR/min_const_fn.rs:64:25
@@ -111,6 +120,7 @@ LL |     const fn get_mut_sq(&mut self) -> &mut T { &mut self.0 }
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = 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 constant functions
   --> $DIR/min_const_fn.rs:64:39
@@ -120,6 +130,7 @@ LL |     const fn get_mut_sq(&mut self) -> &mut T { &mut self.0 }
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = 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 constant functions
   --> $DIR/min_const_fn.rs:64:48
@@ -129,6 +140,7 @@ LL |     const fn get_mut_sq(&mut self) -> &mut T { &mut self.0 }
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0013]: constant functions cannot refer to statics
   --> $DIR/min_const_fn.rs:89:27
@@ -190,6 +202,7 @@ LL | const fn inc(x: &mut i32) { *x += 1 }
    |
    = 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[E0493]: destructor of `AlanTuring<impl std::fmt::Debug>` cannot be evaluated at compile-time
   --> $DIR/min_const_fn.rs:122:19
diff --git a/tests/ui/consts/min_const_fn/min_const_fn_unsafe_bad.stderr b/tests/ui/consts/min_const_fn/min_const_fn_unsafe_bad.stderr
index e68376e7b87..13d733494d2 100644
--- a/tests/ui/consts/min_const_fn/min_const_fn_unsafe_bad.stderr
+++ b/tests/ui/consts/min_const_fn/min_const_fn_unsafe_bad.stderr
@@ -6,6 +6,7 @@ LL | const fn bad_const_fn_deref_raw(x: *mut usize) -> &'static usize { unsafe {
    |
    = 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/min_const_fn_unsafe_bad.rs:4:70
@@ -15,6 +16,7 @@ LL | const unsafe fn bad_const_unsafe_deref_raw(x: *mut usize) -> usize { *x }
    |
    = 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/min_const_fn_unsafe_bad.rs:7:83
@@ -24,6 +26,7 @@ LL | const unsafe fn bad_const_unsafe_deref_raw_ref(x: *mut usize) -> &'static u
    |
    = 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/min_const_fn_unsafe_bad.rs:10:80
@@ -33,6 +36,7 @@ LL | const unsafe fn bad_const_unsafe_deref_raw_underscore(x: *mut usize) { let
    |
    = 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: aborting due to 4 previous errors
 
diff --git a/tests/ui/consts/min_const_fn/mutable_borrow.stderr b/tests/ui/consts/min_const_fn/mutable_borrow.stderr
index 8e95a4c68a2..31653602c75 100644
--- a/tests/ui/consts/min_const_fn/mutable_borrow.stderr
+++ b/tests/ui/consts/min_const_fn/mutable_borrow.stderr
@@ -6,6 +6,7 @@ LL |     let b = &mut a;
    |
    = 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 constant functions
   --> $DIR/mutable_borrow.rs:12:17
@@ -15,6 +16,7 @@ LL |         let b = &mut a;
    |
    = 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: aborting due to 2 previous errors
 
diff --git a/tests/ui/consts/static_mut_containing_mut_ref2.stock.stderr b/tests/ui/consts/static_mut_containing_mut_ref2.stock.stderr
index c6e5b07e3b7..e9fe82d2f87 100644
--- a/tests/ui/consts/static_mut_containing_mut_ref2.stock.stderr
+++ b/tests/ui/consts/static_mut_containing_mut_ref2.stock.stderr
@@ -21,6 +21,7 @@ LL |     *(&mut STDERR_BUFFER_SPACE) = 42;
    |
    = 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: aborting due to 1 previous error; 1 warning emitted
 
diff --git a/tests/ui/consts/write_to_mut_ref_dest.stock.stderr b/tests/ui/consts/write_to_mut_ref_dest.stock.stderr
index bb105927606..688d48ec707 100644
--- a/tests/ui/consts/write_to_mut_ref_dest.stock.stderr
+++ b/tests/ui/consts/write_to_mut_ref_dest.stock.stderr
@@ -6,6 +6,7 @@ LL |         let b: *mut u32 = &mut a;
    |
    = 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/write_to_mut_ref_dest.rs:12:18
@@ -15,6 +16,7 @@ LL |         unsafe { *b = 5; }
    |
    = 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: aborting due to 2 previous errors
 
diff --git a/tests/ui/coroutine/async_gen_fn.e2024.stderr b/tests/ui/coroutine/async_gen_fn.e2024.stderr
index d24cdbbc30d..37dc674a7e3 100644
--- a/tests/ui/coroutine/async_gen_fn.e2024.stderr
+++ b/tests/ui/coroutine/async_gen_fn.e2024.stderr
@@ -6,6 +6,7 @@ LL | async gen fn foo() {}
    |
    = note: see issue #117078 <https://github.com/rust-lang/rust/issues/117078> for more information
    = help: add `#![feature(gen_blocks)]` 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 1 previous error
 
diff --git a/tests/ui/coroutine/gen_block.e2024.stderr b/tests/ui/coroutine/gen_block.e2024.stderr
index e32f80dafa0..2b9eb4a820b 100644
--- a/tests/ui/coroutine/gen_block.e2024.stderr
+++ b/tests/ui/coroutine/gen_block.e2024.stderr
@@ -6,6 +6,7 @@ LL |     let _ = || yield true;
    |
    = note: see issue #43122 <https://github.com/rust-lang/rust/issues/43122> for more information
    = help: add `#![feature(coroutines)]` 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[E0282]: type annotations needed
   --> $DIR/gen_block.rs:6:13
diff --git a/tests/ui/coroutine/gen_block.none.stderr b/tests/ui/coroutine/gen_block.none.stderr
index 012a8308c7f..78a8c5e798a 100644
--- a/tests/ui/coroutine/gen_block.none.stderr
+++ b/tests/ui/coroutine/gen_block.none.stderr
@@ -32,6 +32,7 @@ LL |     let _ = || yield true;
    |
    = note: see issue #43122 <https://github.com/rust-lang/rust/issues/43122> for more information
    = help: add `#![feature(coroutines)]` 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]: yield syntax is experimental
   --> $DIR/gen_block.rs:15:16
@@ -41,6 +42,7 @@ LL |     let _ = || yield true;
    |
    = note: see issue #43122 <https://github.com/rust-lang/rust/issues/43122> for more information
    = help: add `#![feature(coroutines)]` 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: aborting due to 6 previous errors
diff --git a/tests/ui/coroutine/gen_fn.e2024.stderr b/tests/ui/coroutine/gen_fn.e2024.stderr
index 9ad890af3e1..9c1843a0f52 100644
--- a/tests/ui/coroutine/gen_fn.e2024.stderr
+++ b/tests/ui/coroutine/gen_fn.e2024.stderr
@@ -6,6 +6,7 @@ LL | gen fn foo() {}
    |
    = note: see issue #117078 <https://github.com/rust-lang/rust/issues/117078> for more information
    = help: add `#![feature(gen_blocks)]` 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 1 previous error
 
diff --git a/tests/ui/deprecation/issue-66340-deprecated-attr-non-meta-grammar.rs b/tests/ui/deprecation/issue-66340-deprecated-attr-non-meta-grammar.rs
index c0cde75d4ca..6653bd15ddd 100644
--- a/tests/ui/deprecation/issue-66340-deprecated-attr-non-meta-grammar.rs
+++ b/tests/ui/deprecation/issue-66340-deprecated-attr-non-meta-grammar.rs
@@ -7,5 +7,5 @@ fn main() {
 }
 
 #[deprecated(note = test)]
-//~^ ERROR expected unsuffixed literal or identifier, found `test`
+//~^ ERROR expected unsuffixed literal, found `test`
 fn foo() {}
diff --git a/tests/ui/deprecation/issue-66340-deprecated-attr-non-meta-grammar.stderr b/tests/ui/deprecation/issue-66340-deprecated-attr-non-meta-grammar.stderr
index 48c763c50e3..078c766deed 100644
--- a/tests/ui/deprecation/issue-66340-deprecated-attr-non-meta-grammar.stderr
+++ b/tests/ui/deprecation/issue-66340-deprecated-attr-non-meta-grammar.stderr
@@ -1,8 +1,13 @@
-error: expected unsuffixed literal or identifier, found `test`
+error: expected unsuffixed literal, found `test`
   --> $DIR/issue-66340-deprecated-attr-non-meta-grammar.rs:9:21
    |
 LL | #[deprecated(note = test)]
    |                     ^^^^
+   |
+help: surround the identifier with quotation marks to parse it as a string
+   |
+LL | #[deprecated(note = "test")]
+   |                     +    +
 
 error: aborting due to 1 previous error
 
diff --git a/tests/ui/diagnostic_namespace/feature-gate-diagnostic_namespace.stderr b/tests/ui/diagnostic_namespace/feature-gate-diagnostic_namespace.stderr
index 017d00e2c8e..38424c13d86 100644
--- a/tests/ui/diagnostic_namespace/feature-gate-diagnostic_namespace.stderr
+++ b/tests/ui/diagnostic_namespace/feature-gate-diagnostic_namespace.stderr
@@ -6,6 +6,7 @@ LL | #[diagnostic::non_existing_attribute]
    |
    = note: see issue #111996 <https://github.com/rust-lang/rust/issues/111996> for more information
    = help: add `#![feature(diagnostic_namespace)]` 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]: `#[diagnostic]` attribute name space is experimental
   --> $DIR/feature-gate-diagnostic_namespace.rs:7:3
@@ -15,6 +16,7 @@ LL | #[diagnostic::non_existing_attribute(with_option = "foo")]
    |
    = note: see issue #111996 <https://github.com/rust-lang/rust/issues/111996> for more information
    = help: add `#![feature(diagnostic_namespace)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: unknown diagnostic attribute
   --> $DIR/feature-gate-diagnostic_namespace.rs:1:15
diff --git a/tests/ui/diagnostic_namespace/on_unimplemented/feature-gate-diagnostic_on_unimplemented.stderr b/tests/ui/diagnostic_namespace/on_unimplemented/feature-gate-diagnostic_on_unimplemented.stderr
index 82e3b709f70..719322fa0f5 100644
--- a/tests/ui/diagnostic_namespace/on_unimplemented/feature-gate-diagnostic_on_unimplemented.stderr
+++ b/tests/ui/diagnostic_namespace/on_unimplemented/feature-gate-diagnostic_on_unimplemented.stderr
@@ -6,6 +6,7 @@ LL | #[diagnostic::on_unimplemented(message = "Foo")]
    |
    = note: see issue #111996 <https://github.com/rust-lang/rust/issues/111996> for more information
    = help: add `#![feature(diagnostic_namespace)]` 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 1 previous error
 
diff --git a/tests/ui/dyn-star/feature-gate-dyn_star.stderr b/tests/ui/dyn-star/feature-gate-dyn_star.stderr
index d8fe25b84bd..c3e99b20d06 100644
--- a/tests/ui/dyn-star/feature-gate-dyn_star.stderr
+++ b/tests/ui/dyn-star/feature-gate-dyn_star.stderr
@@ -6,6 +6,7 @@ LL | pub fn dyn_star_parameter(_: &dyn* Send) {
    |
    = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
    = help: add `#![feature(dyn_star)]` 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 1 previous error
 
diff --git a/tests/ui/dyn-star/gated-span.stderr b/tests/ui/dyn-star/gated-span.stderr
index da5afa2d578..8ba6d7969fc 100644
--- a/tests/ui/dyn-star/gated-span.stderr
+++ b/tests/ui/dyn-star/gated-span.stderr
@@ -6,6 +6,7 @@ LL | t!(dyn* Send);
    |
    = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
    = help: add `#![feature(dyn_star)]` 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 1 previous error
 
diff --git a/tests/ui/dyn-star/no-explicit-dyn-star-cast.stderr b/tests/ui/dyn-star/no-explicit-dyn-star-cast.stderr
index 78af9c7a389..bb4c612cedd 100644
--- a/tests/ui/dyn-star/no-explicit-dyn-star-cast.stderr
+++ b/tests/ui/dyn-star/no-explicit-dyn-star-cast.stderr
@@ -6,6 +6,7 @@ LL |     let dyn_i: dyn* Debug = i as dyn* Debug;
    |
    = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
    = help: add `#![feature(dyn_star)]` 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]: `dyn*` trait objects are experimental
   --> $DIR/no-explicit-dyn-star-cast.rs:5:34
@@ -15,6 +16,7 @@ LL |     let dyn_i: dyn* Debug = i as dyn* Debug;
    |
    = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
    = help: add `#![feature(dyn_star)]` 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[E0606]: casting `usize` as `dyn* Debug` is invalid
   --> $DIR/no-explicit-dyn-star-cast.rs:5:29
diff --git a/tests/ui/error-codes/E0017.stderr b/tests/ui/error-codes/E0017.stderr
index ea6055da1c1..2a70f2ee0ae 100644
--- a/tests/ui/error-codes/E0017.stderr
+++ b/tests/ui/error-codes/E0017.stderr
@@ -42,6 +42,7 @@ LL | static STATIC_REF: &'static mut i32 = &mut X;
    |
    = 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[E0764]: mutable references are not allowed in the final value of statics
   --> $DIR/E0017.rs:8:39
diff --git a/tests/ui/error-codes/E0388.stderr b/tests/ui/error-codes/E0388.stderr
index b51aa263d5e..1f7b688899e 100644
--- a/tests/ui/error-codes/E0388.stderr
+++ b/tests/ui/error-codes/E0388.stderr
@@ -27,6 +27,7 @@ LL | static STATIC_REF: &'static mut i32 = &mut X;
    |
    = 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[E0764]: mutable references are not allowed in the final value of statics
   --> $DIR/E0388.rs:6:39
diff --git a/tests/ui/error-codes/E0396.stderr b/tests/ui/error-codes/E0396.stderr
index a84a1216e0a..ac1e7d65ce8 100644
--- a/tests/ui/error-codes/E0396.stderr
+++ b/tests/ui/error-codes/E0396.stderr
@@ -6,6 +6,7 @@ LL | const VALUE: u8 = unsafe { *REG_ADDR };
    |
    = 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
@@ -15,6 +16,7 @@ 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 constant functions is unstable
   --> $DIR/E0396.rs:10:11
@@ -24,6 +26,7 @@ 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
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
 error[E0658]: dereferencing raw mutable pointers in constants is unstable
@@ -34,6 +37,7 @@ 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 constants is unstable
   --> $DIR/E0396.rs:14:36
@@ -43,6 +47,7 @@ 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: aborting due to 5 previous errors
diff --git a/tests/ui/error-codes/E0658.stderr b/tests/ui/error-codes/E0658.stderr
index 686394b6d22..e1e812940ec 100644
--- a/tests/ui/error-codes/E0658.stderr
+++ b/tests/ui/error-codes/E0658.stderr
@@ -6,6 +6,7 @@ LL | enum Foo {
    |
    = note: see issue #56071 <https://github.com/rust-lang/rust/issues/56071> for more information
    = help: add `#![feature(repr128)]` 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 1 previous error
 
diff --git a/tests/ui/explore-issue-38412.stderr b/tests/ui/explore-issue-38412.stderr
index d8b485c9dc3..a45ec688855 100644
--- a/tests/ui/explore-issue-38412.stderr
+++ b/tests/ui/explore-issue-38412.stderr
@@ -6,6 +6,7 @@ LL |     let Record { a_stable_pub: _, a_unstable_declared_pub: _, a_unstable_un
    |
    = note: see issue #38412 <https://github.com/rust-lang/rust/issues/38412> for more information
    = help: add `#![feature(unstable_undeclared)]` 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]: use of unstable library feature 'unstable_undeclared'
   --> $DIR/explore-issue-38412.rs:28:5
@@ -15,6 +16,7 @@ LL |     r.a_unstable_undeclared_pub;
    |
    = note: see issue #38412 <https://github.com/rust-lang/rust/issues/38412> for more information
    = help: add `#![feature(unstable_undeclared)]` 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[E0616]: field `b_crate` of struct `Record` is private
   --> $DIR/explore-issue-38412.rs:29:7
@@ -42,6 +44,7 @@ LL |     t.2;
    |
    = note: see issue #38412 <https://github.com/rust-lang/rust/issues/38412> for more information
    = help: add `#![feature(unstable_undeclared)]` 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[E0616]: field `3` of struct `pub_and_stability::Tuple` is private
   --> $DIR/explore-issue-38412.rs:36:7
@@ -69,6 +72,7 @@ LL |     r.unstable_undeclared_trait_method();
    |
    = note: see issue #38412 <https://github.com/rust-lang/rust/issues/38412> for more information
    = help: add `#![feature(unstable_undeclared)]` 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]: use of unstable library feature 'unstable_undeclared'
   --> $DIR/explore-issue-38412.rs:46:7
@@ -78,6 +82,7 @@ LL |     r.unstable_undeclared();
    |
    = note: see issue #38412 <https://github.com/rust-lang/rust/issues/38412> for more information
    = help: add `#![feature(unstable_undeclared)]` 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[E0624]: method `pub_crate` is private
   --> $DIR/explore-issue-38412.rs:48:7
@@ -120,6 +125,7 @@ LL |     t.unstable_undeclared_trait_method();
    |
    = note: see issue #38412 <https://github.com/rust-lang/rust/issues/38412> for more information
    = help: add `#![feature(unstable_undeclared)]` 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]: use of unstable library feature 'unstable_undeclared'
   --> $DIR/explore-issue-38412.rs:59:7
@@ -129,6 +135,7 @@ LL |     t.unstable_undeclared();
    |
    = note: see issue #38412 <https://github.com/rust-lang/rust/issues/38412> for more information
    = help: add `#![feature(unstable_undeclared)]` 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[E0624]: method `pub_crate` is private
   --> $DIR/explore-issue-38412.rs:61:7
diff --git a/tests/ui/expr/if/attrs/stmt-expr-gated.stderr b/tests/ui/expr/if/attrs/stmt-expr-gated.stderr
index afc26757c46..b30de464118 100644
--- a/tests/ui/expr/if/attrs/stmt-expr-gated.stderr
+++ b/tests/ui/expr/if/attrs/stmt-expr-gated.stderr
@@ -6,6 +6,7 @@ LL |     let _ = #[deny(warnings)] if true {
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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 1 previous error
 
diff --git a/tests/ui/extern/issue-112363-extern-item-where-clauses-debug-ice.stderr b/tests/ui/extern/issue-112363-extern-item-where-clauses-debug-ice.stderr
index bdc6755038a..039e50b5e12 100644
--- a/tests/ui/extern/issue-112363-extern-item-where-clauses-debug-ice.stderr
+++ b/tests/ui/extern/issue-112363-extern-item-where-clauses-debug-ice.stderr
@@ -40,6 +40,7 @@ LL |     type Item = [T] where [T]: Sized;
    |
    = note: see issue #43467 <https://github.com/rust-lang/rust/issues/43467> for more information
    = help: add `#![feature(extern_types)]` 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 5 previous errors
 
diff --git a/tests/ui/feature-gates/doc-rust-logo.stderr b/tests/ui/feature-gates/doc-rust-logo.stderr
index 15398c8505f..5c64652667e 100644
--- a/tests/ui/feature-gates/doc-rust-logo.stderr
+++ b/tests/ui/feature-gates/doc-rust-logo.stderr
@@ -6,6 +6,7 @@ LL | #![doc(rust_logo)]
    |
    = note: see issue #90418 <https://github.com/rust-lang/rust/issues/90418> for more information
    = help: add `#![feature(rustdoc_internals)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-abi-avr-interrupt.stderr b/tests/ui/feature-gates/feature-gate-abi-avr-interrupt.stderr
index d017d03a385..c6786699de1 100644
--- a/tests/ui/feature-gates/feature-gate-abi-avr-interrupt.stderr
+++ b/tests/ui/feature-gates/feature-gate-abi-avr-interrupt.stderr
@@ -6,6 +6,7 @@ LL | extern "avr-non-blocking-interrupt" fn fu() {}
    |
    = note: see issue #69664 <https://github.com/rust-lang/rust/issues/69664> for more information
    = help: add `#![feature(abi_avr_interrupt)]` 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]: avr-interrupt and avr-non-blocking-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-avr-interrupt.rs:13:8
@@ -15,6 +16,7 @@ LL | extern "avr-interrupt" fn f() {}
    |
    = note: see issue #69664 <https://github.com/rust-lang/rust/issues/69664> for more information
    = help: add `#![feature(abi_avr_interrupt)]` 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]: avr-interrupt and avr-non-blocking-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-avr-interrupt.rs:17:12
@@ -24,6 +26,7 @@ LL |     extern "avr-interrupt" fn m();
    |
    = note: see issue #69664 <https://github.com/rust-lang/rust/issues/69664> for more information
    = help: add `#![feature(abi_avr_interrupt)]` 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]: avr-interrupt and avr-non-blocking-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-avr-interrupt.rs:19:12
@@ -33,6 +36,7 @@ LL |     extern "avr-non-blocking-interrupt" fn mu();
    |
    = note: see issue #69664 <https://github.com/rust-lang/rust/issues/69664> for more information
    = help: add `#![feature(abi_avr_interrupt)]` 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]: avr-interrupt and avr-non-blocking-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-avr-interrupt.rs:22:12
@@ -42,6 +46,7 @@ LL |     extern "avr-interrupt" fn dm() {}
    |
    = note: see issue #69664 <https://github.com/rust-lang/rust/issues/69664> for more information
    = help: add `#![feature(abi_avr_interrupt)]` 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]: avr-interrupt and avr-non-blocking-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-avr-interrupt.rs:24:12
@@ -51,6 +56,7 @@ LL |     extern "avr-non-blocking-interrupt" fn dmu() {}
    |
    = note: see issue #69664 <https://github.com/rust-lang/rust/issues/69664> for more information
    = help: add `#![feature(abi_avr_interrupt)]` 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]: avr-interrupt and avr-non-blocking-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-avr-interrupt.rs:30:12
@@ -60,6 +66,7 @@ LL |     extern "avr-interrupt" fn m() {}
    |
    = note: see issue #69664 <https://github.com/rust-lang/rust/issues/69664> for more information
    = help: add `#![feature(abi_avr_interrupt)]` 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]: avr-interrupt and avr-non-blocking-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-avr-interrupt.rs:32:12
@@ -69,6 +76,7 @@ LL |     extern "avr-non-blocking-interrupt" fn mu() {}
    |
    = note: see issue #69664 <https://github.com/rust-lang/rust/issues/69664> for more information
    = help: add `#![feature(abi_avr_interrupt)]` 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]: avr-interrupt and avr-non-blocking-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-avr-interrupt.rs:37:12
@@ -78,6 +86,7 @@ LL |     extern "avr-interrupt" fn im() {}
    |
    = note: see issue #69664 <https://github.com/rust-lang/rust/issues/69664> for more information
    = help: add `#![feature(abi_avr_interrupt)]` 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]: avr-interrupt and avr-non-blocking-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-avr-interrupt.rs:39:12
@@ -87,6 +96,7 @@ LL |     extern "avr-non-blocking-interrupt" fn imu() {}
    |
    = note: see issue #69664 <https://github.com/rust-lang/rust/issues/69664> for more information
    = help: add `#![feature(abi_avr_interrupt)]` 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]: avr-interrupt and avr-non-blocking-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-avr-interrupt.rs:43:18
@@ -96,6 +106,7 @@ LL | type TA = extern "avr-interrupt" fn();
    |
    = note: see issue #69664 <https://github.com/rust-lang/rust/issues/69664> for more information
    = help: add `#![feature(abi_avr_interrupt)]` 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]: avr-interrupt and avr-non-blocking-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-avr-interrupt.rs:45:19
@@ -105,6 +116,7 @@ LL | type TAU = extern "avr-non-blocking-interrupt" fn();
    |
    = note: see issue #69664 <https://github.com/rust-lang/rust/issues/69664> for more information
    = help: add `#![feature(abi_avr_interrupt)]` 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]: avr-interrupt and avr-non-blocking-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-avr-interrupt.rs:48:8
@@ -114,6 +126,7 @@ LL | extern "avr-interrupt" {}
    |
    = note: see issue #69664 <https://github.com/rust-lang/rust/issues/69664> for more information
    = help: add `#![feature(abi_avr_interrupt)]` 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]: avr-interrupt and avr-non-blocking-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-avr-interrupt.rs:50:8
@@ -123,6 +136,7 @@ LL | extern "avr-non-blocking-interrupt" {}
    |
    = note: see issue #69664 <https://github.com/rust-lang/rust/issues/69664> for more information
    = help: add `#![feature(abi_avr_interrupt)]` 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 14 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-abi-msp430-interrupt.stderr b/tests/ui/feature-gates/feature-gate-abi-msp430-interrupt.stderr
index c19ec97896b..5dacc86dcc5 100644
--- a/tests/ui/feature-gates/feature-gate-abi-msp430-interrupt.stderr
+++ b/tests/ui/feature-gates/feature-gate-abi-msp430-interrupt.stderr
@@ -6,6 +6,7 @@ LL | extern "msp430-interrupt" fn f() {}
    |
    = note: see issue #38487 <https://github.com/rust-lang/rust/issues/38487> for more information
    = help: add `#![feature(abi_msp430_interrupt)]` 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]: msp430-interrupt ABI is experimental and subject to change
   --> $DIR/feature-gate-abi-msp430-interrupt.rs:12:12
@@ -15,6 +16,7 @@ LL |     extern "msp430-interrupt" fn m();
    |
    = note: see issue #38487 <https://github.com/rust-lang/rust/issues/38487> for more information
    = help: add `#![feature(abi_msp430_interrupt)]` 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]: msp430-interrupt ABI is experimental and subject to change
   --> $DIR/feature-gate-abi-msp430-interrupt.rs:15:12
@@ -24,6 +26,7 @@ LL |     extern "msp430-interrupt" fn dm() {}
    |
    = note: see issue #38487 <https://github.com/rust-lang/rust/issues/38487> for more information
    = help: add `#![feature(abi_msp430_interrupt)]` 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]: msp430-interrupt ABI is experimental and subject to change
   --> $DIR/feature-gate-abi-msp430-interrupt.rs:21:12
@@ -33,6 +36,7 @@ LL |     extern "msp430-interrupt" fn m() {}
    |
    = note: see issue #38487 <https://github.com/rust-lang/rust/issues/38487> for more information
    = help: add `#![feature(abi_msp430_interrupt)]` 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]: msp430-interrupt ABI is experimental and subject to change
   --> $DIR/feature-gate-abi-msp430-interrupt.rs:26:12
@@ -42,6 +46,7 @@ LL |     extern "msp430-interrupt" fn im() {}
    |
    = note: see issue #38487 <https://github.com/rust-lang/rust/issues/38487> for more information
    = help: add `#![feature(abi_msp430_interrupt)]` 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]: msp430-interrupt ABI is experimental and subject to change
   --> $DIR/feature-gate-abi-msp430-interrupt.rs:30:18
@@ -51,6 +56,7 @@ LL | type TA = extern "msp430-interrupt" fn();
    |
    = note: see issue #38487 <https://github.com/rust-lang/rust/issues/38487> for more information
    = help: add `#![feature(abi_msp430_interrupt)]` 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]: msp430-interrupt ABI is experimental and subject to change
   --> $DIR/feature-gate-abi-msp430-interrupt.rs:33:8
@@ -60,6 +66,7 @@ LL | extern "msp430-interrupt" {}
    |
    = note: see issue #38487 <https://github.com/rust-lang/rust/issues/38487> for more information
    = help: add `#![feature(abi_msp430_interrupt)]` 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 7 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-abi-riscv-interrupt.stderr b/tests/ui/feature-gates/feature-gate-abi-riscv-interrupt.stderr
index 60c7fa0ea67..6b7853a320b 100644
--- a/tests/ui/feature-gates/feature-gate-abi-riscv-interrupt.stderr
+++ b/tests/ui/feature-gates/feature-gate-abi-riscv-interrupt.stderr
@@ -6,6 +6,7 @@ LL | extern "riscv-interrupt-m" fn f() {}
    |
    = note: see issue #111889 <https://github.com/rust-lang/rust/issues/111889> for more information
    = help: add `#![feature(abi_riscv_interrupt)]` 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]: riscv-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-riscv-interrupt.rs:13:8
@@ -15,6 +16,7 @@ LL | extern "riscv-interrupt-s" fn f_s() {}
    |
    = note: see issue #111889 <https://github.com/rust-lang/rust/issues/111889> for more information
    = help: add `#![feature(abi_riscv_interrupt)]` 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]: riscv-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-riscv-interrupt.rs:17:12
@@ -24,6 +26,7 @@ LL |     extern "riscv-interrupt-m" fn m();
    |
    = note: see issue #111889 <https://github.com/rust-lang/rust/issues/111889> for more information
    = help: add `#![feature(abi_riscv_interrupt)]` 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]: riscv-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-riscv-interrupt.rs:23:12
@@ -33,6 +36,7 @@ LL |     extern "riscv-interrupt-m" fn m() {}
    |
    = note: see issue #111889 <https://github.com/rust-lang/rust/issues/111889> for more information
    = help: add `#![feature(abi_riscv_interrupt)]` 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]: riscv-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-riscv-interrupt.rs:28:12
@@ -42,6 +46,7 @@ LL |     extern "riscv-interrupt-m" fn im() {}
    |
    = note: see issue #111889 <https://github.com/rust-lang/rust/issues/111889> for more information
    = help: add `#![feature(abi_riscv_interrupt)]` 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]: riscv-interrupt ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi-riscv-interrupt.rs:32:18
@@ -51,6 +56,7 @@ LL | type TA = extern "riscv-interrupt-m" fn();
    |
    = note: see issue #111889 <https://github.com/rust-lang/rust/issues/111889> for more information
    = help: add `#![feature(abi_riscv_interrupt)]` 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 6 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-abi-x86-interrupt.stderr b/tests/ui/feature-gates/feature-gate-abi-x86-interrupt.stderr
index 3b727a745e8..860005cac34 100644
--- a/tests/ui/feature-gates/feature-gate-abi-x86-interrupt.stderr
+++ b/tests/ui/feature-gates/feature-gate-abi-x86-interrupt.stderr
@@ -6,6 +6,7 @@ LL | extern "x86-interrupt" fn f7() {}
    |
    = note: see issue #40180 <https://github.com/rust-lang/rust/issues/40180> for more information
    = help: add `#![feature(abi_x86_interrupt)]` 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]: x86-interrupt ABI is experimental and subject to change
   --> $DIR/feature-gate-abi-x86-interrupt.rs:10:12
@@ -15,6 +16,7 @@ LL |     extern "x86-interrupt" fn m7();
    |
    = note: see issue #40180 <https://github.com/rust-lang/rust/issues/40180> for more information
    = help: add `#![feature(abi_x86_interrupt)]` 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]: x86-interrupt ABI is experimental and subject to change
   --> $DIR/feature-gate-abi-x86-interrupt.rs:11:12
@@ -24,6 +26,7 @@ LL |     extern "x86-interrupt" fn dm7() {}
    |
    = note: see issue #40180 <https://github.com/rust-lang/rust/issues/40180> for more information
    = help: add `#![feature(abi_x86_interrupt)]` 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]: x86-interrupt ABI is experimental and subject to change
   --> $DIR/feature-gate-abi-x86-interrupt.rs:18:12
@@ -33,6 +36,7 @@ LL |     extern "x86-interrupt" fn m7() {}
    |
    = note: see issue #40180 <https://github.com/rust-lang/rust/issues/40180> for more information
    = help: add `#![feature(abi_x86_interrupt)]` 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]: x86-interrupt ABI is experimental and subject to change
   --> $DIR/feature-gate-abi-x86-interrupt.rs:23:12
@@ -42,6 +46,7 @@ LL |     extern "x86-interrupt" fn im7() {}
    |
    = note: see issue #40180 <https://github.com/rust-lang/rust/issues/40180> for more information
    = help: add `#![feature(abi_x86_interrupt)]` 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]: x86-interrupt ABI is experimental and subject to change
   --> $DIR/feature-gate-abi-x86-interrupt.rs:26:18
@@ -51,6 +56,7 @@ LL | type A7 = extern "x86-interrupt" fn();
    |
    = note: see issue #40180 <https://github.com/rust-lang/rust/issues/40180> for more information
    = help: add `#![feature(abi_x86_interrupt)]` 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]: x86-interrupt ABI is experimental and subject to change
   --> $DIR/feature-gate-abi-x86-interrupt.rs:28:8
@@ -60,6 +66,7 @@ LL | extern "x86-interrupt" {}
    |
    = note: see issue #40180 <https://github.com/rust-lang/rust/issues/40180> for more information
    = help: add `#![feature(abi_x86_interrupt)]` 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 7 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-abi.stderr b/tests/ui/feature-gates/feature-gate-abi.stderr
index e9791b9513f..d031c2adf50 100644
--- a/tests/ui/feature-gates/feature-gate-abi.stderr
+++ b/tests/ui/feature-gates/feature-gate-abi.stderr
@@ -5,6 +5,7 @@ LL | extern "rust-intrinsic" fn f1() {}
    |        ^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(intrinsics)]` 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]: platform intrinsics are experimental and possibly buggy
   --> $DIR/feature-gate-abi.rs:17:8
@@ -14,6 +15,7 @@ LL | extern "platform-intrinsic" fn f2() {}
    |
    = note: see issue #27731 <https://github.com/rust-lang/rust/issues/27731> for more information
    = help: add `#![feature(platform_intrinsics)]` 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]: rust-call ABI is subject to change
   --> $DIR/feature-gate-abi.rs:19:8
@@ -23,6 +25,7 @@ LL | extern "rust-call" fn f4(_: ()) {}
    |
    = 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[E0658]: intrinsics are subject to change
   --> $DIR/feature-gate-abi.rs:23:12
@@ -31,6 +34,7 @@ LL |     extern "rust-intrinsic" fn m1();
    |            ^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(intrinsics)]` 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]: platform intrinsics are experimental and possibly buggy
   --> $DIR/feature-gate-abi.rs:25:12
@@ -40,6 +44,7 @@ LL |     extern "platform-intrinsic" fn m2();
    |
    = note: see issue #27731 <https://github.com/rust-lang/rust/issues/27731> for more information
    = help: add `#![feature(platform_intrinsics)]` 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]: rust-call ABI is subject to change
   --> $DIR/feature-gate-abi.rs:27:12
@@ -49,6 +54,7 @@ LL |     extern "rust-call" fn m4(_: ());
    |
    = 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[E0658]: rust-call ABI is subject to change
   --> $DIR/feature-gate-abi.rs:29:12
@@ -58,6 +64,7 @@ LL |     extern "rust-call" fn dm4(_: ()) {}
    |
    = 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[E0658]: intrinsics are subject to change
   --> $DIR/feature-gate-abi.rs:36:12
@@ -66,6 +73,7 @@ LL |     extern "rust-intrinsic" fn m1() {}
    |            ^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(intrinsics)]` 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]: platform intrinsics are experimental and possibly buggy
   --> $DIR/feature-gate-abi.rs:38:12
@@ -75,6 +83,7 @@ LL |     extern "platform-intrinsic" fn m2() {}
    |
    = note: see issue #27731 <https://github.com/rust-lang/rust/issues/27731> for more information
    = help: add `#![feature(platform_intrinsics)]` 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]: rust-call ABI is subject to change
   --> $DIR/feature-gate-abi.rs:40:12
@@ -84,6 +93,7 @@ LL |     extern "rust-call" fn m4(_: ()) {}
    |
    = 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[E0658]: intrinsics are subject to change
   --> $DIR/feature-gate-abi.rs:45:12
@@ -92,6 +102,7 @@ LL |     extern "rust-intrinsic" fn im1() {}
    |            ^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(intrinsics)]` 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]: platform intrinsics are experimental and possibly buggy
   --> $DIR/feature-gate-abi.rs:47:12
@@ -101,6 +112,7 @@ LL |     extern "platform-intrinsic" fn im2() {}
    |
    = note: see issue #27731 <https://github.com/rust-lang/rust/issues/27731> for more information
    = help: add `#![feature(platform_intrinsics)]` 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]: rust-call ABI is subject to change
   --> $DIR/feature-gate-abi.rs:49:12
@@ -110,6 +122,7 @@ LL |     extern "rust-call" fn im4(_: ()) {}
    |
    = 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[E0658]: intrinsics are subject to change
   --> $DIR/feature-gate-abi.rs:53:18
@@ -118,6 +131,7 @@ LL | type A1 = extern "rust-intrinsic" fn();
    |                  ^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(intrinsics)]` 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]: platform intrinsics are experimental and possibly buggy
   --> $DIR/feature-gate-abi.rs:54:18
@@ -127,6 +141,7 @@ LL | type A2 = extern "platform-intrinsic" fn();
    |
    = note: see issue #27731 <https://github.com/rust-lang/rust/issues/27731> for more information
    = help: add `#![feature(platform_intrinsics)]` 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]: rust-call ABI is subject to change
   --> $DIR/feature-gate-abi.rs:55:18
@@ -136,6 +151,7 @@ LL | type A4 = extern "rust-call" fn(_: ());
    |
    = 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[E0658]: intrinsics are subject to change
   --> $DIR/feature-gate-abi.rs:58:8
@@ -144,6 +160,7 @@ LL | extern "rust-intrinsic" {}
    |        ^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(intrinsics)]` 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]: platform intrinsics are experimental and possibly buggy
   --> $DIR/feature-gate-abi.rs:59:8
@@ -153,6 +170,7 @@ LL | extern "platform-intrinsic" {}
    |
    = note: see issue #27731 <https://github.com/rust-lang/rust/issues/27731> for more information
    = help: add `#![feature(platform_intrinsics)]` 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]: rust-call ABI is subject to change
   --> $DIR/feature-gate-abi.rs:60:8
@@ -162,6 +180,7 @@ LL | extern "rust-call" {}
    |
    = 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: intrinsic must be in `extern "rust-intrinsic" { ... }` block
   --> $DIR/feature-gate-abi.rs:23:32
diff --git a/tests/ui/feature-gates/feature-gate-abi_amdgpu_kernel.stderr b/tests/ui/feature-gates/feature-gate-abi_amdgpu_kernel.stderr
index c89ab7bae11..c5ae52c789b 100644
--- a/tests/ui/feature-gates/feature-gate-abi_amdgpu_kernel.stderr
+++ b/tests/ui/feature-gates/feature-gate-abi_amdgpu_kernel.stderr
@@ -6,6 +6,7 @@ LL | extern "amdgpu-kernel" fn fu() {}
    |
    = note: see issue #51575 <https://github.com/rust-lang/rust/issues/51575> for more information
    = help: add `#![feature(abi_amdgpu_kernel)]` 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]: amdgpu-kernel ABI is experimental and subject to change
   --> $DIR/feature-gate-abi_amdgpu_kernel.rs:11:12
@@ -15,6 +16,7 @@ LL |     extern "amdgpu-kernel" fn mu();
    |
    = note: see issue #51575 <https://github.com/rust-lang/rust/issues/51575> for more information
    = help: add `#![feature(abi_amdgpu_kernel)]` 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]: amdgpu-kernel ABI is experimental and subject to change
   --> $DIR/feature-gate-abi_amdgpu_kernel.rs:12:12
@@ -24,6 +26,7 @@ LL |     extern "amdgpu-kernel" fn dmu() {}
    |
    = note: see issue #51575 <https://github.com/rust-lang/rust/issues/51575> for more information
    = help: add `#![feature(abi_amdgpu_kernel)]` 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]: amdgpu-kernel ABI is experimental and subject to change
   --> $DIR/feature-gate-abi_amdgpu_kernel.rs:18:12
@@ -33,6 +36,7 @@ LL |     extern "amdgpu-kernel" fn mu() {}
    |
    = note: see issue #51575 <https://github.com/rust-lang/rust/issues/51575> for more information
    = help: add `#![feature(abi_amdgpu_kernel)]` 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]: amdgpu-kernel ABI is experimental and subject to change
   --> $DIR/feature-gate-abi_amdgpu_kernel.rs:23:12
@@ -42,6 +46,7 @@ LL |     extern "amdgpu-kernel" fn imu() {}
    |
    = note: see issue #51575 <https://github.com/rust-lang/rust/issues/51575> for more information
    = help: add `#![feature(abi_amdgpu_kernel)]` 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]: amdgpu-kernel ABI is experimental and subject to change
   --> $DIR/feature-gate-abi_amdgpu_kernel.rs:27:19
@@ -51,6 +56,7 @@ LL | type TAU = extern "amdgpu-kernel" fn();
    |
    = note: see issue #51575 <https://github.com/rust-lang/rust/issues/51575> for more information
    = help: add `#![feature(abi_amdgpu_kernel)]` 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]: amdgpu-kernel ABI is experimental and subject to change
   --> $DIR/feature-gate-abi_amdgpu_kernel.rs:29:8
@@ -60,6 +66,7 @@ LL | extern "amdgpu-kernel" {}
    |
    = note: see issue #51575 <https://github.com/rust-lang/rust/issues/51575> for more information
    = help: add `#![feature(abi_amdgpu_kernel)]` 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[E0570]: `"amdgpu-kernel"` is not a supported ABI for the current target
   --> $DIR/feature-gate-abi_amdgpu_kernel.rs:29:1
diff --git a/tests/ui/feature-gates/feature-gate-abi_ptx.stderr b/tests/ui/feature-gates/feature-gate-abi_ptx.stderr
index 40782d361ee..22b493e577d 100644
--- a/tests/ui/feature-gates/feature-gate-abi_ptx.stderr
+++ b/tests/ui/feature-gates/feature-gate-abi_ptx.stderr
@@ -6,6 +6,7 @@ LL | extern "ptx-kernel" fn fu() {}
    |
    = note: see issue #38788 <https://github.com/rust-lang/rust/issues/38788> for more information
    = help: add `#![feature(abi_ptx)]` 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]: PTX ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi_ptx.rs:11:12
@@ -15,6 +16,7 @@ LL |     extern "ptx-kernel" fn mu();
    |
    = note: see issue #38788 <https://github.com/rust-lang/rust/issues/38788> for more information
    = help: add `#![feature(abi_ptx)]` 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]: PTX ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi_ptx.rs:12:12
@@ -24,6 +26,7 @@ LL |     extern "ptx-kernel" fn dmu() {}
    |
    = note: see issue #38788 <https://github.com/rust-lang/rust/issues/38788> for more information
    = help: add `#![feature(abi_ptx)]` 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]: PTX ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi_ptx.rs:17:12
@@ -33,6 +36,7 @@ LL |     extern "ptx-kernel" fn mu() {}
    |
    = note: see issue #38788 <https://github.com/rust-lang/rust/issues/38788> for more information
    = help: add `#![feature(abi_ptx)]` 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]: PTX ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi_ptx.rs:21:12
@@ -42,6 +46,7 @@ LL |     extern "ptx-kernel" fn imu() {}
    |
    = note: see issue #38788 <https://github.com/rust-lang/rust/issues/38788> for more information
    = help: add `#![feature(abi_ptx)]` 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]: PTX ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi_ptx.rs:24:19
@@ -51,6 +56,7 @@ LL | type TAU = extern "ptx-kernel" fn();
    |
    = note: see issue #38788 <https://github.com/rust-lang/rust/issues/38788> for more information
    = help: add `#![feature(abi_ptx)]` 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]: PTX ABIs are experimental and subject to change
   --> $DIR/feature-gate-abi_ptx.rs:26:8
@@ -60,6 +66,7 @@ LL | extern "ptx-kernel" {}
    |
    = note: see issue #38788 <https://github.com/rust-lang/rust/issues/38788> for more information
    = help: add `#![feature(abi_ptx)]` 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 7 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-abi_unadjusted.stderr b/tests/ui/feature-gates/feature-gate-abi_unadjusted.stderr
index 3cc7b100db2..1d5fb11cd3d 100644
--- a/tests/ui/feature-gates/feature-gate-abi_unadjusted.stderr
+++ b/tests/ui/feature-gates/feature-gate-abi_unadjusted.stderr
@@ -5,6 +5,7 @@ LL | extern "unadjusted" fn foo() {
    |        ^^^^^^^^^^^^
    |
    = help: add `#![feature(abi_unadjusted)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-alloc-error-handler.stderr b/tests/ui/feature-gates/feature-gate-alloc-error-handler.stderr
index 1f22c8c5851..2ebd7cd9b02 100644
--- a/tests/ui/feature-gates/feature-gate-alloc-error-handler.stderr
+++ b/tests/ui/feature-gates/feature-gate-alloc-error-handler.stderr
@@ -6,6 +6,7 @@ LL | #[alloc_error_handler]
    |
    = note: see issue #51540 <https://github.com/rust-lang/rust/issues/51540> for more information
    = help: add `#![feature(alloc_error_handler)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-allocator_internals.stderr b/tests/ui/feature-gates/feature-gate-allocator_internals.stderr
index 66a1c1be3f4..905c0252484 100644
--- a/tests/ui/feature-gates/feature-gate-allocator_internals.stderr
+++ b/tests/ui/feature-gates/feature-gate-allocator_internals.stderr
@@ -5,6 +5,7 @@ LL | #![default_lib_allocator]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(allocator_internals)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-allow-internal-unsafe-nested-macro.stderr b/tests/ui/feature-gates/feature-gate-allow-internal-unsafe-nested-macro.stderr
index c2d29db6866..7a0dcb08435 100644
--- a/tests/ui/feature-gates/feature-gate-allow-internal-unsafe-nested-macro.stderr
+++ b/tests/ui/feature-gates/feature-gate-allow-internal-unsafe-nested-macro.stderr
@@ -8,6 +8,7 @@ LL | bar!();
    | ------ in this macro invocation
    |
    = help: add `#![feature(allow_internal_unsafe)]` 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: this error originates in the macro `bar` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: aborting due to 1 previous error
diff --git a/tests/ui/feature-gates/feature-gate-allow-internal-unstable-nested-macro.stderr b/tests/ui/feature-gates/feature-gate-allow-internal-unstable-nested-macro.stderr
index c0ab67025b2..4aacfebd6b1 100644
--- a/tests/ui/feature-gates/feature-gate-allow-internal-unstable-nested-macro.stderr
+++ b/tests/ui/feature-gates/feature-gate-allow-internal-unstable-nested-macro.stderr
@@ -8,6 +8,7 @@ LL | bar!();
    | ------ in this macro invocation
    |
    = help: add `#![feature(allow_internal_unstable)]` 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: this error originates in the macro `bar` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: aborting due to 1 previous error
diff --git a/tests/ui/feature-gates/feature-gate-allow-internal-unstable-struct.stderr b/tests/ui/feature-gates/feature-gate-allow-internal-unstable-struct.stderr
index df7773ba4fb..28f1a0d6ed5 100644
--- a/tests/ui/feature-gates/feature-gate-allow-internal-unstable-struct.stderr
+++ b/tests/ui/feature-gates/feature-gate-allow-internal-unstable-struct.stderr
@@ -5,6 +5,7 @@ LL | #[allow_internal_unstable()]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(allow_internal_unstable)]` 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: attribute should be applied to a macro
   --> $DIR/feature-gate-allow-internal-unstable-struct.rs:4:1
diff --git a/tests/ui/feature-gates/feature-gate-allow-internal-unstable.stderr b/tests/ui/feature-gates/feature-gate-allow-internal-unstable.stderr
index cb6cf4699fd..3e3ecc1e5ba 100644
--- a/tests/ui/feature-gates/feature-gate-allow-internal-unstable.stderr
+++ b/tests/ui/feature-gates/feature-gate-allow-internal-unstable.stderr
@@ -5,6 +5,7 @@ LL | #[allow_internal_unstable()]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(allow_internal_unstable)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-arbitrary-self-types.stderr b/tests/ui/feature-gates/feature-gate-arbitrary-self-types.stderr
index a1c69a5afb6..7f0e02c91f8 100644
--- a/tests/ui/feature-gates/feature-gate-arbitrary-self-types.stderr
+++ b/tests/ui/feature-gates/feature-gate-arbitrary-self-types.stderr
@@ -6,6 +6,7 @@ LL |     fn foo(self: Ptr<Self>) {}
    |
    = note: see issue #44874 <https://github.com/rust-lang/rust/issues/44874> for more information
    = help: add `#![feature(arbitrary_self_types)]` 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: consider changing to `self`, `&self`, `&mut self`, `self: Box<Self>`, `self: Rc<Self>`, `self: Arc<Self>`, or `self: Pin<P>` (where P is one of the previous types except `Self`)
 
 error[E0658]: `Box<Ptr<Bar>>` cannot be used as the type of `self` without the `arbitrary_self_types` feature
@@ -16,6 +17,7 @@ LL |     fn bar(self: Box<Ptr<Self>>) {}
    |
    = note: see issue #44874 <https://github.com/rust-lang/rust/issues/44874> for more information
    = help: add `#![feature(arbitrary_self_types)]` 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: consider changing to `self`, `&self`, `&mut self`, `self: Box<Self>`, `self: Rc<Self>`, `self: Arc<Self>`, or `self: Pin<P>` (where P is one of the previous types except `Self`)
 
 error[E0658]: `Ptr<Self>` cannot be used as the type of `self` without the `arbitrary_self_types` feature
@@ -26,6 +28,7 @@ LL |     fn foo(self: Ptr<Self>);
    |
    = note: see issue #44874 <https://github.com/rust-lang/rust/issues/44874> for more information
    = help: add `#![feature(arbitrary_self_types)]` 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: consider changing to `self`, `&self`, `&mut self`, `self: Box<Self>`, `self: Rc<Self>`, `self: Arc<Self>`, or `self: Pin<P>` (where P is one of the previous types except `Self`)
 
 error: aborting due to 3 previous errors
diff --git a/tests/ui/feature-gates/feature-gate-arbitrary_self_types-raw-pointer.stderr b/tests/ui/feature-gates/feature-gate-arbitrary_self_types-raw-pointer.stderr
index a9f611b8745..711025ff93b 100644
--- a/tests/ui/feature-gates/feature-gate-arbitrary_self_types-raw-pointer.stderr
+++ b/tests/ui/feature-gates/feature-gate-arbitrary_self_types-raw-pointer.stderr
@@ -6,6 +6,7 @@ LL |     fn foo(self: *const Self) {}
    |
    = note: see issue #44874 <https://github.com/rust-lang/rust/issues/44874> for more information
    = help: add `#![feature(arbitrary_self_types)]` 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: consider changing to `self`, `&self`, `&mut self`, `self: Box<Self>`, `self: Rc<Self>`, `self: Arc<Self>`, or `self: Pin<P>` (where P is one of the previous types except `Self`)
 
 error[E0658]: `*const ()` cannot be used as the type of `self` without the `arbitrary_self_types` feature
@@ -16,6 +17,7 @@ LL |     fn bar(self: *const Self) {}
    |
    = note: see issue #44874 <https://github.com/rust-lang/rust/issues/44874> for more information
    = help: add `#![feature(arbitrary_self_types)]` 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: consider changing to `self`, `&self`, `&mut self`, `self: Box<Self>`, `self: Rc<Self>`, `self: Arc<Self>`, or `self: Pin<P>` (where P is one of the previous types except `Self`)
 
 error[E0658]: `*const Self` cannot be used as the type of `self` without the `arbitrary_self_types` feature
@@ -26,6 +28,7 @@ LL |     fn bar(self: *const Self);
    |
    = note: see issue #44874 <https://github.com/rust-lang/rust/issues/44874> for more information
    = help: add `#![feature(arbitrary_self_types)]` 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: consider changing to `self`, `&self`, `&mut self`, `self: Box<Self>`, `self: Rc<Self>`, `self: Arc<Self>`, or `self: Pin<P>` (where P is one of the previous types except `Self`)
 
 error: aborting due to 3 previous errors
diff --git a/tests/ui/feature-gates/feature-gate-asm_const.stderr b/tests/ui/feature-gates/feature-gate-asm_const.stderr
index c248374ec49..4f83fee6759 100644
--- a/tests/ui/feature-gates/feature-gate-asm_const.stderr
+++ b/tests/ui/feature-gates/feature-gate-asm_const.stderr
@@ -6,6 +6,7 @@ LL |     asm!("mov eax, {}", const N + 1);
    |
    = note: see issue #93332 <https://github.com/rust-lang/rust/issues/93332> for more information
    = help: add `#![feature(asm_const)]` 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 operands for inline assembly are unstable
   --> $DIR/feature-gate-asm_const.rs:13:29
@@ -15,6 +16,7 @@ LL |         asm!("mov eax, {}", const 123);
    |
    = note: see issue #93332 <https://github.com/rust-lang/rust/issues/93332> for more information
    = help: add `#![feature(asm_const)]` 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 2 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-asm_experimental_arch.stderr b/tests/ui/feature-gates/feature-gate-asm_experimental_arch.stderr
index 9db088475a1..d930429779c 100644
--- a/tests/ui/feature-gates/feature-gate-asm_experimental_arch.stderr
+++ b/tests/ui/feature-gates/feature-gate-asm_experimental_arch.stderr
@@ -6,6 +6,7 @@ LL |     asm!("");
    |
    = note: see issue #93335 <https://github.com/rust-lang/rust/issues/93335> for more information
    = help: add `#![feature(asm_experimental_arch)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-asm_unwind.stderr b/tests/ui/feature-gates/feature-gate-asm_unwind.stderr
index eeabf7a5b0c..bae263ee3a0 100644
--- a/tests/ui/feature-gates/feature-gate-asm_unwind.stderr
+++ b/tests/ui/feature-gates/feature-gate-asm_unwind.stderr
@@ -6,6 +6,7 @@ LL |         asm!("", options(may_unwind));
    |
    = note: see issue #93334 <https://github.com/rust-lang/rust/issues/93334> for more information
    = help: add `#![feature(asm_unwind)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-assoc-type-defaults.stderr b/tests/ui/feature-gates/feature-gate-assoc-type-defaults.stderr
index 2ebaf40dcf6..d7f4e6da782 100644
--- a/tests/ui/feature-gates/feature-gate-assoc-type-defaults.stderr
+++ b/tests/ui/feature-gates/feature-gate-assoc-type-defaults.stderr
@@ -6,6 +6,7 @@ LL |     type Bar = u8;
    |
    = note: see issue #29661 <https://github.com/rust-lang/rust/issues/29661> for more information
    = help: add `#![feature(associated_type_defaults)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-associated_const_equality.stderr b/tests/ui/feature-gates/feature-gate-associated_const_equality.stderr
index a5f92b44c41..5a0fb69b6ba 100644
--- a/tests/ui/feature-gates/feature-gate-associated_const_equality.stderr
+++ b/tests/ui/feature-gates/feature-gate-associated_const_equality.stderr
@@ -6,6 +6,7 @@ LL | fn foo<A: TraitWAssocConst<A=32>>() {}
    |
    = note: see issue #92827 <https://github.com/rust-lang/rust/issues/92827> for more information
    = help: add `#![feature(associated_const_equality)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-associated_type_bounds.stderr b/tests/ui/feature-gates/feature-gate-associated_type_bounds.stderr
index 4a643d31259..efab91f25f0 100644
--- a/tests/ui/feature-gates/feature-gate-associated_type_bounds.stderr
+++ b/tests/ui/feature-gates/feature-gate-associated_type_bounds.stderr
@@ -6,6 +6,7 @@ LL |     type A: Iterator<Item: Copy>;
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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]: associated type bounds are unstable
   --> $DIR/feature-gate-associated_type_bounds.rs:16:22
@@ -15,6 +16,7 @@ LL |     type B: Iterator<Item: 'static>;
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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]: associated type bounds are unstable
   --> $DIR/feature-gate-associated_type_bounds.rs:20:20
@@ -24,6 +26,7 @@ LL | struct _St1<T: Tr1<As1: Tr2>> {
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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]: associated type bounds are unstable
   --> $DIR/feature-gate-associated_type_bounds.rs:27:18
@@ -33,6 +36,7 @@ LL | enum _En1<T: Tr1<As1: Tr2>> {
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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]: associated type bounds are unstable
   --> $DIR/feature-gate-associated_type_bounds.rs:34:19
@@ -42,6 +46,7 @@ LL | union _Un1<T: Tr1<As1: Tr2>> {
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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]: associated type bounds are unstable
   --> $DIR/feature-gate-associated_type_bounds.rs:41:37
@@ -51,6 +56,7 @@ LL | type _TaWhere1<T> where T: Iterator<Item: Copy> = T;
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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]: associated type bounds are unstable
   --> $DIR/feature-gate-associated_type_bounds.rs:44:22
@@ -60,6 +66,7 @@ LL | fn _apit(_: impl Tr1<As1: Copy>) {}
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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]: associated type bounds are unstable
   --> $DIR/feature-gate-associated_type_bounds.rs:46:26
@@ -69,6 +76,7 @@ LL | fn _apit_dyn(_: &dyn Tr1<As1: Copy>) {}
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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]: associated type bounds are unstable
   --> $DIR/feature-gate-associated_type_bounds.rs:49:24
@@ -78,6 +86,7 @@ LL | fn _rpit() -> impl Tr1<As1: Copy> { S1 }
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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]: associated type bounds are unstable
   --> $DIR/feature-gate-associated_type_bounds.rs:52:31
@@ -87,6 +96,7 @@ LL | fn _rpit_dyn() -> Box<dyn Tr1<As1: Copy>> { Box::new(S1) }
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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]: associated type bounds are unstable
   --> $DIR/feature-gate-associated_type_bounds.rs:55:23
@@ -96,6 +106,7 @@ LL | const _cdef: impl Tr1<As1: Copy> = S1;
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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]: associated type bounds are unstable
   --> $DIR/feature-gate-associated_type_bounds.rs:61:24
@@ -105,6 +116,7 @@ LL | static _sdef: impl Tr1<As1: Copy> = S1;
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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]: associated type bounds are unstable
   --> $DIR/feature-gate-associated_type_bounds.rs:68:21
@@ -114,6 +126,7 @@ LL |     let _: impl Tr1<As1: Copy> = S1;
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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[E0562]: `impl Trait` is not allowed in const types
   --> $DIR/feature-gate-associated_type_bounds.rs:55:14
diff --git a/tests/ui/feature-gates/feature-gate-auto-traits.stderr b/tests/ui/feature-gates/feature-gate-auto-traits.stderr
index e015418161e..139229ca809 100644
--- a/tests/ui/feature-gates/feature-gate-auto-traits.stderr
+++ b/tests/ui/feature-gates/feature-gate-auto-traits.stderr
@@ -6,6 +6,7 @@ LL | auto trait AutoDummyTrait {}
    |
    = note: see issue #13231 <https://github.com/rust-lang/rust/issues/13231> for more information
    = help: add `#![feature(auto_traits)]` 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]: negative trait bounds are not yet fully implemented; use marker types for now
   --> $DIR/feature-gate-auto-traits.rs:9:6
@@ -15,6 +16,7 @@ LL | impl !AutoDummyTrait for DummyStruct {}
    |
    = note: see issue #68318 <https://github.com/rust-lang/rust/issues/68318> for more information
    = help: add `#![feature(negative_impls)]` 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 2 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-box_patterns.stderr b/tests/ui/feature-gates/feature-gate-box_patterns.stderr
index da15f698b75..fb61b2b1810 100644
--- a/tests/ui/feature-gates/feature-gate-box_patterns.stderr
+++ b/tests/ui/feature-gates/feature-gate-box_patterns.stderr
@@ -6,6 +6,7 @@ LL |     let box x = Box::new('c');
    |
    = note: see issue #29641 <https://github.com/rust-lang/rust/issues/29641> for more information
    = help: add `#![feature(box_patterns)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-builtin_syntax.stderr b/tests/ui/feature-gates/feature-gate-builtin_syntax.stderr
index 6601d4cb417..297363b3de7 100644
--- a/tests/ui/feature-gates/feature-gate-builtin_syntax.stderr
+++ b/tests/ui/feature-gates/feature-gate-builtin_syntax.stderr
@@ -6,6 +6,7 @@ LL |     builtin # offset_of(Foo, v);
    |
    = note: see issue #110680 <https://github.com/rust-lang/rust/issues/110680> for more information
    = help: add `#![feature(builtin_syntax)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-c_variadic.stderr b/tests/ui/feature-gates/feature-gate-c_variadic.stderr
index a439f297ba3..1b6a8c92af5 100644
--- a/tests/ui/feature-gates/feature-gate-c_variadic.stderr
+++ b/tests/ui/feature-gates/feature-gate-c_variadic.stderr
@@ -6,6 +6,7 @@ LL | pub unsafe extern "C" fn test(_: i32, ap: ...) { }
    |
    = note: see issue #44930 <https://github.com/rust-lang/rust/issues/44930> for more information
    = help: add `#![feature(c_variadic)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-cfg-relocation-model.stderr b/tests/ui/feature-gates/feature-gate-cfg-relocation-model.stderr
index bd43e190513..e107e49b088 100644
--- a/tests/ui/feature-gates/feature-gate-cfg-relocation-model.stderr
+++ b/tests/ui/feature-gates/feature-gate-cfg-relocation-model.stderr
@@ -6,6 +6,7 @@ LL | #[cfg(relocation_model = "pic")]
    |
    = note: see issue #114929 <https://github.com/rust-lang/rust/issues/114929> for more information
    = help: add `#![feature(cfg_relocation_model)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-cfg-sanitizer_cfi.stderr b/tests/ui/feature-gates/feature-gate-cfg-sanitizer_cfi.stderr
index 8c2a8411c7b..0d49635b2e6 100644
--- a/tests/ui/feature-gates/feature-gate-cfg-sanitizer_cfi.stderr
+++ b/tests/ui/feature-gates/feature-gate-cfg-sanitizer_cfi.stderr
@@ -6,6 +6,7 @@ LL | #[cfg(sanitizer_cfi_generalize_pointers)]
    |
    = note: see issue #89653 <https://github.com/rust-lang/rust/issues/89653> for more information
    = help: add `#![feature(cfg_sanitizer_cfi)]` 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]: `cfg(sanitizer_cfi_normalize_integers)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-sanitizer_cfi.rs:5:7
@@ -15,6 +16,7 @@ LL | #[cfg(sanitizer_cfi_normalize_integers)]
    |
    = note: see issue #89653 <https://github.com/rust-lang/rust/issues/89653> for more information
    = help: add `#![feature(cfg_sanitizer_cfi)]` 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 2 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-cfg-target-abi.stderr b/tests/ui/feature-gates/feature-gate-cfg-target-abi.stderr
index 013705d4886..4829f8572cc 100644
--- a/tests/ui/feature-gates/feature-gate-cfg-target-abi.stderr
+++ b/tests/ui/feature-gates/feature-gate-cfg-target-abi.stderr
@@ -6,6 +6,7 @@ LL | #[cfg(target_abi = "x")]
    |
    = note: see issue #80970 <https://github.com/rust-lang/rust/issues/80970> for more information
    = help: add `#![feature(cfg_target_abi)]` 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]: `cfg(target_abi)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-target-abi.rs:4:12
@@ -15,6 +16,7 @@ LL | #[cfg_attr(target_abi = "x", x)]
    |
    = note: see issue #80970 <https://github.com/rust-lang/rust/issues/80970> for more information
    = help: add `#![feature(cfg_target_abi)]` 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]: `cfg(target_abi)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-target-abi.rs:7:19
@@ -24,6 +26,7 @@ LL | #[cfg(not(any(all(target_abi = "x"))))]
    |
    = note: see issue #80970 <https://github.com/rust-lang/rust/issues/80970> for more information
    = help: add `#![feature(cfg_target_abi)]` 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]: `cfg(target_abi)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-target-abi.rs:11:10
@@ -33,6 +36,7 @@ LL |     cfg!(target_abi = "x");
    |
    = note: see issue #80970 <https://github.com/rust-lang/rust/issues/80970> for more information
    = help: add `#![feature(cfg_target_abi)]` 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 4 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-cfg-target-compact.stderr b/tests/ui/feature-gates/feature-gate-cfg-target-compact.stderr
index be6fe23ded1..1fd59651957 100644
--- a/tests/ui/feature-gates/feature-gate-cfg-target-compact.stderr
+++ b/tests/ui/feature-gates/feature-gate-cfg-target-compact.stderr
@@ -6,6 +6,7 @@ LL | #[cfg(target(os = "x"))]
    |
    = note: see issue #96901 <https://github.com/rust-lang/rust/issues/96901> for more information
    = help: add `#![feature(cfg_target_compact)]` 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]: compact `cfg(target(..))` is experimental and subject to change
   --> $DIR/feature-gate-cfg-target-compact.rs:4:12
@@ -15,6 +16,7 @@ LL | #[cfg_attr(target(os = "x"), x)]
    |
    = note: see issue #96901 <https://github.com/rust-lang/rust/issues/96901> for more information
    = help: add `#![feature(cfg_target_compact)]` 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]: compact `cfg(target(..))` is experimental and subject to change
   --> $DIR/feature-gate-cfg-target-compact.rs:7:19
@@ -24,6 +26,7 @@ LL | #[cfg(not(any(all(target(os = "x")))))]
    |
    = note: see issue #96901 <https://github.com/rust-lang/rust/issues/96901> for more information
    = help: add `#![feature(cfg_target_compact)]` 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]: compact `cfg(target(..))` is experimental and subject to change
   --> $DIR/feature-gate-cfg-target-compact.rs:11:10
@@ -33,6 +36,7 @@ LL |     cfg!(target(os = "x"));
    |
    = note: see issue #96901 <https://github.com/rust-lang/rust/issues/96901> for more information
    = help: add `#![feature(cfg_target_compact)]` 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 4 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-cfg-target-has-atomic-equal-alignment.stderr b/tests/ui/feature-gates/feature-gate-cfg-target-has-atomic-equal-alignment.stderr
index 8ad3b034aa5..8d5d232ccc4 100644
--- a/tests/ui/feature-gates/feature-gate-cfg-target-has-atomic-equal-alignment.stderr
+++ b/tests/ui/feature-gates/feature-gate-cfg-target-has-atomic-equal-alignment.stderr
@@ -6,6 +6,7 @@ LL |     cfg!(target_has_atomic_equal_alignment = "8");
    |
    = note: see issue #93822 <https://github.com/rust-lang/rust/issues/93822> for more information
    = help: add `#![feature(cfg_target_has_atomic_equal_alignment)]` 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]: `cfg(target_has_atomic_equal_alignment)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-target-has-atomic-equal-alignment.rs:4:10
@@ -15,6 +16,7 @@ LL |     cfg!(target_has_atomic_equal_alignment = "16");
    |
    = note: see issue #93822 <https://github.com/rust-lang/rust/issues/93822> for more information
    = help: add `#![feature(cfg_target_has_atomic_equal_alignment)]` 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]: `cfg(target_has_atomic_equal_alignment)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-target-has-atomic-equal-alignment.rs:6:10
@@ -24,6 +26,7 @@ LL |     cfg!(target_has_atomic_equal_alignment = "32");
    |
    = note: see issue #93822 <https://github.com/rust-lang/rust/issues/93822> for more information
    = help: add `#![feature(cfg_target_has_atomic_equal_alignment)]` 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]: `cfg(target_has_atomic_equal_alignment)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-target-has-atomic-equal-alignment.rs:8:10
@@ -33,6 +36,7 @@ LL |     cfg!(target_has_atomic_equal_alignment = "64");
    |
    = note: see issue #93822 <https://github.com/rust-lang/rust/issues/93822> for more information
    = help: add `#![feature(cfg_target_has_atomic_equal_alignment)]` 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]: `cfg(target_has_atomic_equal_alignment)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-target-has-atomic-equal-alignment.rs:10:10
@@ -42,6 +46,7 @@ LL |     cfg!(target_has_atomic_equal_alignment = "128");
    |
    = note: see issue #93822 <https://github.com/rust-lang/rust/issues/93822> for more information
    = help: add `#![feature(cfg_target_has_atomic_equal_alignment)]` 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]: `cfg(target_has_atomic_equal_alignment)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-target-has-atomic-equal-alignment.rs:12:10
@@ -51,6 +56,7 @@ LL |     cfg!(target_has_atomic_equal_alignment = "ptr");
    |
    = note: see issue #93822 <https://github.com/rust-lang/rust/issues/93822> for more information
    = help: add `#![feature(cfg_target_has_atomic_equal_alignment)]` 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 6 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-cfg-target-has-atomic.stderr b/tests/ui/feature-gates/feature-gate-cfg-target-has-atomic.stderr
index b9e6830a9f0..f253ec3bef1 100644
--- a/tests/ui/feature-gates/feature-gate-cfg-target-has-atomic.stderr
+++ b/tests/ui/feature-gates/feature-gate-cfg-target-has-atomic.stderr
@@ -6,6 +6,7 @@ LL |     cfg!(target_has_atomic_load_store = "8");
    |
    = note: see issue #94039 <https://github.com/rust-lang/rust/issues/94039> for more information
    = help: add `#![feature(cfg_target_has_atomic)]` 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]: `cfg(target_has_atomic_load_store)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-target-has-atomic.rs:4:10
@@ -15,6 +16,7 @@ LL |     cfg!(target_has_atomic_load_store = "16");
    |
    = note: see issue #94039 <https://github.com/rust-lang/rust/issues/94039> for more information
    = help: add `#![feature(cfg_target_has_atomic)]` 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]: `cfg(target_has_atomic_load_store)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-target-has-atomic.rs:6:10
@@ -24,6 +26,7 @@ LL |     cfg!(target_has_atomic_load_store = "32");
    |
    = note: see issue #94039 <https://github.com/rust-lang/rust/issues/94039> for more information
    = help: add `#![feature(cfg_target_has_atomic)]` 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]: `cfg(target_has_atomic_load_store)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-target-has-atomic.rs:8:10
@@ -33,6 +36,7 @@ LL |     cfg!(target_has_atomic_load_store = "64");
    |
    = note: see issue #94039 <https://github.com/rust-lang/rust/issues/94039> for more information
    = help: add `#![feature(cfg_target_has_atomic)]` 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]: `cfg(target_has_atomic_load_store)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-target-has-atomic.rs:10:10
@@ -42,6 +46,7 @@ LL |     cfg!(target_has_atomic_load_store = "128");
    |
    = note: see issue #94039 <https://github.com/rust-lang/rust/issues/94039> for more information
    = help: add `#![feature(cfg_target_has_atomic)]` 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]: `cfg(target_has_atomic_load_store)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-target-has-atomic.rs:12:10
@@ -51,6 +56,7 @@ LL |     cfg!(target_has_atomic_load_store = "ptr");
    |
    = note: see issue #94039 <https://github.com/rust-lang/rust/issues/94039> for more information
    = help: add `#![feature(cfg_target_has_atomic)]` 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 6 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-cfg-target-thread-local.stderr b/tests/ui/feature-gates/feature-gate-cfg-target-thread-local.stderr
index 3400808bb72..0e1fe5572a9 100644
--- a/tests/ui/feature-gates/feature-gate-cfg-target-thread-local.stderr
+++ b/tests/ui/feature-gates/feature-gate-cfg-target-thread-local.stderr
@@ -6,6 +6,7 @@ LL |     #[cfg_attr(target_thread_local, thread_local)]
    |
    = note: see issue #29594 <https://github.com/rust-lang/rust/issues/29594> for more information
    = help: add `#![feature(cfg_target_thread_local)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-cfg-version.stderr b/tests/ui/feature-gates/feature-gate-cfg-version.stderr
index ae899d409ec..c1c3e8e5897 100644
--- a/tests/ui/feature-gates/feature-gate-cfg-version.stderr
+++ b/tests/ui/feature-gates/feature-gate-cfg-version.stderr
@@ -6,6 +6,7 @@ LL | #[cfg(version(42))]
    |
    = note: see issue #64796 <https://github.com/rust-lang/rust/issues/64796> for more information
    = help: add `#![feature(cfg_version)]` 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: expected a version literal
   --> $DIR/feature-gate-cfg-version.rs:1:15
@@ -21,6 +22,7 @@ LL | #[cfg(version(1.20))]
    |
    = note: see issue #64796 <https://github.com/rust-lang/rust/issues/64796> for more information
    = help: add `#![feature(cfg_version)]` 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: expected a version literal
   --> $DIR/feature-gate-cfg-version.rs:4:15
@@ -36,6 +38,7 @@ LL | #[cfg(version("1.44"))]
    |
    = note: see issue #64796 <https://github.com/rust-lang/rust/issues/64796> for more information
    = help: add `#![feature(cfg_version)]` 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]: `cfg(version)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-version.rs:10:11
@@ -45,6 +48,7 @@ LL | #[cfg(not(version("1.44")))]
    |
    = note: see issue #64796 <https://github.com/rust-lang/rust/issues/64796> for more information
    = help: add `#![feature(cfg_version)]` 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]: `cfg(version)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-version.rs:14:7
@@ -54,6 +58,7 @@ LL | #[cfg(version("1.43", "1.44", "1.45"))]
    |
    = note: see issue #64796 <https://github.com/rust-lang/rust/issues/64796> for more information
    = help: add `#![feature(cfg_version)]` 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: expected single version literal
   --> $DIR/feature-gate-cfg-version.rs:14:7
@@ -69,6 +74,7 @@ LL | #[cfg(version(false))]
    |
    = note: see issue #64796 <https://github.com/rust-lang/rust/issues/64796> for more information
    = help: add `#![feature(cfg_version)]` 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: expected a version literal
   --> $DIR/feature-gate-cfg-version.rs:17:15
@@ -84,6 +90,7 @@ LL | #[cfg(version("foo"))]
    |
    = note: see issue #64796 <https://github.com/rust-lang/rust/issues/64796> for more information
    = help: add `#![feature(cfg_version)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: unknown version literal format, assuming it refers to a future version
   --> $DIR/feature-gate-cfg-version.rs:20:15
@@ -99,6 +106,7 @@ LL | #[cfg(version("999"))]
    |
    = note: see issue #64796 <https://github.com/rust-lang/rust/issues/64796> for more information
    = help: add `#![feature(cfg_version)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: unknown version literal format, assuming it refers to a future version
   --> $DIR/feature-gate-cfg-version.rs:23:15
@@ -114,6 +122,7 @@ LL | #[cfg(version("-1"))]
    |
    = note: see issue #64796 <https://github.com/rust-lang/rust/issues/64796> for more information
    = help: add `#![feature(cfg_version)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: unknown version literal format, assuming it refers to a future version
   --> $DIR/feature-gate-cfg-version.rs:26:15
@@ -129,6 +138,7 @@ LL | #[cfg(version("65536"))]
    |
    = note: see issue #64796 <https://github.com/rust-lang/rust/issues/64796> for more information
    = help: add `#![feature(cfg_version)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: unknown version literal format, assuming it refers to a future version
   --> $DIR/feature-gate-cfg-version.rs:29:15
@@ -144,6 +154,7 @@ LL | #[cfg(version("0"))]
    |
    = note: see issue #64796 <https://github.com/rust-lang/rust/issues/64796> for more information
    = help: add `#![feature(cfg_version)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: unknown version literal format, assuming it refers to a future version
   --> $DIR/feature-gate-cfg-version.rs:32:15
@@ -159,6 +170,7 @@ LL | #[cfg(version("1.0"))]
    |
    = note: see issue #64796 <https://github.com/rust-lang/rust/issues/64796> for more information
    = help: add `#![feature(cfg_version)]` 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]: `cfg(version)` is experimental and subject to change
   --> $DIR/feature-gate-cfg-version.rs:38:7
@@ -168,6 +180,7 @@ LL | #[cfg(version("1.65536.2"))]
    |
    = note: see issue #64796 <https://github.com/rust-lang/rust/issues/64796> for more information
    = help: add `#![feature(cfg_version)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: unknown version literal format, assuming it refers to a future version
   --> $DIR/feature-gate-cfg-version.rs:38:15
@@ -183,6 +196,7 @@ LL | #[cfg(version("1.20.0-stable"))]
    |
    = note: see issue #64796 <https://github.com/rust-lang/rust/issues/64796> for more information
    = help: add `#![feature(cfg_version)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: unknown version literal format, assuming it refers to a future version
   --> $DIR/feature-gate-cfg-version.rs:41:15
@@ -198,6 +212,7 @@ LL |     assert!(cfg!(version("1.42")));
    |
    = note: see issue #64796 <https://github.com/rust-lang/rust/issues/64796> for more information
    = help: add `#![feature(cfg_version)]` 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 19 previous errors; 7 warnings emitted
 
diff --git a/tests/ui/feature-gates/feature-gate-cfg_overflow_checks.stderr b/tests/ui/feature-gates/feature-gate-cfg_overflow_checks.stderr
index 22f9af8390d..d5c0cd5927a 100644
--- a/tests/ui/feature-gates/feature-gate-cfg_overflow_checks.stderr
+++ b/tests/ui/feature-gates/feature-gate-cfg_overflow_checks.stderr
@@ -6,6 +6,7 @@ LL | #[cfg(overflow_checks)]
    |
    = note: see issue #111466 <https://github.com/rust-lang/rust/issues/111466> for more information
    = help: add `#![feature(cfg_overflow_checks)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-cfg_sanitize.stderr b/tests/ui/feature-gates/feature-gate-cfg_sanitize.stderr
index b53fc3acdbc..da29b0c96a3 100644
--- a/tests/ui/feature-gates/feature-gate-cfg_sanitize.stderr
+++ b/tests/ui/feature-gates/feature-gate-cfg_sanitize.stderr
@@ -6,6 +6,7 @@ LL | #[cfg(not(sanitize = "thread"))]
    |
    = note: see issue #39699 <https://github.com/rust-lang/rust/issues/39699> for more information
    = help: add `#![feature(cfg_sanitize)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-cfi_encoding.stderr b/tests/ui/feature-gates/feature-gate-cfi_encoding.stderr
index 04b20649940..ae5efc0275f 100644
--- a/tests/ui/feature-gates/feature-gate-cfi_encoding.stderr
+++ b/tests/ui/feature-gates/feature-gate-cfi_encoding.stderr
@@ -6,6 +6,7 @@ LL | #[cfi_encoding = "3Bar"]
    |
    = note: see issue #89653 <https://github.com/rust-lang/rust/issues/89653> for more information
    = help: add `#![feature(cfi_encoding)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-closure_lifetime_binder.stderr b/tests/ui/feature-gates/feature-gate-closure_lifetime_binder.stderr
index aea5cfeed07..96e428fb9a3 100644
--- a/tests/ui/feature-gates/feature-gate-closure_lifetime_binder.stderr
+++ b/tests/ui/feature-gates/feature-gate-closure_lifetime_binder.stderr
@@ -6,6 +6,7 @@ LL |     for<> || -> () {};
    |
    = note: see issue #97362 <https://github.com/rust-lang/rust/issues/97362> for more information
    = help: add `#![feature(closure_lifetime_binder)]` 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: consider removing `for<...>`
 
 error[E0658]: `for<...>` binders for closures are experimental
@@ -16,6 +17,7 @@ LL |     for<'a> || -> () {};
    |
    = note: see issue #97362 <https://github.com/rust-lang/rust/issues/97362> for more information
    = help: add `#![feature(closure_lifetime_binder)]` 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: consider removing `for<...>`
 
 error[E0658]: `for<...>` binders for closures are experimental
@@ -26,6 +28,7 @@ LL |     for<'a, 'b> |_: &'a ()| -> () {};
    |
    = note: see issue #97362 <https://github.com/rust-lang/rust/issues/97362> for more information
    = help: add `#![feature(closure_lifetime_binder)]` 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: consider removing `for<...>`
 
 error: aborting due to 3 previous errors
diff --git a/tests/ui/feature-gates/feature-gate-closure_track_caller.stderr b/tests/ui/feature-gates/feature-gate-closure_track_caller.stderr
index d5ef5d09ed4..17b5e6016a4 100644
--- a/tests/ui/feature-gates/feature-gate-closure_track_caller.stderr
+++ b/tests/ui/feature-gates/feature-gate-closure_track_caller.stderr
@@ -6,6 +6,7 @@ LL |     let _closure = #[track_caller] || {};
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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]: `#[track_caller]` on closures is currently unstable
   --> $DIR/feature-gate-closure_track_caller.rs:7:22
@@ -15,6 +16,7 @@ LL |     let _coroutine = #[track_caller] || { yield; };
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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]: `#[track_caller]` on closures is currently unstable
   --> $DIR/feature-gate-closure_track_caller.rs:8:19
@@ -24,6 +26,7 @@ LL |     let _future = #[track_caller] async {};
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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
 
diff --git a/tests/ui/feature-gates/feature-gate-collapse_debuginfo.stderr b/tests/ui/feature-gates/feature-gate-collapse_debuginfo.stderr
index f0b8fd1f373..f361a76b4a7 100644
--- a/tests/ui/feature-gates/feature-gate-collapse_debuginfo.stderr
+++ b/tests/ui/feature-gates/feature-gate-collapse_debuginfo.stderr
@@ -6,6 +6,7 @@ LL | #[collapse_debuginfo]
    |
    = note: see issue #100758 <https://github.com/rust-lang/rust/issues/100758> for more information
    = help: add `#![feature(collapse_debuginfo)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-compiler-builtins.stderr b/tests/ui/feature-gates/feature-gate-compiler-builtins.stderr
index eadc4ddcb28..65137a442b0 100644
--- a/tests/ui/feature-gates/feature-gate-compiler-builtins.stderr
+++ b/tests/ui/feature-gates/feature-gate-compiler-builtins.stderr
@@ -5,6 +5,7 @@ LL | #![compiler_builtins]
    | ^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(compiler_builtins)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-concat_bytes.stderr b/tests/ui/feature-gates/feature-gate-concat_bytes.stderr
index 69b196335da..ed9692d3693 100644
--- a/tests/ui/feature-gates/feature-gate-concat_bytes.stderr
+++ b/tests/ui/feature-gates/feature-gate-concat_bytes.stderr
@@ -6,6 +6,7 @@ LL |     let a = concat_bytes!(b'A', b"BC");
    |
    = note: see issue #87555 <https://github.com/rust-lang/rust/issues/87555> for more information
    = help: add `#![feature(concat_bytes)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-concat_idents.stderr b/tests/ui/feature-gates/feature-gate-concat_idents.stderr
index 0454fd4945c..eaaef0f2539 100644
--- a/tests/ui/feature-gates/feature-gate-concat_idents.stderr
+++ b/tests/ui/feature-gates/feature-gate-concat_idents.stderr
@@ -6,6 +6,7 @@ LL |     let a = concat_idents!(X, Y_1);
    |
    = note: see issue #29599 <https://github.com/rust-lang/rust/issues/29599> for more information
    = help: add `#![feature(concat_idents)]` 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]: use of unstable library feature 'concat_idents': `concat_idents` is not stable enough for use and is subject to change
   --> $DIR/feature-gate-concat_idents.rs:6:13
@@ -15,6 +16,7 @@ LL |     let b = concat_idents!(X, Y_2);
    |
    = note: see issue #29599 <https://github.com/rust-lang/rust/issues/29599> for more information
    = help: add `#![feature(concat_idents)]` 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 2 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-concat_idents2.stderr b/tests/ui/feature-gates/feature-gate-concat_idents2.stderr
index 8663bc7ca7e..2fe786ff406 100644
--- a/tests/ui/feature-gates/feature-gate-concat_idents2.stderr
+++ b/tests/ui/feature-gates/feature-gate-concat_idents2.stderr
@@ -6,6 +6,7 @@ LL |     concat_idents!(a, b);
    |
    = note: see issue #29599 <https://github.com/rust-lang/rust/issues/29599> for more information
    = help: add `#![feature(concat_idents)]` 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[E0425]: cannot find value `ab` in this scope
   --> $DIR/feature-gate-concat_idents2.rs:2:5
diff --git a/tests/ui/feature-gates/feature-gate-concat_idents3.stderr b/tests/ui/feature-gates/feature-gate-concat_idents3.stderr
index 1316107a3dc..a7daa1f949f 100644
--- a/tests/ui/feature-gates/feature-gate-concat_idents3.stderr
+++ b/tests/ui/feature-gates/feature-gate-concat_idents3.stderr
@@ -6,6 +6,7 @@ LL |     assert_eq!(10, concat_idents!(X, Y_1));
    |
    = note: see issue #29599 <https://github.com/rust-lang/rust/issues/29599> for more information
    = help: add `#![feature(concat_idents)]` 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]: use of unstable library feature 'concat_idents': `concat_idents` is not stable enough for use and is subject to change
   --> $DIR/feature-gate-concat_idents3.rs:6:20
@@ -15,6 +16,7 @@ LL |     assert_eq!(20, concat_idents!(X, Y_2));
    |
    = note: see issue #29599 <https://github.com/rust-lang/rust/issues/29599> for more information
    = help: add `#![feature(concat_idents)]` 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 2 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-coroutines.e2024.stderr b/tests/ui/feature-gates/feature-gate-coroutines.e2024.stderr
index 2e529236ad8..1cef163cef5 100644
--- a/tests/ui/feature-gates/feature-gate-coroutines.e2024.stderr
+++ b/tests/ui/feature-gates/feature-gate-coroutines.e2024.stderr
@@ -6,6 +6,7 @@ LL |     yield true;
    |
    = note: see issue #43122 <https://github.com/rust-lang/rust/issues/43122> for more information
    = help: add `#![feature(coroutines)]` 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]: yield syntax is experimental
   --> $DIR/feature-gate-coroutines.rs:9:16
@@ -15,6 +16,7 @@ LL |     let _ = || yield true;
    |
    = note: see issue #43122 <https://github.com/rust-lang/rust/issues/43122> for more information
    = help: add `#![feature(coroutines)]` 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[E0627]: yield expression outside of coroutine literal
   --> $DIR/feature-gate-coroutines.rs:5:5
diff --git a/tests/ui/feature-gates/feature-gate-coroutines.none.stderr b/tests/ui/feature-gates/feature-gate-coroutines.none.stderr
index ab24805e467..403f0549aef 100644
--- a/tests/ui/feature-gates/feature-gate-coroutines.none.stderr
+++ b/tests/ui/feature-gates/feature-gate-coroutines.none.stderr
@@ -6,6 +6,7 @@ LL |     yield true;
    |
    = note: see issue #43122 <https://github.com/rust-lang/rust/issues/43122> for more information
    = help: add `#![feature(coroutines)]` 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]: yield syntax is experimental
   --> $DIR/feature-gate-coroutines.rs:9:16
@@ -15,6 +16,7 @@ LL |     let _ = || yield true;
    |
    = note: see issue #43122 <https://github.com/rust-lang/rust/issues/43122> for more information
    = help: add `#![feature(coroutines)]` 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]: yield syntax is experimental
   --> $DIR/feature-gate-coroutines.rs:16:5
@@ -24,6 +26,7 @@ LL |     yield;
    |
    = note: see issue #43122 <https://github.com/rust-lang/rust/issues/43122> for more information
    = help: add `#![feature(coroutines)]` 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]: yield syntax is experimental
   --> $DIR/feature-gate-coroutines.rs:17:5
@@ -33,6 +36,7 @@ LL |     yield 0;
    |
    = note: see issue #43122 <https://github.com/rust-lang/rust/issues/43122> for more information
    = help: add `#![feature(coroutines)]` 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]: yield syntax is experimental
   --> $DIR/feature-gate-coroutines.rs:5:5
@@ -42,6 +46,7 @@ LL |     yield true;
    |
    = note: see issue #43122 <https://github.com/rust-lang/rust/issues/43122> for more information
    = help: add `#![feature(coroutines)]` 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]: yield syntax is experimental
@@ -52,6 +57,7 @@ LL |     let _ = || yield true;
    |
    = note: see issue #43122 <https://github.com/rust-lang/rust/issues/43122> for more information
    = help: add `#![feature(coroutines)]` 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[E0627]: yield expression outside of coroutine literal
diff --git a/tests/ui/feature-gates/feature-gate-coverage-attribute.stderr b/tests/ui/feature-gates/feature-gate-coverage-attribute.stderr
index 0131a19a39d..00e0f0afbde 100644
--- a/tests/ui/feature-gates/feature-gate-coverage-attribute.stderr
+++ b/tests/ui/feature-gates/feature-gate-coverage-attribute.stderr
@@ -14,6 +14,7 @@ LL | #[coverage(off)]
    |
    = note: see issue #84605 <https://github.com/rust-lang/rust/issues/84605> for more information
    = help: add `#![feature(coverage_attribute)]` 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 2 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-custom_mir.stderr b/tests/ui/feature-gates/feature-gate-custom_mir.stderr
index f0f67adcca5..34899e5e66c 100644
--- a/tests/ui/feature-gates/feature-gate-custom_mir.stderr
+++ b/tests/ui/feature-gates/feature-gate-custom_mir.stderr
@@ -5,6 +5,7 @@ LL | #[custom_mir(dialect = "built")]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(custom_mir)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-custom_test_frameworks.stderr b/tests/ui/feature-gates/feature-gate-custom_test_frameworks.stderr
index b65b009a342..016be980d4d 100644
--- a/tests/ui/feature-gates/feature-gate-custom_test_frameworks.stderr
+++ b/tests/ui/feature-gates/feature-gate-custom_test_frameworks.stderr
@@ -6,6 +6,7 @@ LL | #[test_case]
    |
    = note: see issue #50297 <https://github.com/rust-lang/rust/issues/50297> for more information
    = help: add `#![feature(custom_test_frameworks)]` 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]: custom test frameworks are an unstable feature
   --> $DIR/feature-gate-custom_test_frameworks.rs:1:1
@@ -15,6 +16,7 @@ LL | #![test_runner(main)]
    |
    = note: see issue #50297 <https://github.com/rust-lang/rust/issues/50297> for more information
    = help: add `#![feature(custom_test_frameworks)]` 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 2 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-decl_macro.stderr b/tests/ui/feature-gates/feature-gate-decl_macro.stderr
index 94b609f0526..e76fe3714ea 100644
--- a/tests/ui/feature-gates/feature-gate-decl_macro.stderr
+++ b/tests/ui/feature-gates/feature-gate-decl_macro.stderr
@@ -6,6 +6,7 @@ LL | macro m() {}
    |
    = note: see issue #39412 <https://github.com/rust-lang/rust/issues/39412> for more information
    = help: add `#![feature(decl_macro)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-deprecated_safe.stderr b/tests/ui/feature-gates/feature-gate-deprecated_safe.stderr
index 5e98a1faaa3..415d54463d1 100644
--- a/tests/ui/feature-gates/feature-gate-deprecated_safe.stderr
+++ b/tests/ui/feature-gates/feature-gate-deprecated_safe.stderr
@@ -6,6 +6,7 @@ LL | #[deprecated_safe(since = "TBD", note = "...")]
    |
    = note: see issue #94978 <https://github.com/rust-lang/rust/issues/94978> for more information
    = help: add `#![feature(deprecated_safe)]` 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]: the `#[deprecated_safe]` attribute is an experimental feature
   --> $DIR/feature-gate-deprecated_safe.rs:4:1
@@ -15,6 +16,7 @@ LL | #[deprecated_safe(since = "TBD", note = "...")]
    |
    = note: see issue #94978 <https://github.com/rust-lang/rust/issues/94978> for more information
    = help: add `#![feature(deprecated_safe)]` 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 2 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-doc_cfg.stderr b/tests/ui/feature-gates/feature-gate-doc_cfg.stderr
index 1a313a86f7c..5315aaeeb3e 100644
--- a/tests/ui/feature-gates/feature-gate-doc_cfg.stderr
+++ b/tests/ui/feature-gates/feature-gate-doc_cfg.stderr
@@ -6,6 +6,7 @@ LL | #[doc(cfg(unix))]
    |
    = note: see issue #43781 <https://github.com/rust-lang/rust/issues/43781> for more information
    = help: add `#![feature(doc_cfg)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-doc_masked.stderr b/tests/ui/feature-gates/feature-gate-doc_masked.stderr
index 96377d8d036..10607a19757 100644
--- a/tests/ui/feature-gates/feature-gate-doc_masked.stderr
+++ b/tests/ui/feature-gates/feature-gate-doc_masked.stderr
@@ -6,6 +6,7 @@ LL | #[doc(masked)]
    |
    = note: see issue #44027 <https://github.com/rust-lang/rust/issues/44027> for more information
    = help: add `#![feature(doc_masked)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-doc_notable_trait.stderr b/tests/ui/feature-gates/feature-gate-doc_notable_trait.stderr
index d19d3fa0ff7..1b40b9ac18a 100644
--- a/tests/ui/feature-gates/feature-gate-doc_notable_trait.stderr
+++ b/tests/ui/feature-gates/feature-gate-doc_notable_trait.stderr
@@ -6,6 +6,7 @@ LL | #[doc(notable_trait)]
    |
    = note: see issue #45040 <https://github.com/rust-lang/rust/issues/45040> for more information
    = help: add `#![feature(doc_notable_trait)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-exclusive-range-pattern.stderr b/tests/ui/feature-gates/feature-gate-exclusive-range-pattern.stderr
index 4a0c8d7fdc3..d05971fb052 100644
--- a/tests/ui/feature-gates/feature-gate-exclusive-range-pattern.stderr
+++ b/tests/ui/feature-gates/feature-gate-exclusive-range-pattern.stderr
@@ -6,6 +6,7 @@ LL |         0 .. 3 => {}
    |
    = note: see issue #37854 <https://github.com/rust-lang/rust/issues/37854> for more information
    = help: add `#![feature(exclusive_range_pattern)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-explicit_tail_calls.stderr b/tests/ui/feature-gates/feature-gate-explicit_tail_calls.stderr
index b58da19c174..8447ac41e2c 100644
--- a/tests/ui/feature-gates/feature-gate-explicit_tail_calls.stderr
+++ b/tests/ui/feature-gates/feature-gate-explicit_tail_calls.stderr
@@ -6,6 +6,7 @@ LL |     become bottom();
    |
    = note: see issue #112788 <https://github.com/rust-lang/rust/issues/112788> for more information
    = help: add `#![feature(explicit_tail_calls)]` 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]: `become` expression is experimental
   --> $DIR/feature-gate-explicit_tail_calls.rs:6:5
@@ -15,6 +16,7 @@ LL |     become you();
    |
    = note: see issue #112788 <https://github.com/rust-lang/rust/issues/112788> for more information
    = help: add `#![feature(explicit_tail_calls)]` 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 2 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-extern_types.stderr b/tests/ui/feature-gates/feature-gate-extern_types.stderr
index 17ce01fd59b..599713b452a 100644
--- a/tests/ui/feature-gates/feature-gate-extern_types.stderr
+++ b/tests/ui/feature-gates/feature-gate-extern_types.stderr
@@ -6,6 +6,7 @@ LL |     type T;
    |
    = note: see issue #43467 <https://github.com/rust-lang/rust/issues/43467> for more information
    = help: add `#![feature(extern_types)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-ffi_const.stderr b/tests/ui/feature-gates/feature-gate-ffi_const.stderr
index c86606f3352..d083b826d6e 100644
--- a/tests/ui/feature-gates/feature-gate-ffi_const.stderr
+++ b/tests/ui/feature-gates/feature-gate-ffi_const.stderr
@@ -6,6 +6,7 @@ LL |     #[ffi_const]
    |
    = note: see issue #58328 <https://github.com/rust-lang/rust/issues/58328> for more information
    = help: add `#![feature(ffi_const)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-ffi_pure.stderr b/tests/ui/feature-gates/feature-gate-ffi_pure.stderr
index 4392fb16deb..6544d450eeb 100644
--- a/tests/ui/feature-gates/feature-gate-ffi_pure.stderr
+++ b/tests/ui/feature-gates/feature-gate-ffi_pure.stderr
@@ -6,6 +6,7 @@ LL |     #[ffi_pure]
    |
    = note: see issue #58329 <https://github.com/rust-lang/rust/issues/58329> for more information
    = help: add `#![feature(ffi_pure)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-ffi_returns_twice.stderr b/tests/ui/feature-gates/feature-gate-ffi_returns_twice.stderr
index 7a030d45460..8d19874c36a 100644
--- a/tests/ui/feature-gates/feature-gate-ffi_returns_twice.stderr
+++ b/tests/ui/feature-gates/feature-gate-ffi_returns_twice.stderr
@@ -6,6 +6,7 @@ LL |     #[ffi_returns_twice]
    |
    = note: see issue #58314 <https://github.com/rust-lang/rust/issues/58314> for more information
    = help: add `#![feature(ffi_returns_twice)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-fn_align.stderr b/tests/ui/feature-gates/feature-gate-fn_align.stderr
index 3351ceaf2f0..eec332792b7 100644
--- a/tests/ui/feature-gates/feature-gate-fn_align.stderr
+++ b/tests/ui/feature-gates/feature-gate-fn_align.stderr
@@ -6,6 +6,7 @@ LL | #[repr(align(16))]
    |
    = note: see issue #82232 <https://github.com/rust-lang/rust/issues/82232> for more information
    = help: add `#![feature(fn_align)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-fn_delegation.stderr b/tests/ui/feature-gates/feature-gate-fn_delegation.stderr
index 9b62e4ecff4..d7f8040803a 100644
--- a/tests/ui/feature-gates/feature-gate-fn_delegation.stderr
+++ b/tests/ui/feature-gates/feature-gate-fn_delegation.stderr
@@ -6,6 +6,7 @@ LL | reuse to_reuse::foo;
    |
    = note: see issue #118212 <https://github.com/rust-lang/rust/issues/118212> for more information
    = help: add `#![feature(fn_delegation)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-format_args_nl.stderr b/tests/ui/feature-gates/feature-gate-format_args_nl.stderr
index 35a712aad8a..f72d34d9b0b 100644
--- a/tests/ui/feature-gates/feature-gate-format_args_nl.stderr
+++ b/tests/ui/feature-gates/feature-gate-format_args_nl.stderr
@@ -5,6 +5,7 @@ LL |     format_args_nl!("");
    |     ^^^^^^^^^^^^^^
    |
    = help: add `#![feature(format_args_nl)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-fundamental.stderr b/tests/ui/feature-gates/feature-gate-fundamental.stderr
index 14ee169bdaa..61b30dfb29c 100644
--- a/tests/ui/feature-gates/feature-gate-fundamental.stderr
+++ b/tests/ui/feature-gates/feature-gate-fundamental.stderr
@@ -6,6 +6,7 @@ LL | #[fundamental]
    |
    = note: see issue #29635 <https://github.com/rust-lang/rust/issues/29635> for more information
    = help: add `#![feature(fundamental)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-gen_blocks.e2024.stderr b/tests/ui/feature-gates/feature-gate-gen_blocks.e2024.stderr
index 526354f6cfb..7cdcaeaee57 100644
--- a/tests/ui/feature-gates/feature-gate-gen_blocks.e2024.stderr
+++ b/tests/ui/feature-gates/feature-gate-gen_blocks.e2024.stderr
@@ -6,6 +6,7 @@ LL |     gen {};
    |
    = note: see issue #117078 <https://github.com/rust-lang/rust/issues/117078> for more information
    = help: add `#![feature(gen_blocks)]` 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]: gen blocks are experimental
   --> $DIR/feature-gate-gen_blocks.rs:12:5
@@ -15,6 +16,7 @@ LL |     async gen {};
    |
    = note: see issue #117078 <https://github.com/rust-lang/rust/issues/117078> for more information
    = help: add `#![feature(gen_blocks)]` 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]: gen blocks are experimental
   --> $DIR/feature-gate-gen_blocks.rs:22:5
@@ -24,6 +26,7 @@ LL |     gen {};
    |
    = note: see issue #117078 <https://github.com/rust-lang/rust/issues/117078> for more information
    = help: add `#![feature(gen_blocks)]` 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]: gen blocks are experimental
   --> $DIR/feature-gate-gen_blocks.rs:25:5
@@ -33,6 +36,7 @@ LL |     async gen {};
    |
    = note: see issue #117078 <https://github.com/rust-lang/rust/issues/117078> for more information
    = help: add `#![feature(gen_blocks)]` 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[E0282]: type annotations needed
   --> $DIR/feature-gate-gen_blocks.rs:5:5
diff --git a/tests/ui/feature-gates/feature-gate-generic_arg_infer.normal.stderr b/tests/ui/feature-gates/feature-gate-generic_arg_infer.normal.stderr
index 56123a983b3..bc022476c19 100644
--- a/tests/ui/feature-gates/feature-gate-generic_arg_infer.normal.stderr
+++ b/tests/ui/feature-gates/feature-gate-generic_arg_infer.normal.stderr
@@ -18,6 +18,7 @@ LL |     let _y: [u8; _] = [0; 3];
    |
    = note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
    = help: add `#![feature(generic_arg_infer)]` 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[E0747]: type provided when a constant was expected
   --> $DIR/feature-gate-generic_arg_infer.rs:20:20
@@ -36,6 +37,7 @@ LL |     let _x: [u8; 3] = [0; _];
    |
    = note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
    = help: add `#![feature(generic_arg_infer)]` 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 5 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-generic_associated_types_extended.stderr b/tests/ui/feature-gates/feature-gate-generic_associated_types_extended.stderr
index e5265b67eab..a5ab1b0d631 100644
--- a/tests/ui/feature-gates/feature-gate-generic_associated_types_extended.stderr
+++ b/tests/ui/feature-gates/feature-gate-generic_associated_types_extended.stderr
@@ -5,6 +5,7 @@ LL | #[rustc_error]
    | ^^^^^^^^^^^^^^
    |
    = help: add `#![feature(rustc_attrs)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-impl_trait_in_assoc_type.stderr b/tests/ui/feature-gates/feature-gate-impl_trait_in_assoc_type.stderr
index 420363ced6f..7dfd79c7286 100644
--- a/tests/ui/feature-gates/feature-gate-impl_trait_in_assoc_type.stderr
+++ b/tests/ui/feature-gates/feature-gate-impl_trait_in_assoc_type.stderr
@@ -6,6 +6,7 @@ LL |     type Bar = impl std::fmt::Debug;
    |
    = note: see issue #63063 <https://github.com/rust-lang/rust/issues/63063> for more information
    = help: add `#![feature(impl_trait_in_assoc_type)]` 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]: `impl Trait` in associated types is unstable
   --> $DIR/feature-gate-impl_trait_in_assoc_type.rs:14:16
@@ -15,6 +16,7 @@ LL |     type Bop = impl std::fmt::Debug;
    |
    = note: see issue #63063 <https://github.com/rust-lang/rust/issues/63063> for more information
    = help: add `#![feature(impl_trait_in_assoc_type)]` 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]: inherent associated types are unstable
   --> $DIR/feature-gate-impl_trait_in_assoc_type.rs:14:5
@@ -24,6 +26,7 @@ LL |     type Bop = impl std::fmt::Debug;
    |
    = note: see issue #8995 <https://github.com/rust-lang/rust/issues/8995> for more information
    = help: add `#![feature(inherent_associated_types)]` 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: unconstrained opaque type
   --> $DIR/feature-gate-impl_trait_in_assoc_type.rs:6:16
diff --git a/tests/ui/feature-gates/feature-gate-impl_trait_in_fn_trait_return.stderr b/tests/ui/feature-gates/feature-gate-impl_trait_in_fn_trait_return.stderr
index dacf1ca4c37..d939d8c5c28 100644
--- a/tests/ui/feature-gates/feature-gate-impl_trait_in_fn_trait_return.stderr
+++ b/tests/ui/feature-gates/feature-gate-impl_trait_in_fn_trait_return.stderr
@@ -7,6 +7,7 @@ LL | fn f() -> impl Fn() -> impl Sized { || () }
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
    = note: see issue #99697 <https://github.com/rust-lang/rust/issues/99697> for more information
    = help: add `#![feature(impl_trait_in_fn_trait_return)]` 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[E0562]: `impl Trait` is not allowed in the return type of `Fn` trait bounds
   --> $DIR/feature-gate-impl_trait_in_fn_trait_return.rs:3:32
@@ -17,6 +18,7 @@ LL | fn g() -> &'static dyn Fn() -> impl Sized { &|| () }
    = note: `impl Trait` is only allowed in arguments and return types of functions and methods
    = note: see issue #99697 <https://github.com/rust-lang/rust/issues/99697> for more information
    = help: add `#![feature(impl_trait_in_fn_trait_return)]` 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 2 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-imported_main.stderr b/tests/ui/feature-gates/feature-gate-imported_main.stderr
index 94cb74047c8..987bda7059c 100644
--- a/tests/ui/feature-gates/feature-gate-imported_main.stderr
+++ b/tests/ui/feature-gates/feature-gate-imported_main.stderr
@@ -6,6 +6,7 @@ LL | use foo::bar as main;
    |
    = note: see issue #28937 <https://github.com/rust-lang/rust/issues/28937> for more information
    = help: add `#![feature(imported_main)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-inherent_associated_types.stderr b/tests/ui/feature-gates/feature-gate-inherent_associated_types.stderr
index 8e117422a79..0eb7558b08f 100644
--- a/tests/ui/feature-gates/feature-gate-inherent_associated_types.stderr
+++ b/tests/ui/feature-gates/feature-gate-inherent_associated_types.stderr
@@ -6,6 +6,7 @@ LL |     type Bar = isize;
    |
    = note: see issue #8995 <https://github.com/rust-lang/rust/issues/8995> for more information
    = help: add `#![feature(inherent_associated_types)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-inline_const.stderr b/tests/ui/feature-gates/feature-gate-inline_const.stderr
index 3cb4aad003f..6cf675065f3 100644
--- a/tests/ui/feature-gates/feature-gate-inline_const.stderr
+++ b/tests/ui/feature-gates/feature-gate-inline_const.stderr
@@ -6,6 +6,7 @@ LL |     let _ = const {
    |
    = note: see issue #76001 <https://github.com/rust-lang/rust/issues/76001> for more information
    = help: add `#![feature(inline_const)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-inline_const_pat.stderr b/tests/ui/feature-gates/feature-gate-inline_const_pat.stderr
index eab024dde66..7d7376fa818 100644
--- a/tests/ui/feature-gates/feature-gate-inline_const_pat.stderr
+++ b/tests/ui/feature-gates/feature-gate-inline_const_pat.stderr
@@ -6,6 +6,7 @@ LL |     let const { () } = ();
    |
    = note: see issue #76001 <https://github.com/rust-lang/rust/issues/76001> for more information
    = help: add `#![feature(inline_const_pat)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-intrinsics.stderr b/tests/ui/feature-gates/feature-gate-intrinsics.stderr
index 8f943d357ce..ebd0f41715e 100644
--- a/tests/ui/feature-gates/feature-gate-intrinsics.stderr
+++ b/tests/ui/feature-gates/feature-gate-intrinsics.stderr
@@ -5,6 +5,7 @@ LL | extern "rust-intrinsic" {
    |        ^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(intrinsics)]` 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]: intrinsics are subject to change
   --> $DIR/feature-gate-intrinsics.rs:5:8
@@ -13,6 +14,7 @@ LL | extern "rust-intrinsic" fn baz() {}
    |        ^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(intrinsics)]` 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[E0093]: unrecognized intrinsic function: `bar`
   --> $DIR/feature-gate-intrinsics.rs:2:5
diff --git a/tests/ui/feature-gates/feature-gate-is_sorted.stderr b/tests/ui/feature-gates/feature-gate-is_sorted.stderr
index ccac827076b..f3e87659b02 100644
--- a/tests/ui/feature-gates/feature-gate-is_sorted.stderr
+++ b/tests/ui/feature-gates/feature-gate-is_sorted.stderr
@@ -6,6 +6,7 @@ LL |     assert!([1, 2, 2, 9].iter().is_sorted());
    |
    = note: see issue #53485 <https://github.com/rust-lang/rust/issues/53485> for more information
    = help: add `#![feature(is_sorted)]` 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]: use of unstable library feature 'is_sorted': new API
   --> $DIR/feature-gate-is_sorted.rs:5:39
@@ -15,6 +16,7 @@ LL |     assert!(![-2i32, -1, 0, 3].iter().is_sorted_by_key(|n| n.abs()));
    |
    = note: see issue #53485 <https://github.com/rust-lang/rust/issues/53485> for more information
    = help: add `#![feature(is_sorted)]` 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]: use of unstable library feature 'is_sorted': new API
   --> $DIR/feature-gate-is_sorted.rs:9:26
@@ -24,6 +26,7 @@ LL |     assert!([1, 2, 2, 9].is_sorted());
    |
    = note: see issue #53485 <https://github.com/rust-lang/rust/issues/53485> for more information
    = help: add `#![feature(is_sorted)]` 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]: use of unstable library feature 'is_sorted': new API
   --> $DIR/feature-gate-is_sorted.rs:11:32
@@ -33,6 +36,7 @@ LL |     assert!(![-2i32, -1, 0, 3].is_sorted_by_key(|n| n.abs()));
    |
    = note: see issue #53485 <https://github.com/rust-lang/rust/issues/53485> for more information
    = help: add `#![feature(is_sorted)]` 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 4 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-lang-items.stderr b/tests/ui/feature-gates/feature-gate-lang-items.stderr
index c2496863fea..54787e03784 100644
--- a/tests/ui/feature-gates/feature-gate-lang-items.stderr
+++ b/tests/ui/feature-gates/feature-gate-lang-items.stderr
@@ -5,6 +5,7 @@ LL | #[lang = "foo"]
    | ^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(lang_items)]` 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[E0522]: definition of an unknown language item: `foo`
   --> $DIR/feature-gate-lang-items.rs:1:1
diff --git a/tests/ui/feature-gates/feature-gate-large-assignments.stderr b/tests/ui/feature-gates/feature-gate-large-assignments.stderr
index c025be4f636..7b0b4470c4e 100644
--- a/tests/ui/feature-gates/feature-gate-large-assignments.stderr
+++ b/tests/ui/feature-gates/feature-gate-large-assignments.stderr
@@ -6,6 +6,7 @@ LL | #![move_size_limit = "42"]
    |
    = note: see issue #83518 <https://github.com/rust-lang/rust/issues/83518> for more information
    = help: add `#![feature(large_assignments)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-link-arg-attribute.stderr b/tests/ui/feature-gates/feature-gate-link-arg-attribute.stderr
index 673835b8b9e..8cbad78478e 100644
--- a/tests/ui/feature-gates/feature-gate-link-arg-attribute.stderr
+++ b/tests/ui/feature-gates/feature-gate-link-arg-attribute.stderr
@@ -6,6 +6,7 @@ LL | #[link(kind = "link-arg", name = "foo")]
    |
    = note: see issue #99427 <https://github.com/rust-lang/rust/issues/99427> for more information
    = help: add `#![feature(link_arg_attribute)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-link_cfg.stderr b/tests/ui/feature-gates/feature-gate-link_cfg.stderr
index 6e42be3954d..bfe7f74a921 100644
--- a/tests/ui/feature-gates/feature-gate-link_cfg.stderr
+++ b/tests/ui/feature-gates/feature-gate-link_cfg.stderr
@@ -5,6 +5,7 @@ LL | #[link(name = "foo", cfg(foo))]
    |                      ^^^^^^^^
    |
    = help: add `#![feature(link_cfg)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-link_llvm_intrinsics.stderr b/tests/ui/feature-gates/feature-gate-link_llvm_intrinsics.stderr
index 0cad260a14a..686007dcbb7 100644
--- a/tests/ui/feature-gates/feature-gate-link_llvm_intrinsics.stderr
+++ b/tests/ui/feature-gates/feature-gate-link_llvm_intrinsics.stderr
@@ -6,6 +6,7 @@ LL |     fn sqrt(x: f32) -> f32;
    |
    = note: see issue #29602 <https://github.com/rust-lang/rust/issues/29602> for more information
    = help: add `#![feature(link_llvm_intrinsics)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-linkage.stderr b/tests/ui/feature-gates/feature-gate-linkage.stderr
index ca1f5414568..2044b8a3c24 100644
--- a/tests/ui/feature-gates/feature-gate-linkage.stderr
+++ b/tests/ui/feature-gates/feature-gate-linkage.stderr
@@ -6,6 +6,7 @@ LL |     #[linkage = "extern_weak"] static foo: *mut isize;
    |
    = note: see issue #29603 <https://github.com/rust-lang/rust/issues/29603> for more information
    = help: add `#![feature(linkage)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-lint-reasons.stderr b/tests/ui/feature-gates/feature-gate-lint-reasons.stderr
index 6d49b7ed2cd..efcb3a10f32 100644
--- a/tests/ui/feature-gates/feature-gate-lint-reasons.stderr
+++ b/tests/ui/feature-gates/feature-gate-lint-reasons.stderr
@@ -6,6 +6,7 @@ LL | #![warn(nonstandard_style, reason = "the standard should be respected")]
    |
    = note: see issue #54503 <https://github.com/rust-lang/rust/issues/54503> for more information
    = help: add `#![feature(lint_reasons)]` 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]: lint reasons are experimental
   --> $DIR/feature-gate-lint-reasons.rs:1:28
@@ -15,6 +16,7 @@ LL | #![warn(nonstandard_style, reason = "the standard should be respected")]
    |
    = note: see issue #54503 <https://github.com/rust-lang/rust/issues/54503> for more information
    = help: add `#![feature(lint_reasons)]` 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: aborting due to 2 previous errors
diff --git a/tests/ui/feature-gates/feature-gate-log_syntax.stderr b/tests/ui/feature-gates/feature-gate-log_syntax.stderr
index 500c752e20d..0eba231a287 100644
--- a/tests/ui/feature-gates/feature-gate-log_syntax.stderr
+++ b/tests/ui/feature-gates/feature-gate-log_syntax.stderr
@@ -6,6 +6,7 @@ LL |     log_syntax!()
    |
    = note: see issue #29598 <https://github.com/rust-lang/rust/issues/29598> for more information
    = help: add `#![feature(log_syntax)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-log_syntax2.stderr b/tests/ui/feature-gates/feature-gate-log_syntax2.stderr
index a808a9463a0..e1f92dd60a3 100644
--- a/tests/ui/feature-gates/feature-gate-log_syntax2.stderr
+++ b/tests/ui/feature-gates/feature-gate-log_syntax2.stderr
@@ -6,6 +6,7 @@ LL |     println!("{:?}", log_syntax!());
    |
    = note: see issue #29598 <https://github.com/rust-lang/rust/issues/29598> for more information
    = help: add `#![feature(log_syntax)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-marker_trait_attr.stderr b/tests/ui/feature-gates/feature-gate-marker_trait_attr.stderr
index 4555ef1874f..15888a38589 100644
--- a/tests/ui/feature-gates/feature-gate-marker_trait_attr.stderr
+++ b/tests/ui/feature-gates/feature-gate-marker_trait_attr.stderr
@@ -6,6 +6,7 @@ LL | #[marker] trait ExplicitMarker {}
    |
    = note: see issue #29864 <https://github.com/rust-lang/rust/issues/29864> for more information
    = help: add `#![feature(marker_trait_attr)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-may-dangle.stderr b/tests/ui/feature-gates/feature-gate-may-dangle.stderr
index c12b3ba517d..67d00714d95 100644
--- a/tests/ui/feature-gates/feature-gate-may-dangle.stderr
+++ b/tests/ui/feature-gates/feature-gate-may-dangle.stderr
@@ -6,6 +6,7 @@ LL | unsafe impl<#[may_dangle] A> Drop for Pt<A> {
    |
    = note: see issue #34761 <https://github.com/rust-lang/rust/issues/34761> for more information
    = help: add `#![feature(dropck_eyepatch)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-more-qualified-paths.stderr b/tests/ui/feature-gates/feature-gate-more-qualified-paths.stderr
index 80ebcabcf8d..e14ef828a57 100644
--- a/tests/ui/feature-gates/feature-gate-more-qualified-paths.stderr
+++ b/tests/ui/feature-gates/feature-gate-more-qualified-paths.stderr
@@ -6,6 +6,7 @@ LL |     let <Foo as A>::Assoc { br } = StructStruct { br: 2 };
    |
    = note: see issue #86935 <https://github.com/rust-lang/rust/issues/86935> for more information
    = help: add `#![feature(more_qualified_paths)]` 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]: usage of qualified paths in this context is experimental
   --> $DIR/feature-gate-more-qualified-paths.rs:5:13
@@ -15,6 +16,7 @@ LL |     let _ = <Foo as A>::Assoc { br: 2 };
    |
    = note: see issue #86935 <https://github.com/rust-lang/rust/issues/86935> for more information
    = help: add `#![feature(more_qualified_paths)]` 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]: usage of qualified paths in this context is experimental
   --> $DIR/feature-gate-more-qualified-paths.rs:7:9
@@ -24,6 +26,7 @@ LL |     let <E>::V(..) = E::V(0);
    |
    = note: see issue #86935 <https://github.com/rust-lang/rust/issues/86935> for more information
    = help: add `#![feature(more_qualified_paths)]` 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
 
diff --git a/tests/ui/feature-gates/feature-gate-multiple_supertrait_upcastable.stderr b/tests/ui/feature-gates/feature-gate-multiple_supertrait_upcastable.stderr
index f6fcf4ee3ed..8a43d615963 100644
--- a/tests/ui/feature-gates/feature-gate-multiple_supertrait_upcastable.stderr
+++ b/tests/ui/feature-gates/feature-gate-multiple_supertrait_upcastable.stderr
@@ -6,6 +6,7 @@ LL | #![deny(multiple_supertrait_upcastable)]
    |
    = note: the `multiple_supertrait_upcastable` lint is unstable
    = help: add `#![feature(multiple_supertrait_upcastable)]` 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: `#[warn(unknown_lints)]` on by default
 
 warning: unknown lint: `multiple_supertrait_upcastable`
@@ -16,6 +17,7 @@ LL | #![warn(multiple_supertrait_upcastable)]
    |
    = note: the `multiple_supertrait_upcastable` lint is unstable
    = help: add `#![feature(multiple_supertrait_upcastable)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: 2 warnings emitted
 
diff --git a/tests/ui/feature-gates/feature-gate-naked_functions.stderr b/tests/ui/feature-gates/feature-gate-naked_functions.stderr
index dc6c9138c5d..e1b82658217 100644
--- a/tests/ui/feature-gates/feature-gate-naked_functions.stderr
+++ b/tests/ui/feature-gates/feature-gate-naked_functions.stderr
@@ -6,6 +6,7 @@ LL | #[naked]
    |
    = note: see issue #90957 <https://github.com/rust-lang/rust/issues/90957> for more information
    = help: add `#![feature(naked_functions)]` 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]: the `#[naked]` attribute is an experimental feature
   --> $DIR/feature-gate-naked_functions.rs:11:1
@@ -15,6 +16,7 @@ LL | #[naked]
    |
    = note: see issue #90957 <https://github.com/rust-lang/rust/issues/90957> for more information
    = help: add `#![feature(naked_functions)]` 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 2 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-native_link_modifiers_as_needed.stderr b/tests/ui/feature-gates/feature-gate-native_link_modifiers_as_needed.stderr
index 4c7ae9e2ef5..216477828e7 100644
--- a/tests/ui/feature-gates/feature-gate-native_link_modifiers_as_needed.stderr
+++ b/tests/ui/feature-gates/feature-gate-native_link_modifiers_as_needed.stderr
@@ -6,6 +6,7 @@ LL | #[link(name = "foo", kind = "dylib", modifiers = "+as-needed")]
    |
    = note: see issue #81490 <https://github.com/rust-lang/rust/issues/81490> for more information
    = help: add `#![feature(native_link_modifiers_as_needed)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-needs-allocator.stderr b/tests/ui/feature-gates/feature-gate-needs-allocator.stderr
index ca21f222588..f26243de25f 100644
--- a/tests/ui/feature-gates/feature-gate-needs-allocator.stderr
+++ b/tests/ui/feature-gates/feature-gate-needs-allocator.stderr
@@ -5,6 +5,7 @@ LL | #![needs_allocator]
    | ^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(allocator_internals)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-never_patterns.rs b/tests/ui/feature-gates/feature-gate-never_patterns.rs
index f3910622313..d23405ada2d 100644
--- a/tests/ui/feature-gates/feature-gate-never_patterns.rs
+++ b/tests/ui/feature-gates/feature-gate-never_patterns.rs
@@ -7,7 +7,6 @@ fn main() {
     let res: Result<u32, Void> = Ok(0);
     let (Ok(_x) | Err(&!)) = res.as_ref();
     //~^ ERROR `!` patterns are experimental
-    //~| ERROR: is not bound in all patterns
 
     unsafe {
         let ptr: *const Void = NonNull::dangling().as_ptr();
diff --git a/tests/ui/feature-gates/feature-gate-never_patterns.stderr b/tests/ui/feature-gates/feature-gate-never_patterns.stderr
index dd10829d495..9f94e962035 100644
--- a/tests/ui/feature-gates/feature-gate-never_patterns.stderr
+++ b/tests/ui/feature-gates/feature-gate-never_patterns.stderr
@@ -1,5 +1,5 @@
 error: unexpected `,` in pattern
-  --> $DIR/feature-gate-never_patterns.rs:34:16
+  --> $DIR/feature-gate-never_patterns.rs:33:16
    |
 LL |         Some(_),
    |                ^
@@ -13,14 +13,6 @@ help: ...or a vertical bar to match on multiple alternatives
 LL |         Some(_) |
    |
 
-error[E0408]: variable `_x` is not bound in all patterns
-  --> $DIR/feature-gate-never_patterns.rs:8:19
-   |
-LL |     let (Ok(_x) | Err(&!)) = res.as_ref();
-   |             --    ^^^^^^^ pattern doesn't bind `_x`
-   |             |
-   |             variable not in all patterns
-
 error[E0658]: `!` patterns are experimental
   --> $DIR/feature-gate-never_patterns.rs:8:24
    |
@@ -29,89 +21,94 @@ LL |     let (Ok(_x) | Err(&!)) = res.as_ref();
    |
    = note: see issue #118155 <https://github.com/rust-lang/rust/issues/118155> for more information
    = help: add `#![feature(never_patterns)]` 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]: `!` patterns are experimental
-  --> $DIR/feature-gate-never_patterns.rs:15:13
+  --> $DIR/feature-gate-never_patterns.rs:14:13
    |
 LL |             !
    |             ^
    |
    = note: see issue #118155 <https://github.com/rust-lang/rust/issues/118155> for more information
    = help: add `#![feature(never_patterns)]` 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]: `!` patterns are experimental
-  --> $DIR/feature-gate-never_patterns.rs:21:13
+  --> $DIR/feature-gate-never_patterns.rs:20:13
    |
 LL |             !
    |             ^
    |
    = note: see issue #118155 <https://github.com/rust-lang/rust/issues/118155> for more information
    = help: add `#![feature(never_patterns)]` 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]: `!` patterns are experimental
-  --> $DIR/feature-gate-never_patterns.rs:26:13
+  --> $DIR/feature-gate-never_patterns.rs:25:13
    |
 LL |             ! => {}
    |             ^
    |
    = note: see issue #118155 <https://github.com/rust-lang/rust/issues/118155> for more information
    = help: add `#![feature(never_patterns)]` 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: `match` arm with no body
-  --> $DIR/feature-gate-never_patterns.rs:39:9
+  --> $DIR/feature-gate-never_patterns.rs:38:9
    |
 LL |         Some(_)
    |         ^^^^^^^- help: add a body after the pattern: `=> todo!(),`
 
 error: `match` arm with no body
-  --> $DIR/feature-gate-never_patterns.rs:44:9
+  --> $DIR/feature-gate-never_patterns.rs:43:9
    |
 LL |         Some(_) if false,
    |         ^^^^^^^- help: add a body after the pattern: `=> todo!(),`
 
 error: `match` arm with no body
-  --> $DIR/feature-gate-never_patterns.rs:46:9
+  --> $DIR/feature-gate-never_patterns.rs:45:9
    |
 LL |         Some(_) if false
    |         ^^^^^^^- help: add a body after the pattern: `=> todo!(),`
 
 error[E0658]: `!` patterns are experimental
-  --> $DIR/feature-gate-never_patterns.rs:51:13
+  --> $DIR/feature-gate-never_patterns.rs:50:13
    |
 LL |         Err(!),
    |             ^
    |
    = note: see issue #118155 <https://github.com/rust-lang/rust/issues/118155> for more information
    = help: add `#![feature(never_patterns)]` 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]: `!` patterns are experimental
-  --> $DIR/feature-gate-never_patterns.rs:55:13
+  --> $DIR/feature-gate-never_patterns.rs:54:13
    |
 LL |         Err(!) if false,
    |             ^
    |
    = note: see issue #118155 <https://github.com/rust-lang/rust/issues/118155> for more information
    = help: add `#![feature(never_patterns)]` 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: `match` arm with no body
-  --> $DIR/feature-gate-never_patterns.rs:65:9
+  --> $DIR/feature-gate-never_patterns.rs:64:9
    |
 LL |         Some(_)
    |         ^^^^^^^- help: add a body after the pattern: `=> todo!(),`
 
 error: `match` arm with no body
-  --> $DIR/feature-gate-never_patterns.rs:71:9
+  --> $DIR/feature-gate-never_patterns.rs:70:9
    |
 LL |         Some(_) if false
    |         ^^^^^^^- help: add a body after the pattern: `=> todo!(),`
 
 error: a guard on a never pattern will never be run
-  --> $DIR/feature-gate-never_patterns.rs:55:19
+  --> $DIR/feature-gate-never_patterns.rs:54:19
    |
 LL |         Err(!) if false,
    |                   ^^^^^ help: remove this guard
 
-error: aborting due to 14 previous errors
+error: aborting due to 13 previous errors
 
-Some errors have detailed explanations: E0408, E0658.
-For more information about an error, try `rustc --explain E0408`.
+For more information about this error, try `rustc --explain E0658`.
diff --git a/tests/ui/feature-gates/feature-gate-never_type.stderr b/tests/ui/feature-gates/feature-gate-never_type.stderr
index 0a59cae9c8c..0fca58519ce 100644
--- a/tests/ui/feature-gates/feature-gate-never_type.stderr
+++ b/tests/ui/feature-gates/feature-gate-never_type.stderr
@@ -6,6 +6,7 @@ LL | type Ma = (u32, !, i32);
    |
    = note: see issue #35121 <https://github.com/rust-lang/rust/issues/35121> for more information
    = help: add `#![feature(never_type)]` 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]: the `!` type is experimental
   --> $DIR/feature-gate-never_type.rs:8:20
@@ -15,6 +16,7 @@ LL | type Meeshka = Vec<!>;
    |
    = note: see issue #35121 <https://github.com/rust-lang/rust/issues/35121> for more information
    = help: add `#![feature(never_type)]` 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]: the `!` type is experimental
   --> $DIR/feature-gate-never_type.rs:9:24
@@ -24,6 +26,7 @@ LL | type Mow = &'static fn(!) -> !;
    |
    = note: see issue #35121 <https://github.com/rust-lang/rust/issues/35121> for more information
    = help: add `#![feature(never_type)]` 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]: the `!` type is experimental
   --> $DIR/feature-gate-never_type.rs:10:27
@@ -33,6 +36,7 @@ LL | type Skwoz = &'static mut !;
    |
    = note: see issue #35121 <https://github.com/rust-lang/rust/issues/35121> for more information
    = help: add `#![feature(never_type)]` 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]: the `!` type is experimental
   --> $DIR/feature-gate-never_type.rs:13:16
@@ -42,6 +46,7 @@ LL |     type Wub = !;
    |
    = note: see issue #35121 <https://github.com/rust-lang/rust/issues/35121> for more information
    = help: add `#![feature(never_type)]` 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 5 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-no_core.stderr b/tests/ui/feature-gates/feature-gate-no_core.stderr
index e525c95ac36..f5f04c346ae 100644
--- a/tests/ui/feature-gates/feature-gate-no_core.stderr
+++ b/tests/ui/feature-gates/feature-gate-no_core.stderr
@@ -6,6 +6,7 @@ LL | #![no_core]
    |
    = note: see issue #29639 <https://github.com/rust-lang/rust/issues/29639> for more information
    = help: add `#![feature(no_core)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-no_sanitize.stderr b/tests/ui/feature-gates/feature-gate-no_sanitize.stderr
index bb808961eb2..a33bf6a9e40 100644
--- a/tests/ui/feature-gates/feature-gate-no_sanitize.stderr
+++ b/tests/ui/feature-gates/feature-gate-no_sanitize.stderr
@@ -6,6 +6,7 @@ LL | #[no_sanitize(address)]
    |
    = note: see issue #39699 <https://github.com/rust-lang/rust/issues/39699> for more information
    = help: add `#![feature(no_sanitize)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-non_exhaustive_omitted_patterns_lint.stderr b/tests/ui/feature-gates/feature-gate-non_exhaustive_omitted_patterns_lint.stderr
index 955d7fe3f3e..41764c8e018 100644
--- a/tests/ui/feature-gates/feature-gate-non_exhaustive_omitted_patterns_lint.stderr
+++ b/tests/ui/feature-gates/feature-gate-non_exhaustive_omitted_patterns_lint.stderr
@@ -7,6 +7,7 @@ LL | #![deny(non_exhaustive_omitted_patterns)]
    = note: the `non_exhaustive_omitted_patterns` lint is unstable
    = note: see issue #89554 <https://github.com/rust-lang/rust/issues/89554> for more information
    = help: add `#![feature(non_exhaustive_omitted_patterns_lint)]` 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: `#[warn(unknown_lints)]` on by default
 
 warning: unknown lint: `non_exhaustive_omitted_patterns`
@@ -18,6 +19,7 @@ LL | #![allow(non_exhaustive_omitted_patterns)]
    = note: the `non_exhaustive_omitted_patterns` lint is unstable
    = note: see issue #89554 <https://github.com/rust-lang/rust/issues/89554> for more information
    = help: add `#![feature(non_exhaustive_omitted_patterns_lint)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: unknown lint: `non_exhaustive_omitted_patterns`
   --> $DIR/feature-gate-non_exhaustive_omitted_patterns_lint.rs:15:5
@@ -28,6 +30,7 @@ LL |     #[allow(non_exhaustive_omitted_patterns)]
    = note: the `non_exhaustive_omitted_patterns` lint is unstable
    = note: see issue #89554 <https://github.com/rust-lang/rust/issues/89554> for more information
    = help: add `#![feature(non_exhaustive_omitted_patterns_lint)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: unknown lint: `non_exhaustive_omitted_patterns`
   --> $DIR/feature-gate-non_exhaustive_omitted_patterns_lint.rs:15:5
@@ -38,6 +41,7 @@ LL |     #[allow(non_exhaustive_omitted_patterns)]
    = note: the `non_exhaustive_omitted_patterns` lint is unstable
    = note: see issue #89554 <https://github.com/rust-lang/rust/issues/89554> for more information
    = help: add `#![feature(non_exhaustive_omitted_patterns_lint)]` 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`
 
 warning: unknown lint: `non_exhaustive_omitted_patterns`
@@ -49,6 +53,7 @@ LL |     #[warn(non_exhaustive_omitted_patterns)]
    = note: the `non_exhaustive_omitted_patterns` lint is unstable
    = note: see issue #89554 <https://github.com/rust-lang/rust/issues/89554> for more information
    = help: add `#![feature(non_exhaustive_omitted_patterns_lint)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: unknown lint: `non_exhaustive_omitted_patterns`
   --> $DIR/feature-gate-non_exhaustive_omitted_patterns_lint.rs:24:5
@@ -59,6 +64,7 @@ LL |     #[warn(non_exhaustive_omitted_patterns)]
    = note: the `non_exhaustive_omitted_patterns` lint is unstable
    = note: see issue #89554 <https://github.com/rust-lang/rust/issues/89554> for more information
    = help: add `#![feature(non_exhaustive_omitted_patterns_lint)]` 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[E0004]: non-exhaustive patterns: `Foo::C` not covered
diff --git a/tests/ui/feature-gates/feature-gate-non_lifetime_binders.stderr b/tests/ui/feature-gates/feature-gate-non_lifetime_binders.stderr
index f727fdae90e..6dbebc7cf33 100644
--- a/tests/ui/feature-gates/feature-gate-non_lifetime_binders.stderr
+++ b/tests/ui/feature-gates/feature-gate-non_lifetime_binders.stderr
@@ -6,6 +6,7 @@ LL | fn foo() where for<T> T:, {}
    |
    = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
    = help: add `#![feature(non_lifetime_binders)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-offset-of-enum.stderr b/tests/ui/feature-gates/feature-gate-offset-of-enum.stderr
index 893f7870237..02ee54e8607 100644
--- a/tests/ui/feature-gates/feature-gate-offset-of-enum.stderr
+++ b/tests/ui/feature-gates/feature-gate-offset-of-enum.stderr
@@ -15,6 +15,7 @@ LL |     offset_of!(Alpha, One);
    |
    = note: see issue #106655 <https://github.com/rust-lang/rust/issues/106655> for more information
    = help: add `#![feature(offset_of_enum)]` 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[E0795]: `One` is an enum variant; expected field at end of `offset_of`
   --> $DIR/feature-gate-offset-of-enum.rs:12:23
@@ -30,6 +31,7 @@ LL |     offset_of!(Alpha, Two.0);
    |
    = note: see issue #106655 <https://github.com/rust-lang/rust/issues/106655> for more information
    = help: add `#![feature(offset_of_enum)]` 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 4 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-omit-gdb-pretty-printer-section.stderr b/tests/ui/feature-gates/feature-gate-omit-gdb-pretty-printer-section.stderr
index 86f6040b14f..2e1d27fb776 100644
--- a/tests/ui/feature-gates/feature-gate-omit-gdb-pretty-printer-section.stderr
+++ b/tests/ui/feature-gates/feature-gate-omit-gdb-pretty-printer-section.stderr
@@ -5,6 +5,7 @@ LL | #[omit_gdb_pretty_printer_section]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(omit_gdb_pretty_printer_section)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-optimize_attribute.stderr b/tests/ui/feature-gates/feature-gate-optimize_attribute.stderr
index a3ced35155f..815013733a9 100644
--- a/tests/ui/feature-gates/feature-gate-optimize_attribute.stderr
+++ b/tests/ui/feature-gates/feature-gate-optimize_attribute.stderr
@@ -6,6 +6,7 @@ LL | #[optimize(size)]
    |
    = note: see issue #54882 <https://github.com/rust-lang/rust/issues/54882> for more information
    = help: add `#![feature(optimize_attribute)]` 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]: the `#[optimize]` attribute is an experimental feature
   --> $DIR/feature-gate-optimize_attribute.rs:10:1
@@ -15,6 +16,7 @@ LL | #[optimize(speed)]
    |
    = note: see issue #54882 <https://github.com/rust-lang/rust/issues/54882> for more information
    = help: add `#![feature(optimize_attribute)]` 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]: the `#[optimize]` attribute is an experimental feature
   --> $DIR/feature-gate-optimize_attribute.rs:13:1
@@ -24,6 +26,7 @@ LL | #[optimize(banana)]
    |
    = note: see issue #54882 <https://github.com/rust-lang/rust/issues/54882> for more information
    = help: add `#![feature(optimize_attribute)]` 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]: the `#[optimize]` attribute is an experimental feature
   --> $DIR/feature-gate-optimize_attribute.rs:4:1
@@ -33,6 +36,7 @@ LL | #[optimize(size)]
    |
    = note: see issue #54882 <https://github.com/rust-lang/rust/issues/54882> for more information
    = help: add `#![feature(optimize_attribute)]` 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]: the `#[optimize]` attribute is an experimental feature
   --> $DIR/feature-gate-optimize_attribute.rs:2:1
@@ -42,6 +46,7 @@ LL | #![optimize(speed)]
    |
    = note: see issue #54882 <https://github.com/rust-lang/rust/issues/54882> for more information
    = help: add `#![feature(optimize_attribute)]` 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[E0722]: invalid argument
   --> $DIR/feature-gate-optimize_attribute.rs:13:12
diff --git a/tests/ui/feature-gates/feature-gate-prelude_import.stderr b/tests/ui/feature-gates/feature-gate-prelude_import.stderr
index b2e2a7c8cc1..3b22c65cd1f 100644
--- a/tests/ui/feature-gates/feature-gate-prelude_import.stderr
+++ b/tests/ui/feature-gates/feature-gate-prelude_import.stderr
@@ -5,6 +5,7 @@ LL | #[prelude_import]
    | ^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(prelude_import)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-proc_macro_byte_character.stderr b/tests/ui/feature-gates/feature-gate-proc_macro_byte_character.stderr
index f8fa8c54198..c14d19381c8 100644
--- a/tests/ui/feature-gates/feature-gate-proc_macro_byte_character.stderr
+++ b/tests/ui/feature-gates/feature-gate-proc_macro_byte_character.stderr
@@ -6,6 +6,7 @@ LL |     Literal::byte_character(b'a');
    |
    = note: see issue #115268 <https://github.com/rust-lang/rust/issues/115268> for more information
    = help: add `#![feature(proc_macro_byte_character)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-proc_macro_c_str_literals.rs b/tests/ui/feature-gates/feature-gate-proc_macro_c_str_literals.rs
new file mode 100644
index 00000000000..5554c813925
--- /dev/null
+++ b/tests/ui/feature-gates/feature-gate-proc_macro_c_str_literals.rs
@@ -0,0 +1,11 @@
+// edition: 2021
+// force-host
+#![crate_type = "proc-macro"]
+
+extern crate proc_macro;
+
+use proc_macro::Literal;
+
+fn test() {
+    Literal::c_string(c"a"); //~ ERROR use of unstable library feature 'proc_macro_c_str_literals'
+}
diff --git a/tests/ui/feature-gates/feature-gate-proc_macro_c_str_literals.stderr b/tests/ui/feature-gates/feature-gate-proc_macro_c_str_literals.stderr
new file mode 100644
index 00000000000..9bba1d50ce3
--- /dev/null
+++ b/tests/ui/feature-gates/feature-gate-proc_macro_c_str_literals.stderr
@@ -0,0 +1,13 @@
+error[E0658]: use of unstable library feature 'proc_macro_c_str_literals'
+  --> $DIR/feature-gate-proc_macro_c_str_literals.rs:10:5
+   |
+LL |     Literal::c_string(c"a");
+   |     ^^^^^^^^^^^^^^^^^
+   |
+   = note: see issue #119750 <https://github.com/rust-lang/rust/issues/119750> for more information
+   = help: add `#![feature(proc_macro_c_str_literals)]` 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 1 previous error
+
+For more information about this error, try `rustc --explain E0658`.
diff --git a/tests/ui/feature-gates/feature-gate-profiler-runtime.stderr b/tests/ui/feature-gates/feature-gate-profiler-runtime.stderr
index cc6506c5680..23792fb09ba 100644
--- a/tests/ui/feature-gates/feature-gate-profiler-runtime.stderr
+++ b/tests/ui/feature-gates/feature-gate-profiler-runtime.stderr
@@ -5,6 +5,7 @@ LL | #![profiler_runtime]
    | ^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(profiler_runtime)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-register_tool.stderr b/tests/ui/feature-gates/feature-gate-register_tool.stderr
index d72249e0212..a0db6ba7446 100644
--- a/tests/ui/feature-gates/feature-gate-register_tool.stderr
+++ b/tests/ui/feature-gates/feature-gate-register_tool.stderr
@@ -6,6 +6,7 @@ LL | #![register_tool(tool)]
    |
    = note: see issue #66079 <https://github.com/rust-lang/rust/issues/66079> for more information
    = help: add `#![feature(register_tool)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-repr-simd.stderr b/tests/ui/feature-gates/feature-gate-repr-simd.stderr
index 5b1270a1984..5b490c0c0c3 100644
--- a/tests/ui/feature-gates/feature-gate-repr-simd.stderr
+++ b/tests/ui/feature-gates/feature-gate-repr-simd.stderr
@@ -6,6 +6,7 @@ LL | #[repr(simd)]
    |
    = note: see issue #27731 <https://github.com/rust-lang/rust/issues/27731> for more information
    = help: add `#![feature(repr_simd)]` 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]: SIMD types are experimental and possibly buggy
   --> $DIR/feature-gate-repr-simd.rs:6:1
@@ -15,6 +16,7 @@ LL | #[repr(simd)]
    |
    = note: see issue #27731 <https://github.com/rust-lang/rust/issues/27731> for more information
    = help: add `#![feature(repr_simd)]` 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[E0566]: conflicting representation hints
   --> $DIR/feature-gate-repr-simd.rs:4:8
diff --git a/tests/ui/feature-gates/feature-gate-repr128.stderr b/tests/ui/feature-gates/feature-gate-repr128.stderr
index 657802632b0..2607032447b 100644
--- a/tests/ui/feature-gates/feature-gate-repr128.stderr
+++ b/tests/ui/feature-gates/feature-gate-repr128.stderr
@@ -6,6 +6,7 @@ LL | enum A {
    |
    = note: see issue #56071 <https://github.com/rust-lang/rust/issues/56071> for more information
    = help: add `#![feature(repr128)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-return_type_notation.cfg.stderr b/tests/ui/feature-gates/feature-gate-return_type_notation.cfg.stderr
index a15b01618f5..41bd66b13e7 100644
--- a/tests/ui/feature-gates/feature-gate-return_type_notation.cfg.stderr
+++ b/tests/ui/feature-gates/feature-gate-return_type_notation.cfg.stderr
@@ -6,6 +6,7 @@ LL | fn foo<T: Trait<m(): Send>>() {}
    |
    = note: see issue #109417 <https://github.com/rust-lang/rust/issues/109417> for more information
    = help: add `#![feature(return_type_notation)]` 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: parenthesized generic arguments cannot be used in associated type constraints
   --> $DIR/feature-gate-return_type_notation.rs:14:17
diff --git a/tests/ui/feature-gates/feature-gate-return_type_notation.no.stderr b/tests/ui/feature-gates/feature-gate-return_type_notation.no.stderr
index dd6ebb61038..79c626cef35 100644
--- a/tests/ui/feature-gates/feature-gate-return_type_notation.no.stderr
+++ b/tests/ui/feature-gates/feature-gate-return_type_notation.no.stderr
@@ -6,6 +6,7 @@ LL | fn foo<T: Trait<m(): Send>>() {}
    |
    = note: see issue #109417 <https://github.com/rust-lang/rust/issues/109417> for more information
    = help: add `#![feature(return_type_notation)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
    = warning: unstable syntax can change at any point in the future, causing a hard error!
    = note: for more information, see issue #65860 <https://github.com/rust-lang/rust/issues/65860>
 
diff --git a/tests/ui/feature-gates/feature-gate-rust_cold_cc.stderr b/tests/ui/feature-gates/feature-gate-rust_cold_cc.stderr
index ab7e5f0366d..eeff9534d52 100644
--- a/tests/ui/feature-gates/feature-gate-rust_cold_cc.stderr
+++ b/tests/ui/feature-gates/feature-gate-rust_cold_cc.stderr
@@ -6,6 +6,7 @@ LL | extern "rust-cold" fn fu() {}
    |
    = note: see issue #97544 <https://github.com/rust-lang/rust/issues/97544> for more information
    = help: add `#![feature(rust_cold_cc)]` 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]: rust-cold is experimental and subject to change
   --> $DIR/feature-gate-rust_cold_cc.rs:6:12
@@ -15,6 +16,7 @@ LL |     extern "rust-cold" fn mu();
    |
    = note: see issue #97544 <https://github.com/rust-lang/rust/issues/97544> for more information
    = help: add `#![feature(rust_cold_cc)]` 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]: rust-cold is experimental and subject to change
   --> $DIR/feature-gate-rust_cold_cc.rs:7:12
@@ -24,6 +26,7 @@ LL |     extern "rust-cold" fn dmu() {}
    |
    = note: see issue #97544 <https://github.com/rust-lang/rust/issues/97544> for more information
    = help: add `#![feature(rust_cold_cc)]` 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]: rust-cold is experimental and subject to change
   --> $DIR/feature-gate-rust_cold_cc.rs:12:12
@@ -33,6 +36,7 @@ LL |     extern "rust-cold" fn mu() {}
    |
    = note: see issue #97544 <https://github.com/rust-lang/rust/issues/97544> for more information
    = help: add `#![feature(rust_cold_cc)]` 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]: rust-cold is experimental and subject to change
   --> $DIR/feature-gate-rust_cold_cc.rs:16:12
@@ -42,6 +46,7 @@ LL |     extern "rust-cold" fn imu() {}
    |
    = note: see issue #97544 <https://github.com/rust-lang/rust/issues/97544> for more information
    = help: add `#![feature(rust_cold_cc)]` 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]: rust-cold is experimental and subject to change
   --> $DIR/feature-gate-rust_cold_cc.rs:19:19
@@ -51,6 +56,7 @@ LL | type TAU = extern "rust-cold" fn();
    |
    = note: see issue #97544 <https://github.com/rust-lang/rust/issues/97544> for more information
    = help: add `#![feature(rust_cold_cc)]` 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]: rust-cold is experimental and subject to change
   --> $DIR/feature-gate-rust_cold_cc.rs:21:8
@@ -60,6 +66,7 @@ LL | extern "rust-cold" {}
    |
    = note: see issue #97544 <https://github.com/rust-lang/rust/issues/97544> for more information
    = help: add `#![feature(rust_cold_cc)]` 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 7 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-rustc-allow-const-fn-unstable.stderr b/tests/ui/feature-gates/feature-gate-rustc-allow-const-fn-unstable.stderr
index b33721ca43d..44f7a4bb0e6 100644
--- a/tests/ui/feature-gates/feature-gate-rustc-allow-const-fn-unstable.stderr
+++ b/tests/ui/feature-gates/feature-gate-rustc-allow-const-fn-unstable.stderr
@@ -6,6 +6,7 @@ LL | #[rustc_allow_const_fn_unstable()]
    |
    = note: see issue #69399 <https://github.com/rust-lang/rust/issues/69399> for more information
    = help: add `#![feature(rustc_allow_const_fn_unstable)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-rustc-attrs-1.stderr b/tests/ui/feature-gates/feature-gate-rustc-attrs-1.stderr
index 45a095903d2..8177d5ef6be 100644
--- a/tests/ui/feature-gates/feature-gate-rustc-attrs-1.stderr
+++ b/tests/ui/feature-gates/feature-gate-rustc-attrs-1.stderr
@@ -5,6 +5,7 @@ LL | #[rustc_variance]
    | ^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(rustc_attrs)]` 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]: the `#[rustc_error]` attribute is just used for rustc unit tests and will never be stable
   --> $DIR/feature-gate-rustc-attrs-1.rs:4:1
@@ -13,6 +14,7 @@ LL | #[rustc_error]
    | ^^^^^^^^^^^^^^
    |
    = help: add `#![feature(rustc_attrs)]` 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]: the `#[rustc_nonnull_optimization_guaranteed]` attribute is just used to enable niche optimizations in libcore and libstd and will never be stable
   --> $DIR/feature-gate-rustc-attrs-1.rs:5:1
@@ -21,6 +23,7 @@ LL | #[rustc_nonnull_optimization_guaranteed]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(rustc_attrs)]` 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
 
diff --git a/tests/ui/feature-gates/feature-gate-rustc-attrs.stderr b/tests/ui/feature-gates/feature-gate-rustc-attrs.stderr
index 1517a7a5c73..c7a5ef3e44b 100644
--- a/tests/ui/feature-gates/feature-gate-rustc-attrs.stderr
+++ b/tests/ui/feature-gates/feature-gate-rustc-attrs.stderr
@@ -41,6 +41,7 @@ LL | #[rustc_dummy]
    | ^^^^^^^^^^^^^^
    |
    = help: add `#![feature(rustc_attrs)]` 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 7 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-rustdoc_internals.stderr b/tests/ui/feature-gates/feature-gate-rustdoc_internals.stderr
index c4272a2c04c..bbb9edd58f0 100644
--- a/tests/ui/feature-gates/feature-gate-rustdoc_internals.stderr
+++ b/tests/ui/feature-gates/feature-gate-rustdoc_internals.stderr
@@ -6,6 +6,7 @@ LL | #[doc(keyword = "match")]
    |
    = note: see issue #90418 <https://github.com/rust-lang/rust/issues/90418> for more information
    = help: add `#![feature(rustdoc_internals)]` 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]: `#[doc(fake_variadic)]` is meant for internal use only
   --> $DIR/feature-gate-rustdoc_internals.rs:7:1
@@ -15,6 +16,7 @@ LL | #[doc(fake_variadic)]
    |
    = note: see issue #90418 <https://github.com/rust-lang/rust/issues/90418> for more information
    = help: add `#![feature(rustdoc_internals)]` 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 2 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-simd.stderr b/tests/ui/feature-gates/feature-gate-simd.stderr
index fa30d461f9c..b020db35a51 100644
--- a/tests/ui/feature-gates/feature-gate-simd.stderr
+++ b/tests/ui/feature-gates/feature-gate-simd.stderr
@@ -6,6 +6,7 @@ LL | #[repr(simd)]
    |
    = note: see issue #27731 <https://github.com/rust-lang/rust/issues/27731> for more information
    = help: add `#![feature(repr_simd)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-start.stderr b/tests/ui/feature-gates/feature-gate-start.stderr
index 157bf18c9e8..b1859c43718 100644
--- a/tests/ui/feature-gates/feature-gate-start.stderr
+++ b/tests/ui/feature-gates/feature-gate-start.stderr
@@ -6,6 +6,7 @@ LL | fn foo(_: isize, _: *const *const u8) -> isize { 0 }
    |
    = note: see issue #29633 <https://github.com/rust-lang/rust/issues/29633> for more information
    = help: add `#![feature(start)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-stmt_expr_attributes.stderr b/tests/ui/feature-gates/feature-gate-stmt_expr_attributes.stderr
index 4ff85dc0797..67fdae030c0 100644
--- a/tests/ui/feature-gates/feature-gate-stmt_expr_attributes.stderr
+++ b/tests/ui/feature-gates/feature-gate-stmt_expr_attributes.stderr
@@ -6,6 +6,7 @@ LL | const X: i32 = #[allow(dead_code)] 8;
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-strict_provenance.stderr b/tests/ui/feature-gates/feature-gate-strict_provenance.stderr
index 36224ee864b..82078d576ad 100644
--- a/tests/ui/feature-gates/feature-gate-strict_provenance.stderr
+++ b/tests/ui/feature-gates/feature-gate-strict_provenance.stderr
@@ -7,6 +7,7 @@ LL | #![deny(fuzzy_provenance_casts)]
    = note: the `fuzzy_provenance_casts` lint is unstable
    = note: see issue #95228 <https://github.com/rust-lang/rust/issues/95228> for more information
    = help: add `#![feature(strict_provenance)]` 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: `#[warn(unknown_lints)]` on by default
 
 warning: unknown lint: `lossy_provenance_casts`
@@ -18,6 +19,7 @@ LL | #![deny(lossy_provenance_casts)]
    = note: the `lossy_provenance_casts` lint is unstable
    = note: see issue #95228 <https://github.com/rust-lang/rust/issues/95228> for more information
    = help: add `#![feature(strict_provenance)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: 2 warnings emitted
 
diff --git a/tests/ui/feature-gates/feature-gate-test_unstable_lint.stderr b/tests/ui/feature-gates/feature-gate-test_unstable_lint.stderr
index aec32ac4abb..5dc303da742 100644
--- a/tests/ui/feature-gates/feature-gate-test_unstable_lint.stderr
+++ b/tests/ui/feature-gates/feature-gate-test_unstable_lint.stderr
@@ -6,6 +6,7 @@ LL | #![allow(test_unstable_lint)]
    |
    = note: the `test_unstable_lint` lint is unstable
    = help: add `#![feature(test_unstable_lint)]` 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: `#[warn(unknown_lints)]` on by default
 
 warning: 1 warning emitted
diff --git a/tests/ui/feature-gates/feature-gate-thread_local.stderr b/tests/ui/feature-gates/feature-gate-thread_local.stderr
index 8fbbfb59a48..de6debafb9d 100644
--- a/tests/ui/feature-gates/feature-gate-thread_local.stderr
+++ b/tests/ui/feature-gates/feature-gate-thread_local.stderr
@@ -6,6 +6,7 @@ LL | #[thread_local]
    |
    = note: see issue #29594 <https://github.com/rust-lang/rust/issues/29594> for more information
    = help: add `#![feature(thread_local)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-trace_macros.stderr b/tests/ui/feature-gates/feature-gate-trace_macros.stderr
index 305186e5117..68d3f75e995 100644
--- a/tests/ui/feature-gates/feature-gate-trace_macros.stderr
+++ b/tests/ui/feature-gates/feature-gate-trace_macros.stderr
@@ -6,6 +6,7 @@ LL |     trace_macros!(true);
    |
    = note: see issue #29598 <https://github.com/rust-lang/rust/issues/29598> for more information
    = help: add `#![feature(trace_macros)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-trait-alias.stderr b/tests/ui/feature-gates/feature-gate-trait-alias.stderr
index 919a97673fb..175c16cf366 100644
--- a/tests/ui/feature-gates/feature-gate-trait-alias.stderr
+++ b/tests/ui/feature-gates/feature-gate-trait-alias.stderr
@@ -6,6 +6,7 @@ LL | trait Foo = Default;
    |
    = note: see issue #41517 <https://github.com/rust-lang/rust/issues/41517> for more information
    = help: add `#![feature(trait_alias)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-transparent_unions.stderr b/tests/ui/feature-gates/feature-gate-transparent_unions.stderr
index 13ea3603a8d..fc1dc12c571 100644
--- a/tests/ui/feature-gates/feature-gate-transparent_unions.stderr
+++ b/tests/ui/feature-gates/feature-gate-transparent_unions.stderr
@@ -6,6 +6,7 @@ LL | union OkButUnstableUnion {
    |
    = note: see issue #60405 <https://github.com/rust-lang/rust/issues/60405> for more information
    = help: add `#![feature(transparent_unions)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-try_blocks.stderr b/tests/ui/feature-gates/feature-gate-try_blocks.stderr
index 028dff34c9d..dbef7fbe9d2 100644
--- a/tests/ui/feature-gates/feature-gate-try_blocks.stderr
+++ b/tests/ui/feature-gates/feature-gate-try_blocks.stderr
@@ -10,6 +10,7 @@ LL | |     };
    |
    = note: see issue #31436 <https://github.com/rust-lang/rust/issues/31436> for more information
    = help: add `#![feature(try_blocks)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-type_ascription.stderr b/tests/ui/feature-gates/feature-gate-type_ascription.stderr
index 2c78e4e3832..88da58d07e1 100644
--- a/tests/ui/feature-gates/feature-gate-type_ascription.stderr
+++ b/tests/ui/feature-gates/feature-gate-type_ascription.stderr
@@ -6,6 +6,7 @@ LL |     let a = type_ascribe!(10, u8);
    |
    = note: see issue #23416 <https://github.com/rust-lang/rust/issues/23416> for more information
    = help: add `#![feature(type_ascription)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-type_privacy_lints.stderr b/tests/ui/feature-gates/feature-gate-type_privacy_lints.stderr
index 5cc30de9c57..72ac3792fff 100644
--- a/tests/ui/feature-gates/feature-gate-type_privacy_lints.stderr
+++ b/tests/ui/feature-gates/feature-gate-type_privacy_lints.stderr
@@ -7,6 +7,7 @@ LL | #![warn(unnameable_types)]
    = note: the `unnameable_types` lint is unstable
    = note: see issue #48054 <https://github.com/rust-lang/rust/issues/48054> for more information
    = help: add `#![feature(type_privacy_lints)]` 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: `#[warn(unknown_lints)]` on by default
 
 warning: 1 warning emitted
diff --git a/tests/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.stderr b/tests/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.stderr
index b417dfb506a..5d598ec2969 100644
--- a/tests/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.stderr
+++ b/tests/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.stderr
@@ -6,6 +6,7 @@ LL |     extern "rust-call" fn call(self, args: ()) -> () {}
    |
    = 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[E0658]: rust-call ABI is subject to change
   --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:22:12
@@ -15,6 +16,7 @@ LL |     extern "rust-call" fn call_once(self, args: ()) -> () {}
    |
    = 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[E0658]: rust-call ABI is subject to change
   --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:30:12
@@ -24,6 +26,7 @@ LL |     extern "rust-call" fn call_mut(&self, args: ()) -> () {}
    |
    = 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[E0658]: rust-call ABI is subject to change
   --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:39:12
@@ -33,6 +36,7 @@ LL |     extern "rust-call" fn call_once(&self, args: ()) -> () {}
    |
    = 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[E0658]: the precise format of `Fn`-family traits' type parameters is subject to change
   --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:9:6
@@ -42,6 +46,7 @@ LL | impl Fn<()> for Foo {
    |
    = 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/feature-gate-unboxed-closures-manual-impls.rs:9:6
@@ -79,6 +84,7 @@ LL | impl FnMut<()> for Bar {
    |
    = 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 `FnMut` are experimental
   --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:26:6
@@ -96,6 +102,7 @@ LL | impl FnOnce<()> for Baz {
    |
    = 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 `FnOnce` are experimental
   --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:35:6
diff --git a/tests/ui/feature-gates/feature-gate-unboxed-closures-method-calls.stderr b/tests/ui/feature-gates/feature-gate-unboxed-closures-method-calls.stderr
index c61382c64f5..0ef732d391b 100644
--- a/tests/ui/feature-gates/feature-gate-unboxed-closures-method-calls.stderr
+++ b/tests/ui/feature-gates/feature-gate-unboxed-closures-method-calls.stderr
@@ -6,6 +6,7 @@ LL |     f.call(());
    |
    = note: see issue #29625 <https://github.com/rust-lang/rust/issues/29625> for more information
    = help: add `#![feature(fn_traits)]` 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]: use of unstable library feature 'fn_traits'
   --> $DIR/feature-gate-unboxed-closures-method-calls.rs:5:7
@@ -15,6 +16,7 @@ LL |     f.call_mut(());
    |
    = note: see issue #29625 <https://github.com/rust-lang/rust/issues/29625> for more information
    = help: add `#![feature(fn_traits)]` 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]: use of unstable library feature 'fn_traits'
   --> $DIR/feature-gate-unboxed-closures-method-calls.rs:6:7
@@ -24,6 +26,7 @@ LL |     f.call_once(());
    |
    = note: see issue #29625 <https://github.com/rust-lang/rust/issues/29625> for more information
    = help: add `#![feature(fn_traits)]` 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
 
diff --git a/tests/ui/feature-gates/feature-gate-unboxed-closures-ufcs-calls.stderr b/tests/ui/feature-gates/feature-gate-unboxed-closures-ufcs-calls.stderr
index 50eaeecde3d..f4d75fc6a86 100644
--- a/tests/ui/feature-gates/feature-gate-unboxed-closures-ufcs-calls.stderr
+++ b/tests/ui/feature-gates/feature-gate-unboxed-closures-ufcs-calls.stderr
@@ -6,6 +6,7 @@ LL |     Fn::call(&f, ());
    |
    = note: see issue #29625 <https://github.com/rust-lang/rust/issues/29625> for more information
    = help: add `#![feature(fn_traits)]` 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]: use of unstable library feature 'fn_traits'
   --> $DIR/feature-gate-unboxed-closures-ufcs-calls.rs:5:5
@@ -15,6 +16,7 @@ LL |     FnMut::call_mut(&mut f, ());
    |
    = note: see issue #29625 <https://github.com/rust-lang/rust/issues/29625> for more information
    = help: add `#![feature(fn_traits)]` 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]: use of unstable library feature 'fn_traits'
   --> $DIR/feature-gate-unboxed-closures-ufcs-calls.rs:6:5
@@ -24,6 +26,7 @@ LL |     FnOnce::call_once(f, ());
    |
    = note: see issue #29625 <https://github.com/rust-lang/rust/issues/29625> for more information
    = help: add `#![feature(fn_traits)]` 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
 
diff --git a/tests/ui/feature-gates/feature-gate-unboxed-closures.stderr b/tests/ui/feature-gates/feature-gate-unboxed-closures.stderr
index a763c28de60..52c18ec34c5 100644
--- a/tests/ui/feature-gates/feature-gate-unboxed-closures.stderr
+++ b/tests/ui/feature-gates/feature-gate-unboxed-closures.stderr
@@ -6,6 +6,7 @@ LL |     extern "rust-call" fn call_once(self, (a, b): (u32, u32)) -> u32 {
    |
    = 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[E0658]: the precise format of `Fn`-family traits' type parameters is subject to change
   --> $DIR/feature-gate-unboxed-closures.rs:5:6
@@ -15,6 +16,7 @@ LL | impl FnOnce<(u32, u32)> for Test {
    |
    = 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 `FnOnce` are experimental
   --> $DIR/feature-gate-unboxed-closures.rs:5:6
diff --git a/tests/ui/feature-gates/feature-gate-unix_sigpipe.stderr b/tests/ui/feature-gates/feature-gate-unix_sigpipe.stderr
index 6fbade424b8..88c18e72683 100644
--- a/tests/ui/feature-gates/feature-gate-unix_sigpipe.stderr
+++ b/tests/ui/feature-gates/feature-gate-unix_sigpipe.stderr
@@ -6,6 +6,7 @@ LL | #[unix_sigpipe = "inherit"]
    |
    = note: see issue #97889 <https://github.com/rust-lang/rust/issues/97889> for more information
    = help: add `#![feature(unix_sigpipe)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-unnamed_fields.stderr b/tests/ui/feature-gates/feature-gate-unnamed_fields.stderr
index f026f2c3600..82f08912bc8 100644
--- a/tests/ui/feature-gates/feature-gate-unnamed_fields.stderr
+++ b/tests/ui/feature-gates/feature-gate-unnamed_fields.stderr
@@ -6,6 +6,7 @@ LL |     _: union {
    |
    = note: see issue #49804 <https://github.com/rust-lang/rust/issues/49804> for more information
    = help: add `#![feature(unnamed_fields)]` 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]: unnamed fields are not yet fully implemented
   --> $DIR/feature-gate-unnamed_fields.rs:3:8
@@ -21,6 +22,7 @@ LL | |     }
    |
    = note: see issue #49804 <https://github.com/rust-lang/rust/issues/49804> for more information
    = help: add `#![feature(unnamed_fields)]` 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]: unnamed fields are not yet fully implemented
   --> $DIR/feature-gate-unnamed_fields.rs:13:5
@@ -30,6 +32,7 @@ LL |     _: struct {
    |
    = note: see issue #49804 <https://github.com/rust-lang/rust/issues/49804> for more information
    = help: add `#![feature(unnamed_fields)]` 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]: unnamed fields are not yet fully implemented
   --> $DIR/feature-gate-unnamed_fields.rs:13:8
@@ -45,6 +48,7 @@ LL | |     }
    |
    = note: see issue #49804 <https://github.com/rust-lang/rust/issues/49804> for more information
    = help: add `#![feature(unnamed_fields)]` 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]: unnamed fields are not yet fully implemented
   --> $DIR/feature-gate-unnamed_fields.rs:23:5
@@ -54,6 +58,7 @@ LL |     _: S
    |
    = note: see issue #49804 <https://github.com/rust-lang/rust/issues/49804> for more information
    = help: add `#![feature(unnamed_fields)]` 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: anonymous unions are unimplemented
   --> $DIR/feature-gate-unnamed_fields.rs:3:8
diff --git a/tests/ui/feature-gates/feature-gate-unsized_tuple_coercion.stderr b/tests/ui/feature-gates/feature-gate-unsized_tuple_coercion.stderr
index dd5a1cd89e7..251928658df 100644
--- a/tests/ui/feature-gates/feature-gate-unsized_tuple_coercion.stderr
+++ b/tests/ui/feature-gates/feature-gate-unsized_tuple_coercion.stderr
@@ -6,6 +6,7 @@ LL |     let _ : &(dyn Send,) = &((),);
    |
    = note: see issue #42877 <https://github.com/rust-lang/rust/issues/42877> for more information
    = help: add `#![feature(unsized_tuple_coercion)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/feature-gate-used_with_arg.stderr b/tests/ui/feature-gates/feature-gate-used_with_arg.stderr
index d115bf4e365..6288715604f 100644
--- a/tests/ui/feature-gates/feature-gate-used_with_arg.stderr
+++ b/tests/ui/feature-gates/feature-gate-used_with_arg.stderr
@@ -6,6 +6,7 @@ LL | #[used(linker)]
    |
    = note: see issue #93798 <https://github.com/rust-lang/rust/issues/93798> for more information
    = help: add `#![feature(used_with_arg)]` 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]: `#[used(compiler)]` is currently unstable
   --> $DIR/feature-gate-used_with_arg.rs:4:1
@@ -15,6 +16,7 @@ LL | #[used(compiler)]
    |
    = note: see issue #93798 <https://github.com/rust-lang/rust/issues/93798> for more information
    = help: add `#![feature(used_with_arg)]` 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 2 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-vectorcall.stderr b/tests/ui/feature-gates/feature-gate-vectorcall.stderr
index 55ee76ec3f1..df93e8812c1 100644
--- a/tests/ui/feature-gates/feature-gate-vectorcall.stderr
+++ b/tests/ui/feature-gates/feature-gate-vectorcall.stderr
@@ -5,6 +5,7 @@ LL | extern "vectorcall" fn f() {}
    |        ^^^^^^^^^^^^
    |
    = help: add `#![feature(abi_vectorcall)]` 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]: vectorcall is experimental and subject to change
   --> $DIR/feature-gate-vectorcall.rs:15:12
@@ -13,6 +14,7 @@ LL |     extern "vectorcall" fn m();
    |            ^^^^^^^^^^^^
    |
    = help: add `#![feature(abi_vectorcall)]` 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]: vectorcall is experimental and subject to change
   --> $DIR/feature-gate-vectorcall.rs:17:12
@@ -21,6 +23,7 @@ LL |     extern "vectorcall" fn dm() {}
    |            ^^^^^^^^^^^^
    |
    = help: add `#![feature(abi_vectorcall)]` 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]: vectorcall is experimental and subject to change
   --> $DIR/feature-gate-vectorcall.rs:22:12
@@ -29,6 +32,7 @@ LL |     extern "vectorcall" fn m() {}
    |            ^^^^^^^^^^^^
    |
    = help: add `#![feature(abi_vectorcall)]` 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]: vectorcall is experimental and subject to change
   --> $DIR/feature-gate-vectorcall.rs:26:12
@@ -37,6 +41,7 @@ LL |     extern "vectorcall" fn im() {}
    |            ^^^^^^^^^^^^
    |
    = help: add `#![feature(abi_vectorcall)]` 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]: vectorcall is experimental and subject to change
   --> $DIR/feature-gate-vectorcall.rs:29:18
@@ -45,6 +50,7 @@ LL | type TA = extern "vectorcall" fn();
    |                  ^^^^^^^^^^^^
    |
    = help: add `#![feature(abi_vectorcall)]` 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]: vectorcall is experimental and subject to change
   --> $DIR/feature-gate-vectorcall.rs:31:8
@@ -53,6 +59,7 @@ LL | extern "vectorcall" {}
    |        ^^^^^^^^^^^^
    |
    = help: add `#![feature(abi_vectorcall)]` 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 7 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-wasm_abi.stderr b/tests/ui/feature-gates/feature-gate-wasm_abi.stderr
index 0140002e350..973c42af19c 100644
--- a/tests/ui/feature-gates/feature-gate-wasm_abi.stderr
+++ b/tests/ui/feature-gates/feature-gate-wasm_abi.stderr
@@ -6,6 +6,7 @@ LL | extern "wasm" fn fu() {}
    |
    = note: see issue #83788 <https://github.com/rust-lang/rust/issues/83788> for more information
    = help: add `#![feature(wasm_abi)]` 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]: wasm ABI is experimental and subject to change
   --> $DIR/feature-gate-wasm_abi.rs:11:12
@@ -15,6 +16,7 @@ LL |     extern "wasm" fn mu();
    |
    = note: see issue #83788 <https://github.com/rust-lang/rust/issues/83788> for more information
    = help: add `#![feature(wasm_abi)]` 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]: wasm ABI is experimental and subject to change
   --> $DIR/feature-gate-wasm_abi.rs:12:12
@@ -24,6 +26,7 @@ LL |     extern "wasm" fn dmu() {}
    |
    = note: see issue #83788 <https://github.com/rust-lang/rust/issues/83788> for more information
    = help: add `#![feature(wasm_abi)]` 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]: wasm ABI is experimental and subject to change
   --> $DIR/feature-gate-wasm_abi.rs:17:12
@@ -33,6 +36,7 @@ LL |     extern "wasm" fn mu() {}
    |
    = note: see issue #83788 <https://github.com/rust-lang/rust/issues/83788> for more information
    = help: add `#![feature(wasm_abi)]` 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]: wasm ABI is experimental and subject to change
   --> $DIR/feature-gate-wasm_abi.rs:21:12
@@ -42,6 +46,7 @@ LL |     extern "wasm" fn imu() {}
    |
    = note: see issue #83788 <https://github.com/rust-lang/rust/issues/83788> for more information
    = help: add `#![feature(wasm_abi)]` 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]: wasm ABI is experimental and subject to change
   --> $DIR/feature-gate-wasm_abi.rs:24:19
@@ -51,6 +56,7 @@ LL | type TAU = extern "wasm" fn();
    |
    = note: see issue #83788 <https://github.com/rust-lang/rust/issues/83788> for more information
    = help: add `#![feature(wasm_abi)]` 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]: wasm ABI is experimental and subject to change
   --> $DIR/feature-gate-wasm_abi.rs:26:8
@@ -60,6 +66,7 @@ LL | extern "wasm" {}
    |
    = note: see issue #83788 <https://github.com/rust-lang/rust/issues/83788> for more information
    = help: add `#![feature(wasm_abi)]` 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 7 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-yeet_expr-in-cfg.stderr b/tests/ui/feature-gates/feature-gate-yeet_expr-in-cfg.stderr
index f90c379bdaf..890517b2506 100644
--- a/tests/ui/feature-gates/feature-gate-yeet_expr-in-cfg.stderr
+++ b/tests/ui/feature-gates/feature-gate-yeet_expr-in-cfg.stderr
@@ -6,6 +6,7 @@ LL |         do yeet
    |
    = note: see issue #96373 <https://github.com/rust-lang/rust/issues/96373> for more information
    = help: add `#![feature(yeet_expr)]` 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]: `do yeet` expression is experimental
   --> $DIR/feature-gate-yeet_expr-in-cfg.rs:14:5
@@ -15,6 +16,7 @@ LL |     do yeet "hello";
    |
    = note: see issue #96373 <https://github.com/rust-lang/rust/issues/96373> for more information
    = help: add `#![feature(yeet_expr)]` 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 2 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gate-yeet_expr.stderr b/tests/ui/feature-gates/feature-gate-yeet_expr.stderr
index 8d1b92370fb..4c576714357 100644
--- a/tests/ui/feature-gates/feature-gate-yeet_expr.stderr
+++ b/tests/ui/feature-gates/feature-gate-yeet_expr.stderr
@@ -6,6 +6,7 @@ LL |     do yeet
    |
    = note: see issue #96373 <https://github.com/rust-lang/rust/issues/96373> for more information
    = help: add `#![feature(yeet_expr)]` 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]: `do yeet` expression is experimental
   --> $DIR/feature-gate-yeet_expr.rs:8:5
@@ -15,6 +16,7 @@ LL |     do yeet "hello";
    |
    = note: see issue #96373 <https://github.com/rust-lang/rust/issues/96373> for more information
    = help: add `#![feature(yeet_expr)]` 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 2 previous errors
 
diff --git a/tests/ui/feature-gates/feature-gated-feature-in-macro-arg.stderr b/tests/ui/feature-gates/feature-gated-feature-in-macro-arg.stderr
index 0053d9d5cff..b0ed6e60760 100644
--- a/tests/ui/feature-gates/feature-gated-feature-in-macro-arg.stderr
+++ b/tests/ui/feature-gates/feature-gated-feature-in-macro-arg.stderr
@@ -5,6 +5,7 @@ LL |         extern "rust-intrinsic" {
    |                ^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(intrinsics)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/issue-43106-gating-of-builtin-attrs-error.rs b/tests/ui/feature-gates/issue-43106-gating-of-builtin-attrs-error.rs
index 0f833f793bd..bd3b69c2b4a 100644
--- a/tests/ui/feature-gates/issue-43106-gating-of-builtin-attrs-error.rs
+++ b/tests/ui/feature-gates/issue-43106-gating-of-builtin-attrs-error.rs
@@ -13,6 +13,7 @@
 //~^ ERROR: `macro_export` attribute cannot be used at crate level
 #![rustc_main] //~ ERROR: the `#[rustc_main]` attribute is used internally to specify
 //~^ ERROR: `rustc_main` attribute cannot be used at crate level
+//~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 #![start]
 //~^ ERROR: `start` attribute cannot be used at crate level
 #![repr()]
diff --git a/tests/ui/feature-gates/issue-43106-gating-of-builtin-attrs-error.stderr b/tests/ui/feature-gates/issue-43106-gating-of-builtin-attrs-error.stderr
index f01153dcb96..89fa2abffc2 100644
--- a/tests/ui/feature-gates/issue-43106-gating-of-builtin-attrs-error.stderr
+++ b/tests/ui/feature-gates/issue-43106-gating-of-builtin-attrs-error.stderr
@@ -5,9 +5,10 @@ LL | #![rustc_main]
    | ^^^^^^^^^^^^^^
    |
    = help: add `#![feature(rustc_attrs)]` 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: attribute must be of the form `#[inline]` or `#[inline(always|never)]`
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:46:5
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:47:5
    |
 LL |     #[inline = "2100"] fn f() { }
    |     ^^^^^^^^^^^^^^^^^^
@@ -17,37 +18,37 @@ LL |     #[inline = "2100"] fn f() { }
    = note: `#[deny(ill_formed_attribute_input)]` on by default
 
 error: `start` attribute can only be used on functions
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:125:1
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:126:1
    |
 LL | #[start]
    | ^^^^^^^^
 
 error: `start` attribute can only be used on functions
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:128:17
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:129:17
    |
 LL |     mod inner { #![start] }
    |                 ^^^^^^^^^
 
 error: `start` attribute can only be used on functions
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:133:5
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:134:5
    |
 LL |     #[start] struct S;
    |     ^^^^^^^^
 
 error: `start` attribute can only be used on functions
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:136:5
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:137:5
    |
 LL |     #[start] type T = S;
    |     ^^^^^^^^
 
 error: `start` attribute can only be used on functions
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:139:5
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:140:5
    |
 LL |     #[start] impl S { }
    |     ^^^^^^^^
 
 error[E0518]: attribute should be applied to function or closure
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:31:1
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:32:1
    |
 LL |   #[inline]
    |   ^^^^^^^^^
@@ -62,7 +63,7 @@ LL | | }
    | |_- not a function or closure
 
 error: attribute should be applied to an `extern crate` item
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:65:1
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:66:1
    |
 LL |   #[no_link]
    |   ^^^^^^^^^^
@@ -77,7 +78,7 @@ LL | | }
    | |_- not an `extern crate` item
 
 error: attribute should be applied to a free function, impl method or static
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:91:1
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:92:1
    |
 LL |   #[export_name = "2200"]
    |   ^^^^^^^^^^^^^^^^^^^^^^^
@@ -92,7 +93,7 @@ LL | | }
    | |_- not a free function, impl method or static
 
 error[E0517]: attribute should be applied to a struct, enum, or union
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:143:8
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:144:8
    |
 LL |   #[repr(C)]
    |          ^
@@ -107,19 +108,19 @@ LL | | }
    | |_- not a struct, enum, or union
 
 error: attribute should be applied to an `extern crate` item
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:25:1
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:26:1
    |
 LL | #![no_link]
    | ^^^^^^^^^^^ not an `extern crate` item
 
 error: attribute should be applied to a free function, impl method or static
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:27:1
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:28:1
    |
 LL | #![export_name = "2200"]
    | ^^^^^^^^^^^^^^^^^^^^^^^^ not a free function, impl method or static
 
 error[E0518]: attribute should be applied to function or closure
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:29:1
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:30:1
    |
 LL | #![inline]
    | ^^^^^^^^^^ not a function or closure
@@ -155,7 +156,7 @@ LL + #[rustc_main]
    |
 
 error: `start` attribute cannot be used at crate level
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:16:1
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:17:1
    |
 LL | #![start]
    | ^^^^^^^^^
@@ -170,7 +171,7 @@ LL + #[start]
    |
 
 error: `repr` attribute cannot be used at crate level
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:18:1
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:19:1
    |
 LL | #![repr()]
    | ^^^^^^^^^^
@@ -185,7 +186,7 @@ LL + #[repr()]
    |
 
 error: `path` attribute cannot be used at crate level
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:20:1
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:21:1
    |
 LL | #![path = "3800"]
    | ^^^^^^^^^^^^^^^^^
@@ -200,7 +201,7 @@ LL + #[path = "3800"]
    |
 
 error: `automatically_derived` attribute cannot be used at crate level
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:22:1
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:23:1
    |
 LL | #![automatically_derived]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -215,115 +216,115 @@ LL + #[automatically_derived]
    |
 
 error[E0518]: attribute should be applied to function or closure
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:42:17
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:43:17
    |
 LL |     mod inner { #![inline] }
    |     ------------^^^^^^^^^^-- not a function or closure
 
 error[E0518]: attribute should be applied to function or closure
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:52:5
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:53:5
    |
 LL |     #[inline] struct S;
    |     ^^^^^^^^^ --------- not a function or closure
 
 error[E0518]: attribute should be applied to function or closure
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:56:5
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:57:5
    |
 LL |     #[inline] type T = S;
    |     ^^^^^^^^^ ----------- not a function or closure
 
 error[E0518]: attribute should be applied to function or closure
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:60:5
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:61:5
    |
 LL |     #[inline] impl S { }
    |     ^^^^^^^^^ ---------- not a function or closure
 
 error: attribute should be applied to an `extern crate` item
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:70:17
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:71:17
    |
 LL |     mod inner { #![no_link] }
    |     ------------^^^^^^^^^^^-- not an `extern crate` item
 
 error: attribute should be applied to an `extern crate` item
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:74:5
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:75:5
    |
 LL |     #[no_link] fn f() { }
    |     ^^^^^^^^^^ ---------- not an `extern crate` item
 
 error: attribute should be applied to an `extern crate` item
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:78:5
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:79:5
    |
 LL |     #[no_link] struct S;
    |     ^^^^^^^^^^ --------- not an `extern crate` item
 
 error: attribute should be applied to an `extern crate` item
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:82:5
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:83:5
    |
 LL |     #[no_link]type T = S;
    |     ^^^^^^^^^^----------- not an `extern crate` item
 
 error: attribute should be applied to an `extern crate` item
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:86:5
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:87:5
    |
 LL |     #[no_link] impl S { }
    |     ^^^^^^^^^^ ---------- not an `extern crate` item
 
 error: attribute should be applied to a free function, impl method or static
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:96:17
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:97:17
    |
 LL |     mod inner { #![export_name="2200"] }
    |     ------------^^^^^^^^^^^^^^^^^^^^^^-- not a free function, impl method or static
 
 error: attribute should be applied to a free function, impl method or static
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:102:5
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:103:5
    |
 LL |     #[export_name = "2200"] struct S;
    |     ^^^^^^^^^^^^^^^^^^^^^^^ --------- not a free function, impl method or static
 
 error: attribute should be applied to a free function, impl method or static
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:106:5
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:107:5
    |
 LL |     #[export_name = "2200"] type T = S;
    |     ^^^^^^^^^^^^^^^^^^^^^^^ ----------- not a free function, impl method or static
 
 error: attribute should be applied to a free function, impl method or static
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:110:5
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:111:5
    |
 LL |     #[export_name = "2200"] impl S { }
    |     ^^^^^^^^^^^^^^^^^^^^^^^ ---------- not a free function, impl method or static
 
 error: attribute should be applied to a free function, impl method or static
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:115:9
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:116:9
    |
 LL |         #[export_name = "2200"] fn foo();
    |         ^^^^^^^^^^^^^^^^^^^^^^^ --------- not a free function, impl method or static
 
 error: attribute should be applied to a free function, impl method or static
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:119:9
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:120:9
    |
 LL |         #[export_name = "2200"] fn bar() {}
    |         ^^^^^^^^^^^^^^^^^^^^^^^ ----------- not a free function, impl method or static
 
 error[E0517]: attribute should be applied to a struct, enum, or union
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:147:25
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:148:25
    |
 LL |     mod inner { #![repr(C)] }
    |     --------------------^---- not a struct, enum, or union
 
 error[E0517]: attribute should be applied to a struct, enum, or union
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:151:12
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:152:12
    |
 LL |     #[repr(C)] fn f() { }
    |            ^   ---------- not a struct, enum, or union
 
 error[E0517]: attribute should be applied to a struct, enum, or union
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:157:12
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:158:12
    |
 LL |     #[repr(C)] type T = S;
    |            ^   ----------- not a struct, enum, or union
 
 error[E0517]: attribute should be applied to a struct, enum, or union
-  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:161:12
+  --> $DIR/issue-43106-gating-of-builtin-attrs-error.rs:162:12
    |
 LL |     #[repr(C)] impl S { }
    |            ^   ---------- not a struct, enum, or union
diff --git a/tests/ui/feature-gates/issue-43106-gating-of-derive.stderr b/tests/ui/feature-gates/issue-43106-gating-of-derive.stderr
index bb8651ffb09..4dee7a00544 100644
--- a/tests/ui/feature-gates/issue-43106-gating-of-derive.stderr
+++ b/tests/ui/feature-gates/issue-43106-gating-of-derive.stderr
@@ -21,6 +21,7 @@ LL |     mod inner { #![derive(Debug)] }
    |
    = note: see issue #54726 <https://github.com/rust-lang/rust/issues/54726> for more information
    = help: add `#![feature(custom_inner_attributes)]` 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[E0774]: `derive` may only be applied to `struct`s, `enum`s and `union`s
   --> $DIR/issue-43106-gating-of-derive.rs:7:17
diff --git a/tests/ui/feature-gates/issue-49983-see-issue-0.stderr b/tests/ui/feature-gates/issue-49983-see-issue-0.stderr
index 5f9e5d440fb..8f090c9eef9 100644
--- a/tests/ui/feature-gates/issue-49983-see-issue-0.stderr
+++ b/tests/ui/feature-gates/issue-49983-see-issue-0.stderr
@@ -5,6 +5,7 @@ LL | #[allow(unused_imports)] use core::ptr::Unique;
    |                              ^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(ptr_internals)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/rustc-private.stderr b/tests/ui/feature-gates/rustc-private.stderr
index 7419af80a32..03397cba763 100644
--- a/tests/ui/feature-gates/rustc-private.stderr
+++ b/tests/ui/feature-gates/rustc-private.stderr
@@ -6,6 +6,7 @@ LL | extern crate libc;
    |
    = note: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
    = help: add `#![feature(rustc_private)]` 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 1 previous error
 
diff --git a/tests/ui/feature-gates/soft-syntax-gates-with-errors.stderr b/tests/ui/feature-gates/soft-syntax-gates-with-errors.stderr
index 49550d811ba..6f7b402d03b 100644
--- a/tests/ui/feature-gates/soft-syntax-gates-with-errors.stderr
+++ b/tests/ui/feature-gates/soft-syntax-gates-with-errors.stderr
@@ -6,6 +6,7 @@ LL | macro a() {}
    |
    = note: see issue #39412 <https://github.com/rust-lang/rust/issues/39412> for more information
    = help: add `#![feature(decl_macro)]` 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]: `macro` is experimental
   --> $DIR/soft-syntax-gates-with-errors.rs:16:5
@@ -15,6 +16,7 @@ LL |     macro c() {}
    |
    = note: see issue #39412 <https://github.com/rust-lang/rust/issues/39412> for more information
    = help: add `#![feature(decl_macro)]` 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 2 previous errors
 
diff --git a/tests/ui/feature-gates/soft-syntax-gates-without-errors.stderr b/tests/ui/feature-gates/soft-syntax-gates-without-errors.stderr
index 3d9c22e5487..817e28570f2 100644
--- a/tests/ui/feature-gates/soft-syntax-gates-without-errors.stderr
+++ b/tests/ui/feature-gates/soft-syntax-gates-without-errors.stderr
@@ -6,6 +6,7 @@ LL | macro b() {}
    |
    = note: see issue #39412 <https://github.com/rust-lang/rust/issues/39412> for more information
    = help: add `#![feature(decl_macro)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
    = warning: unstable syntax can change at any point in the future, causing a hard error!
    = note: for more information, see issue #65860 <https://github.com/rust-lang/rust/issues/65860>
 
@@ -17,6 +18,7 @@ LL |     macro e() {}
    |
    = note: see issue #39412 <https://github.com/rust-lang/rust/issues/39412> for more information
    = help: add `#![feature(decl_macro)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
    = warning: unstable syntax can change at any point in the future, causing a hard error!
    = note: for more information, see issue #65860 <https://github.com/rust-lang/rust/issues/65860>
 
diff --git a/tests/ui/feature-gates/trace_macros-gate.stderr b/tests/ui/feature-gates/trace_macros-gate.stderr
index 1ca10aeece5..1313a0e8ae2 100644
--- a/tests/ui/feature-gates/trace_macros-gate.stderr
+++ b/tests/ui/feature-gates/trace_macros-gate.stderr
@@ -6,6 +6,7 @@ LL |     trace_macros!();
    |
    = note: see issue #29598 <https://github.com/rust-lang/rust/issues/29598> for more information
    = help: add `#![feature(trace_macros)]` 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: trace_macros! accepts only `true` or `false`
   --> $DIR/trace_macros-gate.rs:4:5
@@ -21,6 +22,7 @@ LL |     trace_macros!(true);
    |
    = note: see issue #29598 <https://github.com/rust-lang/rust/issues/29598> for more information
    = help: add `#![feature(trace_macros)]` 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]: use of unstable library feature 'trace_macros': `trace_macros` is not stable enough for use and is subject to change
   --> $DIR/trace_macros-gate.rs:7:5
@@ -30,6 +32,7 @@ LL |     trace_macros!(false);
    |
    = note: see issue #29598 <https://github.com/rust-lang/rust/issues/29598> for more information
    = help: add `#![feature(trace_macros)]` 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]: use of unstable library feature 'trace_macros': `trace_macros` is not stable enough for use and is subject to change
   --> $DIR/trace_macros-gate.rs:10:26
@@ -42,6 +45,7 @@ LL |     expando!(true);
    |
    = note: see issue #29598 <https://github.com/rust-lang/rust/issues/29598> for more information
    = help: add `#![feature(trace_macros)]` 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: this error originates in the macro `expando` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: aborting due to 5 previous errors
diff --git a/tests/ui/generic-associated-types/issue-119942-unsatisified-gat-bound-during-assoc-ty-selection.rs b/tests/ui/generic-associated-types/issue-119942-unsatisified-gat-bound-during-assoc-ty-selection.rs
new file mode 100644
index 00000000000..252dc7d751e
--- /dev/null
+++ b/tests/ui/generic-associated-types/issue-119942-unsatisified-gat-bound-during-assoc-ty-selection.rs
@@ -0,0 +1,33 @@
+use std::ops::Deref;
+
+trait PointerFamily {
+    type Pointer<T>: Deref<Target = T>;
+}
+
+struct RcFamily;
+
+impl PointerFamily for RcFamily {
+    type Pointer<T> = dyn Deref<Target = T>;
+    //~^ ERROR the size for values of type `(dyn Deref<Target = T> + 'static)` cannot be known at compilation time
+}
+
+enum Node<T, P: PointerFamily> {
+    Cons(T, P::Pointer<Node<T, P>>),
+    Nil,
+}
+
+type RcNode<T> = Node<T, RcFamily>;
+
+impl<T, P: PointerFamily> Node<T, P>
+where
+    P::Pointer<Node<T, P>>: Sized,
+{
+    fn new() -> P::Pointer<Self> {
+        todo!()
+    }
+}
+
+fn main() {
+    let mut list = RcNode::<i32>::new();
+    //~^ ERROR the size for values of type `Node<i32, RcFamily>` cannot be known at compilation time
+}
diff --git a/tests/ui/generic-associated-types/issue-119942-unsatisified-gat-bound-during-assoc-ty-selection.stderr b/tests/ui/generic-associated-types/issue-119942-unsatisified-gat-bound-during-assoc-ty-selection.stderr
new file mode 100644
index 00000000000..3a973d356dc
--- /dev/null
+++ b/tests/ui/generic-associated-types/issue-119942-unsatisified-gat-bound-during-assoc-ty-selection.stderr
@@ -0,0 +1,52 @@
+error[E0277]: the size for values of type `(dyn Deref<Target = T> + 'static)` cannot be known at compilation time
+  --> $DIR/issue-119942-unsatisified-gat-bound-during-assoc-ty-selection.rs:10:23
+   |
+LL |     type Pointer<T> = dyn Deref<Target = T>;
+   |                       ^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
+   |
+   = help: the trait `Sized` is not implemented for `(dyn Deref<Target = T> + 'static)`
+note: required by a bound in `PointerFamily::Pointer`
+  --> $DIR/issue-119942-unsatisified-gat-bound-during-assoc-ty-selection.rs:4:5
+   |
+LL |     type Pointer<T>: Deref<Target = T>;
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `PointerFamily::Pointer`
+help: consider relaxing the implicit `Sized` restriction
+   |
+LL |     type Pointer<T>: Deref<Target = T> + ?Sized;
+   |                                        ++++++++
+
+error[E0599]: the size for values of type `Node<i32, RcFamily>` cannot be known at compilation time
+  --> $DIR/issue-119942-unsatisified-gat-bound-during-assoc-ty-selection.rs:31:35
+   |
+LL | enum Node<T, P: PointerFamily> {
+   | ------------------------------
+   | |
+   | variant or associated item `new` not found for this enum
+   | doesn't satisfy `Node<i32, RcFamily>: Sized`
+...
+LL |     let mut list = RcNode::<i32>::new();
+   |                                   ^^^ doesn't have a size known at compile-time
+  --> $SRC_DIR/core/src/ops/deref.rs:LL:COL
+   |
+   = note: doesn't satisfy `_: Sized`
+   |
+note: trait bound `Node<i32, RcFamily>: Sized` was not satisfied
+  --> $DIR/issue-119942-unsatisified-gat-bound-during-assoc-ty-selection.rs:4:18
+   |
+LL |     type Pointer<T>: Deref<Target = T>;
+   |          ------- ^ unsatisfied trait bound introduced here
+note: trait bound `(dyn Deref<Target = Node<i32, RcFamily>> + 'static): Sized` was not satisfied
+  --> $DIR/issue-119942-unsatisified-gat-bound-during-assoc-ty-selection.rs:23:29
+   |
+LL | impl<T, P: PointerFamily> Node<T, P>
+   |                           ----------
+LL | where
+LL |     P::Pointer<Node<T, P>>: Sized,
+   |                             ^^^^^ unsatisfied trait bound introduced here
+note: the trait `Sized` must be implemented
+  --> $SRC_DIR/core/src/marker.rs:LL:COL
+
+error: aborting due to 2 previous errors
+
+Some errors have detailed explanations: E0277, E0599.
+For more information about an error, try `rustc --explain E0277`.
diff --git a/tests/ui/generic-const-items/feature-gate-generic_const_items.stderr b/tests/ui/generic-const-items/feature-gate-generic_const_items.stderr
index a1fdf5f6ef3..12882bd3470 100644
--- a/tests/ui/generic-const-items/feature-gate-generic_const_items.stderr
+++ b/tests/ui/generic-const-items/feature-gate-generic_const_items.stderr
@@ -6,6 +6,7 @@ LL |     const ONE<T>: i32;
    |
    = note: see issue #113521 <https://github.com/rust-lang/rust/issues/113521> for more information
    = help: add `#![feature(generic_const_items)]` 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]: generic const items are experimental
   --> $DIR/feature-gate-generic_const_items.rs:6:5
@@ -16,6 +17,7 @@ LL | |         A: Copy;
    |
    = note: see issue #113521 <https://github.com/rust-lang/rust/issues/113521> for more information
    = help: add `#![feature(generic_const_items)]` 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]: generic const items are experimental
   --> $DIR/feature-gate-generic_const_items.rs:11:12
@@ -25,6 +27,7 @@ LL | const CONST<T>: i32 = 0;
    |
    = note: see issue #113521 <https://github.com/rust-lang/rust/issues/113521> for more information
    = help: add `#![feature(generic_const_items)]` 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]: generic const items are experimental
   --> $DIR/feature-gate-generic_const_items.rs:14:12
@@ -34,6 +37,7 @@ LL | const EMPTY<>: i32 = 0;
    |
    = note: see issue #113521 <https://github.com/rust-lang/rust/issues/113521> for more information
    = help: add `#![feature(generic_const_items)]` 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]: generic const items are experimental
   --> $DIR/feature-gate-generic_const_items.rs:18:1
@@ -44,6 +48,7 @@ LL | |     String: Clone;
    |
    = note: see issue #113521 <https://github.com/rust-lang/rust/issues/113521> for more information
    = help: add `#![feature(generic_const_items)]` 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]: generic const items are experimental
   --> $DIR/feature-gate-generic_const_items.rs:28:22
@@ -53,6 +58,7 @@ LL | discard! { const FREE<T>: () = (); }
    |
    = note: see issue #113521 <https://github.com/rust-lang/rust/issues/113521> for more information
    = help: add `#![feature(generic_const_items)]` 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]: generic const items are experimental
   --> $DIR/feature-gate-generic_const_items.rs:31:33
@@ -62,6 +68,7 @@ LL | discard! { impl () { const ASSOC<const N: ()>: () = (); } }
    |
    = note: see issue #113521 <https://github.com/rust-lang/rust/issues/113521> for more information
    = help: add `#![feature(generic_const_items)]` 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]: generic const items are experimental
   --> $DIR/feature-gate-generic_const_items.rs:34:43
@@ -71,6 +78,7 @@ LL | discard! { impl () { const ASSOC: i32 = 0 where String: Copy; } }
    |
    = note: see issue #113521 <https://github.com/rust-lang/rust/issues/113521> for more information
    = help: add `#![feature(generic_const_items)]` 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 8 previous errors
 
diff --git a/tests/ui/half-open-range-patterns/feature-gate-half-open-range-patterns-in-slices.stderr b/tests/ui/half-open-range-patterns/feature-gate-half-open-range-patterns-in-slices.stderr
index b44a69525a6..8ae8f052e5b 100644
--- a/tests/ui/half-open-range-patterns/feature-gate-half-open-range-patterns-in-slices.stderr
+++ b/tests/ui/half-open-range-patterns/feature-gate-half-open-range-patterns-in-slices.stderr
@@ -6,6 +6,7 @@ LL |     let [a @ 3.., b @ ..3, c @ 4..6, ..] = xs;
    |
    = note: see issue #67264 <https://github.com/rust-lang/rust/issues/67264> for more information
    = help: add `#![feature(half_open_range_patterns_in_slices)]` 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 1 previous error
 
diff --git a/tests/ui/half-open-range-patterns/range_pat_interactions1.stderr b/tests/ui/half-open-range-patterns/range_pat_interactions1.stderr
index 19ebcaf0f36..e2fab14ffc2 100644
--- a/tests/ui/half-open-range-patterns/range_pat_interactions1.stderr
+++ b/tests/ui/half-open-range-patterns/range_pat_interactions1.stderr
@@ -20,6 +20,7 @@ LL |         if let n @ 2..3|4 = x {
    |
    = note: see issue #37854 <https://github.com/rust-lang/rust/issues/37854> for more information
    = help: add `#![feature(exclusive_range_pattern)]` 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]: exclusive range pattern syntax is experimental
   --> $DIR/range_pat_interactions1.rs:14:23
@@ -29,6 +30,7 @@ LL |         } else if let 2..3 | 4 = x {
    |
    = note: see issue #37854 <https://github.com/rust-lang/rust/issues/37854> for more information
    = help: add `#![feature(exclusive_range_pattern)]` 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 4 previous errors
 
diff --git a/tests/ui/half-open-range-patterns/range_pat_interactions3.stderr b/tests/ui/half-open-range-patterns/range_pat_interactions3.stderr
index f7fda67758f..fe233496261 100644
--- a/tests/ui/half-open-range-patterns/range_pat_interactions3.stderr
+++ b/tests/ui/half-open-range-patterns/range_pat_interactions3.stderr
@@ -6,6 +6,7 @@ LL |             y @ 0..const { 5 + 1 } => assert_eq!(y, 5),
    |
    = note: see issue #76001 <https://github.com/rust-lang/rust/issues/76001> for more information
    = help: add `#![feature(inline_const_pat)]` 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]: exclusive range pattern syntax is experimental
   --> $DIR/range_pat_interactions3.rs:10:17
@@ -15,6 +16,7 @@ LL |             1 | -3..0 => first_or.push(x),
    |
    = note: see issue #37854 <https://github.com/rust-lang/rust/issues/37854> for more information
    = help: add `#![feature(exclusive_range_pattern)]` 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]: exclusive range pattern syntax is experimental
   --> $DIR/range_pat_interactions3.rs:12:18
@@ -24,6 +26,7 @@ LL |             y @ (0..5 | 6) => or_two.push(y),
    |
    = note: see issue #37854 <https://github.com/rust-lang/rust/issues/37854> for more information
    = help: add `#![feature(exclusive_range_pattern)]` 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]: exclusive range pattern syntax is experimental
   --> $DIR/range_pat_interactions3.rs:14:17
@@ -33,6 +36,7 @@ LL |             y @ 0..const { 5 + 1 } => assert_eq!(y, 5),
    |
    = note: see issue #37854 <https://github.com/rust-lang/rust/issues/37854> for more information
    = help: add `#![feature(exclusive_range_pattern)]` 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]: exclusive range pattern syntax is experimental
   --> $DIR/range_pat_interactions3.rs:18:17
@@ -42,6 +46,7 @@ LL |             y @ ..-7 => assert_eq!(y, -8),
    |
    = note: see issue #37854 <https://github.com/rust-lang/rust/issues/37854> for more information
    = help: add `#![feature(exclusive_range_pattern)]` 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 5 previous errors
 
diff --git a/tests/ui/half-open-range-patterns/slice_pattern_syntax_problem1.stderr b/tests/ui/half-open-range-patterns/slice_pattern_syntax_problem1.stderr
index 3bca554b1e5..5edd877bee0 100644
--- a/tests/ui/half-open-range-patterns/slice_pattern_syntax_problem1.stderr
+++ b/tests/ui/half-open-range-patterns/slice_pattern_syntax_problem1.stderr
@@ -6,6 +6,7 @@ LL |     let [a @ 3.., b @ ..3, c @ 4..6, ..] = xs;
    |
    = note: see issue #67264 <https://github.com/rust-lang/rust/issues/67264> for more information
    = help: add `#![feature(half_open_range_patterns_in_slices)]` 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]: exclusive range pattern syntax is experimental
   --> $DIR/slice_pattern_syntax_problem1.rs:4:23
@@ -15,6 +16,7 @@ LL |     let [a @ 3.., b @ ..3, c @ 4..6, ..] = xs;
    |
    = note: see issue #37854 <https://github.com/rust-lang/rust/issues/37854> for more information
    = help: add `#![feature(exclusive_range_pattern)]` 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]: exclusive range pattern syntax is experimental
   --> $DIR/slice_pattern_syntax_problem1.rs:4:32
@@ -24,6 +26,7 @@ LL |     let [a @ 3.., b @ ..3, c @ 4..6, ..] = xs;
    |
    = note: see issue #37854 <https://github.com/rust-lang/rust/issues/37854> for more information
    = help: add `#![feature(exclusive_range_pattern)]` 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
 
diff --git a/tests/ui/higher-ranked/trait-bounds/hrtb-wrong-kind.stderr b/tests/ui/higher-ranked/trait-bounds/hrtb-wrong-kind.stderr
index 765ea9f7854..b512e0bdb43 100644
--- a/tests/ui/higher-ranked/trait-bounds/hrtb-wrong-kind.stderr
+++ b/tests/ui/higher-ranked/trait-bounds/hrtb-wrong-kind.stderr
@@ -6,6 +6,7 @@ LL | fn a() where for<T> T: Copy {}
    |
    = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
    = help: add `#![feature(non_lifetime_binders)]` 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]: only lifetime parameters can be used in this context
   --> $DIR/hrtb-wrong-kind.rs:4:24
@@ -15,6 +16,7 @@ LL | fn b() where for<const C: usize> [(); C]: Copy {}
    |
    = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
    = help: add `#![feature(non_lifetime_binders)]` 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 2 previous errors
 
diff --git a/tests/ui/higher-ranked/trait-bounds/issue-59311.rs b/tests/ui/higher-ranked/trait-bounds/issue-59311.rs
index 3ad548450e5..387c78a802a 100644
--- a/tests/ui/higher-ranked/trait-bounds/issue-59311.rs
+++ b/tests/ui/higher-ranked/trait-bounds/issue-59311.rs
@@ -17,6 +17,7 @@ where
     v.t(|| {});
     //~^ ERROR: higher-ranked lifetime error
     //~| ERROR: higher-ranked lifetime error
+    //~| ERROR: higher-ranked lifetime error
 }
 
 fn main() {}
diff --git a/tests/ui/higher-ranked/trait-bounds/issue-59311.stderr b/tests/ui/higher-ranked/trait-bounds/issue-59311.stderr
index e50aad876d8..3053a299802 100644
--- a/tests/ui/higher-ranked/trait-bounds/issue-59311.stderr
+++ b/tests/ui/higher-ranked/trait-bounds/issue-59311.stderr
@@ -7,6 +7,15 @@ LL |     v.t(|| {});
    = note: could not prove `{closure@$DIR/issue-59311.rs:17:9: 17:11} well-formed`
 
 error: higher-ranked lifetime error
+  --> $DIR/issue-59311.rs:17:5
+   |
+LL |     v.t(|| {});
+   |     ^^^^^^^^^^
+   |
+   = note: could not prove `{closure@$DIR/issue-59311.rs:17:9: 17:11} well-formed`
+   = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
+
+error: higher-ranked lifetime error
   --> $DIR/issue-59311.rs:17:9
    |
 LL |     v.t(|| {});
@@ -14,5 +23,5 @@ LL |     v.t(|| {});
    |
    = note: could not prove `for<'a> &'a V: 'b`
 
-error: aborting due to 2 previous errors
+error: aborting due to 3 previous errors
 
diff --git a/tests/ui/impl-trait/issue-72911.rs b/tests/ui/impl-trait/issue-72911.rs
index 63f4898f430..7ba8579e24f 100644
--- a/tests/ui/impl-trait/issue-72911.rs
+++ b/tests/ui/impl-trait/issue-72911.rs
@@ -15,6 +15,7 @@ fn gather_from_file(dir_entry: &foo::MissingItem) -> impl Iterator<Item = Lint>
 
 fn lint_files() -> impl Iterator<Item = foo::MissingItem> {
     //~^ ERROR: failed to resolve
+    //~| ERROR: `()` is not an iterator
     unimplemented!()
 }
 
diff --git a/tests/ui/impl-trait/issue-72911.stderr b/tests/ui/impl-trait/issue-72911.stderr
index 0e86561aa27..44c20a7be53 100644
--- a/tests/ui/impl-trait/issue-72911.stderr
+++ b/tests/ui/impl-trait/issue-72911.stderr
@@ -1,3 +1,11 @@
+error[E0277]: `()` is not an iterator
+  --> $DIR/issue-72911.rs:16:20
+   |
+LL | fn lint_files() -> impl Iterator<Item = foo::MissingItem> {
+   |                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ `()` is not an iterator
+   |
+   = help: the trait `Iterator` is not implemented for `()`
+
 error[E0433]: failed to resolve: use of undeclared crate or module `foo`
   --> $DIR/issue-72911.rs:11:33
    |
@@ -10,6 +18,7 @@ error[E0433]: failed to resolve: use of undeclared crate or module `foo`
 LL | fn lint_files() -> impl Iterator<Item = foo::MissingItem> {
    |                                         ^^^ use of undeclared crate or module `foo`
 
-error: aborting due to 2 previous errors
+error: aborting due to 3 previous errors
 
-For more information about this error, try `rustc --explain E0433`.
+Some errors have detailed explanations: E0277, E0433.
+For more information about an error, try `rustc --explain E0277`.
diff --git a/tests/ui/impl-trait/issues/issue-78722-2.stderr b/tests/ui/impl-trait/issues/issue-78722-2.stderr
index 69c734530f2..c402ce864c7 100644
--- a/tests/ui/impl-trait/issues/issue-78722-2.stderr
+++ b/tests/ui/impl-trait/issues/issue-78722-2.stderr
@@ -25,6 +25,7 @@ LL |         let f: F = async { 1 };
    |
    = note: see issue #85368 <https://github.com/rust-lang/rust/issues/85368> for more information
    = help: add `#![feature(const_async_blocks)]` 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
 
diff --git a/tests/ui/impl-trait/issues/issue-78722.stderr b/tests/ui/impl-trait/issues/issue-78722.stderr
index 5ad65969731..0bb24fae822 100644
--- a/tests/ui/impl-trait/issues/issue-78722.stderr
+++ b/tests/ui/impl-trait/issues/issue-78722.stderr
@@ -6,6 +6,7 @@ LL |         let f: F = async { 1 };
    |
    = note: see issue #85368 <https://github.com/rust-lang/rust/issues/85368> for more information
    = help: add `#![feature(const_async_blocks)]` 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[E0271]: expected `{async block@$DIR/issue-78722.rs:10:13: 10:21}` to be a future that resolves to `u8`, but it resolves to `()`
   --> $DIR/issue-78722.rs:8:30
diff --git a/tests/ui/impl-trait/issues/issue-92305.rs b/tests/ui/impl-trait/issues/issue-92305.rs
index e16199caaaa..4a89238d07e 100644
--- a/tests/ui/impl-trait/issues/issue-92305.rs
+++ b/tests/ui/impl-trait/issues/issue-92305.rs
@@ -5,7 +5,6 @@ use std::iter;
 fn f<T>(data: &[T]) -> impl Iterator<Item = Vec> {
     //~^ ERROR: missing generics for struct `Vec` [E0107]
     iter::empty()
-    //~^ ERROR: type annotations needed
 }
 
 fn g<T>(data: &[T], target: T) -> impl Iterator<Item = Vec<T>> {
diff --git a/tests/ui/impl-trait/issues/issue-92305.stderr b/tests/ui/impl-trait/issues/issue-92305.stderr
index 55e966bd7bf..88fb1fb2707 100644
--- a/tests/ui/impl-trait/issues/issue-92305.stderr
+++ b/tests/ui/impl-trait/issues/issue-92305.stderr
@@ -9,18 +9,6 @@ help: add missing generic argument
 LL | fn f<T>(data: &[T]) -> impl Iterator<Item = Vec<T>> {
    |                                                +++
 
-error[E0282]: type annotations needed
-  --> $DIR/issue-92305.rs:7:5
-   |
-LL |     iter::empty()
-   |     ^^^^^^^^^^^ cannot infer type of the type parameter `T` declared on the function `empty`
-   |
-help: consider specifying the generic argument
-   |
-LL |     iter::empty::<T>()
-   |                +++++
-
-error: aborting due to 2 previous errors
+error: aborting due to 1 previous error
 
-Some errors have detailed explanations: E0107, E0282.
-For more information about an error, try `rustc --explain E0107`.
+For more information about this error, try `rustc --explain E0107`.
diff --git a/tests/ui/impl-trait/where-allowed.stderr b/tests/ui/impl-trait/where-allowed.stderr
index 5e8a8637d04..3e1d4e22272 100644
--- a/tests/ui/impl-trait/where-allowed.stderr
+++ b/tests/ui/impl-trait/where-allowed.stderr
@@ -24,6 +24,7 @@ LL |     type Out = impl Debug;
    |
    = note: see issue #63063 <https://github.com/rust-lang/rust/issues/63063> for more information
    = help: add `#![feature(impl_trait_in_assoc_type)]` 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]: `impl Trait` in type aliases is unstable
   --> $DIR/where-allowed.rs:154:23
@@ -33,6 +34,7 @@ LL | type InTypeAlias<R> = impl Debug;
    |
    = note: see issue #63063 <https://github.com/rust-lang/rust/issues/63063> for more information
    = help: add `#![feature(type_alias_impl_trait)]` 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]: `impl Trait` in type aliases is unstable
   --> $DIR/where-allowed.rs:157:39
@@ -42,6 +44,7 @@ LL | type InReturnInTypeAlias<R> = fn() -> impl Debug;
    |
    = note: see issue #63063 <https://github.com/rust-lang/rust/issues/63063> for more information
    = help: add `#![feature(type_alias_impl_trait)]` 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[E0562]: `impl Trait` is not allowed in `fn` pointer parameters
   --> $DIR/where-allowed.rs:18:40
diff --git a/tests/ui/implied-bounds/implied-bounds-on-trait-hierarchy.rs b/tests/ui/implied-bounds/implied-bounds-on-trait-hierarchy-1.rs
index 9c26cd59d10..b532a110a1c 100644
--- a/tests/ui/implied-bounds/implied-bounds-on-trait-hierarchy.rs
+++ b/tests/ui/implied-bounds/implied-bounds-on-trait-hierarchy-1.rs
@@ -1,9 +1,7 @@
-// check-pass
-// known-bug: #84591
+// issue: #84591
 
-// Should fail. Subtrait can incorrectly extend supertrait lifetimes even when
-// supertrait has weaker implied bounds than subtrait. Strongly related to
-// issue #25860.
+// Subtrait was able to incorrectly extend supertrait lifetimes even when
+// supertrait had weaker implied bounds than subtrait.
 
 trait Subtrait<T>: Supertrait {}
 trait Supertrait {
@@ -34,6 +32,7 @@ fn main() {
     {
         let x = "Hello World".to_string();
         subs_to_soup((x.as_str(), &mut d));
+        //~^ does not live long enough
     }
     println!("{}", d);
 }
diff --git a/tests/ui/implied-bounds/implied-bounds-on-trait-hierarchy-1.stderr b/tests/ui/implied-bounds/implied-bounds-on-trait-hierarchy-1.stderr
new file mode 100644
index 00000000000..f44defccf58
--- /dev/null
+++ b/tests/ui/implied-bounds/implied-bounds-on-trait-hierarchy-1.stderr
@@ -0,0 +1,16 @@
+error[E0597]: `x` does not live long enough
+  --> $DIR/implied-bounds-on-trait-hierarchy-1.rs:34:23
+   |
+LL |         let x = "Hello World".to_string();
+   |             - binding `x` declared here
+LL |         subs_to_soup((x.as_str(), &mut d));
+   |                       ^ borrowed value does not live long enough
+LL |
+LL |     }
+   |     - `x` dropped here while still borrowed
+LL |     println!("{}", d);
+   |                    - borrow later used here
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0597`.
diff --git a/tests/ui/implied-bounds/implied-bounds-on-trait-hierarchy-2.rs b/tests/ui/implied-bounds/implied-bounds-on-trait-hierarchy-2.rs
new file mode 100644
index 00000000000..511a9ad9a2a
--- /dev/null
+++ b/tests/ui/implied-bounds/implied-bounds-on-trait-hierarchy-2.rs
@@ -0,0 +1,45 @@
+// check-pass
+// known-bug: #84591
+
+trait Subtrait<'a, 'b, R>: Supertrait<'a, 'b> {}
+trait Supertrait<'a, 'b> {
+    fn convert<T: ?Sized>(x: &'a T) -> &'b T;
+}
+
+fn need_hrtb_subtrait<'a_, 'b_, S, T: ?Sized>(x: &'a_ T) -> &'b_ T
+where
+    S: for<'a, 'b> Subtrait<'a, 'b, &'b &'a ()>,
+{
+    need_hrtb_supertrait::<S, T>(x)
+    // This call works and drops the implied bound `'a: 'b`
+    // of the where-bound. This means the where-bound can
+    // now be used to transmute any two lifetimes.
+}
+
+fn need_hrtb_supertrait<'a_, 'b_, S, T: ?Sized>(x: &'a_ T) -> &'b_ T
+where
+    S: for<'a, 'b> Supertrait<'a, 'b>,
+{
+    S::convert(x)
+}
+
+struct MyStruct;
+impl<'a: 'b, 'b> Supertrait<'a, 'b> for MyStruct {
+    fn convert<T: ?Sized>(x: &'a T) -> &'b T {
+        x
+    }
+}
+impl<'a, 'b> Subtrait<'a, 'b, &'b &'a ()> for MyStruct {}
+
+fn extend_lifetime<'a, 'b, T: ?Sized>(x: &'a T) -> &'b T {
+    need_hrtb_subtrait::<MyStruct, T>(x)
+}
+
+fn main() {
+    let d;
+    {
+        let x = "Hello World".to_string();
+        d = extend_lifetime(&x);
+    }
+    println!("{}", d);
+}
diff --git a/tests/ui/imports/issue-37887.stderr b/tests/ui/imports/issue-37887.stderr
index 75185cad3b7..6117fd21af1 100644
--- a/tests/ui/imports/issue-37887.stderr
+++ b/tests/ui/imports/issue-37887.stderr
@@ -14,6 +14,7 @@ LL |     extern crate libc;
    |
    = note: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
    = help: add `#![feature(rustc_private)]` 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 2 previous errors
 
diff --git a/tests/ui/inference/inference_unstable_forced.stderr b/tests/ui/inference/inference_unstable_forced.stderr
index 2301eacc596..26eaddd2707 100644
--- a/tests/ui/inference/inference_unstable_forced.stderr
+++ b/tests/ui/inference/inference_unstable_forced.stderr
@@ -6,6 +6,7 @@ LL |     assert_eq!('x'.ipu_flatten(), 0);
    |
    = note: see issue #99999 <https://github.com/rust-lang/rust/issues/99999> for more information
    = help: add `#![feature(ipu_flatten)]` 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 1 previous error
 
diff --git a/tests/ui/internal/internal-unstable-noallow.stderr b/tests/ui/internal/internal-unstable-noallow.stderr
index b0ceae62aba..b39456b1cae 100644
--- a/tests/ui/internal/internal-unstable-noallow.stderr
+++ b/tests/ui/internal/internal-unstable-noallow.stderr
@@ -5,6 +5,7 @@ LL |     call_unstable_noallow!();
    |     ^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(function)]` 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: this error originates in the macro `call_unstable_noallow` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error[E0658]: use of unstable library feature 'struct_field'
@@ -14,6 +15,7 @@ LL |     construct_unstable_noallow!(0);
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(struct_field)]` 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: this error originates in the macro `construct_unstable_noallow` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error[E0658]: use of unstable library feature 'method'
@@ -23,6 +25,7 @@ LL |     |x: internal_unstable::Foo| { call_method_noallow!(x) };
    |                                   ^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(method)]` 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: this error originates in the macro `call_method_noallow` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error[E0658]: use of unstable library feature 'struct2_field'
@@ -32,6 +35,7 @@ LL |     |x: internal_unstable::Bar| { access_field_noallow!(x) };
    |                                   ^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(struct2_field)]` 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: this error originates in the macro `access_field_noallow` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: aborting due to 4 previous errors
diff --git a/tests/ui/internal/internal-unstable-thread-local.stderr b/tests/ui/internal/internal-unstable-thread-local.stderr
index 7c07c762827..58c7b3f67eb 100644
--- a/tests/ui/internal/internal-unstable-thread-local.stderr
+++ b/tests/ui/internal/internal-unstable-thread-local.stderr
@@ -5,6 +5,7 @@ LL | thread_local!(static BAR: () = internal_unstable::unstable());
    |                                ^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(function)]` 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 1 previous error
 
diff --git a/tests/ui/internal/internal-unstable.stderr b/tests/ui/internal/internal-unstable.stderr
index b7c47365c2d..af5ac21e696 100644
--- a/tests/ui/internal/internal-unstable.stderr
+++ b/tests/ui/internal/internal-unstable.stderr
@@ -5,6 +5,7 @@ LL |     pass_through_allow!(internal_unstable::unstable());
    |                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(function)]` 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]: use of unstable library feature 'function'
   --> $DIR/internal-unstable.rs:42:27
@@ -13,6 +14,7 @@ LL |     pass_through_noallow!(internal_unstable::unstable());
    |                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(function)]` 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]: use of unstable library feature 'function'
   --> $DIR/internal-unstable.rs:46:22
@@ -21,6 +23,7 @@ LL |     println!("{:?}", internal_unstable::unstable());
    |                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(function)]` 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]: use of unstable library feature 'function'
   --> $DIR/internal-unstable.rs:48:10
@@ -29,6 +32,7 @@ LL |     bar!(internal_unstable::unstable());
    |          ^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(function)]` 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]: use of unstable library feature 'function'
   --> $DIR/internal-unstable.rs:18:9
@@ -40,6 +44,7 @@ LL |     bar!(internal_unstable::unstable());
    |     ----------------------------------- in this macro invocation
    |
    = help: add `#![feature(function)]` 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: this error originates in the macro `foo` which comes from the expansion of the macro `bar` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: aborting due to 5 previous errors
diff --git a/tests/ui/intrinsics/feature-gate-safe-intrinsic.stderr b/tests/ui/intrinsics/feature-gate-safe-intrinsic.stderr
index 8aeb56598ec..e49880e9bb8 100644
--- a/tests/ui/intrinsics/feature-gate-safe-intrinsic.stderr
+++ b/tests/ui/intrinsics/feature-gate-safe-intrinsic.stderr
@@ -5,6 +5,7 @@ LL | #[rustc_safe_intrinsic]
    | ^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(rustc_attrs)]` 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: attribute should be applied to intrinsic functions
   --> $DIR/feature-gate-safe-intrinsic.rs:1:1
diff --git a/tests/ui/intrinsics/unchecked_math_unstable.stderr b/tests/ui/intrinsics/unchecked_math_unstable.stderr
index a43aa16aedc..c2a116b6200 100644
--- a/tests/ui/intrinsics/unchecked_math_unstable.stderr
+++ b/tests/ui/intrinsics/unchecked_math_unstable.stderr
@@ -5,6 +5,7 @@ LL |         let add = std::intrinsics::unchecked_add(x, y);
    |                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(core_intrinsics)]` 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]: use of unstable library feature 'core_intrinsics': intrinsics are unlikely to ever be stabilized, instead they should be used through stabilized interfaces in the rest of the standard library
   --> $DIR/unchecked_math_unstable.rs:5:19
@@ -13,6 +14,7 @@ LL |         let sub = std::intrinsics::unchecked_sub(x, y);
    |                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(core_intrinsics)]` 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]: use of unstable library feature 'core_intrinsics': intrinsics are unlikely to ever be stabilized, instead they should be used through stabilized interfaces in the rest of the standard library
   --> $DIR/unchecked_math_unstable.rs:6:19
@@ -21,6 +23,7 @@ LL |         let mul = std::intrinsics::unchecked_mul(x, y);
    |                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(core_intrinsics)]` 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
 
diff --git a/tests/ui/issues/issue-20313.stderr b/tests/ui/issues/issue-20313.stderr
index f740b0cca06..a61495440f0 100644
--- a/tests/ui/issues/issue-20313.stderr
+++ b/tests/ui/issues/issue-20313.stderr
@@ -6,6 +6,7 @@ LL |     fn sqrt(x: f32) -> f32;
    |
    = note: see issue #29602 <https://github.com/rust-lang/rust/issues/29602> for more information
    = help: add `#![feature(link_llvm_intrinsics)]` 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 1 previous error
 
diff --git a/tests/ui/issues/issue-23024.stderr b/tests/ui/issues/issue-23024.stderr
index 7d187de1bc4..1672622d8b7 100644
--- a/tests/ui/issues/issue-23024.stderr
+++ b/tests/ui/issues/issue-23024.stderr
@@ -6,6 +6,7 @@ LL |     println!("{:?}",(vfnfer[0] as dyn Fn)(3));
    |
    = 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[E0107]: missing generics for trait `Fn`
   --> $DIR/issue-23024.rs:8:39
diff --git a/tests/ui/issues/issue-32782.stderr b/tests/ui/issues/issue-32782.stderr
index 477c01f6864..830d83f6e57 100644
--- a/tests/ui/issues/issue-32782.stderr
+++ b/tests/ui/issues/issue-32782.stderr
@@ -8,6 +8,7 @@ LL | foo!();
    | ------ in this macro invocation
    |
    = help: add `#![feature(allow_internal_unstable)]` 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: this error originates in the macro `foo` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: aborting due to 1 previous error
diff --git a/tests/ui/issues/issue-50582.stderr b/tests/ui/issues/issue-50582.stderr
index 9eafd7ab4f0..7b65fa25ae3 100644
--- a/tests/ui/issues/issue-50582.stderr
+++ b/tests/ui/issues/issue-50582.stderr
@@ -6,6 +6,7 @@ LL |     Vec::<[(); 1 + for x in 0..1 {}]>::new();
    |
    = note: see issue #87575 <https://github.com/rust-lang/rust/issues/87575> for more information
    = help: add `#![feature(const_for)]` 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[E0277]: cannot add `()` to `{integer}`
   --> $DIR/issue-50582.rs:2:18
diff --git a/tests/ui/issues/issue-50585.stderr b/tests/ui/issues/issue-50585.stderr
index e43cc20cbb5..13181f1cf7f 100644
--- a/tests/ui/issues/issue-50585.stderr
+++ b/tests/ui/issues/issue-50585.stderr
@@ -6,6 +6,7 @@ LL |     |y: Vec<[(); for x in 0..2 {}]>| {};
    |
    = note: see issue #87575 <https://github.com/rust-lang/rust/issues/87575> for more information
    = help: add `#![feature(const_for)]` 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[E0308]: mismatched types
   --> $DIR/issue-50585.rs:2:18
diff --git a/tests/ui/issues/issue-52489.stderr b/tests/ui/issues/issue-52489.stderr
index 442902bd1c3..fa88725bceb 100644
--- a/tests/ui/issues/issue-52489.stderr
+++ b/tests/ui/issues/issue-52489.stderr
@@ -5,6 +5,7 @@ LL | use issue_52489;
    |     ^^^^^^^^^^^
    |
    = help: add `#![feature(issue_52489_unstable)]` 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 1 previous error
 
diff --git a/tests/ui/lang-items/issue-83471.stderr b/tests/ui/lang-items/issue-83471.stderr
index b315df179d0..1f22d966dd7 100644
--- a/tests/ui/lang-items/issue-83471.stderr
+++ b/tests/ui/lang-items/issue-83471.stderr
@@ -11,6 +11,7 @@ LL | #[lang = "sized"]
    | ^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(lang_items)]` 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]: language items are subject to change
   --> $DIR/issue-83471.rs:11:1
@@ -19,6 +20,7 @@ LL | #[lang = "fn"]
    | ^^^^^^^^^^^^^^
    |
    = help: add `#![feature(lang_items)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: anonymous parameters are deprecated and will be removed in the next edition
   --> $DIR/issue-83471.rs:15:13
diff --git a/tests/ui/lifetimes/lifetime-errors/issue_74400.rs b/tests/ui/lifetimes/lifetime-errors/issue_74400.rs
index ddb8bacce8f..f17e0a678c9 100644
--- a/tests/ui/lifetimes/lifetime-errors/issue_74400.rs
+++ b/tests/ui/lifetimes/lifetime-errors/issue_74400.rs
@@ -11,6 +11,8 @@ fn f<T, S>(data: &[T], key: impl Fn(&T) -> S) {
 fn g<T>(data: &[T]) {
     f(data, identity)
     //~^ ERROR the parameter type
+    //~| ERROR the parameter type
+    //~| ERROR the parameter type
     //~| ERROR mismatched types
     //~| ERROR implementation of `FnOnce` is not general
 }
diff --git a/tests/ui/lifetimes/lifetime-errors/issue_74400.stderr b/tests/ui/lifetimes/lifetime-errors/issue_74400.stderr
index 677f918fe93..beb838d2ff8 100644
--- a/tests/ui/lifetimes/lifetime-errors/issue_74400.stderr
+++ b/tests/ui/lifetimes/lifetime-errors/issue_74400.stderr
@@ -12,6 +12,36 @@ help: consider adding an explicit lifetime bound
 LL | fn g<T: 'static>(data: &[T]) {
    |       +++++++++
 
+error[E0310]: the parameter type `T` may not live long enough
+  --> $DIR/issue_74400.rs:12:5
+   |
+LL |     f(data, identity)
+   |     ^^^^^^^^^^^^^^^^^
+   |     |
+   |     the parameter type `T` must be valid for the static lifetime...
+   |     ...so that the type `T` will meet its required lifetime bounds
+   |
+   = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
+help: consider adding an explicit lifetime bound
+   |
+LL | fn g<T: 'static>(data: &[T]) {
+   |       +++++++++
+
+error[E0310]: the parameter type `T` may not live long enough
+  --> $DIR/issue_74400.rs:12:5
+   |
+LL |     f(data, identity)
+   |     ^^^^^^^^^^^^^^^^^
+   |     |
+   |     the parameter type `T` must be valid for the static lifetime...
+   |     ...so that the type `T` will meet its required lifetime bounds
+   |
+   = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
+help: consider adding an explicit lifetime bound
+   |
+LL | fn g<T: 'static>(data: &[T]) {
+   |       +++++++++
+
 error[E0308]: mismatched types
   --> $DIR/issue_74400.rs:12:5
    |
@@ -35,7 +65,7 @@ LL |     f(data, identity)
    = note: `fn(&'2 T) -> &'2 T {identity::<&'2 T>}` must implement `FnOnce<(&'1 T,)>`, for any lifetime `'1`...
    = note: ...but it actually implements `FnOnce<(&'2 T,)>`, for some specific lifetime `'2`
 
-error: aborting due to 3 previous errors
+error: aborting due to 5 previous errors
 
 Some errors have detailed explanations: E0308, E0310.
 For more information about an error, try `rustc --explain E0308`.
diff --git a/tests/ui/linkage-attr/linkage4.stderr b/tests/ui/linkage-attr/linkage4.stderr
index f76655b3c72..8fbcaf841b6 100644
--- a/tests/ui/linkage-attr/linkage4.stderr
+++ b/tests/ui/linkage-attr/linkage4.stderr
@@ -6,6 +6,7 @@ LL | #[linkage = "external"]
    |
    = note: see issue #29603 <https://github.com/rust-lang/rust/issues/29603> for more information
    = help: add `#![feature(linkage)]` 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 1 previous error
 
diff --git a/tests/ui/lint/large_assignments/box_rc_arc_allowed.stderr b/tests/ui/lint/large_assignments/box_rc_arc_allowed.stderr
index b45cbe5da4d..fefb3a9621b 100644
--- a/tests/ui/lint/large_assignments/box_rc_arc_allowed.stderr
+++ b/tests/ui/lint/large_assignments/box_rc_arc_allowed.stderr
@@ -1,8 +1,8 @@
 error: moving 9999 bytes
-  --> $DIR/box_rc_arc_allowed.rs:16:13
+  --> $DIR/box_rc_arc_allowed.rs:16:25
    |
 LL |     let _ = NotBox::new([0; 9999]);
-   |             ^^^^^^^^^^^^^^^^^^^^^^ value moved from here
+   |                         ^^^^^^^^^ value moved from here
    |
    = note: The current maximum size is 1000, but it can be customized with the move_size_limit attribute: `#![move_size_limit = "..."]`
 note: the lint level is defined here
diff --git a/tests/ui/lint/large_assignments/copy_into_fn.rs b/tests/ui/lint/large_assignments/copy_into_fn.rs
new file mode 100644
index 00000000000..ee204bf7af1
--- /dev/null
+++ b/tests/ui/lint/large_assignments/copy_into_fn.rs
@@ -0,0 +1,24 @@
+// build-fail
+
+#![feature(large_assignments)]
+#![move_size_limit = "1000"]
+#![deny(large_assignments)]
+#![allow(unused)]
+
+// We want copy semantics, because moving data into functions generally do not
+// translate to actual `memcpy`s.
+#[derive(Copy, Clone)]
+struct Data([u8; 9999]);
+
+fn main() {
+    one_arg(Data([0; 9999])); //~ ERROR large_assignments
+
+    // each individual large arg shall have its own span
+    many_args(Data([0; 9999]), true, Data([0; 9999]));
+    //~^ ERROR large_assignments
+    //~| ERROR large_assignments
+}
+
+fn one_arg(a: Data) {}
+
+fn many_args(a: Data, b: bool, c: Data) {}
diff --git a/tests/ui/lint/large_assignments/copy_into_fn.stderr b/tests/ui/lint/large_assignments/copy_into_fn.stderr
new file mode 100644
index 00000000000..f05fc33e17e
--- /dev/null
+++ b/tests/ui/lint/large_assignments/copy_into_fn.stderr
@@ -0,0 +1,31 @@
+error: moving 9999 bytes
+  --> $DIR/copy_into_fn.rs:14:13
+   |
+LL |     one_arg(Data([0; 9999]));
+   |             ^^^^^^^^^^^^^^^ value moved from here
+   |
+   = note: The current maximum size is 1000, but it can be customized with the move_size_limit attribute: `#![move_size_limit = "..."]`
+note: the lint level is defined here
+  --> $DIR/copy_into_fn.rs:5:9
+   |
+LL | #![deny(large_assignments)]
+   |         ^^^^^^^^^^^^^^^^^
+
+error: moving 9999 bytes
+  --> $DIR/copy_into_fn.rs:17:15
+   |
+LL |     many_args(Data([0; 9999]), true, Data([0; 9999]));
+   |               ^^^^^^^^^^^^^^^ value moved from here
+   |
+   = note: The current maximum size is 1000, but it can be customized with the move_size_limit attribute: `#![move_size_limit = "..."]`
+
+error: moving 9999 bytes
+  --> $DIR/copy_into_fn.rs:17:38
+   |
+LL |     many_args(Data([0; 9999]), true, Data([0; 9999]));
+   |                                      ^^^^^^^^^^^^^^^ value moved from here
+   |
+   = note: The current maximum size is 1000, but it can be customized with the move_size_limit attribute: `#![move_size_limit = "..."]`
+
+error: aborting due to 3 previous errors
+
diff --git a/tests/ui/lint/lint-output-format.stderr b/tests/ui/lint/lint-output-format.stderr
index 0db79a1564f..c399b6cdbc2 100644
--- a/tests/ui/lint/lint-output-format.stderr
+++ b/tests/ui/lint/lint-output-format.stderr
@@ -5,6 +5,7 @@ LL | extern crate lint_output_format;
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-output-format.rs:7:26
@@ -13,6 +14,7 @@ LL | use lint_output_format::{foo, bar};
    |                          ^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-output-format.rs:7:31
@@ -21,6 +23,7 @@ LL | use lint_output_format::{foo, bar};
    |                               ^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-output-format.rs:12:14
@@ -29,6 +32,7 @@ LL |     let _y = bar();
    |              ^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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 4 previous errors
 
diff --git a/tests/ui/lint/lint-stability-2.stderr b/tests/ui/lint/lint-stability-2.stderr
index 5b7537fa234..20d49780a91 100644
--- a/tests/ui/lint/lint-stability-2.stderr
+++ b/tests/ui/lint/lint-stability-2.stderr
@@ -5,6 +5,7 @@ LL |         foo.method_deprecated_unstable();
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:42:9
@@ -13,6 +14,7 @@ LL |         Foo::method_deprecated_unstable(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:44:9
@@ -21,6 +23,7 @@ LL |         <Foo>::method_deprecated_unstable(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:46:13
@@ -29,6 +32,7 @@ LL |         foo.trait_deprecated_unstable();
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:48:9
@@ -37,6 +41,7 @@ LL |         <Foo>::trait_deprecated_unstable(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:51:13
@@ -45,6 +50,7 @@ LL |         foo.method_deprecated_unstable_text();
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:53:9
@@ -53,6 +59,7 @@ LL |         Foo::method_deprecated_unstable_text(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:55:9
@@ -61,6 +68,7 @@ LL |         <Foo>::method_deprecated_unstable_text(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:57:13
@@ -69,6 +77,7 @@ LL |         foo.trait_deprecated_unstable_text();
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:59:9
@@ -77,6 +86,7 @@ LL |         <Foo>::trait_deprecated_unstable_text(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:62:13
@@ -85,6 +95,7 @@ LL |         foo.method_unstable();
    |             ^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:63:9
@@ -93,6 +104,7 @@ LL |         Foo::method_unstable(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:64:9
@@ -101,6 +113,7 @@ LL |         <Foo>::method_unstable(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:65:13
@@ -109,6 +122,7 @@ LL |         foo.trait_unstable();
    |             ^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:66:9
@@ -117,6 +131,7 @@ LL |         <Foo>::trait_unstable(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature': text
   --> $DIR/lint-stability-2.rs:68:13
@@ -125,6 +140,7 @@ LL |         foo.method_unstable_text();
    |             ^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature': text
   --> $DIR/lint-stability-2.rs:70:9
@@ -133,6 +149,7 @@ LL |         Foo::method_unstable_text(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature': text
   --> $DIR/lint-stability-2.rs:72:9
@@ -141,6 +158,7 @@ LL |         <Foo>::method_unstable_text(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature': text
   --> $DIR/lint-stability-2.rs:74:13
@@ -149,6 +167,7 @@ LL |         foo.trait_unstable_text();
    |             ^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature': text
   --> $DIR/lint-stability-2.rs:76:9
@@ -157,6 +176,7 @@ LL |         <Foo>::trait_unstable_text(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:131:13
@@ -165,6 +185,7 @@ LL |         foo.trait_deprecated_unstable();
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:133:9
@@ -173,6 +194,7 @@ LL |         <Foo>::trait_deprecated_unstable(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:135:13
@@ -181,6 +203,7 @@ LL |         foo.trait_deprecated_unstable_text();
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:137:9
@@ -189,6 +212,7 @@ LL |         <Foo>::trait_deprecated_unstable_text(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:139:13
@@ -197,6 +221,7 @@ LL |         foo.trait_unstable();
    |             ^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:140:9
@@ -205,6 +230,7 @@ LL |         <Foo>::trait_unstable(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature': text
   --> $DIR/lint-stability-2.rs:141:13
@@ -213,6 +239,7 @@ LL |         foo.trait_unstable_text();
    |             ^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature': text
   --> $DIR/lint-stability-2.rs:143:9
@@ -221,6 +248,7 @@ LL |         <Foo>::trait_unstable_text(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:154:13
@@ -229,6 +257,7 @@ LL |         foo.trait_deprecated_unstable();
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:156:13
@@ -237,6 +266,7 @@ LL |         foo.trait_deprecated_unstable_text();
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-2.rs:158:13
@@ -245,6 +275,7 @@ LL |         foo.trait_unstable();
    |             ^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature': text
   --> $DIR/lint-stability-2.rs:159:13
@@ -253,6 +284,7 @@ LL |         foo.trait_unstable_text();
    |             ^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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 32 previous errors
 
diff --git a/tests/ui/lint/lint-stability-fields.stderr b/tests/ui/lint/lint-stability-fields.stderr
index 3d2e73c1e8e..9dffe94c12e 100644
--- a/tests/ui/lint/lint-stability-fields.stderr
+++ b/tests/ui/lint/lint-stability-fields.stderr
@@ -5,6 +5,7 @@ LL |         let x = Unstable {
    |                 ^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:66:13
@@ -13,6 +14,7 @@ LL |         let Unstable {
    |             ^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:72:13
@@ -21,6 +23,7 @@ LL |         let Unstable
    |             ^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:77:17
@@ -29,6 +32,7 @@ LL |         let x = reexport::Unstable2(1, 2, 3);
    |                 ^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:79:17
@@ -37,6 +41,7 @@ LL |         let x = Unstable2(1, 2, 3);
    |                 ^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:85:13
@@ -45,6 +50,7 @@ LL |         let Unstable2
    |             ^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:90:13
@@ -53,6 +59,7 @@ LL |         let Unstable2
    |             ^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:95:17
@@ -61,6 +68,7 @@ LL |         let x = Deprecated {
    |                 ^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:105:13
@@ -69,6 +77,7 @@ LL |         let Deprecated {
    |             ^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:111:13
@@ -77,6 +86,7 @@ LL |         let Deprecated
    |             ^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:115:17
@@ -85,6 +95,7 @@ LL |         let x = Deprecated2(1, 2, 3);
    |                 ^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:121:13
@@ -93,6 +104,7 @@ LL |         let Deprecated2
    |             ^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:126:13
@@ -101,6 +113,7 @@ LL |         let Deprecated2
    |             ^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:21:13
@@ -109,6 +122,7 @@ LL |             override1: 2,
    |             ^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:22:13
@@ -117,6 +131,7 @@ LL |             override2: 3,
    |             ^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:27:17
@@ -125,6 +140,7 @@ LL |         let _ = x.override1;
    |                 ^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:28:17
@@ -133,6 +149,7 @@ LL |         let _ = x.override2;
    |                 ^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:33:13
@@ -141,6 +158,7 @@ LL |             override1: _,
    |             ^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:34:13
@@ -149,6 +167,7 @@ LL |             override2: _,
    |             ^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:43:17
@@ -157,6 +176,7 @@ LL |         let _ = x.1;
    |                 ^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:44:17
@@ -165,6 +185,7 @@ LL |         let _ = x.2;
    |                 ^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:48:20
@@ -173,6 +194,7 @@ LL |                    _,
    |                    ^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:49:20
@@ -181,6 +203,7 @@ LL |                    _,
    |                    ^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:57:13
@@ -189,6 +212,7 @@ LL |             inherit: 1,
    |             ^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:59:13
@@ -197,6 +221,7 @@ LL |             override2: 3,
    |             ^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:62:17
@@ -205,6 +230,7 @@ LL |         let _ = x.inherit;
    |                 ^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:64:17
@@ -213,6 +239,7 @@ LL |         let _ = x.override2;
    |                 ^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:67:13
@@ -221,6 +248,7 @@ LL |             inherit: _,
    |             ^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:69:13
@@ -229,6 +257,7 @@ LL |             override2: _
    |             ^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:81:17
@@ -237,6 +266,7 @@ LL |         let _ = x.0;
    |                 ^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:83:17
@@ -245,6 +275,7 @@ LL |         let _ = x.2;
    |                 ^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:86:14
@@ -253,6 +284,7 @@ LL |             (_,
    |              ^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:88:14
@@ -261,6 +293,7 @@ LL |              _)
    |              ^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:96:13
@@ -269,6 +302,7 @@ LL |             inherit: 1,
    |             ^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:98:13
@@ -277,6 +311,7 @@ LL |             override2: 3,
    |             ^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:101:17
@@ -285,6 +320,7 @@ LL |         let _ = x.inherit;
    |                 ^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:103:17
@@ -293,6 +329,7 @@ LL |         let _ = x.override2;
    |                 ^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:106:13
@@ -301,6 +338,7 @@ LL |             inherit: _,
    |             ^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:108:13
@@ -309,6 +347,7 @@ LL |             override2: _
    |             ^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:117:17
@@ -317,6 +356,7 @@ LL |         let _ = x.0;
    |                 ^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:119:17
@@ -325,6 +365,7 @@ LL |         let _ = x.2;
    |                 ^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:122:14
@@ -333,6 +374,7 @@ LL |             (_,
    |              ^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability-fields.rs:124:14
@@ -341,6 +383,7 @@ LL |              _)
    |              ^
    |
    = help: add `#![feature(unstable_test_feature)]` 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 43 previous errors
 
diff --git a/tests/ui/lint/lint-stability.stderr b/tests/ui/lint/lint-stability.stderr
index bd1a57dc4cc..af5816d4564 100644
--- a/tests/ui/lint/lint-stability.stderr
+++ b/tests/ui/lint/lint-stability.stderr
@@ -5,6 +5,7 @@ LL |     extern crate stability_cfg2;
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:45:9
@@ -13,6 +14,7 @@ LL |         deprecated_unstable();
    |         ^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:47:9
@@ -21,6 +23,7 @@ LL |         Trait::trait_deprecated_unstable(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:49:9
@@ -29,6 +32,7 @@ LL |         <Foo as Trait>::trait_deprecated_unstable(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:52:9
@@ -37,6 +41,7 @@ LL |         deprecated_unstable_text();
    |         ^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:54:9
@@ -45,6 +50,7 @@ LL |         Trait::trait_deprecated_unstable_text(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:56:9
@@ -53,6 +59,7 @@ LL |         <Foo as Trait>::trait_deprecated_unstable_text(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:59:9
@@ -61,6 +68,7 @@ LL |         unstable();
    |         ^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:60:9
@@ -69,6 +77,7 @@ LL |         Trait::trait_unstable(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:61:9
@@ -77,6 +86,7 @@ LL |         <Foo as Trait>::trait_unstable(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature': text
   --> $DIR/lint-stability.rs:63:9
@@ -85,6 +95,7 @@ LL |         unstable_text();
    |         ^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature': text
   --> $DIR/lint-stability.rs:65:9
@@ -93,6 +104,7 @@ LL |         Trait::trait_unstable_text(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature': text
   --> $DIR/lint-stability.rs:67:9
@@ -101,6 +113,7 @@ LL |         <Foo as Trait>::trait_unstable_text(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:99:17
@@ -109,6 +122,7 @@ LL |         let _ = DeprecatedUnstableStruct {
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:103:17
@@ -117,6 +131,7 @@ LL |         let _ = UnstableStruct { i: 0 };
    |                 ^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:107:17
@@ -125,6 +140,7 @@ LL |         let _ = DeprecatedUnstableUnitStruct;
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:109:17
@@ -133,6 +149,7 @@ LL |         let _ = UnstableUnitStruct;
    |                 ^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:113:17
@@ -141,6 +158,7 @@ LL |         let _ = Enum::DeprecatedUnstableVariant;
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:115:17
@@ -149,6 +167,7 @@ LL |         let _ = Enum::UnstableVariant;
    |                 ^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:119:17
@@ -157,6 +176,7 @@ LL |         let _ = DeprecatedUnstableTupleStruct (1);
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:121:17
@@ -165,6 +185,7 @@ LL |         let _ = UnstableTupleStruct (1);
    |                 ^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:130:25
@@ -173,6 +194,7 @@ LL |         macro_test_arg!(deprecated_unstable_text());
    |                         ^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:144:9
@@ -181,6 +203,7 @@ LL |         Trait::trait_deprecated_unstable(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:146:9
@@ -189,6 +212,7 @@ LL |         <Foo as Trait>::trait_deprecated_unstable(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:148:9
@@ -197,6 +221,7 @@ LL |         Trait::trait_deprecated_unstable_text(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:150:9
@@ -205,6 +230,7 @@ LL |         <Foo as Trait>::trait_deprecated_unstable_text(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:152:9
@@ -213,6 +239,7 @@ LL |         Trait::trait_unstable(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:153:9
@@ -221,6 +248,7 @@ LL |         <Foo as Trait>::trait_unstable(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature': text
   --> $DIR/lint-stability.rs:154:9
@@ -229,6 +257,7 @@ LL |         Trait::trait_unstable_text(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature': text
   --> $DIR/lint-stability.rs:156:9
@@ -237,6 +266,7 @@ LL |         <Foo as Trait>::trait_unstable_text(&foo);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:172:10
@@ -245,6 +275,7 @@ LL |     impl UnstableTrait for S { }
    |          ^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:174:24
@@ -253,6 +284,7 @@ LL |     trait LocalTrait : UnstableTrait { }
    |                        ^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:179:9
@@ -261,6 +293,7 @@ LL |         fn trait_unstable(&self) {}
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:184:5
@@ -269,6 +302,7 @@ LL |     extern crate inherited_stability;
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:185:9
@@ -277,6 +311,7 @@ LL |     use self::inherited_stability::*;
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:188:9
@@ -285,6 +320,7 @@ LL |         unstable();
    |         ^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:191:9
@@ -293,6 +329,7 @@ LL |         stable_mod::unstable();
    |         ^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:194:9
@@ -301,6 +338,7 @@ LL |         unstable_mod::deprecated();
    |         ^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:195:9
@@ -309,6 +347,7 @@ LL |         unstable_mod::unstable();
    |         ^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:197:17
@@ -317,6 +356,7 @@ LL |         let _ = Unstable::UnstableVariant;
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:198:17
@@ -325,6 +365,7 @@ LL |         let _ = Unstable::StableVariant;
    |                 ^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:88:48
@@ -333,6 +374,7 @@ LL |         struct S1<T: TraitWithAssociatedTypes>(T::TypeUnstable);
    |                                                ^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/lint-stability.rs:92:13
@@ -341,6 +383,7 @@ LL |             TypeUnstable = u8,
    |             ^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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 43 previous errors
 
diff --git a/tests/ui/lint/must_not_suspend/feature-gate-must_not_suspend.stderr b/tests/ui/lint/must_not_suspend/feature-gate-must_not_suspend.stderr
index 9ec33b1c490..e28ff2ec703 100644
--- a/tests/ui/lint/must_not_suspend/feature-gate-must_not_suspend.stderr
+++ b/tests/ui/lint/must_not_suspend/feature-gate-must_not_suspend.stderr
@@ -6,6 +6,7 @@ LL | #[must_not_suspend = "You gotta use Umm's, ya know?"]
    |
    = note: see issue #83310 <https://github.com/rust-lang/rust/issues/83310> for more information
    = help: add `#![feature(must_not_suspend)]` 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 1 previous error
 
diff --git a/tests/ui/lint/must_not_suspend/gated.stderr b/tests/ui/lint/must_not_suspend/gated.stderr
index c238c1f3351..aff1b6a2ac4 100644
--- a/tests/ui/lint/must_not_suspend/gated.stderr
+++ b/tests/ui/lint/must_not_suspend/gated.stderr
@@ -7,6 +7,7 @@ LL | #![deny(must_not_suspend)]
    = note: the `must_not_suspend` lint is unstable
    = note: see issue #83310 <https://github.com/rust-lang/rust/issues/83310> for more information
    = help: add `#![feature(must_not_suspend)]` 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: `#[warn(unknown_lints)]` on by default
 
 warning: 1 warning emitted
diff --git a/tests/ui/lint/rfc-2383-lint-reason/expect_missing_feature_gate.stderr b/tests/ui/lint/rfc-2383-lint-reason/expect_missing_feature_gate.stderr
index b8e7d61a1ec..5d252fdcf5d 100644
--- a/tests/ui/lint/rfc-2383-lint-reason/expect_missing_feature_gate.stderr
+++ b/tests/ui/lint/rfc-2383-lint-reason/expect_missing_feature_gate.stderr
@@ -6,6 +6,7 @@ LL | #[expect(unused)]
    |
    = note: see issue #54503 <https://github.com/rust-lang/rust/issues/54503> for more information
    = help: add `#![feature(lint_reasons)]` 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 1 previous error
 
diff --git a/tests/ui/lint/unused/unused-doc-comments-edge-cases.stderr b/tests/ui/lint/unused/unused-doc-comments-edge-cases.stderr
index b5aa6215797..55e4834e670 100644
--- a/tests/ui/lint/unused/unused-doc-comments-edge-cases.stderr
+++ b/tests/ui/lint/unused/unused-doc-comments-edge-cases.stderr
@@ -12,6 +12,7 @@ LL |     /// useless doc comment
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: `///` is for documentation comments. For a plain comment, use `//`.
 
 error: unused doc comment
diff --git a/tests/ui/macros/issue-68060.rs b/tests/ui/macros/issue-68060.rs
index fb40cd5387b..1a826bd60e0 100644
--- a/tests/ui/macros/issue-68060.rs
+++ b/tests/ui/macros/issue-68060.rs
@@ -8,6 +8,7 @@ fn main() {
             #[track_caller]
             //~^ ERROR: `#[track_caller]` on closures is currently unstable
             //~| NOTE: see issue #87417
+            //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
             |_| (),
             //~^ NOTE: not a function
         )
diff --git a/tests/ui/macros/issue-68060.stderr b/tests/ui/macros/issue-68060.stderr
index 52e6ed92e9d..5724a9ea438 100644
--- a/tests/ui/macros/issue-68060.stderr
+++ b/tests/ui/macros/issue-68060.stderr
@@ -21,6 +21,7 @@ LL |             #[track_caller]
    |
    = note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
    = help: add `#![feature(closure_track_caller)]` 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
 
diff --git a/tests/ui/macros/macro-stability.stderr b/tests/ui/macros/macro-stability.stderr
index 2cfdb52b174..21b6cef5c9c 100644
--- a/tests/ui/macros/macro-stability.stderr
+++ b/tests/ui/macros/macro-stability.stderr
@@ -5,6 +5,7 @@ LL |     local_unstable!();
    |     ^^^^^^^^^^^^^^
    |
    = help: add `#![feature(local_unstable)]` 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]: use of unstable library feature 'local_unstable'
   --> $DIR/macro-stability.rs:23:5
@@ -13,6 +14,7 @@ LL |     local_unstable_modern!();
    |     ^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(local_unstable)]` 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]: use of unstable library feature 'unstable_macros'
   --> $DIR/macro-stability.rs:24:5
@@ -21,6 +23,7 @@ LL |     unstable_macro!();
    |     ^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_macros)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: use of deprecated macro `deprecated_macro`: deprecation note
   --> $DIR/macro-stability.rs:27:5
diff --git a/tests/ui/macros/rfc-3086-metavar-expr/required-feature.stderr b/tests/ui/macros/rfc-3086-metavar-expr/required-feature.stderr
index 2c2cbb15b72..7f4adb728c0 100644
--- a/tests/ui/macros/rfc-3086-metavar-expr/required-feature.stderr
+++ b/tests/ui/macros/rfc-3086-metavar-expr/required-feature.stderr
@@ -6,6 +6,7 @@ LL |         ${ count($e) }
    |
    = note: see issue #83527 <https://github.com/rust-lang/rust/issues/83527> for more information
    = help: add `#![feature(macro_metavar_expr)]` 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]: meta-variable expressions are unstable
   --> $DIR/required-feature.rs:11:16
@@ -15,6 +16,7 @@ LL |             ( $$( $$any:tt )* ) => { $$( $$any )* };
    |
    = note: see issue #83527 <https://github.com/rust-lang/rust/issues/83527> for more information
    = help: add `#![feature(macro_metavar_expr)]` 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]: meta-variable expressions are unstable
   --> $DIR/required-feature.rs:11:20
@@ -24,6 +26,7 @@ LL |             ( $$( $$any:tt )* ) => { $$( $$any )* };
    |
    = note: see issue #83527 <https://github.com/rust-lang/rust/issues/83527> for more information
    = help: add `#![feature(macro_metavar_expr)]` 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]: meta-variable expressions are unstable
   --> $DIR/required-feature.rs:11:39
@@ -33,6 +36,7 @@ LL |             ( $$( $$any:tt )* ) => { $$( $$any )* };
    |
    = note: see issue #83527 <https://github.com/rust-lang/rust/issues/83527> for more information
    = help: add `#![feature(macro_metavar_expr)]` 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]: meta-variable expressions are unstable
   --> $DIR/required-feature.rs:11:43
@@ -42,6 +46,7 @@ LL |             ( $$( $$any:tt )* ) => { $$( $$any )* };
    |
    = note: see issue #83527 <https://github.com/rust-lang/rust/issues/83527> for more information
    = help: add `#![feature(macro_metavar_expr)]` 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]: meta-variable expressions are unstable
   --> $DIR/required-feature.rs:22:13
@@ -51,6 +56,7 @@ LL |         $( ${ignore($e)} ${index()} )*
    |
    = note: see issue #83527 <https://github.com/rust-lang/rust/issues/83527> for more information
    = help: add `#![feature(macro_metavar_expr)]` 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]: meta-variable expressions are unstable
   --> $DIR/required-feature.rs:22:27
@@ -60,6 +66,7 @@ LL |         $( ${ignore($e)} ${index()} )*
    |
    = note: see issue #83527 <https://github.com/rust-lang/rust/issues/83527> for more information
    = help: add `#![feature(macro_metavar_expr)]` 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]: meta-variable expressions are unstable
   --> $DIR/required-feature.rs:30:19
@@ -69,6 +76,7 @@ LL |         0 $( + 1 ${ignore($i)} )*
    |
    = note: see issue #83527 <https://github.com/rust-lang/rust/issues/83527> for more information
    = help: add `#![feature(macro_metavar_expr)]` 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]: meta-variable expressions are unstable
   --> $DIR/required-feature.rs:37:13
@@ -78,6 +86,7 @@ LL |         $( ${ignore($e)} ${length()} )*
    |
    = note: see issue #83527 <https://github.com/rust-lang/rust/issues/83527> for more information
    = help: add `#![feature(macro_metavar_expr)]` 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]: meta-variable expressions are unstable
   --> $DIR/required-feature.rs:37:27
@@ -87,6 +96,7 @@ LL |         $( ${ignore($e)} ${length()} )*
    |
    = note: see issue #83527 <https://github.com/rust-lang/rust/issues/83527> for more information
    = help: add `#![feature(macro_metavar_expr)]` 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 10 previous errors
 
diff --git a/tests/ui/moves/move-fn-self-receiver.stderr b/tests/ui/moves/move-fn-self-receiver.stderr
index 462deacbe8d..17f48f5f7bf 100644
--- a/tests/ui/moves/move-fn-self-receiver.stderr
+++ b/tests/ui/moves/move-fn-self-receiver.stderr
@@ -55,10 +55,15 @@ note: `Foo::use_box_self` takes ownership of the receiver `self`, which moves `b
    |
 LL |     fn use_box_self(self: Box<Self>) {}
    |                     ^^^^
-help: you could `clone` the value and consume it, if the `Box<Foo>: Clone` trait bound could be satisfied
+help: you could `clone` the value and consume it, if the `Foo: Clone` trait bound could be satisfied
    |
 LL |     boxed_foo.clone().use_box_self();
    |              ++++++++
+help: consider annotating `Foo` with `#[derive(Clone)]`
+   |
+LL + #[derive(Clone)]
+LL | struct Foo;
+   |
 
 error[E0382]: use of moved value: `pin_box_foo`
   --> $DIR/move-fn-self-receiver.rs:46:5
@@ -75,10 +80,15 @@ note: `Foo::use_pin_box_self` takes ownership of the receiver `self`, which move
    |
 LL |     fn use_pin_box_self(self: Pin<Box<Self>>) {}
    |                         ^^^^
-help: you could `clone` the value and consume it, if the `Box<Foo>: Clone` trait bound could be satisfied
+help: you could `clone` the value and consume it, if the `Foo: Clone` trait bound could be satisfied
    |
 LL |     pin_box_foo.clone().use_pin_box_self();
    |                ++++++++
+help: consider annotating `Foo` with `#[derive(Clone)]`
+   |
+LL + #[derive(Clone)]
+LL | struct Foo;
+   |
 
 error[E0505]: cannot move out of `mut_foo` because it is borrowed
   --> $DIR/move-fn-self-receiver.rs:50:5
diff --git a/tests/ui/never_type/issue-52443.stderr b/tests/ui/never_type/issue-52443.stderr
index 59292ed68a3..83afd9ef2f2 100644
--- a/tests/ui/never_type/issue-52443.stderr
+++ b/tests/ui/never_type/issue-52443.stderr
@@ -14,6 +14,7 @@ LL |     [(); { for _ in 0usize.. {}; 0}];
    |
    = note: see issue #87575 <https://github.com/rust-lang/rust/issues/87575> for more information
    = help: add `#![feature(const_for)]` 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[E0308]: mismatched types
   --> $DIR/issue-52443.rs:2:10
@@ -59,6 +60,7 @@ LL |     [(); { for _ in 0usize.. {}; 0}];
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0015]: cannot call non-const fn `<RangeFrom<usize> as Iterator>::next` in constants
   --> $DIR/issue-52443.rs:9:21
diff --git a/tests/ui/offset-of/offset-of-unstable.stderr b/tests/ui/offset-of/offset-of-unstable.stderr
index c39882519a5..4882dee4042 100644
--- a/tests/ui/offset-of/offset-of-unstable.stderr
+++ b/tests/ui/offset-of/offset-of-unstable.stderr
@@ -5,6 +5,7 @@ LL |         Unstable,
    |         ^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/offset-of-unstable.rs:23:9
@@ -13,6 +14,7 @@ LL |         UnstableWithStableFieldType,
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/offset-of-unstable.rs:28:9
@@ -21,6 +23,7 @@ LL |         UnstableWithStableFieldType,
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/offset-of-unstable.rs:12:5
@@ -33,6 +36,7 @@ LL | |     );
    | |_____^
    |
    = help: add `#![feature(unstable_test_feature)]` 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: this error originates in the macro `offset_of` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error[E0658]: use of unstable library feature 'unstable_test_feature'
@@ -42,6 +46,7 @@ LL |     offset_of!(StableWithUnstableField, unstable);
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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: this error originates in the macro `offset_of` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error[E0658]: use of unstable library feature 'unstable_test_feature'
@@ -51,6 +56,7 @@ LL |     offset_of!(StableWithUnstableFieldType, stable.unstable);
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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: this error originates in the macro `offset_of` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error[E0658]: use of unstable library feature 'unstable_test_feature'
@@ -64,6 +70,7 @@ LL | |     );
    | |_____^
    |
    = help: add `#![feature(unstable_test_feature)]` 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: this error originates in the macro `offset_of` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error[E0658]: use of unstable library feature 'unstable_test_feature'
@@ -77,6 +84,7 @@ LL | |     );
    | |_____^
    |
    = help: add `#![feature(unstable_test_feature)]` 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: this error originates in the macro `offset_of` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: aborting due to 8 previous errors
diff --git a/tests/ui/on-unimplemented/feature-gate-on-unimplemented.stderr b/tests/ui/on-unimplemented/feature-gate-on-unimplemented.stderr
index 45ef22f4421..2733f7478f0 100644
--- a/tests/ui/on-unimplemented/feature-gate-on-unimplemented.stderr
+++ b/tests/ui/on-unimplemented/feature-gate-on-unimplemented.stderr
@@ -5,6 +5,7 @@ LL | #[rustc_on_unimplemented = "test error `{Self}` with `{Bar}`"]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(rustc_attrs)]` 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 1 previous error
 
diff --git a/tests/ui/or-patterns/or-patterns-syntactic-pass.stderr b/tests/ui/or-patterns/or-patterns-syntactic-pass.stderr
index c43fe192a73..a755342ecf3 100644
--- a/tests/ui/or-patterns/or-patterns-syntactic-pass.stderr
+++ b/tests/ui/or-patterns/or-patterns-syntactic-pass.stderr
@@ -6,6 +6,7 @@ LL |     let (box 0 | 1); // Unstable; we *can* change the precedence if we want
    |
    = note: see issue #29641 <https://github.com/rust-lang/rust/issues/29641> for more information
    = help: add `#![feature(box_patterns)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
    = warning: unstable syntax can change at any point in the future, causing a hard error!
    = note: for more information, see issue #65860 <https://github.com/rust-lang/rust/issues/65860>
 
diff --git a/tests/ui/panic-runtime/needs-gate.stderr b/tests/ui/panic-runtime/needs-gate.stderr
index e067ccaebcf..9f66f05bac9 100644
--- a/tests/ui/panic-runtime/needs-gate.stderr
+++ b/tests/ui/panic-runtime/needs-gate.stderr
@@ -6,6 +6,7 @@ LL | #![panic_runtime]
    |
    = note: see issue #32837 <https://github.com/rust-lang/rust/issues/32837> for more information
    = help: add `#![feature(panic_runtime)]` 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]: the `#[needs_panic_runtime]` attribute is an experimental feature
   --> $DIR/needs-gate.rs:5:1
@@ -15,6 +16,7 @@ LL | #![needs_panic_runtime]
    |
    = note: see issue #32837 <https://github.com/rust-lang/rust/issues/32837> for more information
    = help: add `#![feature(needs_panic_runtime)]` 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 2 previous errors
 
diff --git a/tests/ui/parser/attribute/attr-unquoted-ident.fixed b/tests/ui/parser/attribute/attr-unquoted-ident.fixed
new file mode 100644
index 00000000000..6cdf22f7ec0
--- /dev/null
+++ b/tests/ui/parser/attribute/attr-unquoted-ident.fixed
@@ -0,0 +1,15 @@
+// compile-flags: -Zdeduplicate-diagnostics=yes
+// run-rustfix
+
+fn main() {
+    #[cfg(key="foo")]
+    //~^ ERROR expected unsuffixed literal, found `foo`
+    //~| HELP surround the identifier with quotation marks to parse it as a string
+    println!();
+    #[cfg(key="bar")]
+    println!();
+    #[cfg(key="foo bar baz")]
+    //~^ ERROR expected unsuffixed literal, found `foo`
+    //~| HELP surround the identifier with quotation marks to parse it as a string
+    println!();
+}
diff --git a/tests/ui/parser/attribute/attr-unquoted-ident.rs b/tests/ui/parser/attribute/attr-unquoted-ident.rs
new file mode 100644
index 00000000000..75af015c9fe
--- /dev/null
+++ b/tests/ui/parser/attribute/attr-unquoted-ident.rs
@@ -0,0 +1,15 @@
+// compile-flags: -Zdeduplicate-diagnostics=yes
+// run-rustfix
+
+fn main() {
+    #[cfg(key=foo)]
+    //~^ ERROR expected unsuffixed literal, found `foo`
+    //~| HELP surround the identifier with quotation marks to parse it as a string
+    println!();
+    #[cfg(key="bar")]
+    println!();
+    #[cfg(key=foo bar baz)]
+    //~^ ERROR expected unsuffixed literal, found `foo`
+    //~| HELP surround the identifier with quotation marks to parse it as a string
+    println!();
+}
diff --git a/tests/ui/parser/attribute/attr-unquoted-ident.stderr b/tests/ui/parser/attribute/attr-unquoted-ident.stderr
new file mode 100644
index 00000000000..bc028f39be6
--- /dev/null
+++ b/tests/ui/parser/attribute/attr-unquoted-ident.stderr
@@ -0,0 +1,24 @@
+error: expected unsuffixed literal, found `foo`
+  --> $DIR/attr-unquoted-ident.rs:5:15
+   |
+LL |     #[cfg(key=foo)]
+   |               ^^^
+   |
+help: surround the identifier with quotation marks to parse it as a string
+   |
+LL |     #[cfg(key="foo")]
+   |               +   +
+
+error: expected unsuffixed literal, found `foo`
+  --> $DIR/attr-unquoted-ident.rs:11:15
+   |
+LL |     #[cfg(key=foo bar baz)]
+   |               ^^^
+   |
+help: surround the identifier with quotation marks to parse it as a string
+   |
+LL |     #[cfg(key="foo bar baz")]
+   |               +           +
+
+error: aborting due to 2 previous errors
+
diff --git a/tests/ui/parser/constraints-before-generic-args-syntactic-pass.stderr b/tests/ui/parser/constraints-before-generic-args-syntactic-pass.stderr
index 7e843c7f4d0..393ed704b41 100644
--- a/tests/ui/parser/constraints-before-generic-args-syntactic-pass.stderr
+++ b/tests/ui/parser/constraints-before-generic-args-syntactic-pass.stderr
@@ -6,6 +6,7 @@ LL |     foo::<T = u8, T: Ord, String>();
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
    = warning: unstable syntax can change at any point in the future, causing a hard error!
    = note: for more information, see issue #65860 <https://github.com/rust-lang/rust/issues/65860>
 
@@ -17,6 +18,7 @@ LL |     foo::<T = u8, 'a, T: Ord>();
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
    = warning: unstable syntax can change at any point in the future, causing a hard error!
    = note: for more information, see issue #65860 <https://github.com/rust-lang/rust/issues/65860>
 
diff --git a/tests/ui/parser/impl-item-type-no-body-semantic-fail.stderr b/tests/ui/parser/impl-item-type-no-body-semantic-fail.stderr
index 5bcbbb9deb7..d23e6027473 100644
--- a/tests/ui/parser/impl-item-type-no-body-semantic-fail.stderr
+++ b/tests/ui/parser/impl-item-type-no-body-semantic-fail.stderr
@@ -50,6 +50,7 @@ LL |     type Y;
    |
    = note: see issue #8995 <https://github.com/rust-lang/rust/issues/8995> for more information
    = help: add `#![feature(inherent_associated_types)]` 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]: inherent associated types are unstable
   --> $DIR/impl-item-type-no-body-semantic-fail.rs:9:5
@@ -59,6 +60,7 @@ LL |     type Z: Ord;
    |
    = note: see issue #8995 <https://github.com/rust-lang/rust/issues/8995> for more information
    = help: add `#![feature(inherent_associated_types)]` 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]: inherent associated types are unstable
   --> $DIR/impl-item-type-no-body-semantic-fail.rs:13:5
@@ -68,6 +70,7 @@ LL |     type W: Ord where Self: Eq;
    |
    = note: see issue #8995 <https://github.com/rust-lang/rust/issues/8995> for more information
    = help: add `#![feature(inherent_associated_types)]` 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]: inherent associated types are unstable
   --> $DIR/impl-item-type-no-body-semantic-fail.rs:17:5
@@ -77,6 +80,7 @@ LL |     type W where Self: Eq;
    |
    = note: see issue #8995 <https://github.com/rust-lang/rust/issues/8995> for more information
    = help: add `#![feature(inherent_associated_types)]` 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[E0592]: duplicate definitions with name `W`
   --> $DIR/impl-item-type-no-body-semantic-fail.rs:17:5
diff --git a/tests/ui/parser/issues/issue-118531-ice.stderr b/tests/ui/parser/issues/issue-118531-ice.stderr
index a32292dcb0d..68c7ad47b9d 100644
--- a/tests/ui/parser/issues/issue-118531-ice.stderr
+++ b/tests/ui/parser/issues/issue-118531-ice.stderr
@@ -26,6 +26,7 @@ LL |     #[attr]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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: cannot find attribute `attr` in this scope
   --> $DIR/issue-118531-ice.rs:5:7
diff --git a/tests/ui/parser/recover/recover-assoc-const-constraint.stderr b/tests/ui/parser/recover/recover-assoc-const-constraint.stderr
index 2d36ce4e986..02b1c3fe68a 100644
--- a/tests/ui/parser/recover/recover-assoc-const-constraint.stderr
+++ b/tests/ui/parser/recover/recover-assoc-const-constraint.stderr
@@ -6,6 +6,7 @@ LL |     bar::<Item = 42>();
    |
    = note: see issue #92827 <https://github.com/rust-lang/rust/issues/92827> for more information
    = help: add `#![feature(associated_const_equality)]` 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]: associated const equality is incomplete
   --> $DIR/recover-assoc-const-constraint.rs:5:11
@@ -15,6 +16,7 @@ LL |     bar::<Item = { 42 }>();
    |
    = note: see issue #92827 <https://github.com/rust-lang/rust/issues/92827> for more information
    = help: add `#![feature(associated_const_equality)]` 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 2 previous errors
 
diff --git a/tests/ui/parser/recover/recover-quantified-closure.stderr b/tests/ui/parser/recover/recover-quantified-closure.stderr
index 37e93cbee7b..6e03bbb5869 100644
--- a/tests/ui/parser/recover/recover-quantified-closure.stderr
+++ b/tests/ui/parser/recover/recover-quantified-closure.stderr
@@ -12,6 +12,7 @@ LL |     for<'a> |x: &'a u8| *x + 1;
    |
    = note: see issue #97362 <https://github.com/rust-lang/rust/issues/97362> for more information
    = help: add `#![feature(closure_lifetime_binder)]` 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: consider removing `for<...>`
 
 error[E0658]: `for<...>` binders for closures are experimental
@@ -22,6 +23,7 @@ LL |     for <Foo>::Bar in x {}
    |
    = note: see issue #97362 <https://github.com/rust-lang/rust/issues/97362> for more information
    = help: add `#![feature(closure_lifetime_binder)]` 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: consider removing `for<...>`
 
 error: implicit types in closure signatures are forbidden when `for<...>` is present
diff --git a/tests/ui/pattern/never_patterns.rs b/tests/ui/pattern/never_patterns.rs
index 915f3e75e7b..8f44f8a6559 100644
--- a/tests/ui/pattern/never_patterns.rs
+++ b/tests/ui/pattern/never_patterns.rs
@@ -7,12 +7,9 @@ fn main() {}
 
 // The classic use for empty types.
 fn safe_unwrap_result<T>(res: Result<T, Void>) {
-    let Ok(_x) = res;
-    // FIXME(never_patterns): These should be allowed
+    let Ok(_x) = res; //~ ERROR refutable pattern in local binding
     let (Ok(_x) | Err(!)) = &res;
-    //~^ ERROR: is not bound in all patterns
     let (Ok(_x) | Err(&!)) = res.as_ref();
-    //~^ ERROR: is not bound in all patterns
 }
 
 // Check we only accept `!` where we want to.
@@ -74,26 +71,3 @@ fn never_pattern_location(void: Void) {
         Some(&(_, !)),
     }
 }
-
-fn never_and_bindings() {
-    let x: Result<bool, &(u32, Void)> = Ok(false);
-
-    // FIXME(never_patterns): Never patterns in or-patterns don't need to share the same bindings.
-    match x {
-        Ok(_x) | Err(&!) => {}
-        //~^ ERROR: is not bound in all patterns
-    }
-    let (Ok(_x) | Err(&!)) = x;
-    //~^ ERROR: is not bound in all patterns
-
-    // FIXME(never_patterns): A never pattern mustn't have bindings.
-    match x {
-        Ok(_) => {}
-        Err(&(_b, !)),
-    }
-    match x {
-        Ok(_a) | Err(&(_b, !)) => {}
-        //~^ ERROR: is not bound in all patterns
-        //~| ERROR: is not bound in all patterns
-    }
-}
diff --git a/tests/ui/pattern/never_patterns.stderr b/tests/ui/pattern/never_patterns.stderr
index 11e50debfd3..20eeb01cf71 100644
--- a/tests/ui/pattern/never_patterns.stderr
+++ b/tests/ui/pattern/never_patterns.stderr
@@ -1,51 +1,17 @@
-error[E0408]: variable `_x` is not bound in all patterns
-  --> $DIR/never_patterns.rs:12:19
+error[E0005]: refutable pattern in local binding
+  --> $DIR/never_patterns.rs:10:9
    |
-LL |     let (Ok(_x) | Err(!)) = &res;
-   |             --    ^^^^^^ pattern doesn't bind `_x`
-   |             |
-   |             variable not in all patterns
-
-error[E0408]: variable `_x` is not bound in all patterns
-  --> $DIR/never_patterns.rs:14:19
-   |
-LL |     let (Ok(_x) | Err(&!)) = res.as_ref();
-   |             --    ^^^^^^^ pattern doesn't bind `_x`
-   |             |
-   |             variable not in all patterns
-
-error[E0408]: variable `_x` is not bound in all patterns
-  --> $DIR/never_patterns.rs:83:18
-   |
-LL |         Ok(_x) | Err(&!) => {}
-   |            --    ^^^^^^^ pattern doesn't bind `_x`
-   |            |
-   |            variable not in all patterns
-
-error[E0408]: variable `_x` is not bound in all patterns
-  --> $DIR/never_patterns.rs:86:19
-   |
-LL |     let (Ok(_x) | Err(&!)) = x;
-   |             --    ^^^^^^^ pattern doesn't bind `_x`
-   |             |
-   |             variable not in all patterns
-
-error[E0408]: variable `_b` is not bound in all patterns
-  --> $DIR/never_patterns.rs:95:9
+LL |     let Ok(_x) = res;
+   |         ^^^^^^ pattern `Err(_)` not covered
    |
-LL |         Ok(_a) | Err(&(_b, !)) => {}
-   |         ^^^^^^         -- variable not in all patterns
-   |         |
-   |         pattern doesn't bind `_b`
-
-error[E0408]: variable `_a` is not bound in all patterns
-  --> $DIR/never_patterns.rs:95:18
+   = note: `let` bindings require an "irrefutable pattern", like a `struct` or an `enum` with only one variant
+   = note: for more information, visit https://doc.rust-lang.org/book/ch18-02-refutability.html
+   = note: the matched value is of type `Result<T, Void>`
+help: you might want to use `let else` to handle the variant that isn't matched
    |
-LL |         Ok(_a) | Err(&(_b, !)) => {}
-   |            --    ^^^^^^^^^^^^^ pattern doesn't bind `_a`
-   |            |
-   |            variable not in all patterns
+LL |     let Ok(_x) = res else { todo!() };
+   |                      ++++++++++++++++
 
-error: aborting due to 6 previous errors
+error: aborting due to 1 previous error
 
-For more information about this error, try `rustc --explain E0408`.
+For more information about this error, try `rustc --explain E0005`.
diff --git a/tests/ui/pattern/range-pattern-meant-to-be-slice-rest-pattern.stderr b/tests/ui/pattern/range-pattern-meant-to-be-slice-rest-pattern.stderr
index cddd0121279..c3c9131b63e 100644
--- a/tests/ui/pattern/range-pattern-meant-to-be-slice-rest-pattern.stderr
+++ b/tests/ui/pattern/range-pattern-meant-to-be-slice-rest-pattern.stderr
@@ -23,6 +23,7 @@ LL |         [1, rest..] => println!("{rest:?}"),
    |
    = note: see issue #67264 <https://github.com/rust-lang/rust/issues/67264> for more information
    = help: add `#![feature(half_open_range_patterns_in_slices)]` 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
 
diff --git a/tests/ui/pattern/rest-pat-syntactic.stderr b/tests/ui/pattern/rest-pat-syntactic.stderr
index 37019b7d5ba..4de27305189 100644
--- a/tests/ui/pattern/rest-pat-syntactic.stderr
+++ b/tests/ui/pattern/rest-pat-syntactic.stderr
@@ -6,6 +6,7 @@ LL |     let box ..;
    |
    = note: see issue #29641 <https://github.com/rust-lang/rust/issues/29641> for more information
    = help: add `#![feature(box_patterns)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
    = warning: unstable syntax can change at any point in the future, causing a hard error!
    = note: for more information, see issue #65860 <https://github.com/rust-lang/rust/issues/65860>
 
@@ -17,6 +18,7 @@ LL |                 box ..,
    |
    = note: see issue #29641 <https://github.com/rust-lang/rust/issues/29641> for more information
    = help: add `#![feature(box_patterns)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
    = warning: unstable syntax can change at any point in the future, causing a hard error!
    = note: for more information, see issue #65860 <https://github.com/rust-lang/rust/issues/65860>
 
diff --git a/tests/ui/pattern/usefulness/issue-119493-type-error-ice.stderr b/tests/ui/pattern/usefulness/issue-119493-type-error-ice.stderr
index 6d74feb7a9f..1c560aa2ca8 100644
--- a/tests/ui/pattern/usefulness/issue-119493-type-error-ice.stderr
+++ b/tests/ui/pattern/usefulness/issue-119493-type-error-ice.stderr
@@ -23,6 +23,7 @@ LL |     type U = impl Copy;
    |
    = note: see issue #63063 <https://github.com/rust-lang/rust/issues/63063> for more information
    = help: add `#![feature(type_alias_impl_trait)]` 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
 
diff --git a/tests/ui/pattern/usefulness/issue-119778-type-error-ice.stderr b/tests/ui/pattern/usefulness/issue-119778-type-error-ice.stderr
index 93ef05decd2..7da384d613e 100644
--- a/tests/ui/pattern/usefulness/issue-119778-type-error-ice.stderr
+++ b/tests/ui/pattern/usefulness/issue-119778-type-error-ice.stderr
@@ -28,6 +28,7 @@ LL |     type U = impl Copy;
    |
    = note: see issue #63063 <https://github.com/rust-lang/rust/issues/63063> for more information
    = help: add `#![feature(type_alias_impl_trait)]` 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
 
diff --git a/tests/ui/pin-macro/cant_access_internals.stderr b/tests/ui/pin-macro/cant_access_internals.stderr
index 9af1cd2a16c..2737b84f599 100644
--- a/tests/ui/pin-macro/cant_access_internals.stderr
+++ b/tests/ui/pin-macro/cant_access_internals.stderr
@@ -5,6 +5,7 @@ LL |     mem::take(phantom_pinned.pointer);
    |               ^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unsafe_pin_internals)]` 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 1 previous error
 
diff --git a/tests/ui/proc-macro/attr-stmt-expr.stderr b/tests/ui/proc-macro/attr-stmt-expr.stderr
index 56178259d43..92edc44b278 100644
--- a/tests/ui/proc-macro/attr-stmt-expr.stderr
+++ b/tests/ui/proc-macro/attr-stmt-expr.stderr
@@ -6,6 +6,7 @@ LL |     #[expect_my_macro_expr]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
   --> $DIR/attr-stmt-expr.rs:62:5
@@ -15,6 +16,7 @@ LL |     #[expect_expr]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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 2 previous errors
 
diff --git a/tests/ui/proc-macro/attributes-on-modules-fail.stderr b/tests/ui/proc-macro/attributes-on-modules-fail.stderr
index 97521f23aee..e69ab787238 100644
--- a/tests/ui/proc-macro/attributes-on-modules-fail.stderr
+++ b/tests/ui/proc-macro/attributes-on-modules-fail.stderr
@@ -14,6 +14,7 @@ LL | mod module;
    |
    = note: see issue #54727 <https://github.com/rust-lang/rust/issues/54727> for more information
    = help: add `#![feature(proc_macro_hygiene)]` 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]: non-inline modules in proc macro input are unstable
   --> $DIR/attributes-on-modules-fail.rs:24:5
@@ -23,6 +24,7 @@ LL |     mod inner;
    |
    = note: see issue #54727 <https://github.com/rust-lang/rust/issues/54727> for more information
    = help: add `#![feature(proc_macro_hygiene)]` 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]: non-inline modules in proc macro input are unstable
   --> $DIR/attributes-on-modules-fail.rs:33:9
@@ -32,6 +34,7 @@ LL |         mod inner;
    |
    = note: see issue #54727 <https://github.com/rust-lang/rust/issues/54727> for more information
    = help: add `#![feature(proc_macro_hygiene)]` 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]: non-inline modules in proc macro input are unstable
   --> $DIR/attributes-on-modules-fail.rs:42:5
@@ -41,6 +44,7 @@ LL |     mod inner;
    |
    = note: see issue #54727 <https://github.com/rust-lang/rust/issues/54727> for more information
    = help: add `#![feature(proc_macro_hygiene)]` 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[E0412]: cannot find type `Y` in this scope
   --> $DIR/attributes-on-modules-fail.rs:10:14
diff --git a/tests/ui/proc-macro/auxiliary/api/mod.rs b/tests/ui/proc-macro/auxiliary/api/mod.rs
index 3bea5d75779..5a533b9e17e 100644
--- a/tests/ui/proc-macro/auxiliary/api/mod.rs
+++ b/tests/ui/proc-macro/auxiliary/api/mod.rs
@@ -1,10 +1,12 @@
 // force-host
 // no-prefer-dynamic
+// edition: 2021
 
 #![crate_type = "proc-macro"]
 #![crate_name = "proc_macro_api_tests"]
 #![feature(proc_macro_span)]
 #![feature(proc_macro_byte_character)]
+#![feature(proc_macro_c_str_literals)]
 #![deny(dead_code)] // catch if a test function is never called
 
 extern crate proc_macro;
diff --git a/tests/ui/proc-macro/auxiliary/api/parse.rs b/tests/ui/proc-macro/auxiliary/api/parse.rs
index 07c9f464961..801c616c804 100644
--- a/tests/ui/proc-macro/auxiliary/api/parse.rs
+++ b/tests/ui/proc-macro/auxiliary/api/parse.rs
@@ -19,10 +19,8 @@ fn test_display_literal() {
         "10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000.0",
     );
 
-    assert_eq!(
-        Literal::string("a \t ❤ ' \" \u{1}").to_string(),
-        "\"a \\t ❤ ' \\\" \\u{1}\"",
-    );
+    assert_eq!(Literal::string("a \t ❤ ' \" \u{1}").to_string(), "\"a \\t ❤ ' \\\" \\u{1}\"",);
+    assert_eq!(Literal::c_string(c"\'\"\x7f\u{7fff}").to_string(), r#"c"\'\"\x7f\xe7\xbf\xbf""#);
     assert_eq!(Literal::character('a').to_string(), "'a'");
     assert_eq!(Literal::character('\t').to_string(), "'\\t'");
     assert_eq!(Literal::character('❤').to_string(), "'❤'");
@@ -41,6 +39,7 @@ fn test_parse_literal() {
     assert_eq!("b'a'".parse::<Literal>().unwrap().to_string(), "b'a'");
     assert_eq!("\"\n\"".parse::<Literal>().unwrap().to_string(), "\"\n\"");
     assert_eq!("b\"\"".parse::<Literal>().unwrap().to_string(), "b\"\"");
+    assert_eq!("c\"\"".parse::<Literal>().unwrap().to_string(), "c\"\"");
     assert_eq!("r##\"\"##".parse::<Literal>().unwrap().to_string(), "r##\"\"##");
     assert_eq!("10ulong".parse::<Literal>().unwrap().to_string(), "10ulong");
     assert_eq!("-10ulong".parse::<Literal>().unwrap().to_string(), "-10ulong");
diff --git a/tests/ui/proc-macro/expand-to-unstable.stderr b/tests/ui/proc-macro/expand-to-unstable.stderr
index dda590ee8c7..9eb701d9702 100644
--- a/tests/ui/proc-macro/expand-to-unstable.stderr
+++ b/tests/ui/proc-macro/expand-to-unstable.stderr
@@ -5,6 +5,7 @@ LL | #[derive(Unstable)]
    |          ^^^^^^^^
    |
    = help: add `#![feature(core_intrinsics)]` 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: this error originates in the derive macro `Unstable` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: aborting due to 1 previous error
diff --git a/tests/ui/proc-macro/inner-attr-non-inline-mod.stderr b/tests/ui/proc-macro/inner-attr-non-inline-mod.stderr
index 36825e5a398..ccc967aaff9 100644
--- a/tests/ui/proc-macro/inner-attr-non-inline-mod.stderr
+++ b/tests/ui/proc-macro/inner-attr-non-inline-mod.stderr
@@ -6,6 +6,7 @@ LL | #![print_attr]
    |
    = note: see issue #54726 <https://github.com/rust-lang/rust/issues/54726> for more information
    = help: add `#![feature(custom_inner_attributes)]` 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]: non-inline modules in proc macro input are unstable
   --> $DIR/inner-attr-non-inline-mod.rs:14:1
@@ -15,6 +16,7 @@ LL | mod module_with_attrs;
    |
    = note: see issue #54727 <https://github.com/rust-lang/rust/issues/54727> for more information
    = help: add `#![feature(proc_macro_hygiene)]` 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]: custom inner attributes are unstable
   --> $DIR/inner-attr-non-inline-mod.rs:14:1
@@ -24,6 +26,7 @@ LL | mod module_with_attrs;
    |
    = note: see issue #54726 <https://github.com/rust-lang/rust/issues/54726> for more information
    = help: add `#![feature(custom_inner_attributes)]` 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: custom inner attributes are unstable
   --> $DIR/module_with_attrs.rs:3:4
diff --git a/tests/ui/proc-macro/issue-83510.stderr b/tests/ui/proc-macro/issue-83510.stderr
index e0628a31791..e59b77af3dc 100644
--- a/tests/ui/proc-macro/issue-83510.stderr
+++ b/tests/ui/proc-macro/issue-83510.stderr
@@ -30,6 +30,7 @@ LL | issue_83510::dance_like_you_want_to_ice!();
    |
    = note: see issue #8995 <https://github.com/rust-lang/rust/issues/8995> for more information
    = help: add `#![feature(inherent_associated_types)]` 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: this error originates in the macro `issue_83510::dance_like_you_want_to_ice` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: aborting due to 4 previous errors
diff --git a/tests/ui/proc-macro/proc-macro-gates.stderr b/tests/ui/proc-macro/proc-macro-gates.stderr
index ab98784bfbd..a05a7d0b185 100644
--- a/tests/ui/proc-macro/proc-macro-gates.stderr
+++ b/tests/ui/proc-macro/proc-macro-gates.stderr
@@ -6,6 +6,7 @@ LL |     #![empty_attr]
    |
    = note: see issue #54726 <https://github.com/rust-lang/rust/issues/54726> for more information
    = help: add `#![feature(custom_inner_attributes)]` 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]: inner macro attributes are unstable
   --> $DIR/proc-macro-gates.rs:14:8
@@ -15,6 +16,7 @@ LL |     #![empty_attr]
    |
    = note: see issue #54726 <https://github.com/rust-lang/rust/issues/54726> for more information
    = help: add `#![feature(custom_inner_attributes)]` 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: key-value macro attributes are not supported
   --> $DIR/proc-macro-gates.rs:17:1
@@ -30,6 +32,7 @@ LL |     #[empty_attr]
    |
    = note: see issue #54727 <https://github.com/rust-lang/rust/issues/54727> for more information
    = help: add `#![feature(proc_macro_hygiene)]` 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]: custom attributes cannot be applied to statements
   --> $DIR/proc-macro-gates.rs:30:5
@@ -39,6 +42,7 @@ LL |     #[empty_attr]
    |
    = note: see issue #54727 <https://github.com/rust-lang/rust/issues/54727> for more information
    = help: add `#![feature(proc_macro_hygiene)]` 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]: custom attributes cannot be applied to statements
   --> $DIR/proc-macro-gates.rs:34:5
@@ -48,6 +52,7 @@ LL |     #[empty_attr]
    |
    = note: see issue #54727 <https://github.com/rust-lang/rust/issues/54727> for more information
    = help: add `#![feature(proc_macro_hygiene)]` 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]: custom attributes cannot be applied to expressions
   --> $DIR/proc-macro-gates.rs:38:14
@@ -57,6 +62,7 @@ LL |     let _x = #[identity_attr] 2;
    |
    = note: see issue #54727 <https://github.com/rust-lang/rust/issues/54727> for more information
    = help: add `#![feature(proc_macro_hygiene)]` 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]: custom attributes cannot be applied to expressions
   --> $DIR/proc-macro-gates.rs:41:15
@@ -66,6 +72,7 @@ LL |     let _x = [#[identity_attr] 2];
    |
    = note: see issue #54727 <https://github.com/rust-lang/rust/issues/54727> for more information
    = help: add `#![feature(proc_macro_hygiene)]` 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]: custom attributes cannot be applied to expressions
   --> $DIR/proc-macro-gates.rs:44:14
@@ -75,6 +82,7 @@ LL |     let _x = #[identity_attr] println!();
    |
    = note: see issue #54727 <https://github.com/rust-lang/rust/issues/54727> for more information
    = help: add `#![feature(proc_macro_hygiene)]` 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: inner macro attributes are unstable
   --> $DIR/proc-macro-gates.rs:49:8
diff --git a/tests/ui/proc-macro/test.rs b/tests/ui/proc-macro/test.rs
index c96aa73175f..2ec62072020 100644
--- a/tests/ui/proc-macro/test.rs
+++ b/tests/ui/proc-macro/test.rs
@@ -1,5 +1,6 @@
 // check-pass
 // aux-build:api/mod.rs
+// edition: 2021
 
 //! This is for everything that *would* be a #[test] inside of libproc_macro,
 //! except for the fact that proc_macro objects are not capable of existing
diff --git a/tests/ui/raw-ref-op/feature-raw-ref-op.stderr b/tests/ui/raw-ref-op/feature-raw-ref-op.stderr
index 1e5fd84ff71..4ffd0c90e48 100644
--- a/tests/ui/raw-ref-op/feature-raw-ref-op.stderr
+++ b/tests/ui/raw-ref-op/feature-raw-ref-op.stderr
@@ -6,6 +6,7 @@ LL |     &raw const a;
    |
    = note: see issue #64490 <https://github.com/rust-lang/rust/issues/64490> for more information
    = help: add `#![feature(raw_ref_op)]` 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]: raw address of syntax is experimental
   --> $DIR/feature-raw-ref-op.rs:14:5
@@ -15,6 +16,7 @@ LL |     &raw mut a;
    |
    = note: see issue #64490 <https://github.com/rust-lang/rust/issues/64490> for more information
    = help: add `#![feature(raw_ref_op)]` 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]: raw address of syntax is experimental
   --> $DIR/feature-raw-ref-op.rs:19:13
@@ -24,6 +26,7 @@ LL |     let x = &raw const y;
    |
    = note: see issue #64490 <https://github.com/rust-lang/rust/issues/64490> for more information
    = help: add `#![feature(raw_ref_op)]` 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]: raw address of syntax is experimental
   --> $DIR/feature-raw-ref-op.rs:20:13
@@ -33,6 +36,7 @@ LL |     let x = &raw mut y;
    |
    = note: see issue #64490 <https://github.com/rust-lang/rust/issues/64490> for more information
    = help: add `#![feature(raw_ref_op)]` 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]: raw address of syntax is experimental
   --> $DIR/feature-raw-ref-op.rs:7:10
@@ -42,6 +46,7 @@ LL | is_expr!(&raw const a);
    |
    = note: see issue #64490 <https://github.com/rust-lang/rust/issues/64490> for more information
    = help: add `#![feature(raw_ref_op)]` 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]: raw address of syntax is experimental
   --> $DIR/feature-raw-ref-op.rs:8:10
@@ -51,6 +56,7 @@ LL | is_expr!(&raw mut a);
    |
    = note: see issue #64490 <https://github.com/rust-lang/rust/issues/64490> for more information
    = help: add `#![feature(raw_ref_op)]` 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 6 previous errors
 
diff --git a/tests/ui/repr/explicit-rust-repr-conflicts.stderr b/tests/ui/repr/explicit-rust-repr-conflicts.stderr
index 7126da574b6..30b667f5f2b 100644
--- a/tests/ui/repr/explicit-rust-repr-conflicts.stderr
+++ b/tests/ui/repr/explicit-rust-repr-conflicts.stderr
@@ -6,6 +6,7 @@ LL | #[repr(Rust, simd)]
    |
    = note: see issue #27731 <https://github.com/rust-lang/rust/issues/27731> for more information
    = help: add `#![feature(repr_simd)]` 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[E0566]: conflicting representation hints
   --> $DIR/explicit-rust-repr-conflicts.rs:1:8
diff --git a/tests/ui/rfcs/rfc-0000-never_patterns/ICE-119271-never-arm-attr-in-guard.stderr b/tests/ui/rfcs/rfc-0000-never_patterns/ICE-119271-never-arm-attr-in-guard.stderr
index 335e6c6db5f..a456b686e56 100644
--- a/tests/ui/rfcs/rfc-0000-never_patterns/ICE-119271-never-arm-attr-in-guard.stderr
+++ b/tests/ui/rfcs/rfc-0000-never_patterns/ICE-119271-never-arm-attr-in-guard.stderr
@@ -6,6 +6,7 @@ LL |             if #[deny(unused_mut)]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: `!` patterns are experimental
   --> $DIR/ICE-119271-never-arm-attr-in-guard.rs:5:14
@@ -15,6 +16,7 @@ LL |         Some(!)
    |
    = note: see issue #118155 <https://github.com/rust-lang/rust/issues/118155> for more information
    = help: add `#![feature(never_patterns)]` 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: a guard on a never pattern will never be run
   --> $DIR/ICE-119271-never-arm-attr-in-guard.rs:7:13
diff --git a/tests/ui/rfcs/rfc-0000-never_patterns/bindings.rs b/tests/ui/rfcs/rfc-0000-never_patterns/bindings.rs
new file mode 100644
index 00000000000..f2e238ecb13
--- /dev/null
+++ b/tests/ui/rfcs/rfc-0000-never_patterns/bindings.rs
@@ -0,0 +1,46 @@
+#![feature(never_patterns)]
+#![allow(incomplete_features)]
+
+enum Void {}
+
+fn main() {
+    let x: Result<bool, &(u32, u32, Void)> = Ok(false);
+
+    match x {
+        Ok(_x) | Err(&!) => {}
+    }
+    let (Ok(_x) | Err(&!)) = x;
+
+    match x {
+        Ok(_) => {}
+        Err(&(_a, _b, !)),
+        //~^ ERROR: never patterns cannot contain variable bindings
+        //~| ERROR: never patterns cannot contain variable bindings
+    }
+    match x {
+        Ok(_ok) | Err(&(_a, _b, !)) => {}
+        //~^ ERROR: never patterns cannot contain variable bindings
+        //~| ERROR: never patterns cannot contain variable bindings
+    }
+}
+
+fn void(void: Void) {
+    let (_a | !) = void;
+    let (! | _a) = void;
+    let ((_a, _) | (_a, _ | !)) = (true, void);
+    let (_a | (! | !,)) = (void,);
+    let ((_a,) | (!,)) = (void,);
+
+    let (_a, (! | !)) = (true, void);
+    //~^ ERROR: never patterns cannot contain variable bindings
+    let (_a, (_b | !)) = (true, void);
+
+    let _a @ ! = void;
+    //~^ ERROR: never patterns cannot contain variable bindings
+    let _a @ (_b | !) = void;
+    let (_a @ (), !) = ((), void);
+    //~^ ERROR: never patterns cannot contain variable bindings
+    let (_a |
+            (_b @ (_, !))) = (true, void);
+    //~^ ERROR: never patterns cannot contain variable bindings
+}
diff --git a/tests/ui/rfcs/rfc-0000-never_patterns/bindings.stderr b/tests/ui/rfcs/rfc-0000-never_patterns/bindings.stderr
new file mode 100644
index 00000000000..b69ba80af88
--- /dev/null
+++ b/tests/ui/rfcs/rfc-0000-never_patterns/bindings.stderr
@@ -0,0 +1,50 @@
+error: never patterns cannot contain variable bindings
+  --> $DIR/bindings.rs:16:15
+   |
+LL |         Err(&(_a, _b, !)),
+   |               ^^ help: use a wildcard `_` instead
+
+error: never patterns cannot contain variable bindings
+  --> $DIR/bindings.rs:16:19
+   |
+LL |         Err(&(_a, _b, !)),
+   |                   ^^ help: use a wildcard `_` instead
+
+error: never patterns cannot contain variable bindings
+  --> $DIR/bindings.rs:21:25
+   |
+LL |         Ok(_ok) | Err(&(_a, _b, !)) => {}
+   |                         ^^ help: use a wildcard `_` instead
+
+error: never patterns cannot contain variable bindings
+  --> $DIR/bindings.rs:21:29
+   |
+LL |         Ok(_ok) | Err(&(_a, _b, !)) => {}
+   |                             ^^ help: use a wildcard `_` instead
+
+error: never patterns cannot contain variable bindings
+  --> $DIR/bindings.rs:34:10
+   |
+LL |     let (_a, (! | !)) = (true, void);
+   |          ^^ help: use a wildcard `_` instead
+
+error: never patterns cannot contain variable bindings
+  --> $DIR/bindings.rs:38:9
+   |
+LL |     let _a @ ! = void;
+   |         ^^ help: use a wildcard `_` instead
+
+error: never patterns cannot contain variable bindings
+  --> $DIR/bindings.rs:41:10
+   |
+LL |     let (_a @ (), !) = ((), void);
+   |          ^^ help: use a wildcard `_` instead
+
+error: never patterns cannot contain variable bindings
+  --> $DIR/bindings.rs:44:14
+   |
+LL |             (_b @ (_, !))) = (true, void);
+   |              ^^ help: use a wildcard `_` instead
+
+error: aborting due to 8 previous errors
+
diff --git a/tests/ui/rfcs/rfc-0000-never_patterns/parse.rs b/tests/ui/rfcs/rfc-0000-never_patterns/parse.rs
index f254b9c201c..566bb071646 100644
--- a/tests/ui/rfcs/rfc-0000-never_patterns/parse.rs
+++ b/tests/ui/rfcs/rfc-0000-never_patterns/parse.rs
@@ -71,6 +71,7 @@ fn parse(x: Void) {
 
     let ! = x;
     let y @ ! = x;
+    //~^ ERROR: never patterns cannot contain variable bindings
 }
 
 fn foo(!: Void) {}
diff --git a/tests/ui/rfcs/rfc-0000-never_patterns/parse.stderr b/tests/ui/rfcs/rfc-0000-never_patterns/parse.stderr
index e81a13a3967..17d1b7e0d43 100644
--- a/tests/ui/rfcs/rfc-0000-never_patterns/parse.stderr
+++ b/tests/ui/rfcs/rfc-0000-never_patterns/parse.stderr
@@ -22,6 +22,12 @@ error: top-level or-patterns are not allowed in `let` bindings
 LL |     let Ok(_) | Err(!) = &res; // Disallowed; see #82048.
    |         ^^^^^^^^^^^^^^ help: wrap the pattern in parentheses: `(Ok(_) | Err(!))`
 
+error: never patterns cannot contain variable bindings
+  --> $DIR/parse.rs:73:9
+   |
+LL |     let y @ ! = x;
+   |         ^ help: use a wildcard `_` instead
+
 error: a guard on a never pattern will never be run
   --> $DIR/parse.rs:31:20
    |
@@ -40,5 +46,5 @@ error: a guard on a never pattern will never be run
 LL |         never!() if true,
    |                     ^^^^ help: remove this guard
 
-error: aborting due to 7 previous errors
+error: aborting due to 8 previous errors
 
diff --git a/tests/ui/rfcs/rfc-1445-restrict-constants-in-patterns/feature-gate.no_gate.stderr b/tests/ui/rfcs/rfc-1445-restrict-constants-in-patterns/feature-gate.no_gate.stderr
index bd294047919..f047afa985d 100644
--- a/tests/ui/rfcs/rfc-1445-restrict-constants-in-patterns/feature-gate.no_gate.stderr
+++ b/tests/ui/rfcs/rfc-1445-restrict-constants-in-patterns/feature-gate.no_gate.stderr
@@ -6,6 +6,7 @@ LL | impl std::marker::StructuralPartialEq for Foo { }
    |
    = note: see issue #31434 <https://github.com/rust-lang/rust/issues/31434> for more information
    = help: add `#![feature(structural_match)]` 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]: use of unstable library feature 'structural_match'
   --> $DIR/feature-gate.rs:31:6
@@ -15,6 +16,7 @@ LL | impl std::marker::StructuralEq for Foo { }
    |
    = note: see issue #31434 <https://github.com/rust-lang/rust/issues/31434> for more information
    = help: add `#![feature(structural_match)]` 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 2 previous errors
 
diff --git a/tests/ui/rfcs/rfc-2294-if-let-guard/feature-gate.stderr b/tests/ui/rfcs/rfc-2294-if-let-guard/feature-gate.stderr
index 62534b555b2..2341dbbbdbd 100644
--- a/tests/ui/rfcs/rfc-2294-if-let-guard/feature-gate.stderr
+++ b/tests/ui/rfcs/rfc-2294-if-let-guard/feature-gate.stderr
@@ -154,6 +154,7 @@ LL |         () if let 0 = 1 => {}
    |
    = note: see issue #51114 <https://github.com/rust-lang/rust/issues/51114> for more information
    = help: add `#![feature(if_let_guard)]` 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: you can write `if matches!(<expr>, <pattern>)` instead of `if let <pattern> = <expr>`
 
 error[E0658]: `if let` guards are experimental
@@ -164,6 +165,7 @@ LL |         () if true && let 0 = 1 => {}
    |
    = note: see issue #51114 <https://github.com/rust-lang/rust/issues/51114> for more information
    = help: add `#![feature(if_let_guard)]` 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: you can write `if matches!(<expr>, <pattern>)` instead of `if let <pattern> = <expr>`
 
 error[E0658]: `if let` guards are experimental
@@ -174,6 +176,7 @@ LL |         () if let 0 = 1 && true => {}
    |
    = note: see issue #51114 <https://github.com/rust-lang/rust/issues/51114> for more information
    = help: add `#![feature(if_let_guard)]` 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: you can write `if matches!(<expr>, <pattern>)` instead of `if let <pattern> = <expr>`
 
 error[E0658]: `if let` guards are experimental
@@ -184,6 +187,7 @@ LL |         () if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 =
    |
    = note: see issue #51114 <https://github.com/rust-lang/rust/issues/51114> for more information
    = help: add `#![feature(if_let_guard)]` 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: you can write `if matches!(<expr>, <pattern>)` instead of `if let <pattern> = <expr>`
 
 error[E0658]: `if let` guards are experimental
@@ -194,6 +198,7 @@ LL |         () if let Range { start: _, end: _ } = (true..true) && false => {}
    |
    = note: see issue #51114 <https://github.com/rust-lang/rust/issues/51114> for more information
    = help: add `#![feature(if_let_guard)]` 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: you can write `if matches!(<expr>, <pattern>)` instead of `if let <pattern> = <expr>`
 
 error[E0658]: `if let` guards are experimental
@@ -204,6 +209,7 @@ LL |         () if let 0 = 1 => {}
    |
    = note: see issue #51114 <https://github.com/rust-lang/rust/issues/51114> for more information
    = help: add `#![feature(if_let_guard)]` 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: you can write `if matches!(<expr>, <pattern>)` instead of `if let <pattern> = <expr>`
 
 error[E0658]: `let` expressions in this position are unstable
@@ -214,6 +220,7 @@ LL |         () if true && let 0 = 1 => {}
    |
    = note: see issue #53667 <https://github.com/rust-lang/rust/issues/53667> for more information
    = help: add `#![feature(let_chains)]` 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]: `let` expressions in this position are unstable
   --> $DIR/feature-gate.rs:20:15
@@ -223,6 +230,7 @@ LL |         () if let 0 = 1 && true => {}
    |
    = note: see issue #53667 <https://github.com/rust-lang/rust/issues/53667> for more information
    = help: add `#![feature(let_chains)]` 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]: `let` expressions in this position are unstable
   --> $DIR/feature-gate.rs:34:15
@@ -232,6 +240,7 @@ LL |         () if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 =
    |
    = note: see issue #53667 <https://github.com/rust-lang/rust/issues/53667> for more information
    = help: add `#![feature(let_chains)]` 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]: `let` expressions in this position are unstable
   --> $DIR/feature-gate.rs:34:28
@@ -241,6 +250,7 @@ LL |         () if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 =
    |
    = note: see issue #53667 <https://github.com/rust-lang/rust/issues/53667> for more information
    = help: add `#![feature(let_chains)]` 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]: `let` expressions in this position are unstable
   --> $DIR/feature-gate.rs:43:15
@@ -250,6 +260,7 @@ LL |         () if let Range { start: _, end: _ } = (true..true) && false => {}
    |
    = note: see issue #53667 <https://github.com/rust-lang/rust/issues/53667> for more information
    = help: add `#![feature(let_chains)]` 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 23 previous errors
 
diff --git a/tests/ui/rfcs/rfc-2396-target_feature-11/feature-gate-target_feature_11.stderr b/tests/ui/rfcs/rfc-2396-target_feature-11/feature-gate-target_feature_11.stderr
index 06c6c905338..4f1994d56fd 100644
--- a/tests/ui/rfcs/rfc-2396-target_feature-11/feature-gate-target_feature_11.stderr
+++ b/tests/ui/rfcs/rfc-2396-target_feature-11/feature-gate-target_feature_11.stderr
@@ -8,6 +8,7 @@ LL | fn foo() {}
    |
    = note: see issue #69098 <https://github.com/rust-lang/rust/issues/69098> for more information
    = help: add `#![feature(target_feature_11)]` 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 1 previous error
 
diff --git a/tests/ui/rfcs/rfc-2397-do-not-recommend/unstable-feature.stderr b/tests/ui/rfcs/rfc-2397-do-not-recommend/unstable-feature.stderr
index b2c1406d093..02bc51ccd3f 100644
--- a/tests/ui/rfcs/rfc-2397-do-not-recommend/unstable-feature.stderr
+++ b/tests/ui/rfcs/rfc-2397-do-not-recommend/unstable-feature.stderr
@@ -6,6 +6,7 @@ LL | #[do_not_recommend]
    |
    = note: see issue #51992 <https://github.com/rust-lang/rust/issues/51992> for more information
    = help: add `#![feature(do_not_recommend)]` 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 1 previous error
 
diff --git a/tests/ui/rfcs/rfc-2497-if-let-chains/feature-gate.stderr b/tests/ui/rfcs/rfc-2497-if-let-chains/feature-gate.stderr
index 6f74736755e..2b1a49be3da 100644
--- a/tests/ui/rfcs/rfc-2497-if-let-chains/feature-gate.stderr
+++ b/tests/ui/rfcs/rfc-2497-if-let-chains/feature-gate.stderr
@@ -37,6 +37,7 @@ LL |     if true && let 0 = 1 {}
    |
    = note: see issue #53667 <https://github.com/rust-lang/rust/issues/53667> for more information
    = help: add `#![feature(let_chains)]` 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]: `let` expressions in this position are unstable
   --> $DIR/feature-gate.rs:17:8
@@ -46,6 +47,7 @@ LL |     if let 0 = 1 && true {}
    |
    = note: see issue #53667 <https://github.com/rust-lang/rust/issues/53667> for more information
    = help: add `#![feature(let_chains)]` 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]: `let` expressions in this position are unstable
   --> $DIR/feature-gate.rs:20:8
@@ -55,6 +57,7 @@ LL |     if let Range { start: _, end: _ } = (true..true) && false {}
    |
    = note: see issue #53667 <https://github.com/rust-lang/rust/issues/53667> for more information
    = help: add `#![feature(let_chains)]` 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]: `let` expressions in this position are unstable
   --> $DIR/feature-gate.rs:23:8
@@ -64,6 +67,7 @@ LL |     if let 1 = 1 && let true = { true } && false {
    |
    = note: see issue #53667 <https://github.com/rust-lang/rust/issues/53667> for more information
    = help: add `#![feature(let_chains)]` 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]: `let` expressions in this position are unstable
   --> $DIR/feature-gate.rs:23:21
@@ -73,6 +77,7 @@ LL |     if let 1 = 1 && let true = { true } && false {
    |
    = note: see issue #53667 <https://github.com/rust-lang/rust/issues/53667> for more information
    = help: add `#![feature(let_chains)]` 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]: `let` expressions in this position are unstable
   --> $DIR/feature-gate.rs:32:19
@@ -82,6 +87,7 @@ LL |     while true && let 0 = 1 {}
    |
    = note: see issue #53667 <https://github.com/rust-lang/rust/issues/53667> for more information
    = help: add `#![feature(let_chains)]` 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]: `let` expressions in this position are unstable
   --> $DIR/feature-gate.rs:35:11
@@ -91,6 +97,7 @@ LL |     while let 0 = 1 && true {}
    |
    = note: see issue #53667 <https://github.com/rust-lang/rust/issues/53667> for more information
    = help: add `#![feature(let_chains)]` 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]: `let` expressions in this position are unstable
   --> $DIR/feature-gate.rs:38:11
@@ -100,6 +107,7 @@ LL |     while let Range { start: _, end: _ } = (true..true) && false {}
    |
    = note: see issue #53667 <https://github.com/rust-lang/rust/issues/53667> for more information
    = help: add `#![feature(let_chains)]` 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 11 previous errors
 
diff --git a/tests/ui/rfcs/rfc-2497-if-let-chains/issue-93150.stderr b/tests/ui/rfcs/rfc-2497-if-let-chains/issue-93150.stderr
index b25f299a219..637ae4915ed 100644
--- a/tests/ui/rfcs/rfc-2497-if-let-chains/issue-93150.stderr
+++ b/tests/ui/rfcs/rfc-2497-if-let-chains/issue-93150.stderr
@@ -6,6 +6,7 @@ LL |         _ if let true = true && true => {}
    |
    = note: see issue #51114 <https://github.com/rust-lang/rust/issues/51114> for more information
    = help: add `#![feature(if_let_guard)]` 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: you can write `if matches!(<expr>, <pattern>)` instead of `if let <pattern> = <expr>`
 
 error[E0658]: `let` expressions in this position are unstable
@@ -16,6 +17,7 @@ LL |         _ if let true = true && true => {}
    |
    = note: see issue #53667 <https://github.com/rust-lang/rust/issues/53667> for more information
    = help: add `#![feature(let_chains)]` 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 2 previous errors
 
diff --git a/tests/ui/rfcs/rfc-2528-type-changing-struct-update/feature-gate.stderr b/tests/ui/rfcs/rfc-2528-type-changing-struct-update/feature-gate.stderr
index 48e46d3d1d1..b67327f3af7 100644
--- a/tests/ui/rfcs/rfc-2528-type-changing-struct-update/feature-gate.stderr
+++ b/tests/ui/rfcs/rfc-2528-type-changing-struct-update/feature-gate.stderr
@@ -6,6 +6,7 @@ LL |         ..m1
    |
    = note: see issue #86555 <https://github.com/rust-lang/rust/issues/86555> for more information
    = help: add `#![feature(type_changing_struct_update)]` 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[E0308]: mismatched types
   --> $DIR/feature-gate.rs:22:11
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage-0.qualified.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage-0.qualified.stderr
new file mode 100644
index 00000000000..62c8a442ab9
--- /dev/null
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage-0.qualified.stderr
@@ -0,0 +1,14 @@
+error[E0277]: the trait bound `T: Trait` is not satisfied
+  --> $DIR/assoc-type-const-bound-usage-0.rs:21:6
+   |
+LL |     <T as /* FIXME: ~const */ Trait>::Assoc::func()
+   |      ^ the trait `Trait` is not implemented for `T`
+   |
+help: consider further restricting this bound
+   |
+LL | const fn qualified<T: ~const Trait + Trait>() -> i32 {
+   |                                    +++++++
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage-0.rs b/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage-0.rs
new file mode 100644
index 00000000000..d8573d3af01
--- /dev/null
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage-0.rs
@@ -0,0 +1,24 @@
+// FIXME(effects): Collapse the revisions into one once we support `<Ty as ~const Trait>::Proj`.
+// revisions: unqualified qualified
+//[unqualified] check-pass
+//[qualified] known-bug: unknown
+
+#![feature(const_trait_impl, effects)]
+
+#[const_trait]
+trait Trait {
+    type Assoc: ~const Trait;
+    fn func() -> i32;
+}
+
+#[cfg(unqualified)]
+const fn unqualified<T: ~const Trait>() -> i32 {
+    T::Assoc::func()
+}
+
+#[cfg(qualified)]
+const fn qualified<T: ~const Trait>() -> i32 {
+    <T as /* FIXME: ~const */ Trait>::Assoc::func()
+}
+
+fn main() {}
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage-1.qualified.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage-1.qualified.stderr
new file mode 100644
index 00000000000..10e467da952
--- /dev/null
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage-1.qualified.stderr
@@ -0,0 +1,14 @@
+error[E0277]: the trait bound `T: Trait` is not satisfied
+  --> $DIR/assoc-type-const-bound-usage-1.rs:23:43
+   |
+LL | fn qualified<T: const Trait>() -> Type<{ <T as /* FIXME: const */ Trait>::Assoc::func() }> {
+   |                                           ^ the trait `Trait` is not implemented for `T`
+   |
+help: consider further restricting this bound
+   |
+LL | fn qualified<T: const Trait + Trait>() -> Type<{ <T as /* FIXME: const */ Trait>::Assoc::func() }> {
+   |                             +++++++
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage-1.rs b/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage-1.rs
new file mode 100644
index 00000000000..2190fa337b4
--- /dev/null
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage-1.rs
@@ -0,0 +1,27 @@
+// FIXME(effects): Collapse the revisions into one once we support `<Ty as const Trait>::Proj`.
+// revisions: unqualified qualified
+//[unqualified] check-pass
+//[qualified] known-bug: unknown
+
+#![feature(const_trait_impl, effects, generic_const_exprs)]
+#![allow(incomplete_features)]
+
+#[const_trait]
+trait Trait {
+    type Assoc: ~const Trait;
+    fn func() -> i32;
+}
+
+struct Type<const N: i32>;
+
+#[cfg(unqualified)]
+fn unqualified<T: const Trait>() -> Type<{ T::Assoc::func() }> {
+    Type
+}
+
+#[cfg(qualified)]
+fn qualified<T: const Trait>() -> Type<{ <T as /* FIXME: const */ Trait>::Assoc::func() }> {
+    Type
+}
+
+fn main() {}
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage.rs b/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage.rs
deleted file mode 100644
index 16b717bc181..00000000000
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage.rs
+++ /dev/null
@@ -1,15 +0,0 @@
-// known-bug: #110395
-// FIXME check-pass
-#![feature(const_trait_impl, effects)]
-
-#[const_trait]
-trait Foo {
-    type Assoc: ~const Foo;
-    fn foo() {}
-}
-
-const fn foo<T: ~const Foo>() {
-    <T as /* FIXME: ~const */ Foo>::Assoc::foo();
-}
-
-fn main() {}
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage.stderr
deleted file mode 100644
index 268e337ee93..00000000000
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type-const-bound-usage.stderr
+++ /dev/null
@@ -1,22 +0,0 @@
-error: `~const` is not allowed here
-  --> $DIR/assoc-type-const-bound-usage.rs:7:17
-   |
-LL |     type Assoc: ~const Foo;
-   |                 ^^^^^^
-   |
-   = note: this item cannot have `~const` trait bounds
-
-error[E0277]: the trait bound `T: Foo` is not satisfied
-  --> $DIR/assoc-type-const-bound-usage.rs:12:6
-   |
-LL |     <T as /* FIXME: ~const */ Foo>::Assoc::foo();
-   |      ^ the trait `Foo` is not implemented for `T`
-   |
-help: consider further restricting this bound
-   |
-LL | const fn foo<T: ~const Foo + Foo>() {
-   |                            +++++
-
-error: aborting due to 2 previous errors
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type.rs b/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type.rs
index 96790a87311..886fa6577d7 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type.rs
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type.rs
@@ -1,29 +1,43 @@
-// known-bug: #110395
+// FIXME(effects): Replace `Add` with `std::ops::Add` once the latter a `#[const_trait]` again.
+#![feature(const_trait_impl, effects)]
 
-#![feature(const_trait_impl)]
+#[const_trait]
+trait Add<Rhs = Self> {
+    type Output;
+
+    fn add(self, other: Rhs) -> Self::Output;
+}
+
+impl const Add for i32 {
+    type Output = Self;
+
+    fn add(self, other: Self) -> Self::Output {
+        self + other
+    }
+}
 
 struct NonConstAdd(i32);
 
-impl std::ops::Add for NonConstAdd {
+impl Add for NonConstAdd {
     type Output = Self;
 
     fn add(self, rhs: Self) -> Self {
-        NonConstAdd(self.0 + rhs.0)
+        NonConstAdd(self.0.add(rhs.0))
     }
 }
 
 #[const_trait]
 trait Foo {
-    type Bar: ~const std::ops::Add;
+    type Bar: ~const Add;
 }
 
 impl const Foo for NonConstAdd {
-    type Bar = NonConstAdd;
+    type Bar = NonConstAdd; //~ ERROR the trait bound `NonConstAdd: ~const Add` is not satisfied
 }
 
 #[const_trait]
 trait Baz {
-    type Qux: std::ops::Add;
+    type Qux: Add;
 }
 
 impl const Baz for NonConstAdd {
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type.stderr
index 58ad1849d4f..a9cae2a70be 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type.stderr
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/assoc-type.stderr
@@ -1,16 +1,16 @@
-error: `~const` is not allowed here
-  --> $DIR/assoc-type.rs:17:15
+error[E0277]: the trait bound `NonConstAdd: ~const Add` is not satisfied
+  --> $DIR/assoc-type.rs:35:16
    |
-LL |     type Bar: ~const std::ops::Add;
-   |               ^^^^^^
+LL |     type Bar = NonConstAdd;
+   |                ^^^^^^^^^^^ the trait `~const Add` is not implemented for `NonConstAdd`
    |
-   = note: this item cannot have `~const` trait bounds
-
-error: `~const` can only be applied to `#[const_trait]` traits
-  --> $DIR/assoc-type.rs:17:22
+   = help: the trait `Add` is implemented for `NonConstAdd`
+note: required by a bound in `Foo::Bar`
+  --> $DIR/assoc-type.rs:31:15
    |
-LL |     type Bar: ~const std::ops::Add;
-   |                      ^^^^^^^^^^^^^
+LL |     type Bar: ~const Add;
+   |               ^^^^^^^^^^ required by this bound in `Foo::Bar`
 
-error: aborting due to 2 previous errors
+error: aborting due to 1 previous error
 
+For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/const_derives/derive-const-gate.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/const_derives/derive-const-gate.stderr
index 2dd96f548fe..9ec2ac93381 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/const_derives/derive-const-gate.stderr
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/const_derives/derive-const-gate.stderr
@@ -5,6 +5,7 @@ LL | #[derive_const(Default)]
    |   ^^^^^^^^^^^^
    |
    = help: add `#![feature(derive_const)]` 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 1 previous error
 
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/effects/ice-112822-expected-type-for-param.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/effects/ice-112822-expected-type-for-param.stderr
index 7e268f50dca..0f6240cc03b 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/effects/ice-112822-expected-type-for-param.stderr
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/effects/ice-112822-expected-type-for-param.stderr
@@ -6,6 +6,7 @@ LL |     const move || {
    |
    = note: see issue #106003 <https://github.com/rust-lang/rust/issues/106003> for more information
    = help: add `#![feature(const_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: `~const` can only be applied to `#[const_trait]` traits
   --> $DIR/ice-112822-expected-type-for-param.rs:3:32
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/feature-gate.stock.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/feature-gate.stock.stderr
index c9826aeb166..78157d57056 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/feature-gate.stock.stderr
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/feature-gate.stock.stderr
@@ -6,6 +6,7 @@ LL | impl const T for S {}
    |
    = 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/feature-gate.rs:13:15
@@ -15,6 +16,7 @@ LL | const fn f<A: ~const T>() {}
    |
    = 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/feature-gate.rs:14:9
@@ -24,6 +26,7 @@ LL | fn g<A: const T>() {}
    |
    = 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/feature-gate.rs:18:17
@@ -33,6 +36,7 @@ LL | discard! { impl ~const T }
    |
    = 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/feature-gate.rs:19:17
@@ -42,6 +46,7 @@ LL | discard! { impl const T }
    |
    = 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` is a temporary placeholder for marking a trait that is suitable for `const` `impls` and all default bodies as `const`, which may be removed or renamed in the future.
   --> $DIR/feature-gate.rs:8:1
@@ -51,6 +56,7 @@ LL | #[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 6 previous errors
 
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/gate.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/gate.stderr
index 11cc2cd569a..19fd54ff369 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/gate.stderr
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/gate.stderr
@@ -6,6 +6,7 @@ LL |     (const || {})();
    |
    = note: see issue #106003 <https://github.com/rust-lang/rust/issues/106003> for more information
    = help: add `#![feature(const_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[E0658]: const closures are experimental
   --> $DIR/gate.rs:12:5
@@ -15,6 +16,7 @@ LL | e!((const || {}));
    |
    = note: see issue #106003 <https://github.com/rust-lang/rust/issues/106003> for more information
    = help: add `#![feature(const_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: aborting due to 2 previous errors
 
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/hir-const-check.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/hir-const-check.stderr
index 90f30ea635f..5b14ef46d25 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/hir-const-check.stderr
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/hir-const-check.stderr
@@ -6,6 +6,7 @@ LL |         Some(())?;
    |
    = note: see issue #74935 <https://github.com/rust-lang/rust/issues/74935> for more information
    = help: add `#![feature(const_try)]` 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 1 previous error
 
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 254d31930b3..fd9184b9dff 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
@@ -24,6 +24,7 @@ LL | demo! { dyn const }
    |
    = 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
 
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/tilde-const-invalid-places.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/tilde-const-invalid-places.stderr
index a54ba7a94b4..d57f5702a63 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/tilde-const-invalid-places.stderr
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/tilde-const-invalid-places.stderr
@@ -72,7 +72,11 @@ error: `~const` is not allowed here
 LL |     type Type<T: ~const Trait>: ~const Trait;
    |                  ^^^^^^
    |
-   = note: this item cannot have `~const` trait bounds
+note: associated types in non-`#[const_trait]` traits cannot have `~const` trait bounds
+  --> $DIR/tilde-const-invalid-places.rs:25:5
+   |
+LL |     type Type<T: ~const Trait>: ~const Trait;
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: `~const` is not allowed here
   --> $DIR/tilde-const-invalid-places.rs:25:33
@@ -80,7 +84,11 @@ error: `~const` is not allowed here
 LL |     type Type<T: ~const Trait>: ~const Trait;
    |                                 ^^^^^^
    |
-   = note: this item cannot have `~const` trait bounds
+note: associated types in non-`#[const_trait]` traits cannot have `~const` trait bounds
+  --> $DIR/tilde-const-invalid-places.rs:25:5
+   |
+LL |     type Type<T: ~const Trait>: ~const Trait;
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: `~const` is not allowed here
   --> $DIR/tilde-const-invalid-places.rs:28:30
@@ -108,7 +116,11 @@ error: `~const` is not allowed here
 LL |     type Type<T: ~const Trait> = ();
    |                  ^^^^^^
    |
-   = note: this item cannot have `~const` trait bounds
+note: associated types in non-const impls cannot have `~const` trait bounds
+  --> $DIR/tilde-const-invalid-places.rs:34:5
+   |
+LL |     type Type<T: ~const Trait> = ();
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: `~const` is not allowed here
   --> $DIR/tilde-const-invalid-places.rs:36:30
@@ -136,7 +148,11 @@ error: `~const` is not allowed here
 LL |     type Type<T: ~const Trait> = ();
    |                  ^^^^^^
    |
-   = note: this item cannot have `~const` trait bounds
+note: inherent associated types cannot have `~const` trait bounds
+  --> $DIR/tilde-const-invalid-places.rs:44:5
+   |
+LL |     type Type<T: ~const Trait> = ();
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: `~const` is not allowed here
   --> $DIR/tilde-const-invalid-places.rs:46:30
@@ -214,6 +230,7 @@ LL | const CONSTANT<T: ~const Trait>: () = ();
    |
    = note: see issue #113521 <https://github.com/rust-lang/rust/issues/113521> for more information
    = help: add `#![feature(generic_const_items)]` 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]: generic const items are experimental
   --> $DIR/tilde-const-invalid-places.rs:29:19
@@ -223,6 +240,7 @@ LL |     const CONSTANT<T: ~const Trait>: ();
    |
    = note: see issue #113521 <https://github.com/rust-lang/rust/issues/113521> for more information
    = help: add `#![feature(generic_const_items)]` 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]: generic const items are experimental
   --> $DIR/tilde-const-invalid-places.rs:37:19
@@ -232,6 +250,7 @@ LL |     const CONSTANT<T: ~const Trait>: () = ();
    |
    = note: see issue #113521 <https://github.com/rust-lang/rust/issues/113521> for more information
    = help: add `#![feature(generic_const_items)]` 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]: generic const items are experimental
   --> $DIR/tilde-const-invalid-places.rs:47:19
@@ -241,6 +260,7 @@ LL |     const CONSTANT<T: ~const Trait>: () = ();
    |
    = note: see issue #113521 <https://github.com/rust-lang/rust/issues/113521> for more information
    = help: add `#![feature(generic_const_items)]` 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]: inherent associated types are unstable
   --> $DIR/tilde-const-invalid-places.rs:44:5
@@ -250,6 +270,7 @@ LL |     type Type<T: ~const Trait> = ();
    |
    = note: see issue #8995 <https://github.com/rust-lang/rust/issues/8995> for more information
    = help: add `#![feature(inherent_associated_types)]` 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[E0392]: parameter `T` is never used
   --> $DIR/tilde-const-invalid-places.rs:11:19
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/tilde-const-trait-assoc-tys.rs b/tests/ui/rfcs/rfc-2632-const-trait-impl/tilde-const-trait-assoc-tys.rs
new file mode 100644
index 00000000000..4c383fe1506
--- /dev/null
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/tilde-const-trait-assoc-tys.rs
@@ -0,0 +1,18 @@
+// check-pass
+#![feature(const_trait_impl, effects)]
+
+#[const_trait]
+trait Trait {
+    // FIXME(effects): `~const` bounds in trait associated types (excluding associated type bounds)
+    // don't look super useful. Should we forbid them again?
+    type Assoc<T: ~const Bound>;
+}
+
+impl const Trait for () {
+    type Assoc<T: ~const Bound> = T;
+}
+
+#[const_trait]
+trait Bound {}
+
+fn main() {}
diff --git a/tests/ui/rustdoc/feature-gate-doc_primitive.stderr b/tests/ui/rustdoc/feature-gate-doc_primitive.stderr
index 0f5665f1fb9..e74b1322b25 100644
--- a/tests/ui/rustdoc/feature-gate-doc_primitive.stderr
+++ b/tests/ui/rustdoc/feature-gate-doc_primitive.stderr
@@ -5,6 +5,7 @@ LL | #[rustc_doc_primitive = "usize"]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(rustc_attrs)]` 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 1 previous error
 
diff --git a/tests/ui/self/arbitrary-self-from-method-substs.default.stderr b/tests/ui/self/arbitrary-self-from-method-substs.default.stderr
index a415aa3d7b4..4cc69666b88 100644
--- a/tests/ui/self/arbitrary-self-from-method-substs.default.stderr
+++ b/tests/ui/self/arbitrary-self-from-method-substs.default.stderr
@@ -6,6 +6,7 @@ LL |     fn get<R: Deref<Target = Self>>(self: R) -> u32 {
    |
    = note: see issue #44874 <https://github.com/rust-lang/rust/issues/44874> for more information
    = help: add `#![feature(arbitrary_self_types)]` 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: consider changing to `self`, `&self`, `&mut self`, `self: Box<Self>`, `self: Rc<Self>`, `self: Arc<Self>`, or `self: Pin<P>` (where P is one of the previous types except `Self`)
 
 error: aborting due to 1 previous error
diff --git a/tests/ui/span/gated-features-attr-spans.stderr b/tests/ui/span/gated-features-attr-spans.stderr
index 5376d7799aa..f05c71774bd 100644
--- a/tests/ui/span/gated-features-attr-spans.stderr
+++ b/tests/ui/span/gated-features-attr-spans.stderr
@@ -6,6 +6,7 @@ LL | #[repr(simd)]
    |
    = note: see issue #27731 <https://github.com/rust-lang/rust/issues/27731> for more information
    = help: add `#![feature(repr_simd)]` 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 1 previous error
 
diff --git a/tests/ui/specialization/allow_internal_unstable.rs b/tests/ui/specialization/allow_internal_unstable.rs
new file mode 100644
index 00000000000..317782b7b72
--- /dev/null
+++ b/tests/ui/specialization/allow_internal_unstable.rs
@@ -0,0 +1,18 @@
+// check-pass
+// test for #119950
+// compile-flags: --crate-type lib
+
+#![allow(internal_features)]
+#![feature(allow_internal_unstable)]
+
+#[allow_internal_unstable(min_specialization)]
+macro_rules! test {
+    () => {
+        struct T<U>(U);
+        trait Tr {}
+        impl<U> Tr for T<U> {}
+        impl Tr for T<u8> {}
+    }
+}
+
+test! {}
diff --git a/tests/ui/specialization/defaultimpl/specialization-feature-gate-default.stderr b/tests/ui/specialization/defaultimpl/specialization-feature-gate-default.stderr
index 18edcad0a47..e28d9c9fa83 100644
--- a/tests/ui/specialization/defaultimpl/specialization-feature-gate-default.stderr
+++ b/tests/ui/specialization/defaultimpl/specialization-feature-gate-default.stderr
@@ -8,6 +8,7 @@ LL | | }
    |
    = note: see issue #31844 <https://github.com/rust-lang/rust/issues/31844> for more information
    = help: add `#![feature(specialization)]` 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 1 previous error
 
diff --git a/tests/ui/specialization/specialization-feature-gate-default.stderr b/tests/ui/specialization/specialization-feature-gate-default.stderr
index 35e5e3bc512..3e651b6ee4f 100644
--- a/tests/ui/specialization/specialization-feature-gate-default.stderr
+++ b/tests/ui/specialization/specialization-feature-gate-default.stderr
@@ -6,6 +6,7 @@ LL |     default fn foo(&self) {}
    |
    = note: see issue #31844 <https://github.com/rust-lang/rust/issues/31844> for more information
    = help: add `#![feature(specialization)]` 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 1 previous error
 
diff --git a/tests/ui/stability-attribute/accidental-stable-in-unstable.stderr b/tests/ui/stability-attribute/accidental-stable-in-unstable.stderr
index f85b3c6eb66..4abf8243d2f 100644
--- a/tests/ui/stability-attribute/accidental-stable-in-unstable.stderr
+++ b/tests/ui/stability-attribute/accidental-stable-in-unstable.stderr
@@ -5,6 +5,7 @@ LL | use core::unicode::UNICODE_VERSION;
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unicode_internals)]` 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 1 previous error
 
diff --git a/tests/ui/stability-attribute/allow-unstable-reexport.stderr b/tests/ui/stability-attribute/allow-unstable-reexport.stderr
index a11da9dc8a7..af75b6afb04 100644
--- a/tests/ui/stability-attribute/allow-unstable-reexport.stderr
+++ b/tests/ui/stability-attribute/allow-unstable-reexport.stderr
@@ -5,6 +5,7 @@ LL | pub use lint_stability::unstable as unstable2;
    |         ^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/allow-unstable-reexport.rs:28:5
@@ -13,6 +14,7 @@ LL |     unstable();
    |     ^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature': text
   --> $DIR/allow-unstable-reexport.rs:29:5
@@ -21,6 +23,7 @@ LL |     unstable_text();
    |     ^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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
 
diff --git a/tests/ui/stability-attribute/allowed-through-unstable.stderr b/tests/ui/stability-attribute/allowed-through-unstable.stderr
index f09289bfb89..5c8e6358b7c 100644
--- a/tests/ui/stability-attribute/allowed-through-unstable.stderr
+++ b/tests/ui/stability-attribute/allowed-through-unstable.stderr
@@ -6,6 +6,7 @@ LL | use allowed_through_unstable_core::unstable_module::NewStableTraitNotAllowe
    |
    = note: see issue #1 <https://github.com/rust-lang/rust/issues/1> for more information
    = help: add `#![feature(unstable_test_feature)]` 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 1 previous error
 
diff --git a/tests/ui/stability-attribute/default-body-stability-err.stderr b/tests/ui/stability-attribute/default-body-stability-err.stderr
index 12ec9ea3adb..9d8ad81f102 100644
--- a/tests/ui/stability-attribute/default-body-stability-err.stderr
+++ b/tests/ui/stability-attribute/default-body-stability-err.stderr
@@ -7,6 +7,7 @@ LL | impl JustTrait for Type {}
    = note: default implementation of `CONSTANT` is unstable
    = note: use of unstable library feature 'constant_default_body'
    = help: add `#![feature(constant_default_body)]` 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[E0046]: not all trait items implemented, missing: `fun`
   --> $DIR/default-body-stability-err.rs:10:1
@@ -17,6 +18,7 @@ LL | impl JustTrait for Type {}
    = note: default implementation of `fun` is unstable
    = note: use of unstable library feature 'fun_default_body'
    = help: add `#![feature(fun_default_body)]` 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[E0046]: not all trait items implemented, missing: `fun2`
   --> $DIR/default-body-stability-err.rs:10:1
@@ -27,6 +29,7 @@ LL | impl JustTrait for Type {}
    = note: default implementation of `fun2` is unstable
    = note: use of unstable library feature 'fun_default_body': reason
    = help: add `#![feature(fun_default_body)]` 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[E0046]: not all trait items implemented, missing: `eq`
   --> $DIR/default-body-stability-err.rs:15:1
@@ -42,6 +45,7 @@ LL | | }
    = note: default implementation of `eq` is unstable
    = note: use of unstable library feature 'eq_default_body'
    = help: add `#![feature(eq_default_body)]` 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 4 previous errors
 
diff --git a/tests/ui/stability-attribute/generics-default-stability-trait.stderr b/tests/ui/stability-attribute/generics-default-stability-trait.stderr
index 03e61b78e06..699e7c83c70 100644
--- a/tests/ui/stability-attribute/generics-default-stability-trait.stderr
+++ b/tests/ui/stability-attribute/generics-default-stability-trait.stderr
@@ -5,6 +5,7 @@ LL | impl Trait1<usize> for S {
    |             ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability-trait.rs:20:13
@@ -13,6 +14,7 @@ LL | impl Trait1<isize> for S {
    |             ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability-trait.rs:24:13
@@ -21,6 +23,7 @@ LL | impl Trait2<usize> for S {
    |             ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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
 
diff --git a/tests/ui/stability-attribute/generics-default-stability-where.stderr b/tests/ui/stability-attribute/generics-default-stability-where.stderr
index 16b560e8a4b..8e4089970f5 100644
--- a/tests/ui/stability-attribute/generics-default-stability-where.stderr
+++ b/tests/ui/stability-attribute/generics-default-stability-where.stderr
@@ -5,6 +5,7 @@ LL | impl<T> Trait3<usize> for T where T: Trait2<usize> {
    |                                             ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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[E0210]: type parameter `T` must be used as the type parameter for some local type (e.g., `MyStruct<T>`)
   --> $DIR/generics-default-stability-where.rs:7:6
diff --git a/tests/ui/stability-attribute/generics-default-stability.stderr b/tests/ui/stability-attribute/generics-default-stability.stderr
index e094a10c8e7..b1b91a850e9 100644
--- a/tests/ui/stability-attribute/generics-default-stability.stderr
+++ b/tests/ui/stability-attribute/generics-default-stability.stderr
@@ -223,6 +223,7 @@ LL |     let _: Struct1<isize> = Struct1 { field: 1 };
    |                    ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:27:20
@@ -231,6 +232,7 @@ LL |     let _: Struct1<usize> = STRUCT1;
    |                    ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:28:20
@@ -239,6 +241,7 @@ LL |     let _: Struct1<isize> = Struct1 { field: 0 };
    |                    ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:57:27
@@ -247,6 +250,7 @@ LL |     let _: Struct3<isize, usize> = STRUCT3;
    |                           ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:59:27
@@ -255,6 +259,7 @@ LL |     let _: Struct3<isize, isize> = Struct3 { field1: 0, field2: 0 };
    |                           ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:60:27
@@ -263,6 +268,7 @@ LL |     let _: Struct3<usize, usize> = Struct3 { field1: 0, field2: 0 };
    |                           ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:84:20
@@ -271,6 +277,7 @@ LL |     let _: Struct5<isize> = Struct5 { field: 1 };
    |                    ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:90:20
@@ -279,6 +286,7 @@ LL |     let _: Struct5<usize> = STRUCT5;
    |                    ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:92:20
@@ -287,6 +295,7 @@ LL |     let _: Struct5<isize> = Struct5 { field: 0 };
    |                    ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:100:19
@@ -295,6 +304,7 @@ LL |     let _: Alias1<isize> = Alias1::Some(1);
    |                   ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:104:19
@@ -303,6 +313,7 @@ LL |     let _: Alias1<usize> = ALIAS1;
    |                   ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:105:19
@@ -311,6 +322,7 @@ LL |     let _: Alias1<isize> = Alias1::Some(0);
    |                   ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:133:26
@@ -319,6 +331,7 @@ LL |     let _: Alias3<isize, usize> = ALIAS3;
    |                          ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:135:26
@@ -327,6 +340,7 @@ LL |     let _: Alias3<isize, isize> = Alias3::Ok(0);
    |                          ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:136:26
@@ -335,6 +349,7 @@ LL |     let _: Alias3<usize, usize> = Alias3::Ok(0);
    |                          ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:158:19
@@ -343,6 +358,7 @@ LL |     let _: Alias5<isize> = Alias5::Some(1);
    |                   ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:163:19
@@ -351,6 +367,7 @@ LL |     let _: Alias5<usize> = ALIAS5;
    |                   ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:165:19
@@ -359,6 +376,7 @@ LL |     let _: Alias5<isize> = Alias5::Some(0);
    |                   ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:172:18
@@ -367,6 +385,7 @@ LL |     let _: Enum1<isize> = Enum1::Some(1);
    |                  ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:176:18
@@ -375,6 +394,7 @@ LL |     let _: Enum1<usize> = ENUM1;
    |                  ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:177:18
@@ -383,6 +403,7 @@ LL |     let _: Enum1<isize> = Enum1::Some(0);
    |                  ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:205:25
@@ -391,6 +412,7 @@ LL |     let _: Enum3<isize, usize> = ENUM3;
    |                         ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:207:25
@@ -399,6 +421,7 @@ LL |     let _: Enum3<isize, isize> = Enum3::Ok(0);
    |                         ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:208:25
@@ -407,6 +430,7 @@ LL |     let _: Enum3<usize, usize> = Enum3::Ok(0);
    |                         ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:230:18
@@ -415,6 +439,7 @@ LL |     let _: Enum5<isize> = Enum5::Some(1);
    |                  ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:235:18
@@ -423,6 +448,7 @@ LL |     let _: Enum5<usize> = ENUM5;
    |                  ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'unstable_default'
   --> $DIR/generics-default-stability.rs:237:18
@@ -431,6 +457,7 @@ LL |     let _: Enum5<isize> = Enum5::Some(0);
    |                  ^^^^^
    |
    = help: add `#![feature(unstable_default)]` 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]: use of unstable library feature 'box_alloc_param'
   --> $DIR/generics-default-stability.rs:244:24
@@ -439,6 +466,7 @@ LL |     let _: Box1<isize, System> = Box1::new(1);
    |                        ^^^^^^
    |
    = help: add `#![feature(box_alloc_param)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 warning: use of deprecated field `unstable_generic_param::Struct4::field`: test
   --> $DIR/generics-default-stability.rs:71:39
diff --git a/tests/ui/stability-attribute/issue-28075.stderr b/tests/ui/stability-attribute/issue-28075.stderr
index e16eae88b01..282686d82bb 100644
--- a/tests/ui/stability-attribute/issue-28075.stderr
+++ b/tests/ui/stability-attribute/issue-28075.stderr
@@ -5,6 +5,7 @@ LL | use lint_stability::{unstable, deprecated};
    |                      ^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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 1 previous error
 
diff --git a/tests/ui/stability-attribute/issue-28388-3.stderr b/tests/ui/stability-attribute/issue-28388-3.stderr
index 0fb62ece313..56ca57591ce 100644
--- a/tests/ui/stability-attribute/issue-28388-3.stderr
+++ b/tests/ui/stability-attribute/issue-28388-3.stderr
@@ -5,6 +5,7 @@ LL | use lint_stability::UnstableEnum::{};
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(unstable_test_feature)]` 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 1 previous error
 
diff --git a/tests/ui/stability-attribute/stability-attribute-implies-no-feature.stderr b/tests/ui/stability-attribute/stability-attribute-implies-no-feature.stderr
index c2331f6766c..b35ee6c1291 100644
--- a/tests/ui/stability-attribute/stability-attribute-implies-no-feature.stderr
+++ b/tests/ui/stability-attribute/stability-attribute-implies-no-feature.stderr
@@ -6,6 +6,7 @@ LL | use stability_attribute_implies::{foo, foobar};
    |
    = note: see issue #1 <https://github.com/rust-lang/rust/issues/1> for more information
    = help: add `#![feature(foobar)]` 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]: use of unstable library feature 'foobar'
   --> $DIR/stability-attribute-implies-no-feature.rs:12:5
@@ -15,6 +16,7 @@ LL |     foobar();
    |
    = note: see issue #1 <https://github.com/rust-lang/rust/issues/1> for more information
    = help: add `#![feature(foobar)]` 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 2 previous errors
 
diff --git a/tests/ui/stability-attribute/stability-attribute-issue.stderr b/tests/ui/stability-attribute/stability-attribute-issue.stderr
index df4aec7e5c8..336e0f1718f 100644
--- a/tests/ui/stability-attribute/stability-attribute-issue.stderr
+++ b/tests/ui/stability-attribute/stability-attribute-issue.stderr
@@ -6,6 +6,7 @@ LL |     unstable();
    |
    = note: see issue #1 <https://github.com/rust-lang/rust/issues/1> for more information
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature': message
   --> $DIR/stability-attribute-issue.rs:10:5
@@ -15,6 +16,7 @@ LL |     unstable_msg();
    |
    = note: see issue #2 <https://github.com/rust-lang/rust/issues/2> for more information
    = help: add `#![feature(unstable_test_feature)]` 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 2 previous errors
 
diff --git a/tests/ui/stability-attribute/stable-in-unstable.stderr b/tests/ui/stability-attribute/stable-in-unstable.stderr
index b5e3e5f1202..eb73f047acd 100644
--- a/tests/ui/stability-attribute/stable-in-unstable.stderr
+++ b/tests/ui/stability-attribute/stable-in-unstable.stderr
@@ -6,6 +6,7 @@ LL |     use stable_in_unstable_core::new_unstable_module;
    |
    = note: see issue #1 <https://github.com/rust-lang/rust/issues/1> for more information
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/stable-in-unstable.rs:17:9
@@ -15,6 +16,7 @@ LL |     use stable_in_unstable_core::new_unstable_module::OldTrait;
    |
    = note: see issue #1 <https://github.com/rust-lang/rust/issues/1> for more information
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/stable-in-unstable.rs:29:9
@@ -24,6 +26,7 @@ LL |     use stable_in_unstable_core::new_unstable_module::OldTrait;
    |
    = note: see issue #1 <https://github.com/rust-lang/rust/issues/1> for more information
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/stable-in-unstable.rs:39:10
@@ -33,6 +36,7 @@ LL |     impl stable_in_unstable_core::new_unstable_module::OldTrait for LocalTy
    |
    = note: see issue #1 <https://github.com/rust-lang/rust/issues/1> for more information
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/stable-in-unstable.rs:49:56
@@ -42,6 +46,7 @@ LL |     use stable_in_unstable_core::new_unstable_module::{OldTrait};
    |
    = note: see issue #1 <https://github.com/rust-lang/rust/issues/1> for more information
    = help: add `#![feature(unstable_test_feature)]` 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]: use of unstable library feature 'unstable_test_feature'
   --> $DIR/stable-in-unstable.rs:53:9
@@ -51,6 +56,7 @@ LL |     use stable_in_unstable_core::new_unstable_module::*;
    |
    = note: see issue #1 <https://github.com/rust-lang/rust/issues/1> for more information
    = help: add `#![feature(unstable_test_feature)]` 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 6 previous errors
 
diff --git a/tests/ui/stability-attribute/suggest-vec-allocator-api.stderr b/tests/ui/stability-attribute/suggest-vec-allocator-api.stderr
index 41e5787b8c2..d7fcba4ced5 100644
--- a/tests/ui/stability-attribute/suggest-vec-allocator-api.stderr
+++ b/tests/ui/stability-attribute/suggest-vec-allocator-api.stderr
@@ -8,6 +8,7 @@ LL |     let _: Vec<u8, _> = vec![];
    |
    = note: see issue #32838 <https://github.com/rust-lang/rust/issues/32838> for more information
    = help: add `#![feature(allocator_api)]` 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]: use of unstable library feature 'allocator_api'
   --> $DIR/suggest-vec-allocator-api.rs:6:9
@@ -17,6 +18,7 @@ LL |         _> = vec![];
    |
    = note: see issue #32838 <https://github.com/rust-lang/rust/issues/32838> for more information
    = help: add `#![feature(allocator_api)]` 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: consider wrapping the inner types in tuple
    |
 LL ~     let _: Vec<(
@@ -32,6 +34,7 @@ LL |     let _boxed: Box<u32, _> = Box::new(10);
    |
    = note: see issue #32838 <https://github.com/rust-lang/rust/issues/32838> for more information
    = help: add `#![feature(allocator_api)]` 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]: use of unstable library feature 'allocator_api'
   --> $DIR/suggest-vec-allocator-api.rs:7:24
@@ -43,6 +46,7 @@ LL |     let _ = Vec::<u16, _>::new();
    |
    = note: see issue #32838 <https://github.com/rust-lang/rust/issues/32838> for more information
    = help: add `#![feature(allocator_api)]` 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 4 previous errors
 
diff --git a/tests/ui/stmt_expr_attrs_no_feature.stderr b/tests/ui/stmt_expr_attrs_no_feature.stderr
index dc06521fe72..c801268c652 100644
--- a/tests/ui/stmt_expr_attrs_no_feature.stderr
+++ b/tests/ui/stmt_expr_attrs_no_feature.stderr
@@ -6,6 +6,7 @@ LL |     #[rustfmt::skip]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
   --> $DIR/stmt_expr_attrs_no_feature.rs:95:18
@@ -15,6 +16,7 @@ LL |     fn y(a: [u8; #[rustc_dummy] 5]);
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
   --> $DIR/stmt_expr_attrs_no_feature.rs:102:19
@@ -24,6 +26,7 @@ LL |     const Y: u8 = #[rustc_dummy] 5;
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
   --> $DIR/stmt_expr_attrs_no_feature.rs:108:19
@@ -33,6 +36,7 @@ LL |     const Y: [u8; #[rustc_dummy] 5];
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
   --> $DIR/stmt_expr_attrs_no_feature.rs:114:18
@@ -42,6 +46,7 @@ LL |     field2: [u8; #[rustc_dummy] 5]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
   --> $DIR/stmt_expr_attrs_no_feature.rs:119:10
@@ -51,6 +56,7 @@ LL |     [u8; #[rustc_dummy] 5]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
   --> $DIR/stmt_expr_attrs_no_feature.rs:125:14
@@ -60,6 +66,7 @@ LL |         [u8; #[rustc_dummy] 5]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
   --> $DIR/stmt_expr_attrs_no_feature.rs:130:22
@@ -69,6 +76,7 @@ LL |         field2: [u8; #[rustc_dummy] 5]
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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]: attributes on expressions are experimental
   --> $DIR/stmt_expr_attrs_no_feature.rs:138:14
@@ -78,6 +86,7 @@ LL |         6 => #[rustc_dummy] (),
    |
    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
    = help: add `#![feature(stmt_expr_attributes)]` 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 9 previous errors
 
diff --git a/tests/ui/suggestions/fn-trait-notation.stderr b/tests/ui/suggestions/fn-trait-notation.stderr
index ed79b3d512c..b221af18bfc 100644
--- a/tests/ui/suggestions/fn-trait-notation.stderr
+++ b/tests/ui/suggestions/fn-trait-notation.stderr
@@ -6,6 +6,7 @@ LL |     F: Fn<i32, Output = i32>,
    |
    = 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[E0658]: the precise format of `Fn`-family traits' type parameters is subject to change
   --> $DIR/fn-trait-notation.rs:6:8
@@ -15,6 +16,7 @@ LL |     G: Fn<(i32, i32, ), Output = (i32, i32)>,
    |
    = 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[E0658]: the precise format of `Fn`-family traits' type parameters is subject to change
   --> $DIR/fn-trait-notation.rs:7:8
@@ -24,6 +26,7 @@ LL |     H: Fn<(i32,), Output = i32>,
    |
    = 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[E0059]: type parameter to bare `Fn` trait must be a tuple
   --> $DIR/fn-trait-notation.rs:4:8
diff --git a/tests/ui/suggestions/impl-trait-missing-lifetime-gated.stderr b/tests/ui/suggestions/impl-trait-missing-lifetime-gated.stderr
index fee4c7268fa..a7d636b63bd 100644
--- a/tests/ui/suggestions/impl-trait-missing-lifetime-gated.stderr
+++ b/tests/ui/suggestions/impl-trait-missing-lifetime-gated.stderr
@@ -131,6 +131,7 @@ LL |     fn f(_: impl Iterator<Item = &()>) {}
    |                                   ^ expected named lifetime parameter
    |
    = help: add `#![feature(anonymous_lifetime_in_impl_trait)]` 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: consider introducing a named lifetime parameter
    |
 LL |     fn f<'a>(_: impl Iterator<Item = &'a ()>) {}
@@ -143,6 +144,7 @@ LL |     fn g(mut x: impl Iterator<Item = &()>) -> Option<&()> { x.next() }
    |                                       ^ expected named lifetime parameter
    |
    = help: add `#![feature(anonymous_lifetime_in_impl_trait)]` 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: consider introducing a named lifetime parameter
    |
 LL |     fn g<'a>(mut x: impl Iterator<Item = &'a ()>) -> Option<&()> { x.next() }
@@ -155,6 +157,7 @@ LL |     fn f(_: impl Iterator<Item = &'_ ()>) {}
    |                                   ^^ expected named lifetime parameter
    |
    = help: add `#![feature(anonymous_lifetime_in_impl_trait)]` 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: consider introducing a named lifetime parameter
    |
 LL |     fn f<'a>(_: impl Iterator<Item = &'a ()>) {}
@@ -167,6 +170,7 @@ LL |     fn g(mut x: impl Iterator<Item = &'_ ()>) -> Option<&'_ ()> { x.next()
    |                                       ^^ expected named lifetime parameter
    |
    = help: add `#![feature(anonymous_lifetime_in_impl_trait)]` 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: consider introducing a named lifetime parameter
    |
 LL |     fn g<'a>(mut x: impl Iterator<Item = &'a ()>) -> Option<&'_ ()> { x.next() }
@@ -179,6 +183,7 @@ LL |     fn f(_: impl Foo) {}
    |                  ^^^ expected named lifetime parameter
    |
    = help: add `#![feature(anonymous_lifetime_in_impl_trait)]` 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: consider introducing a named lifetime parameter
    |
 LL |     fn f<'a>(_: impl Foo<'a>) {}
@@ -191,6 +196,7 @@ LL |     fn g(mut x: impl Foo) -> Option<&()> { x.next() }
    |                      ^^^ expected named lifetime parameter
    |
    = help: add `#![feature(anonymous_lifetime_in_impl_trait)]` 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: consider introducing a named lifetime parameter
    |
 LL |     fn g<'a>(mut x: impl Foo<'a>) -> Option<&()> { x.next() }
@@ -203,6 +209,7 @@ LL |     fn f(_: impl Foo<()>) {}
    |                      ^ expected named lifetime parameter
    |
    = help: add `#![feature(anonymous_lifetime_in_impl_trait)]` 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: consider introducing a named lifetime parameter
    |
 LL |     fn f<'a>(_: impl Foo<'a, ()>) {}
@@ -215,6 +222,7 @@ LL |     fn g(mut x: impl Foo<()>) -> Option<&()> { x.next() }
    |                          ^ expected named lifetime parameter
    |
    = help: add `#![feature(anonymous_lifetime_in_impl_trait)]` 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: consider introducing a named lifetime parameter
    |
 LL |     fn g<'a>(mut x: impl Foo<'a, ()>) -> Option<&()> { x.next() }
diff --git a/tests/ui/suggestions/missing-assoc-fn.stderr b/tests/ui/suggestions/missing-assoc-fn.stderr
index 84cb6e98553..61a5492d583 100644
--- a/tests/ui/suggestions/missing-assoc-fn.stderr
+++ b/tests/ui/suggestions/missing-assoc-fn.stderr
@@ -6,6 +6,7 @@ LL |     fn bat<T: TraitB<Item: Copy>>(_: T) -> Self;
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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[E0046]: not all trait items implemented, missing: `foo`, `bar`, `baz`, `bat`
   --> $DIR/missing-assoc-fn.rs:14:1
diff --git a/tests/ui/suggestions/type-ascription-instead-of-path-in-type.stderr b/tests/ui/suggestions/type-ascription-instead-of-path-in-type.stderr
index 4e3180e84d2..9c22873e79c 100644
--- a/tests/ui/suggestions/type-ascription-instead-of-path-in-type.stderr
+++ b/tests/ui/suggestions/type-ascription-instead-of-path-in-type.stderr
@@ -17,6 +17,7 @@ LL |     let _: Vec<A:B> = A::B;
    |
    = note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
    = help: add `#![feature(associated_type_bounds)]` 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[E0107]: struct takes at least 1 generic argument but 0 generic arguments were supplied
   --> $DIR/type-ascription-instead-of-path-in-type.rs:6:12
diff --git a/tests/ui/target-feature/gate.stderr b/tests/ui/target-feature/gate.stderr
index b3bd12600f8..d281f0a6ab9 100644
--- a/tests/ui/target-feature/gate.stderr
+++ b/tests/ui/target-feature/gate.stderr
@@ -6,6 +6,7 @@ LL | #[target_feature(enable = "avx512bw")]
    |
    = note: see issue #44839 <https://github.com/rust-lang/rust/issues/44839> for more information
    = help: add `#![feature(avx512_target_feature)]` 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 1 previous error
 
diff --git a/tests/ui/target-feature/invalid-attribute.rs b/tests/ui/target-feature/invalid-attribute.rs
index f6357bd9eb0..7c5941f5bae 100644
--- a/tests/ui/target-feature/invalid-attribute.rs
+++ b/tests/ui/target-feature/invalid-attribute.rs
@@ -31,6 +31,7 @@ unsafe fn foo() {}
 #[target_feature(enable = "sse2")]
 //~^ ERROR `#[target_feature(..)]` can only be applied to `unsafe` functions
 //~| NOTE see issue #69098
+//~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 fn bar() {}
 //~^ NOTE not an `unsafe` function
 
@@ -102,6 +103,7 @@ impl Quux for Foo {
     #[target_feature(enable = "sse2")]
     //~^ ERROR `#[target_feature(..)]` can only be applied to `unsafe` functions
     //~| NOTE see issue #69098
+    //~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
     fn foo() {}
     //~^ NOTE not an `unsafe` function
 }
diff --git a/tests/ui/target-feature/invalid-attribute.stderr b/tests/ui/target-feature/invalid-attribute.stderr
index 8f981d27c53..278b9ad5003 100644
--- a/tests/ui/target-feature/invalid-attribute.stderr
+++ b/tests/ui/target-feature/invalid-attribute.stderr
@@ -32,7 +32,7 @@ LL | extern "Rust" {}
    | ---------------- not a function definition
 
 error: attribute should be applied to a function definition
-  --> $DIR/invalid-attribute.rs:37:1
+  --> $DIR/invalid-attribute.rs:38:1
    |
 LL | #[target_feature(enable = "sse2")]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -41,7 +41,7 @@ LL | mod another {}
    | -------------- not a function definition
 
 error: attribute should be applied to a function definition
-  --> $DIR/invalid-attribute.rs:42:1
+  --> $DIR/invalid-attribute.rs:43:1
    |
 LL | #[target_feature(enable = "sse2")]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -50,7 +50,7 @@ LL | const FOO: usize = 7;
    | --------------------- not a function definition
 
 error: attribute should be applied to a function definition
-  --> $DIR/invalid-attribute.rs:47:1
+  --> $DIR/invalid-attribute.rs:48:1
    |
 LL | #[target_feature(enable = "sse2")]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -59,7 +59,7 @@ LL | struct Foo;
    | ----------- not a function definition
 
 error: attribute should be applied to a function definition
-  --> $DIR/invalid-attribute.rs:52:1
+  --> $DIR/invalid-attribute.rs:53:1
    |
 LL | #[target_feature(enable = "sse2")]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -68,7 +68,7 @@ LL | enum Bar {}
    | ----------- not a function definition
 
 error: attribute should be applied to a function definition
-  --> $DIR/invalid-attribute.rs:57:1
+  --> $DIR/invalid-attribute.rs:58:1
    |
 LL |   #[target_feature(enable = "sse2")]
    |   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -81,7 +81,7 @@ LL | | }
    | |_- not a function definition
 
 error: attribute should be applied to a function definition
-  --> $DIR/invalid-attribute.rs:65:1
+  --> $DIR/invalid-attribute.rs:66:1
    |
 LL | #[target_feature(enable = "sse2")]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -90,7 +90,7 @@ LL | type Uwu = ();
    | -------------- not a function definition
 
 error: attribute should be applied to a function definition
-  --> $DIR/invalid-attribute.rs:70:1
+  --> $DIR/invalid-attribute.rs:71:1
    |
 LL | #[target_feature(enable = "sse2")]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -99,7 +99,7 @@ LL | trait Baz {}
    | ------------ not a function definition
 
 error: attribute should be applied to a function definition
-  --> $DIR/invalid-attribute.rs:80:1
+  --> $DIR/invalid-attribute.rs:81:1
    |
 LL | #[target_feature(enable = "sse2")]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -108,7 +108,7 @@ LL | static A: () = ();
    | ------------------ not a function definition
 
 error: attribute should be applied to a function definition
-  --> $DIR/invalid-attribute.rs:85:1
+  --> $DIR/invalid-attribute.rs:86:1
    |
 LL | #[target_feature(enable = "sse2")]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -117,7 +117,7 @@ LL | impl Quux for u8 {}
    | ------------------- not a function definition
 
 error: attribute should be applied to a function definition
-  --> $DIR/invalid-attribute.rs:92:1
+  --> $DIR/invalid-attribute.rs:93:1
    |
 LL | #[target_feature(enable = "sse2")]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -126,7 +126,7 @@ LL | impl Foo {}
    | ----------- not a function definition
 
 error: attribute should be applied to a function definition
-  --> $DIR/invalid-attribute.rs:110:5
+  --> $DIR/invalid-attribute.rs:112:5
    |
 LL |       #[target_feature(enable = "sse2")]
    |       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -138,7 +138,7 @@ LL | |     }
    | |_____- not a function definition
 
 error: attribute should be applied to a function definition
-  --> $DIR/invalid-attribute.rs:118:5
+  --> $DIR/invalid-attribute.rs:120:5
    |
 LL |     #[target_feature(enable = "sse2")]
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -175,15 +175,16 @@ LL | fn bar() {}
    |
    = note: see issue #69098 <https://github.com/rust-lang/rust/issues/69098> for more information
    = help: add `#![feature(target_feature_11)]` 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: cannot use `#[inline(always)]` with `#[target_feature]`
-  --> $DIR/invalid-attribute.rs:75:1
+  --> $DIR/invalid-attribute.rs:76:1
    |
 LL | #[inline(always)]
    | ^^^^^^^^^^^^^^^^^
 
 error[E0658]: `#[target_feature(..)]` can only be applied to `unsafe` functions
-  --> $DIR/invalid-attribute.rs:102:5
+  --> $DIR/invalid-attribute.rs:103:5
    |
 LL |     #[target_feature(enable = "sse2")]
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -193,9 +194,10 @@ LL |     fn foo() {}
    |
    = note: see issue #69098 <https://github.com/rust-lang/rust/issues/69098> for more information
    = help: add `#![feature(target_feature_11)]` 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[E0046]: not all trait items implemented, missing: `foo`
-  --> $DIR/invalid-attribute.rs:87:1
+  --> $DIR/invalid-attribute.rs:88:1
    |
 LL | impl Quux for u8 {}
    | ^^^^^^^^^^^^^^^^ missing `foo` in implementation
diff --git a/tests/ui/thread-local/thread-local-static.stderr b/tests/ui/thread-local/thread-local-static.stderr
index b03f4580c2c..59bd17b39d8 100644
--- a/tests/ui/thread-local/thread-local-static.stderr
+++ b/tests/ui/thread-local/thread-local-static.stderr
@@ -29,6 +29,7 @@ LL | const fn g(x: &mut [u32; 8]) {
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0625]: thread-local statics cannot be accessed at compile-time
   --> $DIR/thread-local-static.rs:10:28
@@ -52,6 +53,7 @@ LL |     std::mem::swap(x, &mut STATIC_VAR_2)
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error: aborting due to 5 previous errors; 1 warning emitted
 
diff --git a/tests/ui/tool-attributes/diagnostic_item.stderr b/tests/ui/tool-attributes/diagnostic_item.stderr
index a181aee6b58..c6ae5a38594 100644
--- a/tests/ui/tool-attributes/diagnostic_item.stderr
+++ b/tests/ui/tool-attributes/diagnostic_item.stderr
@@ -5,6 +5,7 @@ LL | #[rustc_diagnostic_item = "foomp"]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(rustc_attrs)]` 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 1 previous error
 
diff --git a/tests/ui/track-diagnostics/track6.stderr b/tests/ui/track-diagnostics/track6.stderr
index 8ca56d6db21..9ed8a19629d 100644
--- a/tests/ui/track-diagnostics/track6.stderr
+++ b/tests/ui/track-diagnostics/track6.stderr
@@ -7,6 +7,7 @@ LL |     default fn bar() {}
    |
    = note: see issue #31844 <https://github.com/rust-lang/rust/issues/31844> for more information
    = help: add `#![feature(specialization)]` 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 1 previous error
 
diff --git a/tests/ui/traits/alias/generic-default-in-dyn.stderr b/tests/ui/traits/alias/generic-default-in-dyn.stderr
index 0d3f794aa0f..50031e184c1 100644
--- a/tests/ui/traits/alias/generic-default-in-dyn.stderr
+++ b/tests/ui/traits/alias/generic-default-in-dyn.stderr
@@ -6,6 +6,7 @@ LL | trait SendEqAlias<T> = PartialEq;
    |
    = note: see issue #41517 <https://github.com/rust-lang/rust/issues/41517> for more information
    = help: add `#![feature(trait_alias)]` 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[E0393]: the type parameter `Rhs` must be explicitly specified
   --> $DIR/generic-default-in-dyn.rs:4:19
diff --git a/tests/ui/traits/default-method/rustc_must_implement_one_of_gated.stderr b/tests/ui/traits/default-method/rustc_must_implement_one_of_gated.stderr
index cb7eb1567c8..162c3d36cb1 100644
--- a/tests/ui/traits/default-method/rustc_must_implement_one_of_gated.stderr
+++ b/tests/ui/traits/default-method/rustc_must_implement_one_of_gated.stderr
@@ -5,6 +5,7 @@ LL | #[rustc_must_implement_one_of(eq, neq)]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(rustc_attrs)]` 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 1 previous error
 
diff --git a/tests/ui/traits/issue-78372.stderr b/tests/ui/traits/issue-78372.stderr
index ec692ff911d..44a62988daf 100644
--- a/tests/ui/traits/issue-78372.stderr
+++ b/tests/ui/traits/issue-78372.stderr
@@ -44,6 +44,7 @@ LL | use std::ops::DispatchFromDyn;
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(dispatch_from_dyn)]` 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]: use of unstable library feature 'dispatch_from_dyn'
   --> $DIR/issue-78372.rs:3:9
@@ -52,6 +53,7 @@ LL | impl<T> DispatchFromDyn<Smaht<U, MISC>> for T {}
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add `#![feature(dispatch_from_dyn)]` 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[E0378]: the trait `DispatchFromDyn` may only be implemented for a coercion between structures
   --> $DIR/issue-78372.rs:3:1
diff --git a/tests/ui/traits/method-argument-mismatch-variance-ice-119867.rs b/tests/ui/traits/method-argument-mismatch-variance-ice-119867.rs
new file mode 100644
index 00000000000..4b7862abc91
--- /dev/null
+++ b/tests/ui/traits/method-argument-mismatch-variance-ice-119867.rs
@@ -0,0 +1,13 @@
+trait Deserialize {
+    fn deserialize(&self);
+}
+
+struct ArchivedVec<T>(T);
+
+impl<T> Deserialize for ArchivedVec<T> {
+    fn deserialize(s: _) {}
+    //~^ ERROR: `_` is not allowed within types on item signatures
+    //~| ERROR: has a `&self` declaration in the trait, but not in the impl
+}
+
+fn main() {}
diff --git a/tests/ui/traits/method-argument-mismatch-variance-ice-119867.stderr b/tests/ui/traits/method-argument-mismatch-variance-ice-119867.stderr
new file mode 100644
index 00000000000..e63cc522dd1
--- /dev/null
+++ b/tests/ui/traits/method-argument-mismatch-variance-ice-119867.stderr
@@ -0,0 +1,24 @@
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+  --> $DIR/method-argument-mismatch-variance-ice-119867.rs:8:23
+   |
+LL |     fn deserialize(s: _) {}
+   |                       ^ not allowed in type signatures
+   |
+help: try replacing `_` with the type in the corresponding trait method signature
+   |
+LL |     fn deserialize(s: &ArchivedVec<T>) {}
+   |                       ~~~~~~~~~~~~~~~
+
+error[E0186]: method `deserialize` has a `&self` declaration in the trait, but not in the impl
+  --> $DIR/method-argument-mismatch-variance-ice-119867.rs:8:5
+   |
+LL |     fn deserialize(&self);
+   |     ---------------------- `&self` used in trait
+...
+LL |     fn deserialize(s: _) {}
+   |     ^^^^^^^^^^^^^^^^^^^^ expected `&self` in impl
+
+error: aborting due to 2 previous errors
+
+Some errors have detailed explanations: E0121, E0186.
+For more information about an error, try `rustc --explain E0121`.
diff --git a/tests/ui/traits/negative-impls/feature-gate-negative_impls.stderr b/tests/ui/traits/negative-impls/feature-gate-negative_impls.stderr
index a232e6d8619..f3dee114116 100644
--- a/tests/ui/traits/negative-impls/feature-gate-negative_impls.stderr
+++ b/tests/ui/traits/negative-impls/feature-gate-negative_impls.stderr
@@ -6,6 +6,7 @@ LL | impl !MyTrait for u32 {}
    |
    = note: see issue #68318 <https://github.com/rust-lang/rust/issues/68318> for more information
    = help: add `#![feature(negative_impls)]` 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 1 previous error
 
diff --git a/tests/ui/traits/next-solver/dont-ice-on-assoc-projection.stderr b/tests/ui/traits/next-solver/dont-ice-on-assoc-projection.stderr
index 368f5cd0c3b..db7d2dd3e3a 100644
--- a/tests/ui/traits/next-solver/dont-ice-on-assoc-projection.stderr
+++ b/tests/ui/traits/next-solver/dont-ice-on-assoc-projection.stderr
@@ -6,6 +6,7 @@ LL | impl<T> Foo for T where T: Bar<ASSOC = 0> {}
    |
    = note: see issue #92827 <https://github.com/rust-lang/rust/issues/92827> for more information
    = help: add `#![feature(associated_const_equality)]` 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[E0119]: conflicting implementations of trait `Foo` for type `()`
   --> $DIR/dont-ice-on-assoc-projection.rs:15:1
diff --git a/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response-2.current.stderr b/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response-2.current.stderr
new file mode 100644
index 00000000000..4082d6d47e7
--- /dev/null
+++ b/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response-2.current.stderr
@@ -0,0 +1,11 @@
+warning: the feature `non_lifetime_binders` is incomplete and may not be safe to use and/or cause compiler crashes
+  --> $DIR/unifying-placeholders-in-query-response-2.rs:5:12
+   |
+LL | #![feature(non_lifetime_binders)]
+   |            ^^^^^^^^^^^^^^^^^^^^
+   |
+   = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
+   = note: `#[warn(incomplete_features)]` on by default
+
+warning: 1 warning emitted
+
diff --git a/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response-2.next.stderr b/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response-2.next.stderr
new file mode 100644
index 00000000000..4082d6d47e7
--- /dev/null
+++ b/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response-2.next.stderr
@@ -0,0 +1,11 @@
+warning: the feature `non_lifetime_binders` is incomplete and may not be safe to use and/or cause compiler crashes
+  --> $DIR/unifying-placeholders-in-query-response-2.rs:5:12
+   |
+LL | #![feature(non_lifetime_binders)]
+   |            ^^^^^^^^^^^^^^^^^^^^
+   |
+   = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
+   = note: `#[warn(incomplete_features)]` on by default
+
+warning: 1 warning emitted
+
diff --git a/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response-2.rs b/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response-2.rs
new file mode 100644
index 00000000000..bbf1a1f72db
--- /dev/null
+++ b/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response-2.rs
@@ -0,0 +1,23 @@
+// revisions: current next
+//[next] compile-flags: -Znext-solver
+// check-pass
+
+#![feature(non_lifetime_binders)]
+//~^ WARN the feature `non_lifetime_binders` is incomplete
+
+trait Id {
+    type Output: ?Sized;
+}
+
+impl<T: ?Sized> Id for T {
+    type Output = T;
+}
+
+trait Everyone {}
+impl<T: ?Sized> Everyone for T {}
+
+fn hello() where for<T> <T as Id>::Output: Everyone {}
+
+fn main() {
+    hello();
+}
diff --git a/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response.current.stderr b/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response.current.stderr
new file mode 100644
index 00000000000..040009efbde
--- /dev/null
+++ b/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response.current.stderr
@@ -0,0 +1,11 @@
+warning: the feature `non_lifetime_binders` is incomplete and may not be safe to use and/or cause compiler crashes
+  --> $DIR/unifying-placeholders-in-query-response.rs:5:12
+   |
+LL | #![feature(non_lifetime_binders)]
+   |            ^^^^^^^^^^^^^^^^^^^^
+   |
+   = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
+   = note: `#[warn(incomplete_features)]` on by default
+
+warning: 1 warning emitted
+
diff --git a/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response.next.stderr b/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response.next.stderr
new file mode 100644
index 00000000000..040009efbde
--- /dev/null
+++ b/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response.next.stderr
@@ -0,0 +1,11 @@
+warning: the feature `non_lifetime_binders` is incomplete and may not be safe to use and/or cause compiler crashes
+  --> $DIR/unifying-placeholders-in-query-response.rs:5:12
+   |
+LL | #![feature(non_lifetime_binders)]
+   |            ^^^^^^^^^^^^^^^^^^^^
+   |
+   = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
+   = note: `#[warn(incomplete_features)]` on by default
+
+warning: 1 warning emitted
+
diff --git a/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response.rs b/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response.rs
new file mode 100644
index 00000000000..5e28a2ba8b9
--- /dev/null
+++ b/tests/ui/traits/non_lifetime_binders/unifying-placeholders-in-query-response.rs
@@ -0,0 +1,27 @@
+// revisions: current next
+//[next] compile-flags: -Znext-solver
+// check-pass
+
+#![feature(non_lifetime_binders)]
+//~^ WARN the feature `non_lifetime_binders` is incomplete
+
+pub trait Foo<T: ?Sized> {
+    type Bar<K: ?Sized>: ?Sized;
+}
+
+impl Foo<usize> for () {
+    type Bar<K: ?Sized> = K;
+}
+
+pub fn f<T1, T2>(a: T1, b: T2)
+where
+    T1: for<T> Foo<usize, Bar<T> = T>,
+    T2: for<T> Foo<usize, Bar<T> = <T1 as Foo<usize>>::Bar<T>>,
+{
+}
+
+fn it_works() {
+    f((), ());
+}
+
+fn main() {}
diff --git a/tests/ui/transmutability/malformed-program-gracefulness/feature-missing.stderr b/tests/ui/transmutability/malformed-program-gracefulness/feature-missing.stderr
index ba8093f8614..9f221907172 100644
--- a/tests/ui/transmutability/malformed-program-gracefulness/feature-missing.stderr
+++ b/tests/ui/transmutability/malformed-program-gracefulness/feature-missing.stderr
@@ -6,6 +6,7 @@ LL | use std::mem::BikeshedIntrinsicFrom;
    |
    = note: see issue #99571 <https://github.com/rust-lang/rust/issues/99571> for more information
    = help: add `#![feature(transmutability)]` 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]: use of unstable library feature 'transmutability'
   --> $DIR/feature-missing.rs:8:5
@@ -15,6 +16,7 @@ LL | use std::mem::Assume;
    |
    = note: see issue #99571 <https://github.com/rust-lang/rust/issues/99571> for more information
    = help: add `#![feature(transmutability)]` 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 2 previous errors
 
diff --git a/tests/ui/type-alias-impl-trait/issue-60371.stderr b/tests/ui/type-alias-impl-trait/issue-60371.stderr
index ffc66473635..1c83b0655f5 100644
--- a/tests/ui/type-alias-impl-trait/issue-60371.stderr
+++ b/tests/ui/type-alias-impl-trait/issue-60371.stderr
@@ -6,6 +6,7 @@ LL |     type Item = impl Bug;
    |
    = note: see issue #63063 <https://github.com/rust-lang/rust/issues/63063> for more information
    = help: add `#![feature(impl_trait_in_assoc_type)]` 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[E0277]: the trait bound `(): Bug` is not satisfied
   --> $DIR/issue-60371.rs:10:40
diff --git a/tests/ui/type-alias-impl-trait/nested_inference_failure.rs b/tests/ui/type-alias-impl-trait/nested_inference_failure.rs
new file mode 100644
index 00000000000..d2091ca96ea
--- /dev/null
+++ b/tests/ui/type-alias-impl-trait/nested_inference_failure.rs
@@ -0,0 +1,28 @@
+// check-pass
+// revisions: new old
+//[new] compile-flags: -Znext-solver
+
+//! This test checks that we can successfully infer
+//! the hidden type of `FooImpl` to be `Foo<i32, {closure}>`
+//! and `ImplT` to be `i32`. This test used to fail, because
+//! we were unable to make the connection that the closure
+//! argument is the same as the first argument of `Foo`.
+
+#![feature(type_alias_impl_trait)]
+
+use std::fmt::Debug;
+use std::marker::PhantomData;
+
+struct Foo<T: Debug, F: FnOnce(T)> {
+    f: F,
+    _phantom: PhantomData<T>,
+}
+
+type ImplT = impl Debug;
+type FooImpl = Foo<ImplT, impl FnOnce(ImplT)>;
+
+fn bar() -> FooImpl {
+    Foo::<i32, _> { f: |_| (), _phantom: PhantomData }
+}
+
+fn main() {}
diff --git a/tests/ui/type-alias-impl-trait/wf-nested.fail.stderr b/tests/ui/type-alias-impl-trait/wf-nested.fail.stderr
index dcc4b8021ea..17c1f8897bf 100644
--- a/tests/ui/type-alias-impl-trait/wf-nested.fail.stderr
+++ b/tests/ui/type-alias-impl-trait/wf-nested.fail.stderr
@@ -1,5 +1,5 @@
 error[E0310]: the parameter type `T` may not live long enough
-  --> $DIR/wf-nested.rs:55:27
+  --> $DIR/wf-nested.rs:57:27
    |
 LL |     type InnerOpaque<T> = impl Sized;
    |                           ^^^^^^^^^^
diff --git a/tests/ui/type-alias-impl-trait/wf-nested.pass_sound.stderr b/tests/ui/type-alias-impl-trait/wf-nested.pass_sound.stderr
index 121664bd956..f5d3a218542 100644
--- a/tests/ui/type-alias-impl-trait/wf-nested.pass_sound.stderr
+++ b/tests/ui/type-alias-impl-trait/wf-nested.pass_sound.stderr
@@ -12,6 +12,21 @@ help: consider adding an explicit lifetime bound
 LL |     fn test<T: 'static>() {
    |              +++++++++
 
-error: aborting due to 1 previous error
+error[E0310]: the parameter type `T` may not live long enough
+  --> $DIR/wf-nested.rs:46:17
+   |
+LL |         let _ = outer.get();
+   |                 ^^^^^^^^^^^
+   |                 |
+   |                 the parameter type `T` must be valid for the static lifetime...
+   |                 ...so that the type `T` will meet its required lifetime bounds
+   |
+   = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
+help: consider adding an explicit lifetime bound
+   |
+LL |     fn test<T: 'static>() {
+   |              +++++++++
+
+error: aborting due to 2 previous errors
 
 For more information about this error, try `rustc --explain E0310`.
diff --git a/tests/ui/type-alias-impl-trait/wf-nested.rs b/tests/ui/type-alias-impl-trait/wf-nested.rs
index de388329489..2f90c4e00e3 100644
--- a/tests/ui/type-alias-impl-trait/wf-nested.rs
+++ b/tests/ui/type-alias-impl-trait/wf-nested.rs
@@ -43,7 +43,9 @@ mod pass_sound {
 
     fn test<T>() {
         let outer = define::<T>();
-        let _ = outer.get(); //[pass_sound]~ ERROR `T` may not live long enough
+        let _ = outer.get();
+        //[pass_sound]~^ ERROR `T` may not live long enough
+        //[pass_sound]~| ERROR `T` may not live long enough
     }
 }
 
diff --git a/tests/ui/typeck/issue-105946.stderr b/tests/ui/typeck/issue-105946.stderr
index 2220271e581..33d4e0b141a 100644
--- a/tests/ui/typeck/issue-105946.stderr
+++ b/tests/ui/typeck/issue-105946.stderr
@@ -17,6 +17,7 @@ LL |     let [_y..] = [Box::new(1), Box::new(2)];
    |
    = note: see issue #67264 <https://github.com/rust-lang/rust/issues/67264> for more information
    = help: add `#![feature(half_open_range_patterns_in_slices)]` 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[E0308]: mismatched types
   --> $DIR/issue-105946.rs:2:12
diff --git a/tests/ui/unboxed-closures/unboxed-closure-feature-gate.stderr b/tests/ui/unboxed-closures/unboxed-closure-feature-gate.stderr
index d06fa3007df..77aafe227d1 100644
--- a/tests/ui/unboxed-closures/unboxed-closure-feature-gate.stderr
+++ b/tests/ui/unboxed-closures/unboxed-closure-feature-gate.stderr
@@ -6,6 +6,7 @@ LL |     let x: Box<dyn Foo(isize)>;
    |
    = 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: aborting due to 1 previous error
 
diff --git a/tests/ui/unboxed-closures/unboxed-closure-sugar-not-used-on-fn.stderr b/tests/ui/unboxed-closures/unboxed-closure-sugar-not-used-on-fn.stderr
index 9da36906d55..e6f34d7e3b4 100644
--- a/tests/ui/unboxed-closures/unboxed-closure-sugar-not-used-on-fn.stderr
+++ b/tests/ui/unboxed-closures/unboxed-closure-sugar-not-used-on-fn.stderr
@@ -6,6 +6,7 @@ LL | fn bar1(x: &dyn Fn<(), Output=()>) {
    |
    = 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[E0658]: the precise format of `Fn`-family traits' type parameters is subject to change
   --> $DIR/unboxed-closure-sugar-not-used-on-fn.rs:7:28
@@ -15,6 +16,7 @@ LL | fn bar2<T>(x: &T) where T: Fn<()> {
    |
    = 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: aborting due to 2 previous errors
 
diff --git a/tests/ui/unknown-unstable-lints/deny-unstable-lint-command-line.stderr b/tests/ui/unknown-unstable-lints/deny-unstable-lint-command-line.stderr
index df83c103084..1eb469c7cdb 100644
--- a/tests/ui/unknown-unstable-lints/deny-unstable-lint-command-line.stderr
+++ b/tests/ui/unknown-unstable-lints/deny-unstable-lint-command-line.stderr
@@ -2,6 +2,7 @@ error: unknown lint: `test_unstable_lint`
    |
    = note: the `test_unstable_lint` lint is unstable
    = help: add `-Zcrate-attr="feature(test_unstable_lint)"` to the command-line options to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
    = note: requested on the command line with `-D unknown-lints`
 
 error: aborting due to 1 previous error
diff --git a/tests/ui/unknown-unstable-lints/deny-unstable-lint-inline.stderr b/tests/ui/unknown-unstable-lints/deny-unstable-lint-inline.stderr
index 0afe3d55c98..e486f04f273 100644
--- a/tests/ui/unknown-unstable-lints/deny-unstable-lint-inline.stderr
+++ b/tests/ui/unknown-unstable-lints/deny-unstable-lint-inline.stderr
@@ -6,6 +6,7 @@ LL | #![allow(test_unstable_lint)]
    |
    = note: the `test_unstable_lint` lint is unstable
    = help: add `#![feature(test_unstable_lint)]` 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: the lint level is defined here
   --> $DIR/deny-unstable-lint-inline.rs:3:9
    |
diff --git a/tests/ui/unknown-unstable-lints/warn-unknown-unstable-lint-command-line.stderr b/tests/ui/unknown-unstable-lints/warn-unknown-unstable-lint-command-line.stderr
index c133b880ebd..9d838f7d1ea 100644
--- a/tests/ui/unknown-unstable-lints/warn-unknown-unstable-lint-command-line.stderr
+++ b/tests/ui/unknown-unstable-lints/warn-unknown-unstable-lint-command-line.stderr
@@ -2,6 +2,7 @@ warning: unknown lint: `test_unstable_lint`
    |
    = note: the `test_unstable_lint` lint is unstable
    = help: add `-Zcrate-attr="feature(test_unstable_lint)"` to the command-line options to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
    = note: requested on the command line with `-W unknown-lints`
 
 warning: 1 warning emitted
diff --git a/tests/ui/unknown-unstable-lints/warn-unknown-unstable-lint-inline.stderr b/tests/ui/unknown-unstable-lints/warn-unknown-unstable-lint-inline.stderr
index 48c83b49e29..981d3b1a874 100644
--- a/tests/ui/unknown-unstable-lints/warn-unknown-unstable-lint-inline.stderr
+++ b/tests/ui/unknown-unstable-lints/warn-unknown-unstable-lint-inline.stderr
@@ -6,6 +6,7 @@ LL | #![allow(test_unstable_lint)]
    |
    = note: the `test_unstable_lint` lint is unstable
    = help: add `#![feature(test_unstable_lint)]` 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: the lint level is defined here
   --> $DIR/warn-unknown-unstable-lint-inline.rs:3:9
    |
diff --git a/tests/ui/unsafe/ranged_ints2_const.stderr b/tests/ui/unsafe/ranged_ints2_const.stderr
index f267dc6e23e..2d25084314e 100644
--- a/tests/ui/unsafe/ranged_ints2_const.stderr
+++ b/tests/ui/unsafe/ranged_ints2_const.stderr
@@ -14,6 +14,7 @@ LL |     let y = &mut x.0;
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = 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 constant functions
   --> $DIR/ranged_ints2_const.rs:18:22
@@ -23,6 +24,7 @@ LL |     let y = unsafe { &mut x.0 };
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = 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 constant functions
   --> $DIR/ranged_ints2_const.rs:24:22
@@ -32,6 +34,7 @@ LL |     unsafe { let y = &mut x.0; }
    |
    = note: see issue #57349 <https://github.com/rust-lang/rust/issues/57349> for more information
    = help: add `#![feature(const_mut_refs)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error: aborting due to 4 previous errors
 
diff --git a/tests/ui/unsafe/ranged_ints3_const.stderr b/tests/ui/unsafe/ranged_ints3_const.stderr
index 75b36cdf94b..c388a66f631 100644
--- a/tests/ui/unsafe/ranged_ints3_const.stderr
+++ b/tests/ui/unsafe/ranged_ints3_const.stderr
@@ -14,6 +14,7 @@ LL |     let y = &x.0;
    |
    = note: see issue #80384 <https://github.com/rust-lang/rust/issues/80384> for more information
    = help: add `#![feature(const_refs_to_cell)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0658]: cannot borrow here, since the borrowed element may contain interior mutability
   --> $DIR/ranged_ints3_const.rs:19:22
@@ -23,6 +24,7 @@ LL |     let y = unsafe { &x.0 };
    |
    = note: see issue #80384 <https://github.com/rust-lang/rust/issues/80384> for more information
    = help: add `#![feature(const_refs_to_cell)]` to the crate attributes to enable
+   = 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
 
diff --git a/tests/ui/wf/wf-associated-const.rs b/tests/ui/wf/wf-associated-const.rs
new file mode 100644
index 00000000000..629d807cb7f
--- /dev/null
+++ b/tests/ui/wf/wf-associated-const.rs
@@ -0,0 +1,41 @@
+// check that associated consts can assume the impl header is well-formed.
+
+trait Foo<'a, 'b, T>: Sized {
+    const EVIL: fn(u: &'b u32) -> &'a u32;
+}
+
+struct Evil<'a, 'b: 'a>(Option<&'a &'b ()>);
+
+impl<'a, 'b> Foo<'a, 'b, Evil<'a, 'b>> for () {
+    const EVIL: fn(&'b u32) -> &'a u32 = { |u| u };
+}
+
+struct IndirectEvil<'a, 'b: 'a>(Option<&'a &'b ()>);
+
+impl<'a, 'b> Foo<'a, 'b, ()> for IndirectEvil<'a, 'b> {
+    const EVIL: fn(&'b u32) -> &'a u32 = { |u| u };
+}
+
+impl<'a, 'b> Evil<'a, 'b> {
+    const INHERENT_EVIL: fn(&'b u32) -> &'a u32 = { |u| u };
+}
+
+// while static methods can *assume* this, we should still
+// *check* that it holds at the use site.
+
+fn evil<'a, 'b>(b: &'b u32) -> &'a u32 {
+    <()>::EVIL(b)
+    //~^ ERROR lifetime may not live long enough
+}
+
+fn indirect_evil<'a, 'b>(b: &'b u32) -> &'a u32 {
+    <IndirectEvil>::EVIL(b)
+    //~^ ERROR lifetime may not live long enough
+}
+
+fn inherent_evil<'a, 'b>(b: &'b u32) -> &'a u32 {
+    <Evil>::INHERENT_EVIL(b)
+    //~^ ERROR lifetime may not live long enough
+}
+
+fn main() {}
diff --git a/tests/ui/wf/wf-associated-const.stderr b/tests/ui/wf/wf-associated-const.stderr
new file mode 100644
index 00000000000..b0e1a118fab
--- /dev/null
+++ b/tests/ui/wf/wf-associated-const.stderr
@@ -0,0 +1,38 @@
+error: lifetime may not live long enough
+  --> $DIR/wf-associated-const.rs:27:5
+   |
+LL | fn evil<'a, 'b>(b: &'b u32) -> &'a u32 {
+   |         --  -- lifetime `'b` defined here
+   |         |
+   |         lifetime `'a` defined here
+LL |     <()>::EVIL(b)
+   |     ^^^^^^^^^^^^^ function was supposed to return data with lifetime `'a` but it is returning data with lifetime `'b`
+   |
+   = help: consider adding the following bound: `'b: 'a`
+
+error: lifetime may not live long enough
+  --> $DIR/wf-associated-const.rs:32:5
+   |
+LL | fn indirect_evil<'a, 'b>(b: &'b u32) -> &'a u32 {
+   |                  --  -- lifetime `'b` defined here
+   |                  |
+   |                  lifetime `'a` defined here
+LL |     <IndirectEvil>::EVIL(b)
+   |     ^^^^^^^^^^^^^^^^^^^^^^^ function was supposed to return data with lifetime `'a` but it is returning data with lifetime `'b`
+   |
+   = help: consider adding the following bound: `'b: 'a`
+
+error: lifetime may not live long enough
+  --> $DIR/wf-associated-const.rs:37:5
+   |
+LL | fn inherent_evil<'a, 'b>(b: &'b u32) -> &'a u32 {
+   |                  --  -- lifetime `'b` defined here
+   |                  |
+   |                  lifetime `'a` defined here
+LL |     <Evil>::INHERENT_EVIL(b)
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^ function was supposed to return data with lifetime `'a` but it is returning data with lifetime `'b`
+   |
+   = help: consider adding the following bound: `'b: 'a`
+
+error: aborting due to 3 previous errors
+
diff --git a/tests/ui/wf/wf-in-fn-type-implicit.rs b/tests/ui/wf/wf-in-fn-type-implicit.rs
deleted file mode 100644
index c5ff92c8875..00000000000
--- a/tests/ui/wf/wf-in-fn-type-implicit.rs
+++ /dev/null
@@ -1,37 +0,0 @@
-// check-pass
-// known-bug: #104005
-
-// Should fail. Function type parameters with implicit type annotations are not
-// checked for well-formedness, which allows incorrect borrowing.
-
-// In contrast, user annotations are always checked for well-formedness, and the
-// commented code below is correctly rejected by the borrow checker.
-
-use std::fmt::Display;
-
-trait Displayable {
-    fn display(self) -> Box<dyn Display>;
-}
-
-impl<T: Display> Displayable for (T, Option<&'static T>) {
-    fn display(self) -> Box<dyn Display> {
-        Box::new(self.0)
-    }
-}
-
-fn extend_lt<T, U>(val: T) -> Box<dyn Display>
-where
-    (T, Option<U>): Displayable,
-{
-    Displayable::display((val, None))
-}
-
-fn main() {
-    // *incorrectly* compiles
-    let val = extend_lt(&String::from("blah blah blah"));
-    println!("{}", val);
-
-    // *correctly* fails to compile
-    // let val = extend_lt::<_, &_>(&String::from("blah blah blah"));
-    // println!("{}", val);
-}
diff --git a/tests/ui/wf/wf-static-method.rs b/tests/ui/wf/wf-static-method.rs
index 7ff195230bf..66546ac489d 100644
--- a/tests/ui/wf/wf-static-method.rs
+++ b/tests/ui/wf/wf-static-method.rs
@@ -1,8 +1,4 @@
-// check that static methods don't get to assume their trait-ref
-// is well-formed.
-// FIXME(#27579): this is just a bug. However, our checking with
-// static inherent methods isn't quite working - need to
-// fix that before removing the check.
+// check that static methods can assume their trait-ref is well-formed.
 
 trait Foo<'a, 'b, T>: Sized {
     fn make_me() -> Self { loop {} }
@@ -15,7 +11,6 @@ impl<'a, 'b> Foo<'a, 'b, Evil<'a, 'b>> for () {
     fn make_me() -> Self { }
     fn static_evil(u: &'b u32) -> &'a u32 {
         u
-        //~^ ERROR lifetime may not live long enough
     }
 }
 
@@ -25,7 +20,6 @@ impl<'a, 'b> Foo<'a, 'b, ()> for IndirectEvil<'a, 'b> {
     fn make_me() -> Self { IndirectEvil(None) }
     fn static_evil(u: &'b u32) -> &'a u32 {
         let me = Self::make_me();
-        //~^ ERROR lifetime may not live long enough
         loop {} // (`me` could be used for the lifetime transmute).
     }
 }
@@ -33,12 +27,11 @@ impl<'a, 'b> Foo<'a, 'b, ()> for IndirectEvil<'a, 'b> {
 impl<'a, 'b> Evil<'a, 'b> {
     fn inherent_evil(u: &'b u32) -> &'a u32 {
         u
-        //~^ ERROR lifetime may not live long enough
     }
 }
 
-// while static methods don't get to *assume* this, we still
-// *check* that they hold.
+// while static methods can *assume* this, we should still
+// *check* that it holds at the use site.
 
 fn evil<'a, 'b>(b: &'b u32) -> &'a u32 {
     <()>::static_evil(b)
diff --git a/tests/ui/wf/wf-static-method.stderr b/tests/ui/wf/wf-static-method.stderr
index 161609a5f86..6c49098aad3 100644
--- a/tests/ui/wf/wf-static-method.stderr
+++ b/tests/ui/wf/wf-static-method.stderr
@@ -1,44 +1,5 @@
 error: lifetime may not live long enough
-  --> $DIR/wf-static-method.rs:17:9
-   |
-LL | impl<'a, 'b> Foo<'a, 'b, Evil<'a, 'b>> for () {
-   |      --  -- lifetime `'b` defined here
-   |      |
-   |      lifetime `'a` defined here
-...
-LL |         u
-   |         ^ associated function was supposed to return data with lifetime `'a` but it is returning data with lifetime `'b`
-   |
-   = help: consider adding the following bound: `'b: 'a`
-
-error: lifetime may not live long enough
-  --> $DIR/wf-static-method.rs:27:18
-   |
-LL | impl<'a, 'b> Foo<'a, 'b, ()> for IndirectEvil<'a, 'b> {
-   |      --  -- lifetime `'b` defined here
-   |      |
-   |      lifetime `'a` defined here
-...
-LL |         let me = Self::make_me();
-   |                  ^^^^^^^^^^^^^ requires that `'b` must outlive `'a`
-   |
-   = help: consider adding the following bound: `'b: 'a`
-
-error: lifetime may not live long enough
-  --> $DIR/wf-static-method.rs:35:9
-   |
-LL | impl<'a, 'b> Evil<'a, 'b> {
-   |      --  -- lifetime `'b` defined here
-   |      |
-   |      lifetime `'a` defined here
-LL |     fn inherent_evil(u: &'b u32) -> &'a u32 {
-LL |         u
-   |         ^ associated function was supposed to return data with lifetime `'a` but it is returning data with lifetime `'b`
-   |
-   = help: consider adding the following bound: `'b: 'a`
-
-error: lifetime may not live long enough
-  --> $DIR/wf-static-method.rs:44:5
+  --> $DIR/wf-static-method.rs:37:5
    |
 LL | fn evil<'a, 'b>(b: &'b u32) -> &'a u32 {
    |         --  -- lifetime `'b` defined here
@@ -50,7 +11,7 @@ LL |     <()>::static_evil(b)
    = help: consider adding the following bound: `'b: 'a`
 
 error: lifetime may not live long enough
-  --> $DIR/wf-static-method.rs:49:5
+  --> $DIR/wf-static-method.rs:42:5
    |
 LL | fn indirect_evil<'a, 'b>(b: &'b u32) -> &'a u32 {
    |                  --  -- lifetime `'b` defined here
@@ -62,7 +23,7 @@ LL |     <IndirectEvil>::static_evil(b)
    = help: consider adding the following bound: `'b: 'a`
 
 error: lifetime may not live long enough
-  --> $DIR/wf-static-method.rs:54:5
+  --> $DIR/wf-static-method.rs:47:5
    |
 LL | fn inherent_evil<'a, 'b>(b: &'b u32) -> &'a u32 {
    |                  --  -- lifetime `'b` defined here
@@ -73,5 +34,5 @@ LL |     <Evil>::inherent_evil(b)
    |
    = help: consider adding the following bound: `'b: 'a`
 
-error: aborting due to 6 previous errors
+error: aborting due to 3 previous errors