about summary refs log tree commit diff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/mir-opt/casts.redundant.InstCombine.diff25
-rw-r--r--tests/mir-opt/casts.redundant.PreCodegen.after.mir14
-rw-r--r--tests/mir-opt/casts.roundtrip.PreCodegen.after.mir15
-rw-r--r--tests/mir-opt/casts.rs17
-rw-r--r--tests/mir-opt/dataflow-const-prop/enum.multiple.DataflowConstProp.diff82
-rw-r--r--tests/mir-opt/dataflow-const-prop/enum.rs16
-rw-r--r--tests/mir-opt/dataflow-const-prop/enum.simple.DataflowConstProp.diff6
-rw-r--r--tests/mir-opt/issue_41110.main.ElaborateDrops.after.mir70
-rw-r--r--tests/mir-opt/issue_41110.main.ElaborateDrops.diff75
-rw-r--r--tests/mir-opt/issue_41110.rs4
-rw-r--r--tests/mir-opt/issue_41110.test.ElaborateDrops.after.mir101
-rw-r--r--tests/mir-opt/issue_41110.test.ElaborateDrops.diff109
-rw-r--r--tests/mir-opt/issue_41888.main.ElaborateDrops.after.mir152
-rw-r--r--tests/mir-opt/issue_41888.main.ElaborateDrops.diff158
-rw-r--r--tests/mir-opt/issue_41888.rs2
-rw-r--r--tests/run-make-fulldeps/hotplug_codegen_backend/the_backend.rs2
-rw-r--r--tests/run-make-fulldeps/issue-19371/foo.rs1
-rw-r--r--tests/run-make/translation/Makefile18
-rw-r--r--tests/rustdoc-gui/help-page.goml3
-rw-r--r--tests/rustdoc-ui/auxiliary/panic-handler.rs9
-rw-r--r--tests/rustdoc-ui/issue-107918.rs12
-rw-r--r--tests/rustdoc-ui/proc_macro_bug.rs12
-rw-r--r--tests/rustdoc-ui/proc_macro_bug.stderr8
-rw-r--r--tests/rustdoc-ui/unable-fulfill-trait.stderr2
-rw-r--r--tests/rustdoc-ui/z-help.stdout354
-rw-r--r--tests/rustdoc/intra-doc/basic.rs16
-rw-r--r--tests/rustdoc/issue-108281.rs25
-rw-r--r--tests/rustdoc/item-desc-list-at-start.item-table.html1
-rw-r--r--tests/rustdoc/item-desc-list-at-start.rs9
-rw-r--r--tests/rustdoc/reexports-of-same-name.rs26
-rw-r--r--tests/ui-fulldeps/create-dir-all-bare.rs11
-rw-r--r--tests/ui-fulldeps/fluent-messages/duplicate.ftl3
-rw-r--r--tests/ui-fulldeps/fluent-messages/label-with-hyphens.ftl2
-rw-r--r--tests/ui-fulldeps/fluent-messages/missing-crate-name.ftl2
-rw-r--r--tests/ui-fulldeps/fluent-messages/missing-message-ref.ftl2
-rw-r--r--tests/ui-fulldeps/fluent-messages/missing-message.ftl2
-rw-r--r--tests/ui-fulldeps/fluent-messages/slug-with-hyphens.ftl2
-rw-r--r--tests/ui-fulldeps/fluent-messages/test.rs69
-rw-r--r--tests/ui-fulldeps/fluent-messages/test.stderr97
-rw-r--r--tests/ui-fulldeps/fluent-messages/valid.ftl2
-rw-r--r--tests/ui-fulldeps/internal-lints/diagnostics.ftl5
-rw-r--r--tests/ui-fulldeps/internal-lints/diagnostics.rs16
-rw-r--r--tests/ui-fulldeps/internal-lints/diagnostics.stderr12
-rw-r--r--tests/ui-fulldeps/mod_dir_path_canonicalized.rs5
-rw-r--r--tests/ui-fulldeps/pprust-expr-roundtrip.rs16
-rw-r--r--tests/ui-fulldeps/rename-directory.rs30
-rw-r--r--tests/ui-fulldeps/session-diagnostic/diagnostic-derive.rs298
-rw-r--r--tests/ui-fulldeps/session-diagnostic/diagnostic-derive.stderr338
-rw-r--r--tests/ui-fulldeps/session-diagnostic/example.ftl5
-rw-r--r--tests/ui-fulldeps/session-diagnostic/subdiagnostic-derive.rs152
-rw-r--r--tests/ui-fulldeps/session-diagnostic/subdiagnostic-derive.stderr264
-rw-r--r--tests/ui-fulldeps/std/issue-15149.rs (renamed from tests/ui-fulldeps/issue-15149.rs)0
-rw-r--r--tests/ui-fulldeps/std/issue-81357-unsound-file-methods.rs (renamed from tests/ui-fulldeps/issue-81357-unsound-file-methods.rs)0
-rw-r--r--tests/ui-fulldeps/std/stdio-from.rs (renamed from tests/ui-fulldeps/stdio-from.rs)0
-rw-r--r--tests/ui-fulldeps/std/switch-stdout.rs (renamed from tests/ui-fulldeps/switch-stdout.rs)0
-rw-r--r--tests/ui/alloc-error/alloc-error-handler-bad-signature-3.stderr5
-rw-r--r--tests/ui/argument-suggestions/extra_arguments.rs8
-rw-r--r--tests/ui/argument-suggestions/extra_arguments.stderr69
-rw-r--r--tests/ui/argument-suggestions/issue-100154.stderr2
-rw-r--r--tests/ui/argument-suggestions/too-long.stderr2
-rw-r--r--tests/ui/associated-consts/issue-105330.stderr2
-rw-r--r--tests/ui/associated-type-bounds/bad-universal-in-dyn-in-where-clause.rs14
-rw-r--r--tests/ui/associated-type-bounds/bad-universal-in-dyn-in-where-clause.stderr8
-rw-r--r--tests/ui/associated-type-bounds/bad-universal-in-impl-sig.rs13
-rw-r--r--tests/ui/associated-type-bounds/bad-universal-in-impl-sig.stderr8
-rw-r--r--tests/ui/associated-type-bounds/inside-adt.rs22
-rw-r--r--tests/ui/associated-type-bounds/inside-adt.stderr105
-rw-r--r--tests/ui/associated-types/associated-type-projection-from-supertrait.stderr4
-rw-r--r--tests/ui/associated-types/associated-types-eq-hr.stderr4
-rw-r--r--tests/ui/associated-types/defaults-suitability.stderr6
-rw-r--r--tests/ui/associated-types/hr-associated-type-bound-1.stderr2
-rw-r--r--tests/ui/associated-types/hr-associated-type-bound-object.stderr2
-rw-r--r--tests/ui/associated-types/hr-associated-type-bound-param-1.stderr2
-rw-r--r--tests/ui/associated-types/hr-associated-type-bound-param-2.stderr6
-rw-r--r--tests/ui/associated-types/hr-associated-type-bound-param-3.stderr2
-rw-r--r--tests/ui/associated-types/hr-associated-type-bound-param-4.stderr2
-rw-r--r--tests/ui/associated-types/hr-associated-type-bound-param-5.stderr4
-rw-r--r--tests/ui/associated-types/hr-associated-type-projection-1.stderr2
-rw-r--r--tests/ui/associated-types/point-at-type-on-obligation-failure-2.stderr4
-rw-r--r--tests/ui/async-await/in-trait/fn-not-async-err2.rs2
-rw-r--r--tests/ui/async-await/in-trait/fn-not-async-err2.stderr2
-rw-r--r--tests/ui/async-await/issues/issue-62097.rs2
-rw-r--r--tests/ui/async-await/issues/issue-62097.stderr6
-rw-r--r--tests/ui/async-await/issues/issue-65159.rs2
-rw-r--r--tests/ui/async-await/issues/issue-65159.stderr2
-rw-r--r--tests/ui/async-await/issues/issue-72312.stderr6
-rw-r--r--tests/ui/attributes/invalid_macro_export_argument.rs26
-rw-r--r--tests/ui/attributes/invalid_macro_export_argument.stderr16
-rw-r--r--tests/ui/auto-traits/auto-trait-validation.stderr6
-rw-r--r--tests/ui/auto-traits/issue-23080-2.stderr2
-rw-r--r--tests/ui/auto-traits/issue-23080.stderr2
-rw-r--r--tests/ui/auto-traits/issue-84075.stderr2
-rw-r--r--tests/ui/auto-traits/str-contains-slice-conceptually.rs13
-rw-r--r--tests/ui/auto-traits/str-contains-slice-conceptually.stderr16
-rw-r--r--tests/ui/auto-traits/typeck-auto-trait-no-supertraits-2.stderr4
-rw-r--r--tests/ui/auto-traits/typeck-auto-trait-no-supertraits.stderr2
-rw-r--r--tests/ui/borrowck/issue-103624.rs2
-rw-r--r--tests/ui/borrowck/issue-103624.stderr6
-rw-r--r--tests/ui/borrowck/issue-82126-mismatched-subst-and-hir.rs4
-rw-r--r--tests/ui/borrowck/issue-82126-mismatched-subst-and-hir.stderr4
-rw-r--r--tests/ui/closure-expected-type/expect-infer-var-appearing-twice.stderr2
-rw-r--r--tests/ui/const-generics/defaults/wfness.stderr2
-rw-r--r--tests/ui/const-generics/ensure_is_evaluatable.stderr2
-rw-r--r--tests/ui/const-generics/fn_with_two_const_inputs.stderr2
-rw-r--r--tests/ui/const-generics/generic_const_exprs/issue-102768.rs4
-rw-r--r--tests/ui/const-generics/generic_const_exprs/issue-102768.stderr4
-rw-r--r--tests/ui/const-generics/generic_const_exprs/issue-105608.stderr2
-rw-r--r--tests/ui/const-generics/generic_const_exprs/issue-72819-generic-in-const-eval.full.stderr4
-rw-r--r--tests/ui/const-generics/generic_const_exprs/issue-76595.stderr2
-rw-r--r--tests/ui/const-generics/generic_const_exprs/obligation-cause.stderr2
-rw-r--r--tests/ui/const-generics/incorrect-number-of-const-args.stderr4
-rw-r--r--tests/ui/const-generics/infer/method-chain.stderr2
-rw-r--r--tests/ui/const-generics/infer/uninferred-consts.stderr2
-rw-r--r--tests/ui/const-generics/invalid-const-arg-for-type-param.rs4
-rw-r--r--tests/ui/const-generics/invalid-const-arg-for-type-param.stderr4
-rw-r--r--tests/ui/const-generics/invalid-constant-in-args.rs2
-rw-r--r--tests/ui/const-generics/invalid-constant-in-args.stderr2
-rw-r--r--tests/ui/const-generics/issues/issue-67185-2.stderr8
-rw-r--r--tests/ui/const-generics/issues/issue-73260.stderr4
-rw-r--r--tests/ui/const-generics/issues/issue-79674.stderr2
-rw-r--r--tests/ui/const-generics/issues/issue-86530.stderr2
-rw-r--r--tests/ui/const-generics/issues/issue-87493.rs2
-rw-r--r--tests/ui/const-generics/issues/issue-87493.stderr2
-rw-r--r--tests/ui/const-generics/occurs-check/unused-substs-1.stderr2
-rw-r--r--tests/ui/const-generics/parser-error-recovery/issue-89013-no-kw.rs2
-rw-r--r--tests/ui/const-generics/parser-error-recovery/issue-89013-no-kw.stderr2
-rw-r--r--tests/ui/const-generics/parser-error-recovery/issue-89013.rs2
-rw-r--r--tests/ui/const-generics/parser-error-recovery/issue-89013.stderr2
-rw-r--r--tests/ui/const-generics/unify_with_nested_expr.stderr2
-rw-r--r--tests/ui/constructor-lifetime-args.rs8
-rw-r--r--tests/ui/constructor-lifetime-args.stderr8
-rw-r--r--tests/ui/consts/const-eval/validate_uninhabited_zsts.32bit.stderr10
-rw-r--r--tests/ui/consts/const-eval/validate_uninhabited_zsts.64bit.stderr10
-rw-r--r--tests/ui/consts/ct-var-in-collect_all_mismatches.stderr2
-rw-r--r--tests/ui/consts/gate-do-not-const-check.rs5
-rw-r--r--tests/ui/consts/gate-do-not-const-check.stderr11
-rw-r--r--tests/ui/deprecation/deprecation-lint.rs96
-rw-r--r--tests/ui/deprecation/deprecation-lint.stderr140
-rw-r--r--tests/ui/deprecation/issue-84637-deprecated-associated-function.fixed4
-rw-r--r--tests/ui/deprecation/issue-84637-deprecated-associated-function.rs4
-rw-r--r--tests/ui/deprecation/issue-84637-deprecated-associated-function.stderr8
-rw-r--r--tests/ui/deprecation/suggestion.stderr4
-rw-r--r--tests/ui/error-codes/E0107.rs20
-rw-r--r--tests/ui/error-codes/E0107.stderr20
-rw-r--r--tests/ui/error-codes/E0476.rs13
-rw-r--r--tests/ui/error-codes/E0476.stderr31
-rw-r--r--tests/ui/error-codes/E0624.rs2
-rw-r--r--tests/ui/error-codes/E0624.stderr6
-rw-r--r--tests/ui/explore-issue-38412.stderr36
-rw-r--r--tests/ui/expr/malformed_closure/missing_braces_around_block.fixed9
-rw-r--r--tests/ui/expr/malformed_closure/missing_braces_around_block.rs9
-rw-r--r--tests/ui/expr/malformed_closure/missing_braces_around_block.stderr33
-rw-r--r--tests/ui/feature-gates/feature-gate-associated_type_bounds.stderr6
-rw-r--r--tests/ui/feature-gates/feature-gate-impl_trait_in_fn_trait_return.stderr4
-rw-r--r--tests/ui/feature-gates/feature-gate-return_position_impl_trait_in_trait.stderr6
-rw-r--r--tests/ui/fn/issue-3044.stderr2
-rw-r--r--tests/ui/generator/generator-yielding-or-returning-itself.stderr4
-rw-r--r--tests/ui/generator/issue-102645.stderr2
-rw-r--r--tests/ui/generic-associated-types/bugs/issue-88460.stderr2
-rw-r--r--tests/ui/generic-associated-types/gat-trait-path-parenthesised-args.rs6
-rw-r--r--tests/ui/generic-associated-types/gat-trait-path-parenthesised-args.stderr6
-rw-r--r--tests/ui/generic-associated-types/issue-101020.stderr2
-rw-r--r--tests/ui/generic-associated-types/method-unsatisfied-assoc-type-predicate.rs (renamed from tests/ui/generic-associated-types/method-unsatified-assoc-type-predicate.rs)0
-rw-r--r--tests/ui/generic-associated-types/method-unsatisfied-assoc-type-predicate.stderr (renamed from tests/ui/generic-associated-types/method-unsatified-assoc-type-predicate.stderr)4
-rw-r--r--tests/ui/generic-associated-types/missing_lifetime_args.rs4
-rw-r--r--tests/ui/generic-associated-types/missing_lifetime_args.stderr4
-rw-r--r--tests/ui/generic-associated-types/missing_lifetime_const.rs2
-rw-r--r--tests/ui/generic-associated-types/missing_lifetime_const.stderr2
-rw-r--r--tests/ui/generic-associated-types/parameter_number_and_kind.rs6
-rw-r--r--tests/ui/generic-associated-types/parameter_number_and_kind.stderr6
-rw-r--r--tests/ui/generic-associated-types/parse/trait-path-type-error-once-implemented.rs4
-rw-r--r--tests/ui/generic-associated-types/parse/trait-path-type-error-once-implemented.stderr4
-rw-r--r--tests/ui/generic-associated-types/unsatisfied-item-lifetime-bound.rs (renamed from tests/ui/generic-associated-types/unsatified-item-lifetime-bound.rs)2
-rw-r--r--tests/ui/generic-associated-types/unsatisfied-item-lifetime-bound.stderr (renamed from tests/ui/generic-associated-types/unsatified-item-lifetime-bound.stderr)19
-rw-r--r--tests/ui/generics/bad-mid-path-type-params.rs10
-rw-r--r--tests/ui/generics/bad-mid-path-type-params.stderr10
-rw-r--r--tests/ui/generics/generic-arg-mismatch-recover.rs6
-rw-r--r--tests/ui/generics/generic-arg-mismatch-recover.stderr6
-rw-r--r--tests/ui/generics/generic-impl-less-params-with-defaults.rs2
-rw-r--r--tests/ui/generics/generic-impl-less-params-with-defaults.stderr2
-rw-r--r--tests/ui/generics/generic-impl-more-params-with-defaults.rs2
-rw-r--r--tests/ui/generics/generic-impl-more-params-with-defaults.stderr2
-rw-r--r--tests/ui/generics/generic-type-more-params-with-defaults.rs2
-rw-r--r--tests/ui/generics/generic-type-more-params-with-defaults.stderr2
-rw-r--r--tests/ui/generics/wrong-number-of-args.rs106
-rw-r--r--tests/ui/generics/wrong-number-of-args.stderr106
-rw-r--r--tests/ui/higher-rank-trait-bounds/hrtb-higher-ranker-supertraits-transitive.stderr2
-rw-r--r--tests/ui/higher-rank-trait-bounds/hrtb-higher-ranker-supertraits.stderr4
-rw-r--r--tests/ui/higher-rank-trait-bounds/issue-62203-hrtb-ice.stderr4
-rw-r--r--tests/ui/higher-rank-trait-bounds/normalize-under-binder/issue-89118.stderr6
-rw-r--r--tests/ui/higher-rank-trait-bounds/normalize-under-binder/issue-90950.stderr2
-rw-r--r--tests/ui/higher-rank-trait-bounds/normalize-under-binder/norm-before-method-resolution.stderr2
-rw-r--r--tests/ui/impl-trait/equal-hidden-lifetimes.rs1
-rw-r--r--tests/ui/impl-trait/equal-hidden-lifetimes.stderr10
-rw-r--r--tests/ui/impl-trait/explicit-generic-args-with-impl-trait/explicit-generic-args-for-impl.stderr2
-rw-r--r--tests/ui/impl-trait/explicit-generic-args-with-impl-trait/not-enough-args.stderr2
-rw-r--r--tests/ui/impl-trait/in-trait/default-method-constraint.rs17
-rw-r--r--tests/ui/impl-trait/in-trait/default-method-constraint.stderr11
-rw-r--r--tests/ui/impl-trait/issues/issue-54600.stderr2
-rw-r--r--tests/ui/impl-trait/issues/issue-54840.stderr2
-rw-r--r--tests/ui/impl-trait/issues/issue-58504.stderr2
-rw-r--r--tests/ui/impl-trait/issues/issue-58956.stderr4
-rw-r--r--tests/ui/impl-trait/issues/issue-70971.stderr2
-rw-r--r--tests/ui/impl-trait/issues/issue-79099.stderr2
-rw-r--r--tests/ui/impl-trait/issues/issue-83929-impl-trait-in-generic-default.stderr4
-rw-r--r--tests/ui/impl-trait/issues/issue-84919.stderr2
-rw-r--r--tests/ui/impl-trait/issues/issue-86642.stderr2
-rw-r--r--tests/ui/impl-trait/issues/issue-87295.stderr2
-rw-r--r--tests/ui/impl-trait/nested_impl_trait.stderr2
-rw-r--r--tests/ui/impl-trait/normalize-tait-in-const.rs1
-rw-r--r--tests/ui/impl-trait/normalize-tait-in-const.stderr2
-rw-r--r--tests/ui/impl-trait/where-allowed.stderr78
-rw-r--r--tests/ui/implied-bounds/issue-100690.stderr2
-rw-r--r--tests/ui/inference/inference_unstable.rs8
-rw-r--r--tests/ui/inference/inference_unstable.stderr8
-rw-r--r--tests/ui/inference/inference_unstable_featured.stderr4
-rw-r--r--tests/ui/inference/issue-71732.stderr2
-rw-r--r--tests/ui/inference/question-mark-type-infer.stderr2
-rw-r--r--tests/ui/infinite/auxiliary/alias.rs2
-rw-r--r--tests/ui/infinite/infinite-alias.rs9
-rw-r--r--tests/ui/infinite/infinite-alias.stderr14
-rw-r--r--tests/ui/issues/issue-106755.rs19
-rw-r--r--tests/ui/issues/issue-106755.stderr22
-rw-r--r--tests/ui/issues/issue-11374.stderr2
-rw-r--r--tests/ui/issues/issue-17337.stderr2
-rw-r--r--tests/ui/issues/issue-18423.rs2
-rw-r--r--tests/ui/issues/issue-18423.stderr2
-rw-r--r--tests/ui/issues/issue-18446.stderr2
-rw-r--r--tests/ui/issues/issue-21202.rs2
-rw-r--r--tests/ui/issues/issue-21202.stderr6
-rw-r--r--tests/ui/issues/issue-23041.stderr2
-rw-r--r--tests/ui/issues/issue-26094.rs5
-rw-r--r--tests/ui/issues/issue-26094.stderr5
-rw-r--r--tests/ui/issues/issue-30438-c.rs1
-rw-r--r--tests/ui/issues/issue-30438-c.stderr12
-rw-r--r--tests/ui/issues/issue-3214.rs2
-rw-r--r--tests/ui/issues/issue-3214.stderr2
-rw-r--r--tests/ui/issues/issue-3702-2.stderr4
-rw-r--r--tests/ui/issues/issue-3763.rs4
-rw-r--r--tests/ui/issues/issue-3763.stderr12
-rw-r--r--tests/ui/issues/issue-47715.stderr8
-rw-r--r--tests/ui/issues/issue-48364.stderr2
-rw-r--r--tests/ui/issues/issue-53251.rs4
-rw-r--r--tests/ui/issues/issue-53251.stderr4
-rw-r--r--tests/ui/issues/issue-60218.stderr2
-rw-r--r--tests/ui/issues/issue-60622.rs2
-rw-r--r--tests/ui/issues/issue-60622.stderr4
-rw-r--r--tests/ui/issues/issue-65634-raw-ident-suggestion.edition2015.stderr4
-rw-r--r--tests/ui/issues/issue-65634-raw-ident-suggestion.edition2018.stderr4
-rw-r--r--tests/ui/issues/issue-69455.stderr4
-rw-r--r--tests/ui/issues/issue-69683.stderr2
-rw-r--r--tests/ui/issues/issue-70093/issue-70093-link-directives.rs10
-rw-r--r--tests/ui/issues/issue-70093/issue-70093.rs (renamed from tests/ui/issues/issue-70093.rs)0
-rw-r--r--tests/ui/lang-items/bad-add-impl.rs18
-rw-r--r--tests/ui/lang-items/bad-add-impl.stderr11
-rw-r--r--tests/ui/lang-items/fn-fn_mut-call-ill-formed.bad_item.stderr18
-rw-r--r--tests/ui/lang-items/fn-fn_mut-call-ill-formed.bad_sig.stderr18
-rw-r--r--tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_bad_item.stderr18
-rw-r--r--tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_bad_sig.stderr18
-rw-r--r--tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_mut_bad_item.stderr18
-rw-r--r--tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_mut_bad_sig.stderr18
-rw-r--r--tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_once_bad_item.stderr18
-rw-r--r--tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_once_bad_sig.stderr18
-rw-r--r--tests/ui/lang-items/fn-fn_mut-call-ill-formed.rs34
-rw-r--r--tests/ui/lang-items/fn-fn_mut-call-ill-formed.stderr14
-rw-r--r--tests/ui/lang-items/issue-86238.stderr2
-rw-r--r--tests/ui/late-bound-lifetimes/mismatched_arg_count.rs2
-rw-r--r--tests/ui/late-bound-lifetimes/mismatched_arg_count.stderr2
-rw-r--r--tests/ui/lifetimes/lifetime-errors/ex1-return-one-existing-name-return-type-is-anon.stderr2
-rw-r--r--tests/ui/lifetimes/lifetime-errors/ex1-return-one-existing-name-self-is-anon.stderr2
-rw-r--r--tests/ui/lifetimes/lifetime-errors/ex3-both-anon-regions-return-type-is-anon.stderr2
-rw-r--r--tests/ui/lifetimes/lifetime-errors/ex3-both-anon-regions-self-is-anon.stderr2
-rw-r--r--tests/ui/lint/dead-code/in-closure.rs16
-rw-r--r--tests/ui/lint/dead-code/in-closure.stderr20
-rw-r--r--tests/ui/lint/dead-code/issue-85255.rs12
-rw-r--r--tests/ui/lint/dead-code/issue-85255.stderr12
-rw-r--r--tests/ui/lint/dead-code/lint-dead-code-3.rs2
-rw-r--r--tests/ui/lint/dead-code/lint-dead-code-3.stderr2
-rw-r--r--tests/ui/lint/invalid_value.stderr40
-rw-r--r--tests/ui/lint/issue-106991.rs13
-rw-r--r--tests/ui/lint/issue-106991.stderr11
-rw-r--r--tests/ui/lint/lint-missing-doc.rs6
-rw-r--r--tests/ui/lint/lint-missing-doc.stderr46
-rw-r--r--tests/ui/lint/lint-stability-deprecated.rs144
-rw-r--r--tests/ui/lint/lint-stability-deprecated.stderr224
-rw-r--r--tests/ui/lint/lint_map_unit_fn.rs20
-rw-r--r--tests/ui/lint/lint_map_unit_fn.stderr66
-rw-r--r--tests/ui/match/match-ref-mut-invariance.stderr2
-rw-r--r--tests/ui/match/match-ref-mut-let-invariance.stderr2
-rw-r--r--tests/ui/methods/issues/issue-105732.stderr2
-rw-r--r--tests/ui/methods/issues/issue-61525.stderr2
-rw-r--r--tests/ui/methods/method-ambig-two-traits-cross-crate.stderr4
-rw-r--r--tests/ui/methods/method-ambig-two-traits-from-bounds.stderr4
-rw-r--r--tests/ui/methods/method-ambig-two-traits-from-impls.stderr4
-rw-r--r--tests/ui/methods/method-ambig-two-traits-with-default-method.stderr4
-rw-r--r--tests/ui/methods/method-call-err-msg.stderr8
-rw-r--r--tests/ui/methods/method-call-lifetime-args-fail.rs8
-rw-r--r--tests/ui/methods/method-call-lifetime-args-fail.stderr16
-rw-r--r--tests/ui/methods/method-deref-to-same-trait-object-with-separate-params.stderr6
-rw-r--r--tests/ui/methods/method-self-arg-1.stderr4
-rw-r--r--tests/ui/mismatched_types/issue-47706.stderr2
-rw-r--r--tests/ui/nll/outlives-suggestion-simple.stderr4
-rw-r--r--tests/ui/object-safety/object-safety-supertrait-mentions-GAT.stderr5
-rw-r--r--tests/ui/privacy/privacy1.rs2
-rw-r--r--tests/ui/privacy/privacy1.stderr6
-rw-r--r--tests/ui/privacy/private-impl-method.rs2
-rw-r--r--tests/ui/privacy/private-impl-method.stderr6
-rw-r--r--tests/ui/privacy/private-method-cross-crate.rs2
-rw-r--r--tests/ui/privacy/private-method-cross-crate.stderr6
-rw-r--r--tests/ui/privacy/private-method-inherited.rs2
-rw-r--r--tests/ui/privacy/private-method-inherited.stderr6
-rw-r--r--tests/ui/privacy/private-method.rs2
-rw-r--r--tests/ui/privacy/private-method.stderr6
-rw-r--r--tests/ui/privacy/restricted/test.stderr18
-rw-r--r--tests/ui/recursion_limit/issue-105700.rs (renamed from tests/ui/recursion_limit/issue_21102.rs)0
-rw-r--r--tests/ui/recursion_limit/issue-105700.stderr (renamed from tests/ui/recursion_limit/issue_21102.stderr)4
-rw-r--r--tests/ui/regions/regions-early-bound-error-method.stderr2
-rw-r--r--tests/ui/regions/regions-free-region-ordering-incorrect.stderr2
-rw-r--r--tests/ui/regions/regions-free-region-outlives-static-outlives-free-region.rs2
-rw-r--r--tests/ui/regions/regions-free-region-outlives-static-outlives-free-region.stderr7
-rw-r--r--tests/ui/regions/regions-static-bound-rpass.rs2
-rw-r--r--tests/ui/regions/regions-static-bound-rpass.stderr11
-rw-r--r--tests/ui/regions/regions-static-bound.rs8
-rw-r--r--tests/ui/regions/regions-static-bound.stderr30
-rw-r--r--tests/ui/regions/resolve-re-error-ice.rs22
-rw-r--r--tests/ui/regions/resolve-re-error-ice.stderr15
-rw-r--r--tests/ui/rfc-2091-track-caller/error-with-main.stderr2
-rw-r--r--tests/ui/rfc-2457/mod_file_nonascii_forbidden.stderr2
-rw-r--r--tests/ui/rfc-2632-const-trait-impl/do-not-const-check-override.rs19
-rw-r--r--tests/ui/rfc-2632-const-trait-impl/do-not-const-check.rs18
-rw-r--r--tests/ui/self/arbitrary_self_types_pin_lifetime_mismatch-async.stderr6
-rw-r--r--tests/ui/self/arbitrary_self_types_pin_lifetime_mismatch.stderr6
-rw-r--r--tests/ui/self/elision/lt-ref-self-async.stderr12
-rw-r--r--tests/ui/self/elision/lt-ref-self.stderr12
-rw-r--r--tests/ui/self/elision/ref-mut-self-async.stderr12
-rw-r--r--tests/ui/self/elision/ref-mut-self.stderr12
-rw-r--r--tests/ui/self/elision/ref-mut-struct-async.stderr10
-rw-r--r--tests/ui/self/elision/ref-mut-struct.stderr10
-rw-r--r--tests/ui/self/elision/ref-self-async.stderr14
-rw-r--r--tests/ui/self/elision/ref-self.stderr14
-rw-r--r--tests/ui/self/elision/ref-struct-async.stderr10
-rw-r--r--tests/ui/self/elision/ref-struct.stderr10
-rw-r--r--tests/ui/seq-args.rs4
-rw-r--r--tests/ui/seq-args.stderr4
-rw-r--r--tests/ui/span/issue-37767.stderr12
-rw-r--r--tests/ui/span/issue-42234-unknown-receiver-type.full.stderr2
-rw-r--r--tests/ui/span/issue-42234-unknown-receiver-type.generic_arg.stderr2
-rw-r--r--tests/ui/span/missing-unit-argument.stderr4
-rw-r--r--tests/ui/span/type-annotations-needed-expr.stderr2
-rw-r--r--tests/ui/stability-attribute/unresolved_stability_lint.rs8
-rw-r--r--tests/ui/stability-attribute/unresolved_stability_lint.stderr9
-rw-r--r--tests/ui/static/static-lifetime-bound.rs2
-rw-r--r--tests/ui/static/static-lifetime-bound.stderr10
-rw-r--r--tests/ui/statics/uninhabited-static.stderr10
-rw-r--r--tests/ui/stats/hir-stats.stderr208
-rw-r--r--tests/ui/structs/struct-path-associated-type.rs4
-rw-r--r--tests/ui/structs/struct-path-associated-type.stderr4
-rw-r--r--tests/ui/structs/structure-constructor-type-mismatch.rs4
-rw-r--r--tests/ui/structs/structure-constructor-type-mismatch.stderr4
-rw-r--r--tests/ui/suggestions/assoc-ct-for-assoc-method.stderr2
-rw-r--r--tests/ui/suggestions/fn-or-tuple-struct-without-args.stderr8
-rw-r--r--tests/ui/suggestions/imm-ref-trait-object-literal-bound-regions.stderr2
-rw-r--r--tests/ui/suggestions/issue-101421.rs2
-rw-r--r--tests/ui/suggestions/issue-101421.stderr4
-rw-r--r--tests/ui/suggestions/issue-104287.rs2
-rw-r--r--tests/ui/suggestions/issue-104287.stderr4
-rw-r--r--tests/ui/suggestions/issue-84973.stderr2
-rw-r--r--tests/ui/suggestions/issue-85347.rs2
-rw-r--r--tests/ui/suggestions/issue-85347.stderr2
-rw-r--r--tests/ui/suggestions/issue-89064.stderr8
-rw-r--r--tests/ui/suggestions/missing-lifetime-specifier.rs20
-rw-r--r--tests/ui/suggestions/missing-lifetime-specifier.stderr20
-rw-r--r--tests/ui/suggestions/missing-type-param-used-in-param.stderr2
-rw-r--r--tests/ui/suggestions/move-generic-to-trait-in-method-with-params.rs2
-rw-r--r--tests/ui/suggestions/move-generic-to-trait-in-method-with-params.stderr4
-rw-r--r--tests/ui/suggestions/sugg-else-for-closure.stderr2
-rw-r--r--tests/ui/suggestions/trait-with-missing-associated-type-restriction.stderr2
-rw-r--r--tests/ui/suggestions/type-ascription-instead-of-path-in-type.stderr2
-rw-r--r--tests/ui/suggestions/use-type-argument-instead-of-assoc-type.rs2
-rw-r--r--tests/ui/suggestions/use-type-argument-instead-of-assoc-type.stderr2
-rw-r--r--tests/ui/tool-attributes/auxiliary/p1.rs3
-rw-r--r--tests/ui/tool-attributes/auxiliary/p2.rs3
-rw-r--r--tests/ui/tool-attributes/duplicate-diagnostic.rs13
-rw-r--r--tests/ui/tool-attributes/duplicate-diagnostic.stderr12
-rw-r--r--tests/ui/traits/alias/ambiguous.stderr4
-rw-r--r--tests/ui/traits/inductive-overflow/supertrait-auto-trait.stderr2
-rw-r--r--tests/ui/traits/issue-52893.stderr2
-rw-r--r--tests/ui/traits/issue-77982.stderr4
-rw-r--r--tests/ui/traits/item-privacy.rs4
-rw-r--r--tests/ui/traits/item-privacy.stderr12
-rw-r--r--tests/ui/traits/method-private.stderr6
-rw-r--r--tests/ui/traits/multidispatch-convert-ambig-dest.stderr2
-rw-r--r--tests/ui/traits/new-solver/higher-ranked-dyn-bounds.rs17
-rw-r--r--tests/ui/traits/new-solver/more-object-bound.rs27
-rw-r--r--tests/ui/traits/new-solver/more-object-bound.stderr19
-rw-r--r--tests/ui/traits/new-solver/object-unsafety.rs20
-rw-r--r--tests/ui/traits/new-solver/object-unsafety.stderr19
-rw-r--r--tests/ui/traits/non_lifetime_binders/bad-sized-cond.stderr6
-rw-r--r--tests/ui/traits/non_lifetime_binders/fail.stderr4
-rw-r--r--tests/ui/traits/non_lifetime_binders/type-match-with-late-bound.rs14
-rw-r--r--tests/ui/traits/non_lifetime_binders/type-match-with-late-bound.stderr11
-rw-r--r--tests/ui/traits/object/enforce-supertrait-projection.stderr2
-rw-r--r--tests/ui/traits/object/vs-lifetime.rs4
-rw-r--r--tests/ui/traits/object/vs-lifetime.stderr4
-rw-r--r--tests/ui/traits/test-2.rs4
-rw-r--r--tests/ui/traits/test-2.stderr8
-rw-r--r--tests/ui/transmutability/arrays/should_require_well_defined_layout.stderr12
-rw-r--r--tests/ui/transmutability/enums/repr/primitive_reprs_should_have_correct_length.stderr40
-rw-r--r--tests/ui/transmutability/enums/repr/should_require_well_defined_layout.stderr12
-rw-r--r--tests/ui/transmutability/enums/should_pad_variants.stderr2
-rw-r--r--tests/ui/transmutability/enums/should_respect_endianness.stderr2
-rw-r--r--tests/ui/transmutability/issue-101739-2.rs2
-rw-r--r--tests/ui/transmutability/issue-101739-2.stderr2
-rw-r--r--tests/ui/transmutability/primitives/bool.stderr2
-rw-r--r--tests/ui/transmutability/primitives/numbers.stderr114
-rw-r--r--tests/ui/transmutability/primitives/unit.stderr2
-rw-r--r--tests/ui/transmutability/references.stderr2
-rw-r--r--tests/ui/transmutability/structs/repr/should_require_well_defined_layout.stderr24
-rw-r--r--tests/ui/transmutability/unions/repr/should_require_well_defined_layout.stderr4
-rw-r--r--tests/ui/transmutability/unions/should_pad_variants.stderr2
-rw-r--r--tests/ui/transmutability/unions/should_reject_contraction.stderr2
-rw-r--r--tests/ui/transmutability/unions/should_reject_disjoint.stderr4
-rw-r--r--tests/ui/transmutability/unions/should_reject_intersecting.stderr4
-rw-r--r--tests/ui/transmutability/visibility/should_reject_if_dst_has_private_field.stderr2
-rw-r--r--tests/ui/transmutability/visibility/should_reject_if_dst_has_private_variant.stderr2
-rw-r--r--tests/ui/transmutability/visibility/should_reject_if_dst_has_unreachable_field.stderr2
-rw-r--r--tests/ui/transmutability/visibility/should_reject_if_dst_has_unreachable_ty.stderr2
-rw-r--r--tests/ui/transmute/transmute-padding-ice.stderr2
-rw-r--r--tests/ui/tuple/wrong_argument_ice-3.stderr2
-rw-r--r--tests/ui/tuple/wrong_argument_ice.stderr2
-rw-r--r--tests/ui/type-alias-enum-variants/enum-variant-generic-args.rs12
-rw-r--r--tests/ui/type-alias-enum-variants/enum-variant-generic-args.stderr12
-rw-r--r--tests/ui/type-alias-impl-trait/bounds-are-checked.rs1
-rw-r--r--tests/ui/type-alias-impl-trait/bounds-are-checked.stderr12
-rw-r--r--tests/ui/type-alias-impl-trait/implied_lifetime_wf_check3.rs3
-rw-r--r--tests/ui/type-alias-impl-trait/implied_lifetime_wf_check3.stderr34
-rw-r--r--tests/ui/type-alias-impl-trait/match-unification.rs14
-rw-r--r--tests/ui/type-alias-impl-trait/type-alias-impl-trait-fn-type.stderr2
-rw-r--r--tests/ui/type-inference/sort_by_key.stderr2
-rw-r--r--tests/ui/type/type-check/point-at-inference-3.fixed2
-rw-r--r--tests/ui/type/type-check/point-at-inference-3.rs2
-rw-r--r--tests/ui/type/type-check/point-at-inference-3.stderr2
-rw-r--r--tests/ui/type/type-check/point-at-inference-4.rs2
-rw-r--r--tests/ui/type/type-check/point-at-inference-4.stderr2
-rw-r--r--tests/ui/type/wrong-call-return-type-due-to-generic-arg.stderr2
-rw-r--r--tests/ui/typeck/bad-type-in-vec-push.stderr4
-rw-r--r--tests/ui/typeck/issue-104513-ice.stderr2
-rw-r--r--tests/ui/typeck/issue-75883.rs4
-rw-r--r--tests/ui/typeck/issue-75883.stderr4
-rw-r--r--tests/ui/typeck/issue-84768.stderr2
-rw-r--r--tests/ui/typeck/lazy-norm/cast-checks-handling-projections.rs6
-rw-r--r--tests/ui/typeck/lazy-norm/cast-checks-handling-projections.stderr9
-rw-r--r--tests/ui/typeck/typeck-builtin-bound-type-parameters.rs12
-rw-r--r--tests/ui/typeck/typeck-builtin-bound-type-parameters.stderr12
-rw-r--r--tests/ui/typeck/typeck_type_placeholder_item.rs4
-rw-r--r--tests/ui/typeck/typeck_type_placeholder_item.stderr34
-rw-r--r--tests/ui/typeck/typeck_type_placeholder_lifetime_1.rs2
-rw-r--r--tests/ui/typeck/typeck_type_placeholder_lifetime_1.stderr2
-rw-r--r--tests/ui/typeck/typeck_type_placeholder_lifetime_2.rs2
-rw-r--r--tests/ui/typeck/typeck_type_placeholder_lifetime_2.stderr2
-rw-r--r--tests/ui/ufcs/ufcs-qpath-missing-params.rs2
-rw-r--r--tests/ui/ufcs/ufcs-qpath-missing-params.stderr4
-rw-r--r--tests/ui/ufcs/ufcs-qpath-self-mismatch.stderr4
-rw-r--r--tests/ui/unboxed-closures/unboxed-closure-sugar-region.rs2
-rw-r--r--tests/ui/unboxed-closures/unboxed-closure-sugar-region.stderr2
-rw-r--r--tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct-1.rs2
-rw-r--r--tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct-1.stderr2
-rw-r--r--tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct.rs2
-rw-r--r--tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct.stderr2
-rw-r--r--tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters-3.rs2
-rw-r--r--tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters-3.stderr2
-rw-r--r--tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters.rs10
-rw-r--r--tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters.stderr10
-rw-r--r--tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-trait.rs2
-rw-r--r--tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-trait.stderr2
-rw-r--r--tests/ui/unboxed-closures/unboxed-closures-infer-fn-once-move-from-projection.stderr2
-rw-r--r--tests/ui/unsized/issue-71659.stderr2
-rw-r--r--tests/ui/where-clauses/higher-ranked-fn-type.quiet.stderr2
-rw-r--r--tests/ui/where-clauses/higher-ranked-fn-type.verbose.stderr2
-rw-r--r--tests/ui/xc-private-method2.rs4
-rw-r--r--tests/ui/xc-private-method2.stderr12
481 files changed, 3965 insertions, 2854 deletions
diff --git a/tests/mir-opt/casts.redundant.InstCombine.diff b/tests/mir-opt/casts.redundant.InstCombine.diff
new file mode 100644
index 00000000000..528a8e5a90f
--- /dev/null
+++ b/tests/mir-opt/casts.redundant.InstCombine.diff
@@ -0,0 +1,25 @@
+- // MIR for `redundant` before InstCombine
++ // MIR for `redundant` after InstCombine
+  
+  fn redundant(_1: *const &u8) -> *const &u8 {
+      debug x => _1;                       // in scope 0 at $DIR/casts.rs:+0:30: +0:31
+      let mut _0: *const &u8;              // return place in scope 0 at $DIR/casts.rs:+0:51: +0:64
+      let mut _2: *const &u8;              // in scope 0 at $DIR/casts.rs:+1:5: +1:55
+      let mut _3: *const &u8;              // in scope 0 at $DIR/casts.rs:+1:36: +1:37
+      scope 1 (inlined generic_cast::<&u8, &u8>) { // at $DIR/casts.rs:6:5: 6:38
+          debug x => _3;                   // in scope 1 at $DIR/casts.rs:10:23: 10:24
+      }
+  
+      bb0: {
+          StorageLive(_2);                 // scope 0 at $DIR/casts.rs:+1:5: +1:55
+          StorageLive(_3);                 // scope 0 at $DIR/casts.rs:+1:36: +1:37
+          _3 = _1;                         // scope 0 at $DIR/casts.rs:+1:36: +1:37
+-         _2 = _3 as *const &u8 (PtrToPtr); // scope 1 at $DIR/casts.rs:11:5: 11:18
++         _2 = _3;                         // scope 1 at $DIR/casts.rs:11:5: 11:18
+          StorageDead(_3);                 // scope 0 at $DIR/casts.rs:+1:37: +1:38
+          _0 = _2;                         // scope 0 at $DIR/casts.rs:+1:5: +1:55
+          StorageDead(_2);                 // scope 0 at $DIR/casts.rs:+2:1: +2:2
+          return;                          // scope 0 at $DIR/casts.rs:+2:2: +2:2
+      }
+  }
+  
diff --git a/tests/mir-opt/casts.redundant.PreCodegen.after.mir b/tests/mir-opt/casts.redundant.PreCodegen.after.mir
new file mode 100644
index 00000000000..21a470ea300
--- /dev/null
+++ b/tests/mir-opt/casts.redundant.PreCodegen.after.mir
@@ -0,0 +1,14 @@
+// MIR for `redundant` after PreCodegen
+
+fn redundant(_1: *const &u8) -> *const &u8 {
+    debug x => _1;                       // in scope 0 at $DIR/casts.rs:+0:30: +0:31
+    let mut _0: *const &u8;              // return place in scope 0 at $DIR/casts.rs:+0:51: +0:64
+    scope 1 (inlined generic_cast::<&u8, &u8>) { // at $DIR/casts.rs:6:5: 6:38
+        debug x => _1;                   // in scope 1 at $DIR/casts.rs:10:23: 10:24
+    }
+
+    bb0: {
+        _0 = _1;                         // scope 0 at $DIR/casts.rs:+1:5: +1:55
+        return;                          // scope 0 at $DIR/casts.rs:+2:2: +2:2
+    }
+}
diff --git a/tests/mir-opt/casts.roundtrip.PreCodegen.after.mir b/tests/mir-opt/casts.roundtrip.PreCodegen.after.mir
new file mode 100644
index 00000000000..0c793984ceb
--- /dev/null
+++ b/tests/mir-opt/casts.roundtrip.PreCodegen.after.mir
@@ -0,0 +1,15 @@
+// MIR for `roundtrip` after PreCodegen
+
+fn roundtrip(_1: *const u8) -> *const u8 {
+    debug x => _1;                       // in scope 0 at $DIR/casts.rs:+0:18: +0:19
+    let mut _0: *const u8;               // return place in scope 0 at $DIR/casts.rs:+0:35: +0:44
+    let mut _2: *mut u8;                 // in scope 0 at $DIR/casts.rs:+1:5: +1:17
+
+    bb0: {
+        StorageLive(_2);                 // scope 0 at $DIR/casts.rs:+1:5: +1:17
+        _2 = _1 as *mut u8 (PtrToPtr);   // scope 0 at $DIR/casts.rs:+1:5: +1:17
+        _0 = move _2 as *const u8 (Pointer(MutToConstPointer)); // scope 0 at $DIR/casts.rs:+1:5: +1:17
+        StorageDead(_2);                 // scope 0 at $DIR/casts.rs:+1:16: +1:17
+        return;                          // scope 0 at $DIR/casts.rs:+2:2: +2:2
+    }
+}
diff --git a/tests/mir-opt/casts.rs b/tests/mir-opt/casts.rs
new file mode 100644
index 00000000000..259c462da3d
--- /dev/null
+++ b/tests/mir-opt/casts.rs
@@ -0,0 +1,17 @@
+#![crate_type = "lib"]
+
+// EMIT_MIR casts.redundant.InstCombine.diff
+// EMIT_MIR casts.redundant.PreCodegen.after.mir
+pub fn redundant<'a, 'b: 'a>(x: *const &'a u8) -> *const &'a u8 {
+    generic_cast::<&'a u8, &'b u8>(x) as *const &'a u8
+}
+
+#[inline]
+fn generic_cast<T, U>(x: *const T) -> *const U {
+    x as *const U
+}
+
+// EMIT_MIR casts.roundtrip.PreCodegen.after.mir
+pub fn roundtrip(x: *const u8) -> *const u8 {
+    x as *mut u8 as *const u8
+}
diff --git a/tests/mir-opt/dataflow-const-prop/enum.multiple.DataflowConstProp.diff b/tests/mir-opt/dataflow-const-prop/enum.multiple.DataflowConstProp.diff
new file mode 100644
index 00000000000..c4002d65e5d
--- /dev/null
+++ b/tests/mir-opt/dataflow-const-prop/enum.multiple.DataflowConstProp.diff
@@ -0,0 +1,82 @@
+- // MIR for `multiple` before DataflowConstProp
++ // MIR for `multiple` after DataflowConstProp
+  
+  fn multiple(_1: bool, _2: u8) -> () {
+      debug x => _1;                       // in scope 0 at $DIR/enum.rs:+0:13: +0:14
+      debug i => _2;                       // in scope 0 at $DIR/enum.rs:+0:22: +0:23
+      let mut _0: ();                      // return place in scope 0 at $DIR/enum.rs:+0:29: +0:29
+      let _3: std::option::Option<u8>;     // in scope 0 at $DIR/enum.rs:+1:9: +1:10
+      let mut _4: bool;                    // in scope 0 at $DIR/enum.rs:+1:16: +1:17
+      let mut _5: u8;                      // in scope 0 at $DIR/enum.rs:+2:14: +2:15
+      let mut _7: isize;                   // in scope 0 at $DIR/enum.rs:+9:23: +9:30
+      scope 1 {
+          debug e => _3;                   // in scope 1 at $DIR/enum.rs:+1:9: +1:10
+          let _6: u8;                      // in scope 1 at $DIR/enum.rs:+9:9: +9:10
+          let _8: u8;                      // in scope 1 at $DIR/enum.rs:+9:28: +9:29
+          scope 2 {
+              debug x => _6;               // in scope 2 at $DIR/enum.rs:+9:9: +9:10
+              let _9: u8;                  // in scope 2 at $DIR/enum.rs:+11:9: +11:10
+              scope 4 {
+                  debug y => _9;           // in scope 4 at $DIR/enum.rs:+11:9: +11:10
+              }
+          }
+          scope 3 {
+              debug i => _8;               // in scope 3 at $DIR/enum.rs:+9:28: +9:29
+          }
+      }
+  
+      bb0: {
+          StorageLive(_3);                 // scope 0 at $DIR/enum.rs:+1:9: +1:10
+          StorageLive(_4);                 // scope 0 at $DIR/enum.rs:+1:16: +1:17
+          _4 = _1;                         // scope 0 at $DIR/enum.rs:+1:16: +1:17
+          switchInt(move _4) -> [0: bb2, otherwise: bb1]; // scope 0 at $DIR/enum.rs:+1:16: +1:17
+      }
+  
+      bb1: {
+          StorageLive(_5);                 // scope 0 at $DIR/enum.rs:+2:14: +2:15
+          _5 = _2;                         // scope 0 at $DIR/enum.rs:+2:14: +2:15
+          _3 = Option::<u8>::Some(move _5); // scope 0 at $DIR/enum.rs:+2:9: +2:16
+          StorageDead(_5);                 // scope 0 at $DIR/enum.rs:+2:15: +2:16
+          goto -> bb3;                     // scope 0 at $DIR/enum.rs:+1:13: +5:6
+      }
+  
+      bb2: {
+          _3 = Option::<u8>::None;         // scope 0 at $DIR/enum.rs:+4:9: +4:13
+          goto -> bb3;                     // scope 0 at $DIR/enum.rs:+1:13: +5:6
+      }
+  
+      bb3: {
+          StorageDead(_4);                 // scope 0 at $DIR/enum.rs:+5:5: +5:6
+          StorageLive(_6);                 // scope 1 at $DIR/enum.rs:+9:9: +9:10
+          _7 = discriminant(_3);           // scope 1 at $DIR/enum.rs:+9:19: +9:20
+          switchInt(move _7) -> [0: bb4, 1: bb6, otherwise: bb5]; // scope 1 at $DIR/enum.rs:+9:13: +9:20
+      }
+  
+      bb4: {
+          _6 = const 0_u8;                 // scope 1 at $DIR/enum.rs:+9:45: +9:46
+          goto -> bb7;                     // scope 1 at $DIR/enum.rs:+9:45: +9:46
+      }
+  
+      bb5: {
+          unreachable;                     // scope 1 at $DIR/enum.rs:+9:19: +9:20
+      }
+  
+      bb6: {
+          StorageLive(_8);                 // scope 1 at $DIR/enum.rs:+9:28: +9:29
+          _8 = ((_3 as Some).0: u8);       // scope 1 at $DIR/enum.rs:+9:28: +9:29
+          _6 = _8;                         // scope 3 at $DIR/enum.rs:+9:34: +9:35
+          StorageDead(_8);                 // scope 1 at $DIR/enum.rs:+9:34: +9:35
+          goto -> bb7;                     // scope 1 at $DIR/enum.rs:+9:34: +9:35
+      }
+  
+      bb7: {
+          StorageLive(_9);                 // scope 2 at $DIR/enum.rs:+11:9: +11:10
+          _9 = _6;                         // scope 2 at $DIR/enum.rs:+11:13: +11:14
+          _0 = const ();                   // scope 0 at $DIR/enum.rs:+0:29: +12:2
+          StorageDead(_9);                 // scope 2 at $DIR/enum.rs:+12:1: +12:2
+          StorageDead(_6);                 // scope 1 at $DIR/enum.rs:+12:1: +12:2
+          StorageDead(_3);                 // scope 0 at $DIR/enum.rs:+12:1: +12:2
+          return;                          // scope 0 at $DIR/enum.rs:+12:2: +12:2
+      }
+  }
+  
diff --git a/tests/mir-opt/dataflow-const-prop/enum.rs b/tests/mir-opt/dataflow-const-prop/enum.rs
index 7ea405bd9c4..79a20d7ef45 100644
--- a/tests/mir-opt/dataflow-const-prop/enum.rs
+++ b/tests/mir-opt/dataflow-const-prop/enum.rs
@@ -46,7 +46,23 @@ fn mutate_discriminant() -> u8 {
     )
 }
 
+// EMIT_MIR enum.multiple.DataflowConstProp.diff
+fn multiple(x: bool, i: u8) {
+    let e = if x {
+        Some(i)
+    } else {
+        None
+    };
+    // The dataflow state must have:
+    //   discriminant(e) => Top
+    //   (e as Some).0 => Top
+    let x = match e { Some(i) => i, None => 0 };
+    // Therefore, `x` should be `Top` here, and no replacement shall happen.
+    let y = x;
+}
+
 fn main() {
     simple();
     mutate_discriminant();
+    multiple(false, 5);
 }
diff --git a/tests/mir-opt/dataflow-const-prop/enum.simple.DataflowConstProp.diff b/tests/mir-opt/dataflow-const-prop/enum.simple.DataflowConstProp.diff
index 1fb65e65845..22bdc35d694 100644
--- a/tests/mir-opt/dataflow-const-prop/enum.simple.DataflowConstProp.diff
+++ b/tests/mir-opt/dataflow-const-prop/enum.simple.DataflowConstProp.diff
@@ -45,8 +45,10 @@
   
       bb3: {
           StorageLive(_4);                 // scope 1 at $DIR/enum.rs:+2:29: +2:30
-          _4 = ((_1 as V1).0: i32);        // scope 1 at $DIR/enum.rs:+2:29: +2:30
-          _2 = _4;                         // scope 3 at $DIR/enum.rs:+2:35: +2:36
+-         _4 = ((_1 as V1).0: i32);        // scope 1 at $DIR/enum.rs:+2:29: +2:30
+-         _2 = _4;                         // scope 3 at $DIR/enum.rs:+2:35: +2:36
++         _4 = const 0_i32;                // scope 1 at $DIR/enum.rs:+2:29: +2:30
++         _2 = const 0_i32;                // scope 3 at $DIR/enum.rs:+2:35: +2:36
           StorageDead(_4);                 // scope 1 at $DIR/enum.rs:+2:35: +2:36
           goto -> bb4;                     // scope 1 at $DIR/enum.rs:+2:35: +2:36
       }
diff --git a/tests/mir-opt/issue_41110.main.ElaborateDrops.after.mir b/tests/mir-opt/issue_41110.main.ElaborateDrops.after.mir
deleted file mode 100644
index c2ea3ac502f..00000000000
--- a/tests/mir-opt/issue_41110.main.ElaborateDrops.after.mir
+++ /dev/null
@@ -1,70 +0,0 @@
-// MIR for `main` after ElaborateDrops
-
-fn main() -> () {
-    let mut _0: ();                      // return place in scope 0 at $DIR/issue_41110.rs:+0:11: +0:11
-    let _1: ();                          // in scope 0 at $DIR/issue_41110.rs:+1:9: +1:10
-    let mut _2: S;                       // in scope 0 at $DIR/issue_41110.rs:+1:13: +1:14
-    let mut _3: S;                       // in scope 0 at $DIR/issue_41110.rs:+1:21: +1:27
-    let mut _4: S;                       // in scope 0 at $DIR/issue_41110.rs:+1:21: +1:22
-    let mut _5: bool;                    // in scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
-    scope 1 {
-        debug x => _1;                   // in scope 1 at $DIR/issue_41110.rs:+1:9: +1:10
-    }
-
-    bb0: {
-        _5 = const false;                // scope 0 at $DIR/issue_41110.rs:+1:9: +1:10
-        StorageLive(_1);                 // scope 0 at $DIR/issue_41110.rs:+1:9: +1:10
-        StorageLive(_2);                 // scope 0 at $DIR/issue_41110.rs:+1:13: +1:14
-        _5 = const true;                 // scope 0 at $DIR/issue_41110.rs:+1:13: +1:14
-        _2 = S;                          // scope 0 at $DIR/issue_41110.rs:+1:13: +1:14
-        StorageLive(_3);                 // scope 0 at $DIR/issue_41110.rs:+1:21: +1:27
-        StorageLive(_4);                 // scope 0 at $DIR/issue_41110.rs:+1:21: +1:22
-        _4 = S;                          // scope 0 at $DIR/issue_41110.rs:+1:21: +1:22
-        _3 = S::id(move _4) -> [return: bb1, unwind: bb4]; // scope 0 at $DIR/issue_41110.rs:+1:21: +1:27
-                                         // mir::Constant
-                                         // + span: $DIR/issue_41110.rs:8:23: 8:25
-                                         // + literal: Const { ty: fn(S) -> S {S::id}, val: Value(<ZST>) }
-    }
-
-    bb1: {
-        StorageDead(_4);                 // scope 0 at $DIR/issue_41110.rs:+1:26: +1:27
-        _5 = const false;                // scope 0 at $DIR/issue_41110.rs:+1:13: +1:28
-        _1 = S::other(move _2, move _3) -> [return: bb2, unwind: bb3]; // scope 0 at $DIR/issue_41110.rs:+1:13: +1:28
-                                         // mir::Constant
-                                         // + span: $DIR/issue_41110.rs:8:15: 8:20
-                                         // + literal: Const { ty: fn(S, S) {S::other}, val: Value(<ZST>) }
-    }
-
-    bb2: {
-        StorageDead(_3);                 // scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
-        _5 = const false;                // scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
-        StorageDead(_2);                 // scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
-        _0 = const ();                   // scope 0 at $DIR/issue_41110.rs:+0:11: +2:2
-        StorageDead(_1);                 // scope 0 at $DIR/issue_41110.rs:+2:1: +2:2
-        return;                          // scope 0 at $DIR/issue_41110.rs:+2:2: +2:2
-    }
-
-    bb3 (cleanup): {
-        goto -> bb5;                     // scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
-    }
-
-    bb4 (cleanup): {
-        goto -> bb5;                     // scope 0 at $DIR/issue_41110.rs:+1:26: +1:27
-    }
-
-    bb5 (cleanup): {
-        goto -> bb8;                     // scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
-    }
-
-    bb6 (cleanup): {
-        resume;                          // scope 0 at $DIR/issue_41110.rs:+0:1: +2:2
-    }
-
-    bb7 (cleanup): {
-        drop(_2) -> bb6;                 // scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
-    }
-
-    bb8 (cleanup): {
-        switchInt(_5) -> [0: bb6, otherwise: bb7]; // scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
-    }
-}
diff --git a/tests/mir-opt/issue_41110.main.ElaborateDrops.diff b/tests/mir-opt/issue_41110.main.ElaborateDrops.diff
new file mode 100644
index 00000000000..7ac75b51a37
--- /dev/null
+++ b/tests/mir-opt/issue_41110.main.ElaborateDrops.diff
@@ -0,0 +1,75 @@
+- // MIR for `main` before ElaborateDrops
++ // MIR for `main` after ElaborateDrops
+  
+  fn main() -> () {
+      let mut _0: ();                      // return place in scope 0 at $DIR/issue_41110.rs:+0:11: +0:11
+      let _1: ();                          // in scope 0 at $DIR/issue_41110.rs:+1:9: +1:10
+      let mut _2: S;                       // in scope 0 at $DIR/issue_41110.rs:+1:13: +1:14
+      let mut _3: S;                       // in scope 0 at $DIR/issue_41110.rs:+1:21: +1:27
+      let mut _4: S;                       // in scope 0 at $DIR/issue_41110.rs:+1:21: +1:22
++     let mut _5: bool;                    // in scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
+      scope 1 {
+          debug x => _1;                   // in scope 1 at $DIR/issue_41110.rs:+1:9: +1:10
+      }
+  
+      bb0: {
++         _5 = const false;                // scope 0 at $DIR/issue_41110.rs:+1:9: +1:10
+          StorageLive(_1);                 // scope 0 at $DIR/issue_41110.rs:+1:9: +1:10
+          StorageLive(_2);                 // scope 0 at $DIR/issue_41110.rs:+1:13: +1:14
++         _5 = const true;                 // scope 0 at $DIR/issue_41110.rs:+1:13: +1:14
+          _2 = S;                          // scope 0 at $DIR/issue_41110.rs:+1:13: +1:14
+          StorageLive(_3);                 // scope 0 at $DIR/issue_41110.rs:+1:21: +1:27
+          StorageLive(_4);                 // scope 0 at $DIR/issue_41110.rs:+1:21: +1:22
+          _4 = S;                          // scope 0 at $DIR/issue_41110.rs:+1:21: +1:22
+          _3 = S::id(move _4) -> [return: bb1, unwind: bb4]; // scope 0 at $DIR/issue_41110.rs:+1:21: +1:27
+                                           // mir::Constant
+                                           // + span: $DIR/issue_41110.rs:8:23: 8:25
+                                           // + literal: Const { ty: fn(S) -> S {S::id}, val: Value(<ZST>) }
+      }
+  
+      bb1: {
+          StorageDead(_4);                 // scope 0 at $DIR/issue_41110.rs:+1:26: +1:27
++         _5 = const false;                // scope 0 at $DIR/issue_41110.rs:+1:13: +1:28
+          _1 = S::other(move _2, move _3) -> [return: bb2, unwind: bb3]; // scope 0 at $DIR/issue_41110.rs:+1:13: +1:28
+                                           // mir::Constant
+                                           // + span: $DIR/issue_41110.rs:8:15: 8:20
+                                           // + literal: Const { ty: fn(S, S) {S::other}, val: Value(<ZST>) }
+      }
+  
+      bb2: {
+          StorageDead(_3);                 // scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
++         _5 = const false;                // scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
+          StorageDead(_2);                 // scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
+          _0 = const ();                   // scope 0 at $DIR/issue_41110.rs:+0:11: +2:2
+          StorageDead(_1);                 // scope 0 at $DIR/issue_41110.rs:+2:1: +2:2
+          return;                          // scope 0 at $DIR/issue_41110.rs:+2:2: +2:2
+      }
+  
+      bb3 (cleanup): {
+-         drop(_3) -> bb5;                 // scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
++         goto -> bb5;                     // scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
+      }
+  
+      bb4 (cleanup): {
+-         drop(_4) -> bb5;                 // scope 0 at $DIR/issue_41110.rs:+1:26: +1:27
++         goto -> bb5;                     // scope 0 at $DIR/issue_41110.rs:+1:26: +1:27
+      }
+  
+      bb5 (cleanup): {
+-         drop(_2) -> bb6;                 // scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
++         goto -> bb8;                     // scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
+      }
+  
+      bb6 (cleanup): {
+          resume;                          // scope 0 at $DIR/issue_41110.rs:+0:1: +2:2
++     }
++ 
++     bb7 (cleanup): {
++         drop(_2) -> bb6;                 // scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
++     }
++ 
++     bb8 (cleanup): {
++         switchInt(_5) -> [0: bb6, otherwise: bb7]; // scope 0 at $DIR/issue_41110.rs:+1:27: +1:28
+      }
+  }
+  
diff --git a/tests/mir-opt/issue_41110.rs b/tests/mir-opt/issue_41110.rs
index 638dc601ec8..e1067ce53e4 100644
--- a/tests/mir-opt/issue_41110.rs
+++ b/tests/mir-opt/issue_41110.rs
@@ -3,14 +3,14 @@
 // check that we don't emit multiple drop flags when they are not needed.
 
 
-// EMIT_MIR issue_41110.main.ElaborateDrops.after.mir
+// EMIT_MIR issue_41110.main.ElaborateDrops.diff
 fn main() {
     let x = S.other(S.id());
 }
 
 // no_mangle to make sure this gets instantiated even in an executable.
 #[no_mangle]
-// EMIT_MIR issue_41110.test.ElaborateDrops.after.mir
+// EMIT_MIR issue_41110.test.ElaborateDrops.diff
 pub fn test() {
     let u = S;
     let mut v = S;
diff --git a/tests/mir-opt/issue_41110.test.ElaborateDrops.after.mir b/tests/mir-opt/issue_41110.test.ElaborateDrops.after.mir
deleted file mode 100644
index 82989c3f071..00000000000
--- a/tests/mir-opt/issue_41110.test.ElaborateDrops.after.mir
+++ /dev/null
@@ -1,101 +0,0 @@
-// MIR for `test` after ElaborateDrops
-
-fn test() -> () {
-    let mut _0: ();                      // return place in scope 0 at $DIR/issue_41110.rs:+0:15: +0:15
-    let _1: S;                           // in scope 0 at $DIR/issue_41110.rs:+1:9: +1:10
-    let _3: ();                          // in scope 0 at $DIR/issue_41110.rs:+3:5: +3:12
-    let mut _4: S;                       // in scope 0 at $DIR/issue_41110.rs:+3:10: +3:11
-    let mut _5: S;                       // in scope 0 at $DIR/issue_41110.rs:+4:9: +4:10
-    let mut _6: bool;                    // in scope 0 at $DIR/issue_41110.rs:+5:1: +5:2
-    scope 1 {
-        debug u => _1;                   // in scope 1 at $DIR/issue_41110.rs:+1:9: +1:10
-        let mut _2: S;                   // in scope 1 at $DIR/issue_41110.rs:+2:9: +2:14
-        scope 2 {
-            debug v => _2;               // in scope 2 at $DIR/issue_41110.rs:+2:9: +2:14
-        }
-    }
-
-    bb0: {
-        _6 = const false;                // scope 0 at $DIR/issue_41110.rs:+1:9: +1:10
-        StorageLive(_1);                 // scope 0 at $DIR/issue_41110.rs:+1:9: +1:10
-        _6 = const true;                 // scope 0 at $DIR/issue_41110.rs:+1:13: +1:14
-        _1 = S;                          // scope 0 at $DIR/issue_41110.rs:+1:13: +1:14
-        StorageLive(_2);                 // scope 1 at $DIR/issue_41110.rs:+2:9: +2:14
-        _2 = S;                          // scope 1 at $DIR/issue_41110.rs:+2:17: +2:18
-        StorageLive(_3);                 // scope 2 at $DIR/issue_41110.rs:+3:5: +3:12
-        StorageLive(_4);                 // scope 2 at $DIR/issue_41110.rs:+3:10: +3:11
-        _4 = move _2;                    // scope 2 at $DIR/issue_41110.rs:+3:10: +3:11
-        _3 = std::mem::drop::<S>(move _4) -> [return: bb1, unwind: bb7]; // scope 2 at $DIR/issue_41110.rs:+3:5: +3:12
-                                         // mir::Constant
-                                         // + span: $DIR/issue_41110.rs:17:5: 17:9
-                                         // + literal: Const { ty: fn(S) {std::mem::drop::<S>}, val: Value(<ZST>) }
-    }
-
-    bb1: {
-        StorageDead(_4);                 // scope 2 at $DIR/issue_41110.rs:+3:11: +3:12
-        StorageDead(_3);                 // scope 2 at $DIR/issue_41110.rs:+3:12: +3:13
-        StorageLive(_5);                 // scope 2 at $DIR/issue_41110.rs:+4:9: +4:10
-        _6 = const false;                // scope 2 at $DIR/issue_41110.rs:+4:9: +4:10
-        _5 = move _1;                    // scope 2 at $DIR/issue_41110.rs:+4:9: +4:10
-        goto -> bb12;                    // scope 2 at $DIR/issue_41110.rs:+4:5: +4:6
-    }
-
-    bb2: {
-        goto -> bb3;                     // scope 2 at $DIR/issue_41110.rs:+4:9: +4:10
-    }
-
-    bb3: {
-        StorageDead(_5);                 // scope 2 at $DIR/issue_41110.rs:+4:9: +4:10
-        _0 = const ();                   // scope 0 at $DIR/issue_41110.rs:+0:15: +5:2
-        drop(_2) -> [return: bb4, unwind: bb9]; // scope 1 at $DIR/issue_41110.rs:+5:1: +5:2
-    }
-
-    bb4: {
-        StorageDead(_2);                 // scope 1 at $DIR/issue_41110.rs:+5:1: +5:2
-        goto -> bb5;                     // scope 0 at $DIR/issue_41110.rs:+5:1: +5:2
-    }
-
-    bb5: {
-        _6 = const false;                // scope 0 at $DIR/issue_41110.rs:+5:1: +5:2
-        StorageDead(_1);                 // scope 0 at $DIR/issue_41110.rs:+5:1: +5:2
-        return;                          // scope 0 at $DIR/issue_41110.rs:+5:2: +5:2
-    }
-
-    bb6 (cleanup): {
-        goto -> bb8;                     // scope 2 at $DIR/issue_41110.rs:+4:9: +4:10
-    }
-
-    bb7 (cleanup): {
-        goto -> bb8;                     // scope 2 at $DIR/issue_41110.rs:+3:11: +3:12
-    }
-
-    bb8 (cleanup): {
-        goto -> bb9;                     // scope 1 at $DIR/issue_41110.rs:+5:1: +5:2
-    }
-
-    bb9 (cleanup): {
-        goto -> bb14;                    // scope 0 at $DIR/issue_41110.rs:+5:1: +5:2
-    }
-
-    bb10 (cleanup): {
-        resume;                          // scope 0 at $DIR/issue_41110.rs:+0:1: +5:2
-    }
-
-    bb11 (cleanup): {
-        _2 = move _5;                    // scope 2 at $DIR/issue_41110.rs:+4:5: +4:6
-        goto -> bb6;                     // scope 2 at $DIR/issue_41110.rs:+4:5: +4:6
-    }
-
-    bb12: {
-        _2 = move _5;                    // scope 2 at $DIR/issue_41110.rs:+4:5: +4:6
-        goto -> bb2;                     // scope 2 at $DIR/issue_41110.rs:+4:5: +4:6
-    }
-
-    bb13 (cleanup): {
-        drop(_1) -> bb10;                // scope 0 at $DIR/issue_41110.rs:+5:1: +5:2
-    }
-
-    bb14 (cleanup): {
-        switchInt(_6) -> [0: bb10, otherwise: bb13]; // scope 0 at $DIR/issue_41110.rs:+5:1: +5:2
-    }
-}
diff --git a/tests/mir-opt/issue_41110.test.ElaborateDrops.diff b/tests/mir-opt/issue_41110.test.ElaborateDrops.diff
new file mode 100644
index 00000000000..79e3d073be5
--- /dev/null
+++ b/tests/mir-opt/issue_41110.test.ElaborateDrops.diff
@@ -0,0 +1,109 @@
+- // MIR for `test` before ElaborateDrops
++ // MIR for `test` after ElaborateDrops
+  
+  fn test() -> () {
+      let mut _0: ();                      // return place in scope 0 at $DIR/issue_41110.rs:+0:15: +0:15
+      let _1: S;                           // in scope 0 at $DIR/issue_41110.rs:+1:9: +1:10
+      let _3: ();                          // in scope 0 at $DIR/issue_41110.rs:+3:5: +3:12
+      let mut _4: S;                       // in scope 0 at $DIR/issue_41110.rs:+3:10: +3:11
+      let mut _5: S;                       // in scope 0 at $DIR/issue_41110.rs:+4:9: +4:10
++     let mut _6: bool;                    // in scope 0 at $DIR/issue_41110.rs:+5:1: +5:2
+      scope 1 {
+          debug u => _1;                   // in scope 1 at $DIR/issue_41110.rs:+1:9: +1:10
+          let mut _2: S;                   // in scope 1 at $DIR/issue_41110.rs:+2:9: +2:14
+          scope 2 {
+              debug v => _2;               // in scope 2 at $DIR/issue_41110.rs:+2:9: +2:14
+          }
+      }
+  
+      bb0: {
++         _6 = const false;                // scope 0 at $DIR/issue_41110.rs:+1:9: +1:10
+          StorageLive(_1);                 // scope 0 at $DIR/issue_41110.rs:+1:9: +1:10
++         _6 = const true;                 // scope 0 at $DIR/issue_41110.rs:+1:13: +1:14
+          _1 = S;                          // scope 0 at $DIR/issue_41110.rs:+1:13: +1:14
+          StorageLive(_2);                 // scope 1 at $DIR/issue_41110.rs:+2:9: +2:14
+          _2 = S;                          // scope 1 at $DIR/issue_41110.rs:+2:17: +2:18
+          StorageLive(_3);                 // scope 2 at $DIR/issue_41110.rs:+3:5: +3:12
+          StorageLive(_4);                 // scope 2 at $DIR/issue_41110.rs:+3:10: +3:11
+          _4 = move _2;                    // scope 2 at $DIR/issue_41110.rs:+3:10: +3:11
+          _3 = std::mem::drop::<S>(move _4) -> [return: bb1, unwind: bb7]; // scope 2 at $DIR/issue_41110.rs:+3:5: +3:12
+                                           // mir::Constant
+                                           // + span: $DIR/issue_41110.rs:17:5: 17:9
+                                           // + literal: Const { ty: fn(S) {std::mem::drop::<S>}, val: Value(<ZST>) }
+      }
+  
+      bb1: {
+          StorageDead(_4);                 // scope 2 at $DIR/issue_41110.rs:+3:11: +3:12
+          StorageDead(_3);                 // scope 2 at $DIR/issue_41110.rs:+3:12: +3:13
+          StorageLive(_5);                 // scope 2 at $DIR/issue_41110.rs:+4:9: +4:10
++         _6 = const false;                // scope 2 at $DIR/issue_41110.rs:+4:9: +4:10
+          _5 = move _1;                    // scope 2 at $DIR/issue_41110.rs:+4:9: +4:10
+-         replace(_2 <- move _5) -> [return: bb2, unwind: bb6]; // scope 2 at $DIR/issue_41110.rs:+4:5: +4:6
++         goto -> bb12;                    // scope 2 at $DIR/issue_41110.rs:+4:5: +4:6
+      }
+  
+      bb2: {
+-         drop(_5) -> [return: bb3, unwind: bb8]; // scope 2 at $DIR/issue_41110.rs:+4:9: +4:10
++         goto -> bb3;                     // scope 2 at $DIR/issue_41110.rs:+4:9: +4:10
+      }
+  
+      bb3: {
+          StorageDead(_5);                 // scope 2 at $DIR/issue_41110.rs:+4:9: +4:10
+          _0 = const ();                   // scope 0 at $DIR/issue_41110.rs:+0:15: +5:2
+          drop(_2) -> [return: bb4, unwind: bb9]; // scope 1 at $DIR/issue_41110.rs:+5:1: +5:2
+      }
+  
+      bb4: {
+          StorageDead(_2);                 // scope 1 at $DIR/issue_41110.rs:+5:1: +5:2
+-         drop(_1) -> bb5;                 // scope 0 at $DIR/issue_41110.rs:+5:1: +5:2
++         goto -> bb5;                     // scope 0 at $DIR/issue_41110.rs:+5:1: +5:2
+      }
+  
+      bb5: {
++         _6 = const false;                // scope 0 at $DIR/issue_41110.rs:+5:1: +5:2
+          StorageDead(_1);                 // scope 0 at $DIR/issue_41110.rs:+5:1: +5:2
+          return;                          // scope 0 at $DIR/issue_41110.rs:+5:2: +5:2
+      }
+  
+      bb6 (cleanup): {
+          drop(_5) -> bb8;                 // scope 2 at $DIR/issue_41110.rs:+4:9: +4:10
+      }
+  
+      bb7 (cleanup): {
+-         drop(_4) -> bb8;                 // scope 2 at $DIR/issue_41110.rs:+3:11: +3:12
++         goto -> bb8;                     // scope 2 at $DIR/issue_41110.rs:+3:11: +3:12
+      }
+  
+      bb8 (cleanup): {
+-         drop(_2) -> bb9;                 // scope 1 at $DIR/issue_41110.rs:+5:1: +5:2
++         goto -> bb9;                     // scope 1 at $DIR/issue_41110.rs:+5:1: +5:2
+      }
+  
+      bb9 (cleanup): {
+-         drop(_1) -> bb10;                // scope 0 at $DIR/issue_41110.rs:+5:1: +5:2
++         goto -> bb14;                    // scope 0 at $DIR/issue_41110.rs:+5:1: +5:2
+      }
+  
+      bb10 (cleanup): {
+          resume;                          // scope 0 at $DIR/issue_41110.rs:+0:1: +5:2
++     }
++ 
++     bb11 (cleanup): {
++         _2 = move _5;                    // scope 2 at $DIR/issue_41110.rs:+4:5: +4:6
++         goto -> bb10;                    // scope 2 at $DIR/issue_41110.rs:+4:5: +4:6
++     }
++ 
++     bb12: {
++         _2 = move _5;                    // scope 2 at $DIR/issue_41110.rs:+4:5: +4:6
++         goto -> bb2;                     // scope 2 at $DIR/issue_41110.rs:+4:5: +4:6
++     }
++ 
++     bb13 (cleanup): {
++         drop(_1) -> bb10;                // scope 0 at $DIR/issue_41110.rs:+5:1: +5:2
++     }
++ 
++     bb14 (cleanup): {
++         switchInt(_6) -> [0: bb10, otherwise: bb13]; // scope 0 at $DIR/issue_41110.rs:+5:1: +5:2
+      }
+  }
+  
diff --git a/tests/mir-opt/issue_41888.main.ElaborateDrops.after.mir b/tests/mir-opt/issue_41888.main.ElaborateDrops.after.mir
deleted file mode 100644
index 00504273245..00000000000
--- a/tests/mir-opt/issue_41888.main.ElaborateDrops.after.mir
+++ /dev/null
@@ -1,152 +0,0 @@
-// MIR for `main` after ElaborateDrops
-
-fn main() -> () {
-    let mut _0: ();                      // return place in scope 0 at $DIR/issue_41888.rs:+0:11: +0:11
-    let _1: E;                           // in scope 0 at $DIR/issue_41888.rs:+1:9: +1:10
-    let mut _2: bool;                    // in scope 0 at $DIR/issue_41888.rs:+2:8: +2:14
-    let mut _3: E;                       // in scope 0 at $DIR/issue_41888.rs:+3:13: +3:20
-    let mut _4: K;                       // in scope 0 at $DIR/issue_41888.rs:+3:18: +3:19
-    let mut _5: isize;                   // in scope 0 at $DIR/issue_41888.rs:+4:16: +4:24
-    let mut _7: bool;                    // in scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-    let mut _8: bool;                    // in scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-    let mut _9: bool;                    // in scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-    let mut _10: isize;                  // in scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-    let mut _11: isize;                  // in scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-    scope 1 {
-        debug e => _1;                   // in scope 1 at $DIR/issue_41888.rs:+1:9: +1:10
-        scope 2 {
-            debug _k => _6;              // in scope 2 at $DIR/issue_41888.rs:+4:21: +4:23
-            let _6: K;                   // in scope 2 at $DIR/issue_41888.rs:+4:21: +4:23
-        }
-    }
-
-    bb0: {
-        _9 = const false;                // scope 0 at $DIR/issue_41888.rs:+1:9: +1:10
-        _7 = const false;                // scope 0 at $DIR/issue_41888.rs:+1:9: +1:10
-        _8 = const false;                // scope 0 at $DIR/issue_41888.rs:+1:9: +1:10
-        StorageLive(_1);                 // scope 0 at $DIR/issue_41888.rs:+1:9: +1:10
-        StorageLive(_2);                 // scope 1 at $DIR/issue_41888.rs:+2:8: +2:14
-        _2 = cond() -> [return: bb1, unwind: bb11]; // scope 1 at $DIR/issue_41888.rs:+2:8: +2:14
-                                         // mir::Constant
-                                         // + span: $DIR/issue_41888.rs:8:8: 8:12
-                                         // + literal: Const { ty: fn() -> bool {cond}, val: Value(<ZST>) }
-    }
-
-    bb1: {
-        switchInt(move _2) -> [0: bb7, otherwise: bb2]; // scope 1 at $DIR/issue_41888.rs:+2:8: +2:14
-    }
-
-    bb2: {
-        StorageLive(_3);                 // scope 1 at $DIR/issue_41888.rs:+3:13: +3:20
-        StorageLive(_4);                 // scope 1 at $DIR/issue_41888.rs:+3:18: +3:19
-        _4 = K;                          // scope 1 at $DIR/issue_41888.rs:+3:18: +3:19
-        _3 = E::F(move _4);              // scope 1 at $DIR/issue_41888.rs:+3:13: +3:20
-        StorageDead(_4);                 // scope 1 at $DIR/issue_41888.rs:+3:19: +3:20
-        goto -> bb14;                    // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
-    }
-
-    bb3: {
-        goto -> bb4;                     // scope 1 at $DIR/issue_41888.rs:+3:19: +3:20
-    }
-
-    bb4: {
-        StorageDead(_3);                 // scope 1 at $DIR/issue_41888.rs:+3:19: +3:20
-        _5 = discriminant(_1);           // scope 2 at $DIR/issue_41888.rs:+4:16: +4:24
-        switchInt(move _5) -> [0: bb5, otherwise: bb6]; // scope 2 at $DIR/issue_41888.rs:+4:16: +4:24
-    }
-
-    bb5: {
-        StorageLive(_6);                 // scope 2 at $DIR/issue_41888.rs:+4:21: +4:23
-        _9 = const false;                // scope 2 at $DIR/issue_41888.rs:+4:21: +4:23
-        _6 = move ((_1 as F).0: K);      // scope 2 at $DIR/issue_41888.rs:+4:21: +4:23
-        _0 = const ();                   // scope 2 at $DIR/issue_41888.rs:+4:29: +7:10
-        StorageDead(_6);                 // scope 1 at $DIR/issue_41888.rs:+7:9: +7:10
-        goto -> bb8;                     // scope 1 at $DIR/issue_41888.rs:+4:9: +7:10
-    }
-
-    bb6: {
-        _0 = const ();                   // scope 1 at $DIR/issue_41888.rs:+7:10: +7:10
-        goto -> bb8;                     // scope 1 at $DIR/issue_41888.rs:+4:9: +7:10
-    }
-
-    bb7: {
-        _0 = const ();                   // scope 1 at $DIR/issue_41888.rs:+8:6: +8:6
-        goto -> bb8;                     // scope 1 at $DIR/issue_41888.rs:+2:5: +8:6
-    }
-
-    bb8: {
-        StorageDead(_2);                 // scope 1 at $DIR/issue_41888.rs:+8:5: +8:6
-        goto -> bb20;                    // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-    }
-
-    bb9: {
-        _7 = const false;                // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-        _8 = const false;                // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-        _9 = const false;                // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-        StorageDead(_1);                 // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-        return;                          // scope 0 at $DIR/issue_41888.rs:+9:2: +9:2
-    }
-
-    bb10 (cleanup): {
-        goto -> bb11;                    // scope 1 at $DIR/issue_41888.rs:+3:19: +3:20
-    }
-
-    bb11 (cleanup): {
-        goto -> bb12;                    // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-    }
-
-    bb12 (cleanup): {
-        resume;                          // scope 0 at $DIR/issue_41888.rs:+0:1: +9:2
-    }
-
-    bb13 (cleanup): {
-        _7 = const true;                 // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
-        _8 = const true;                 // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
-        _9 = const true;                 // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
-        _1 = move _3;                    // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
-        goto -> bb10;                    // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
-    }
-
-    bb14: {
-        _7 = const true;                 // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
-        _8 = const true;                 // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
-        _9 = const true;                 // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
-        _1 = move _3;                    // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
-        goto -> bb3;                     // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
-    }
-
-    bb15: {
-        _7 = const false;                // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-        goto -> bb9;                     // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-    }
-
-    bb16 (cleanup): {
-        goto -> bb12;                    // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-    }
-
-    bb17: {
-        drop(_1) -> [return: bb15, unwind: bb12]; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-    }
-
-    bb18 (cleanup): {
-        drop(_1) -> bb12;                // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-    }
-
-    bb19: {
-        _10 = discriminant(_1);          // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-        switchInt(move _10) -> [0: bb15, otherwise: bb17]; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-    }
-
-    bb20: {
-        switchInt(_7) -> [0: bb15, otherwise: bb19]; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-    }
-
-    bb21 (cleanup): {
-        _11 = discriminant(_1);          // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-        switchInt(move _11) -> [0: bb16, otherwise: bb18]; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-    }
-
-    bb22 (cleanup): {
-        switchInt(_7) -> [0: bb12, otherwise: bb21]; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
-    }
-}
diff --git a/tests/mir-opt/issue_41888.main.ElaborateDrops.diff b/tests/mir-opt/issue_41888.main.ElaborateDrops.diff
new file mode 100644
index 00000000000..257f0b1e6e8
--- /dev/null
+++ b/tests/mir-opt/issue_41888.main.ElaborateDrops.diff
@@ -0,0 +1,158 @@
+- // MIR for `main` before ElaborateDrops
++ // MIR for `main` after ElaborateDrops
+  
+  fn main() -> () {
+      let mut _0: ();                      // return place in scope 0 at $DIR/issue_41888.rs:+0:11: +0:11
+      let _1: E;                           // in scope 0 at $DIR/issue_41888.rs:+1:9: +1:10
+      let mut _2: bool;                    // in scope 0 at $DIR/issue_41888.rs:+2:8: +2:14
+      let mut _3: E;                       // in scope 0 at $DIR/issue_41888.rs:+3:13: +3:20
+      let mut _4: K;                       // in scope 0 at $DIR/issue_41888.rs:+3:18: +3:19
+      let mut _5: isize;                   // in scope 0 at $DIR/issue_41888.rs:+4:16: +4:24
++     let mut _7: bool;                    // in scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++     let mut _8: bool;                    // in scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++     let mut _9: bool;                    // in scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++     let mut _10: isize;                  // in scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++     let mut _11: isize;                  // in scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
+      scope 1 {
+          debug e => _1;                   // in scope 1 at $DIR/issue_41888.rs:+1:9: +1:10
+          scope 2 {
+              debug _k => _6;              // in scope 2 at $DIR/issue_41888.rs:+4:21: +4:23
+              let _6: K;                   // in scope 2 at $DIR/issue_41888.rs:+4:21: +4:23
+          }
+      }
+  
+      bb0: {
++         _9 = const false;                // scope 0 at $DIR/issue_41888.rs:+1:9: +1:10
++         _7 = const false;                // scope 0 at $DIR/issue_41888.rs:+1:9: +1:10
++         _8 = const false;                // scope 0 at $DIR/issue_41888.rs:+1:9: +1:10
+          StorageLive(_1);                 // scope 0 at $DIR/issue_41888.rs:+1:9: +1:10
+          StorageLive(_2);                 // scope 1 at $DIR/issue_41888.rs:+2:8: +2:14
+          _2 = cond() -> [return: bb1, unwind: bb11]; // scope 1 at $DIR/issue_41888.rs:+2:8: +2:14
+                                           // mir::Constant
+                                           // + span: $DIR/issue_41888.rs:8:8: 8:12
+                                           // + literal: Const { ty: fn() -> bool {cond}, val: Value(<ZST>) }
+      }
+  
+      bb1: {
+          switchInt(move _2) -> [0: bb7, otherwise: bb2]; // scope 1 at $DIR/issue_41888.rs:+2:8: +2:14
+      }
+  
+      bb2: {
+          StorageLive(_3);                 // scope 1 at $DIR/issue_41888.rs:+3:13: +3:20
+          StorageLive(_4);                 // scope 1 at $DIR/issue_41888.rs:+3:18: +3:19
+          _4 = K;                          // scope 1 at $DIR/issue_41888.rs:+3:18: +3:19
+          _3 = E::F(move _4);              // scope 1 at $DIR/issue_41888.rs:+3:13: +3:20
+          StorageDead(_4);                 // scope 1 at $DIR/issue_41888.rs:+3:19: +3:20
+-         replace(_1 <- move _3) -> [return: bb3, unwind: bb10]; // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
++         goto -> bb14;                    // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
+      }
+  
+      bb3: {
+-         drop(_3) -> [return: bb4, unwind: bb11]; // scope 1 at $DIR/issue_41888.rs:+3:19: +3:20
++         goto -> bb4;                     // scope 1 at $DIR/issue_41888.rs:+3:19: +3:20
+      }
+  
+      bb4: {
+          StorageDead(_3);                 // scope 1 at $DIR/issue_41888.rs:+3:19: +3:20
+          _5 = discriminant(_1);           // scope 2 at $DIR/issue_41888.rs:+4:16: +4:24
+          switchInt(move _5) -> [0: bb5, otherwise: bb6]; // scope 2 at $DIR/issue_41888.rs:+4:16: +4:24
+      }
+  
+      bb5: {
+          StorageLive(_6);                 // scope 2 at $DIR/issue_41888.rs:+4:21: +4:23
++         _9 = const false;                // scope 2 at $DIR/issue_41888.rs:+4:21: +4:23
+          _6 = move ((_1 as F).0: K);      // scope 2 at $DIR/issue_41888.rs:+4:21: +4:23
+          _0 = const ();                   // scope 2 at $DIR/issue_41888.rs:+4:29: +7:10
+          StorageDead(_6);                 // scope 1 at $DIR/issue_41888.rs:+7:9: +7:10
+          goto -> bb8;                     // scope 1 at $DIR/issue_41888.rs:+4:9: +7:10
+      }
+  
+      bb6: {
+          _0 = const ();                   // scope 1 at $DIR/issue_41888.rs:+7:10: +7:10
+          goto -> bb8;                     // scope 1 at $DIR/issue_41888.rs:+4:9: +7:10
+      }
+  
+      bb7: {
+          _0 = const ();                   // scope 1 at $DIR/issue_41888.rs:+8:6: +8:6
+          goto -> bb8;                     // scope 1 at $DIR/issue_41888.rs:+2:5: +8:6
+      }
+  
+      bb8: {
+          StorageDead(_2);                 // scope 1 at $DIR/issue_41888.rs:+8:5: +8:6
+-         drop(_1) -> bb9;                 // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++         goto -> bb20;                    // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
+      }
+  
+      bb9: {
++         _7 = const false;                // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++         _8 = const false;                // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++         _9 = const false;                // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
+          StorageDead(_1);                 // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
+          return;                          // scope 0 at $DIR/issue_41888.rs:+9:2: +9:2
+      }
+  
+      bb10 (cleanup): {
+          drop(_3) -> bb11;                // scope 1 at $DIR/issue_41888.rs:+3:19: +3:20
+      }
+  
+      bb11 (cleanup): {
+-         drop(_1) -> bb12;                // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++         goto -> bb12;                    // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
+      }
+  
+      bb12 (cleanup): {
+          resume;                          // scope 0 at $DIR/issue_41888.rs:+0:1: +9:2
++     }
++ 
++     bb13 (cleanup): {
++         _7 = const true;                 // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
++         _8 = const true;                 // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
++         _9 = const true;                 // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
++         _1 = move _3;                    // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
++         goto -> bb12;                    // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
++     }
++ 
++     bb14: {
++         _7 = const true;                 // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
++         _8 = const true;                 // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
++         _9 = const true;                 // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
++         _1 = move _3;                    // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
++         goto -> bb3;                     // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
++     }
++ 
++     bb15: {
++         _7 = const false;                // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++         goto -> bb9;                     // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++     }
++ 
++     bb16 (cleanup): {
++         goto -> bb12;                    // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++     }
++ 
++     bb17: {
++         drop(_1) -> [return: bb15, unwind: bb12]; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++     }
++ 
++     bb18 (cleanup): {
++         drop(_1) -> bb12;                // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++     }
++ 
++     bb19: {
++         _10 = discriminant(_1);          // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++         switchInt(move _10) -> [0: bb15, otherwise: bb17]; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++     }
++ 
++     bb20: {
++         switchInt(_7) -> [0: bb15, otherwise: bb19]; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++     }
++ 
++     bb21 (cleanup): {
++         _11 = discriminant(_1);          // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++         switchInt(move _11) -> [0: bb16, otherwise: bb18]; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
++     }
++ 
++     bb22 (cleanup): {
++         switchInt(_7) -> [0: bb12, otherwise: bb21]; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
+      }
+  }
+  
diff --git a/tests/mir-opt/issue_41888.rs b/tests/mir-opt/issue_41888.rs
index c1046c14dbf..0f10c0a1d09 100644
--- a/tests/mir-opt/issue_41888.rs
+++ b/tests/mir-opt/issue_41888.rs
@@ -2,7 +2,7 @@
 // check that we clear the "ADT master drop flag" even when there are
 // no fields to be dropped.
 
-// EMIT_MIR issue_41888.main.ElaborateDrops.after.mir
+// EMIT_MIR issue_41888.main.ElaborateDrops.diff
 fn main() {
     let e;
     if cond() {
diff --git a/tests/run-make-fulldeps/hotplug_codegen_backend/the_backend.rs b/tests/run-make-fulldeps/hotplug_codegen_backend/the_backend.rs
index 3aa57d58908..8dac53c2a62 100644
--- a/tests/run-make-fulldeps/hotplug_codegen_backend/the_backend.rs
+++ b/tests/run-make-fulldeps/hotplug_codegen_backend/the_backend.rs
@@ -27,6 +27,8 @@ use std::any::Any;
 struct TheBackend;
 
 impl CodegenBackend for TheBackend {
+    fn locale_resource(&self) -> &'static str { "" }
+
     fn codegen_crate<'a, 'tcx>(
         &self,
         tcx: TyCtxt<'tcx>,
diff --git a/tests/run-make-fulldeps/issue-19371/foo.rs b/tests/run-make-fulldeps/issue-19371/foo.rs
index 5bb38fc02af..53ec79e477b 100644
--- a/tests/run-make-fulldeps/issue-19371/foo.rs
+++ b/tests/run-make-fulldeps/issue-19371/foo.rs
@@ -53,6 +53,7 @@ fn compile(code: String, output: PathBuf, sysroot: PathBuf) {
         output_file: Some(output),
         output_dir: None,
         file_loader: None,
+        locale_resources: &[],
         lint_caps: Default::default(),
         parse_sess_created: None,
         register_lints: None,
diff --git a/tests/run-make/translation/Makefile b/tests/run-make/translation/Makefile
index 20e86c7f9a0..5b0b331ca46 100644
--- a/tests/run-make/translation/Makefile
+++ b/tests/run-make/translation/Makefile
@@ -6,8 +6,10 @@ include ../../run-make-fulldeps/tools.mk
 
 SYSROOT:=$(shell $(RUSTC) --print sysroot)
 FAKEROOT=$(TMPDIR)/fakeroot
+RUSTC_LOG:=rustc_error_messages
+export RUSTC_TRANSLATION_NO_DEBUG_ASSERT:=1
 
-all: normal custom sysroot
+all: normal custom missing broken sysroot sysroot-invalid sysroot-missing
 
 # Check that the test works normally, using the built-in fallback bundle.
 normal: test.rs
@@ -32,6 +34,7 @@ broken: test.rs broken.ftl
 # identifier by making a local copy of the sysroot and adding the custom locale
 # to it.
 sysroot: test.rs working.ftl
+	rm -rf $(FAKEROOT)
 	mkdir $(FAKEROOT)
 	ln -s $(SYSROOT)/* $(FAKEROOT)
 	rm -f $(FAKEROOT)/lib
@@ -51,12 +54,12 @@ sysroot: test.rs working.ftl
 # found. This test might start failing if there actually exists a Klingon
 # translation of rustc's error messages.
 sysroot-missing: 
-	$(RUSTC) $< -Ztranslate-lang=tlh 2>&1 || grep "missing locale directory"
+	$(RUSTC) $< -Ztranslate-lang=tlh 2>&1 | grep "missing locale directory"
 
-# Check that the compiler errors out when the sysroot requested cannot be
-# found. This test might start failing if there actually exists a Klingon
-# translation of rustc's error messages.
+# Check that the compiler errors out when the directory for the locale in the
+# sysroot is actually a file.
 sysroot-invalid: test.rs working.ftl
+	rm -rf $(FAKEROOT)
 	mkdir $(FAKEROOT)
 	ln -s $(SYSROOT)/* $(FAKEROOT)
 	rm -f $(FAKEROOT)/lib
@@ -68,5 +71,6 @@ sysroot-invalid: test.rs working.ftl
 	rm -f $(FAKEROOT)/lib/rustlib/src
 	mkdir $(FAKEROOT)/lib/rustlib/src
 	ln -s $(SYSROOT)/lib/rustlib/src/* $(FAKEROOT)/lib/rustlib/src
-	touch $(FAKEROOT)/share/locale/zh-CN/
-	$(RUSTC) $< --sysroot $(FAKEROOT) -Ztranslate-lang=zh-CN 2>&1 || grep "`\$sysroot/share/locales/\$locale` is not a directory"
+	mkdir -p $(FAKEROOT)/share/locale
+	touch $(FAKEROOT)/share/locale/zh-CN
+	$(RUSTC) $< --sysroot $(FAKEROOT) -Ztranslate-lang=zh-CN 2>&1 | grep "`\$sysroot/share/locales/\$locale` is not a directory"
diff --git a/tests/rustdoc-gui/help-page.goml b/tests/rustdoc-gui/help-page.goml
index 5f4c1ba2f85..6e2321a6963 100644
--- a/tests/rustdoc-gui/help-page.goml
+++ b/tests/rustdoc-gui/help-page.goml
@@ -68,5 +68,4 @@ size: (1000, 1000) // Popover only appears when the screen width is >700px.
 assert-false: "#help"
 click: "#help-button > a"
 click: ".popover a[href='https://doc.rust-lang.org/rustdoc/']"
-wait-for: 2000
-assert-document-property: {"URL": "https://doc.rust-lang.org/rustdoc/"}
+wait-for-document-property: {"URL": "https://doc.rust-lang.org/rustdoc/"}
diff --git a/tests/rustdoc-ui/auxiliary/panic-handler.rs b/tests/rustdoc-ui/auxiliary/panic-handler.rs
new file mode 100644
index 00000000000..0aaaeee1051
--- /dev/null
+++ b/tests/rustdoc-ui/auxiliary/panic-handler.rs
@@ -0,0 +1,9 @@
+// compile-flags: -C panic=abort
+
+#![no_std]
+#![no_main]
+
+#[panic_handler]
+fn panic(_: &core::panic::PanicInfo) -> ! {
+    loop {}
+}
diff --git a/tests/rustdoc-ui/issue-107918.rs b/tests/rustdoc-ui/issue-107918.rs
new file mode 100644
index 00000000000..13788df0fc9
--- /dev/null
+++ b/tests/rustdoc-ui/issue-107918.rs
@@ -0,0 +1,12 @@
+// aux-build:panic-handler.rs
+// compile-flags: --document-private-items
+// build-pass
+// ignore-windows
+
+#![no_std]
+#![no_main]
+
+#[panic_handler]
+fn panic(_: &core::panic::PanicInfo) -> ! {
+    loop {}
+}
diff --git a/tests/rustdoc-ui/proc_macro_bug.rs b/tests/rustdoc-ui/proc_macro_bug.rs
new file mode 100644
index 00000000000..e384e4863ad
--- /dev/null
+++ b/tests/rustdoc-ui/proc_macro_bug.rs
@@ -0,0 +1,12 @@
+// regression test for failing to pass `--crate-type proc-macro` to rustdoc
+// when documenting a proc macro crate https://github.com/rust-lang/rust/pull/107291
+
+extern crate proc_macro;
+
+use proc_macro::TokenStream;
+
+#[proc_macro_derive(DeriveA)]
+//~^ ERROR the `#[proc_macro_derive]` attribute is only usable with crates of the `proc-macro` crate type
+pub fn a_derive(input: TokenStream) -> TokenStream {
+    input
+}
diff --git a/tests/rustdoc-ui/proc_macro_bug.stderr b/tests/rustdoc-ui/proc_macro_bug.stderr
new file mode 100644
index 00000000000..5b048097c49
--- /dev/null
+++ b/tests/rustdoc-ui/proc_macro_bug.stderr
@@ -0,0 +1,8 @@
+error: the `#[proc_macro_derive]` attribute is only usable with crates of the `proc-macro` crate type
+  --> $DIR/proc_macro_bug.rs:8:1
+   |
+LL | #[proc_macro_derive(DeriveA)]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+error: aborting due to previous error
+
diff --git a/tests/rustdoc-ui/unable-fulfill-trait.stderr b/tests/rustdoc-ui/unable-fulfill-trait.stderr
index a16b5b6eb2f..72f35cb9224 100644
--- a/tests/rustdoc-ui/unable-fulfill-trait.stderr
+++ b/tests/rustdoc-ui/unable-fulfill-trait.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this trait takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: trait takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/unable-fulfill-trait.rs:4:17
    |
 LL |     field1: dyn Bar<'a, 'b,>,
diff --git a/tests/rustdoc-ui/z-help.stdout b/tests/rustdoc-ui/z-help.stdout
index 8d0155151b8..6aa9785f44e 100644
--- a/tests/rustdoc-ui/z-help.stdout
+++ b/tests/rustdoc-ui/z-help.stdout
@@ -1,76 +1,76 @@
-    -Z                          allow-features=val -- only allow the listed language features to be enabled in code (comma separated)
-    -Z                       always-encode-mir=val -- encode MIR of all functions into the crate metadata (default: no)
-    -Z                            asm-comments=val -- generate comments into the assembly (may change behavior) (default: no)
-    -Z                       assert-incr-state=val -- assert that the incremental cache is in given state: either `loaded` or `not-loaded`.
-    -Z               assume-incomplete-release=val -- make cfg(version) treat the current version as incomplete (default: no)
-    -Z                      binary-dep-depinfo=val -- include artifacts (sysroot, crate dependencies) used during compilation in dep-info (default: no)
-    -Z                             box-noalias=val -- emit noalias metadata for box (default: yes)
-    -Z                       branch-protection=val -- set options for branch target identification and pointer authentication on AArch64
-    -Z                           cf-protection=val -- instrument control-flow architecture protection
-    -Z               cgu-partitioning-strategy=val -- the codegen unit partitioning strategy to use
-    -Z                         codegen-backend=val -- the backend to use
-    -Z                             combine-cgu=val -- combine CGUs into a single one
-    -Z                              crate-attr=val -- inject the given attribute in the crate
-    -Z                debug-info-for-profiling=val -- emit discriminators and other data necessary for AutoFDO
-    -Z                            debug-macros=val -- emit line numbers debug info inside macros (default: no)
-    -Z                 deduplicate-diagnostics=val -- deduplicate identical diagnostics (default: yes)
-    -Z                  dep-info-omit-d-target=val -- in dep-info output, omit targets for tracking dependencies of the dep-info files themselves (default: no)
-    -Z                               dep-tasks=val -- print tasks that execute and the color their dep node gets (requires debug build) (default: no)
-    -Z                        diagnostic-width=val -- set the current output width for diagnostic truncation
-    -Z                                 dlltool=val -- import library generation tool (windows-gnu only)
-    -Z                 dont-buffer-diagnostics=val -- emit diagnostics rather than buffering (breaks NLL error downgrading, sorting) (default: no)
-    -Z                           drop-tracking=val -- enables drop tracking in generators (default: no)
-    -Z                       drop-tracking-mir=val -- enables drop tracking on MIR in generators (default: no)
-    -Z                        dual-proc-macros=val -- load proc macros for both target and host, but only link to the target (default: no)
-    -Z                          dump-dep-graph=val -- dump the dependency graph to $RUST_DEP_GRAPH (default: /tmp/dep_graph.gv) (default: no)
-    -Z                  dump-drop-tracking-cfg=val -- dump drop-tracking control-flow graph as a `.dot` file (default: no)
-    -Z                                dump-mir=val -- dump MIR state to file.
+    -Z                        allow-features=val -- only allow the listed language features to be enabled in code (comma separated)
+    -Z                     always-encode-mir=val -- encode MIR of all functions into the crate metadata (default: no)
+    -Z                          asm-comments=val -- generate comments into the assembly (may change behavior) (default: no)
+    -Z                     assert-incr-state=val -- assert that the incremental cache is in given state: either `loaded` or `not-loaded`.
+    -Z             assume-incomplete-release=val -- make cfg(version) treat the current version as incomplete (default: no)
+    -Z                    binary-dep-depinfo=val -- include artifacts (sysroot, crate dependencies) used during compilation in dep-info (default: no)
+    -Z                           box-noalias=val -- emit noalias metadata for box (default: yes)
+    -Z                     branch-protection=val -- set options for branch target identification and pointer authentication on AArch64
+    -Z                         cf-protection=val -- instrument control-flow architecture protection
+    -Z             cgu-partitioning-strategy=val -- the codegen unit partitioning strategy to use
+    -Z                       codegen-backend=val -- the backend to use
+    -Z                           combine-cgu=val -- combine CGUs into a single one
+    -Z                            crate-attr=val -- inject the given attribute in the crate
+    -Z              debug-info-for-profiling=val -- emit discriminators and other data necessary for AutoFDO
+    -Z                          debug-macros=val -- emit line numbers debug info inside macros (default: no)
+    -Z               deduplicate-diagnostics=val -- deduplicate identical diagnostics (default: yes)
+    -Z                dep-info-omit-d-target=val -- in dep-info output, omit targets for tracking dependencies of the dep-info files themselves (default: no)
+    -Z                             dep-tasks=val -- print tasks that execute and the color their dep node gets (requires debug build) (default: no)
+    -Z                      diagnostic-width=val -- set the current output width for diagnostic truncation
+    -Z                               dlltool=val -- import library generation tool (windows-gnu only)
+    -Z               dont-buffer-diagnostics=val -- emit diagnostics rather than buffering (breaks NLL error downgrading, sorting) (default: no)
+    -Z                         drop-tracking=val -- enables drop tracking in generators (default: no)
+    -Z                     drop-tracking-mir=val -- enables drop tracking on MIR in generators (default: no)
+    -Z                      dual-proc-macros=val -- load proc macros for both target and host, but only link to the target (default: no)
+    -Z                        dump-dep-graph=val -- dump the dependency graph to $RUST_DEP_GRAPH (default: /tmp/dep_graph.gv) (default: no)
+    -Z                dump-drop-tracking-cfg=val -- dump drop-tracking control-flow graph as a `.dot` file (default: no)
+    -Z                              dump-mir=val -- dump MIR state to file.
         `val` is used to select which passes and functions to dump. For example:
         `all` matches all passes and functions,
         `foo` matches all passes for functions whose name contains 'foo',
         `foo & ConstProp` only the 'ConstProp' pass for function names containing 'foo',
         `foo | bar` all passes for function names containing 'foo' or 'bar'.
-    -Z                       dump-mir-dataflow=val -- in addition to `.mir` files, create graphviz `.dot` files with dataflow results (default: no)
-    -Z                            dump-mir-dir=val -- the directory the MIR is dumped into (default: `mir_dump`)
-    -Z            dump-mir-exclude-pass-number=val -- exclude the pass number when dumping MIR (used in tests) (default: no)
-    -Z                       dump-mir-graphviz=val -- in addition to `.mir` files, create graphviz `.dot` files (and with `-Z instrument-coverage`, also create a `.dot` file for the MIR-derived coverage graph) (default: no)
-    -Z                       dump-mir-spanview=val -- in addition to `.mir` files, create `.html` files to view spans for all `statement`s (including terminators), only `terminator` spans, or computed `block` spans (one span encompassing a block's terminator and all statements). If `-Z instrument-coverage` is also enabled, create an additional `.html` file showing the computed coverage spans.
-    -Z                         dump-mono-stats=val -- output statistics about monomorphization collection
-    -Z                  dump-mono-stats-format=val -- the format to use for -Z dump-mono-stats (`markdown` (default) or `json`)
-    -Z                           dwarf-version=val -- version of DWARF debug information to emit (default: 2 or 4, depending on platform)
-    -Z                               dylib-lto=val -- enables LTO for dylib crate type
-    -Z                        emit-stack-sizes=val -- emit a section containing stack size metadata (default: no)
-    -Z                           emit-thin-lto=val -- emit the bc module with thin LTO info (default: yes)
-    -Z               export-executable-symbols=val -- export symbols from executables, as if they were dynamic libraries
-    -Z                   extra-const-ub-checks=val -- turns on more checks to detect const UB, which can be slow (default: no)
-    -Z                             fewer-names=val -- reduce memory use by retaining fewer names within compilation artifacts (LLVM-IR) (default: no)
-    -Z              force-unstable-if-unmarked=val -- force all crates to be `rustc_private` unstable (default: no)
-    -Z                                    fuel=val -- set the optimization fuel quota for a crate
-    -Z                       function-sections=val -- whether each function should go in its own section
-    -Z                    future-incompat-test=val -- forces all lints to be future incompatible, used for internal testing (default: no)
-    -Z                                  gcc-ld=val -- implementation of ld used by cc
-    -Z                      graphviz-dark-mode=val -- use dark-themed colors in graphviz output (default: no)
-    -Z                           graphviz-font=val -- use the given `fontname` in graphviz output; can be overridden by setting environment variable `RUSTC_GRAPHVIZ_FONT` (default: `Courier, monospace`)
-    -Z                               hir-stats=val -- print some statistics about AST and HIR (default: no)
-    -Z                human-readable-cgu-names=val -- generate human-readable, predictable names for codegen units (default: no)
-    -Z                        identify-regions=val -- display unnamed regions as `'<id>`, using a non-ident unique id (default: no)
-    -Z                incremental-ignore-spans=val -- ignore spans during ICH computation -- used for testing (default: no)
-    -Z                        incremental-info=val -- print high-level information about incremental reuse (or the lack thereof) (default: no)
-    -Z              incremental-relative-spans=val -- hash spans relative to their parent item for incr. comp. (default: no)
-    -Z                  incremental-verify-ich=val -- verify incr. comp. hashes of green query instances (default: no)
-    -Z                      inline-in-all-cgus=val -- control whether `#[inline]` functions are in all CGUs
-    -Z                             inline-llvm=val -- enable LLVM inlining (default: yes)
-    -Z                              inline-mir=val -- enable MIR inlining (default: no)
-    -Z               inline-mir-hint-threshold=val -- inlining threshold for functions with inline hint (default: 100)
-    -Z                    inline-mir-threshold=val -- a default MIR inlining threshold (default: 50)
-    -Z                             input-stats=val -- gather statistics about the input (default: no)
-    -Z                     instrument-coverage=val -- instrument the generated code to support LLVM source-based code coverage reports (note, the compiler build config must include `profiler = true`); implies `-C symbol-mangling-version=v0`. Optional values are:
+    -Z                     dump-mir-dataflow=val -- in addition to `.mir` files, create graphviz `.dot` files with dataflow results (default: no)
+    -Z                          dump-mir-dir=val -- the directory the MIR is dumped into (default: `mir_dump`)
+    -Z          dump-mir-exclude-pass-number=val -- exclude the pass number when dumping MIR (used in tests) (default: no)
+    -Z                     dump-mir-graphviz=val -- in addition to `.mir` files, create graphviz `.dot` files (and with `-Z instrument-coverage`, also create a `.dot` file for the MIR-derived coverage graph) (default: no)
+    -Z                     dump-mir-spanview=val -- in addition to `.mir` files, create `.html` files to view spans for all `statement`s (including terminators), only `terminator` spans, or computed `block` spans (one span encompassing a block's terminator and all statements). If `-Z instrument-coverage` is also enabled, create an additional `.html` file showing the computed coverage spans.
+    -Z                       dump-mono-stats=val -- output statistics about monomorphization collection
+    -Z                dump-mono-stats-format=val -- the format to use for -Z dump-mono-stats (`markdown` (default) or `json`)
+    -Z                         dwarf-version=val -- version of DWARF debug information to emit (default: 2 or 4, depending on platform)
+    -Z                             dylib-lto=val -- enables LTO for dylib crate type
+    -Z                      emit-stack-sizes=val -- emit a section containing stack size metadata (default: no)
+    -Z                         emit-thin-lto=val -- emit the bc module with thin LTO info (default: yes)
+    -Z             export-executable-symbols=val -- export symbols from executables, as if they were dynamic libraries
+    -Z                 extra-const-ub-checks=val -- turns on more checks to detect const UB, which can be slow (default: no)
+    -Z                           fewer-names=val -- reduce memory use by retaining fewer names within compilation artifacts (LLVM-IR) (default: no)
+    -Z            force-unstable-if-unmarked=val -- force all crates to be `rustc_private` unstable (default: no)
+    -Z                                  fuel=val -- set the optimization fuel quota for a crate
+    -Z                     function-sections=val -- whether each function should go in its own section
+    -Z                  future-incompat-test=val -- forces all lints to be future incompatible, used for internal testing (default: no)
+    -Z                                gcc-ld=val -- implementation of ld used by cc
+    -Z                    graphviz-dark-mode=val -- use dark-themed colors in graphviz output (default: no)
+    -Z                         graphviz-font=val -- use the given `fontname` in graphviz output; can be overridden by setting environment variable `RUSTC_GRAPHVIZ_FONT` (default: `Courier, monospace`)
+    -Z                             hir-stats=val -- print some statistics about AST and HIR (default: no)
+    -Z              human-readable-cgu-names=val -- generate human-readable, predictable names for codegen units (default: no)
+    -Z                      identify-regions=val -- display unnamed regions as `'<id>`, using a non-ident unique id (default: no)
+    -Z              incremental-ignore-spans=val -- ignore spans during ICH computation -- used for testing (default: no)
+    -Z                      incremental-info=val -- print high-level information about incremental reuse (or the lack thereof) (default: no)
+    -Z            incremental-relative-spans=val -- hash spans relative to their parent item for incr. comp. (default: no)
+    -Z                incremental-verify-ich=val -- verify incr. comp. hashes of green query instances (default: no)
+    -Z                    inline-in-all-cgus=val -- control whether `#[inline]` functions are in all CGUs
+    -Z                           inline-llvm=val -- enable LLVM inlining (default: yes)
+    -Z                            inline-mir=val -- enable MIR inlining (default: no)
+    -Z             inline-mir-hint-threshold=val -- inlining threshold for functions with inline hint (default: 100)
+    -Z                  inline-mir-threshold=val -- a default MIR inlining threshold (default: 50)
+    -Z                           input-stats=val -- gather statistics about the input (default: no)
+    -Z                   instrument-coverage=val -- instrument the generated code to support LLVM source-based code coverage reports (note, the compiler build config must include `profiler = true`); implies `-C symbol-mangling-version=v0`. Optional values are:
         `=all` (implicit value)
         `=except-unused-generics`
         `=except-unused-functions`
         `=off` (default)
-    -Z                       instrument-mcount=val -- insert function instrument code for mcount-based tracing (default: no)
-    -Z                         instrument-xray=val -- insert function instrument code for XRay-based tracing (default: no)
+    -Z                     instrument-mcount=val -- insert function instrument code for mcount-based tracing (default: no)
+    -Z                       instrument-xray=val -- insert function instrument code for XRay-based tracing (default: no)
          Optional extra settings:
          `=always`
          `=never`
@@ -79,125 +79,125 @@
          `=skip-entry`
          `=skip-exit`
          Multiple options can be combined with commas.
-    -Z                       keep-hygiene-data=val -- keep hygiene data after analysis (default: no)
-    -Z                             layout-seed=val -- seed layout randomization
-    -Z                   link-native-libraries=val -- link native libraries in the linker invocation (default: yes)
-    -Z                               link-only=val -- link the `.rlink` file generated by `-Z no-link` (default: no)
-    -Z                            llvm-plugins=val -- a list LLVM plugins to enable (space separated)
-    -Z                         llvm-time-trace=val -- generate JSON tracing data file from LLVM data (default: no)
-    -Z                         location-detail=val -- what location details should be tracked when using caller_location, either `none`, or a comma separated list of location details, for which valid options are `file`, `line`, and `column` (default: `file,line,column`)
-    -Z                                      ls=val -- list the symbols defined by a library crate (default: no)
-    -Z                         macro-backtrace=val -- show macro backtraces (default: no)
-    -Z             maximal-hir-to-mir-coverage=val -- save as much information as possible about the correspondence between MIR and HIR as source scopes (default: no)
-    -Z                         merge-functions=val -- control the operation of the MergeFunctions LLVM pass, taking the same values as the target option of the same name
-    -Z                              meta-stats=val -- gather metadata statistics (default: no)
-    -Z                          mir-emit-retag=val -- emit Retagging MIR statements, interpreted e.g., by miri; implies -Zmir-opt-level=0 (default: no)
-    -Z                       mir-enable-passes=val -- use like `-Zmir-enable-passes=+DestProp,-InstCombine`. Forces the specified passes to be enabled, overriding all other checks. Passes that are not specified are enabled or disabled by other flags as usual.
-    -Z                           mir-opt-level=val -- MIR optimization level (0-4; default: 1 in non optimized builds and 2 in optimized builds)
-    -Z        mir-pretty-relative-line-numbers=val -- use line numbers relative to the function in mir pretty printing
-    -Z                         move-size-limit=val -- the size at which the `large_assignments` lint starts to be emitted
-    -Z                         mutable-noalias=val -- emit noalias metadata for mutable references (default: yes)
-    -Z                               nll-facts=val -- dump facts from NLL analysis into side files (default: no)
-    -Z                           nll-facts-dir=val -- the directory the NLL facts are dumped into (default: `nll-facts`)
-    -Z                             no-analysis=val -- parse and expand the source, but run no analysis
-    -Z                              no-codegen=val -- run all passes except codegen; no output
-    -Z              no-generate-arange-section=val -- omit DWARF address ranges that give faster lookups
-    -Z                          no-jump-tables=val -- disable the jump tables and lookup tables that can be generated from a switch case lowering
-    -Z                           no-leak-check=val -- disable the 'leak check' for subtyping; unsound, but useful for tests
-    -Z                                 no-link=val -- compile without linking
-    -Z                        no-parallel-llvm=val -- run LLVM in non-parallel mode (while keeping codegen-units and ThinLTO)
-    -Z                     no-profiler-runtime=val -- prevent automatic injection of the profiler_builtins crate
-    -Z                 no-unique-section-names=val -- do not use unique names for text and data sections when -Z function-sections is used
-    -Z                          normalize-docs=val -- normalize associated items in rustdoc when generating documentation
-    -Z                                     oom=val -- panic strategy for out-of-memory handling
-    -Z                  osx-rpath-install-name=val -- pass `-install_name @rpath/...` to the macOS linker (default: no)
-    -Z                     packed-bundled-libs=val -- change rlib format to store native libraries as archives
-    -Z                       panic-abort-tests=val -- support compiling tests with panic=abort (default: no)
-    -Z                           panic-in-drop=val -- panic strategy for panics in drops
-    -Z                              parse-only=val -- parse only; do not compile, assemble, or link (default: no)
-    -Z                              perf-stats=val -- print some performance-related statistics (default: no)
-    -Z pick-stable-methods-before-any-unstable=val -- try to pick stable methods first before picking any unstable methods (default: yes)
-    -Z                                     plt=val -- whether to use the PLT when calling into shared libraries;
+    -Z                     keep-hygiene-data=val -- keep hygiene data after analysis (default: no)
+    -Z                           layout-seed=val -- seed layout randomization
+    -Z                       link-directives=val -- honor #[link] directives in the compiled crate (default: yes)
+    -Z                 link-native-libraries=val -- link native libraries in the linker invocation (default: yes)
+    -Z                             link-only=val -- link the `.rlink` file generated by `-Z no-link` (default: no)
+    -Z                          llvm-plugins=val -- a list LLVM plugins to enable (space separated)
+    -Z                       llvm-time-trace=val -- generate JSON tracing data file from LLVM data (default: no)
+    -Z                       location-detail=val -- what location details should be tracked when using caller_location, either `none`, or a comma separated list of location details, for which valid options are `file`, `line`, and `column` (default: `file,line,column`)
+    -Z                                    ls=val -- list the symbols defined by a library crate (default: no)
+    -Z                       macro-backtrace=val -- show macro backtraces (default: no)
+    -Z           maximal-hir-to-mir-coverage=val -- save as much information as possible about the correspondence between MIR and HIR as source scopes (default: no)
+    -Z                       merge-functions=val -- control the operation of the MergeFunctions LLVM pass, taking the same values as the target option of the same name
+    -Z                            meta-stats=val -- gather metadata statistics (default: no)
+    -Z                        mir-emit-retag=val -- emit Retagging MIR statements, interpreted e.g., by miri; implies -Zmir-opt-level=0 (default: no)
+    -Z                     mir-enable-passes=val -- use like `-Zmir-enable-passes=+DestProp,-InstCombine`. Forces the specified passes to be enabled, overriding all other checks. Passes that are not specified are enabled or disabled by other flags as usual.
+    -Z                         mir-opt-level=val -- MIR optimization level (0-4; default: 1 in non optimized builds and 2 in optimized builds)
+    -Z      mir-pretty-relative-line-numbers=val -- use line numbers relative to the function in mir pretty printing
+    -Z                       move-size-limit=val -- the size at which the `large_assignments` lint starts to be emitted
+    -Z                       mutable-noalias=val -- emit noalias metadata for mutable references (default: yes)
+    -Z                             nll-facts=val -- dump facts from NLL analysis into side files (default: no)
+    -Z                         nll-facts-dir=val -- the directory the NLL facts are dumped into (default: `nll-facts`)
+    -Z                           no-analysis=val -- parse and expand the source, but run no analysis
+    -Z                            no-codegen=val -- run all passes except codegen; no output
+    -Z            no-generate-arange-section=val -- omit DWARF address ranges that give faster lookups
+    -Z                        no-jump-tables=val -- disable the jump tables and lookup tables that can be generated from a switch case lowering
+    -Z                         no-leak-check=val -- disable the 'leak check' for subtyping; unsound, but useful for tests
+    -Z                               no-link=val -- compile without linking
+    -Z                      no-parallel-llvm=val -- run LLVM in non-parallel mode (while keeping codegen-units and ThinLTO)
+    -Z                   no-profiler-runtime=val -- prevent automatic injection of the profiler_builtins crate
+    -Z               no-unique-section-names=val -- do not use unique names for text and data sections when -Z function-sections is used
+    -Z                        normalize-docs=val -- normalize associated items in rustdoc when generating documentation
+    -Z                                   oom=val -- panic strategy for out-of-memory handling
+    -Z                osx-rpath-install-name=val -- pass `-install_name @rpath/...` to the macOS linker (default: no)
+    -Z                   packed-bundled-libs=val -- change rlib format to store native libraries as archives
+    -Z                     panic-abort-tests=val -- support compiling tests with panic=abort (default: no)
+    -Z                         panic-in-drop=val -- panic strategy for panics in drops
+    -Z                            parse-only=val -- parse only; do not compile, assemble, or link (default: no)
+    -Z                            perf-stats=val -- print some performance-related statistics (default: no)
+    -Z                                   plt=val -- whether to use the PLT when calling into shared libraries;
         only has effect for PIC code on systems with ELF binaries
         (default: PLT is disabled if full relro is enabled)
-    -Z                                polonius=val -- enable polonius-based borrow-checker (default: no)
-    -Z                            polymorphize=val -- perform polymorphization analysis
-    -Z                            pre-link-arg=val -- a single extra argument to prepend the linker invocation (can be used several times)
-    -Z                           pre-link-args=val -- extra arguments to prepend to the linker invocation (space separated)
-    -Z           precise-enum-drop-elaboration=val -- use a more precise version of drop elaboration for matches on enums (default: yes). This results in better codegen, but has caused miscompilations on some tier 2 platforms. See #77382 and #74551.
-    -Z                              print-fuel=val -- make rustc print the total optimization fuel used by a crate
-    -Z                       print-llvm-passes=val -- print the LLVM optimization passes being run (default: no)
-    -Z                        print-mono-items=val -- print the result of the monomorphization collection pass
-    -Z                        print-type-sizes=val -- print layout information for each type encountered (default: no)
-    -Z                    proc-macro-backtrace=val -- show backtraces for panics during proc-macro execution (default: no)
-    -Z           proc-macro-execution-strategy=val -- how to run proc-macro code (default: same-thread)
-    -Z                                 profile=val -- insert profiling code (default: no)
-    -Z                        profile-closures=val -- profile size of closures
-    -Z                            profile-emit=val -- file path to emit profiling data at runtime when using 'profile' (default based on relative source path)
-    -Z                      profile-sample-use=val -- use the given `.prof` file for sampled profile-guided optimization (also known as AutoFDO)
-    -Z                        profiler-runtime=val -- name of the profiler runtime crate to automatically inject (default: `profiler_builtins`)
-    -Z                         query-dep-graph=val -- enable queries of the dependency graph for regression testing (default: no)
-    -Z                        randomize-layout=val -- randomize the layout of types (default: no)
-    -Z                   relax-elf-relocations=val -- whether ELF relocations can be relaxed
-    -Z                             relro-level=val -- choose which RELRO level to use
-    -Z                        remap-cwd-prefix=val -- remap paths under the current working directory to this path prefix
-    -Z                     report-delayed-bugs=val -- immediately print bugs registered with `delay_span_bug` (default: no)
-    -Z                               sanitizer=val -- use a sanitizer
-    -Z          sanitizer-memory-track-origins=val -- enable origins tracking in MemorySanitizer
-    -Z                       sanitizer-recover=val -- enable recovery for selected sanitizers
-    -Z                  saturating-float-casts=val -- make float->int casts UB-free: numbers outside the integer type's range are clipped to the max/min integer respectively, and NaN is mapped to 0 (default: yes)
-    -Z                            self-profile=val -- run the self profiler and output the raw event data
-    -Z                    self-profile-counter=val -- counter used by the self profiler (default: `wall-time`), one of:
+    -Z                              polonius=val -- enable polonius-based borrow-checker (default: no)
+    -Z                          polymorphize=val -- perform polymorphization analysis
+    -Z                          pre-link-arg=val -- a single extra argument to prepend the linker invocation (can be used several times)
+    -Z                         pre-link-args=val -- extra arguments to prepend to the linker invocation (space separated)
+    -Z         precise-enum-drop-elaboration=val -- use a more precise version of drop elaboration for matches on enums (default: yes). This results in better codegen, but has caused miscompilations on some tier 2 platforms. See #77382 and #74551.
+    -Z                            print-fuel=val -- make rustc print the total optimization fuel used by a crate
+    -Z                     print-llvm-passes=val -- print the LLVM optimization passes being run (default: no)
+    -Z                      print-mono-items=val -- print the result of the monomorphization collection pass
+    -Z                      print-type-sizes=val -- print layout information for each type encountered (default: no)
+    -Z                  proc-macro-backtrace=val -- show backtraces for panics during proc-macro execution (default: no)
+    -Z         proc-macro-execution-strategy=val -- how to run proc-macro code (default: same-thread)
+    -Z                               profile=val -- insert profiling code (default: no)
+    -Z                      profile-closures=val -- profile size of closures
+    -Z                          profile-emit=val -- file path to emit profiling data at runtime when using 'profile' (default based on relative source path)
+    -Z                    profile-sample-use=val -- use the given `.prof` file for sampled profile-guided optimization (also known as AutoFDO)
+    -Z                      profiler-runtime=val -- name of the profiler runtime crate to automatically inject (default: `profiler_builtins`)
+    -Z                       query-dep-graph=val -- enable queries of the dependency graph for regression testing (default: no)
+    -Z                      randomize-layout=val -- randomize the layout of types (default: no)
+    -Z                 relax-elf-relocations=val -- whether ELF relocations can be relaxed
+    -Z                           relro-level=val -- choose which RELRO level to use
+    -Z                      remap-cwd-prefix=val -- remap paths under the current working directory to this path prefix
+    -Z                   report-delayed-bugs=val -- immediately print bugs registered with `delay_span_bug` (default: no)
+    -Z                             sanitizer=val -- use a sanitizer
+    -Z        sanitizer-memory-track-origins=val -- enable origins tracking in MemorySanitizer
+    -Z                     sanitizer-recover=val -- enable recovery for selected sanitizers
+    -Z                saturating-float-casts=val -- make float->int casts UB-free: numbers outside the integer type's range are clipped to the max/min integer respectively, and NaN is mapped to 0 (default: yes)
+    -Z                          self-profile=val -- run the self profiler and output the raw event data
+    -Z                  self-profile-counter=val -- counter used by the self profiler (default: `wall-time`), one of:
         `wall-time` (monotonic clock, i.e. `std::time::Instant`)
         `instructions:u` (retired instructions, userspace-only)
         `instructions-minus-irqs:u` (subtracting hardware interrupt counts for extra accuracy)
-    -Z                     self-profile-events=val -- specify the events recorded by the self profiler;
+    -Z                   self-profile-events=val -- specify the events recorded by the self profiler;
         for example: `-Z self-profile-events=default,query-keys`
         all options: none, all, default, generic-activity, query-provider, query-cache-hit
                      query-blocked, incr-cache-load, incr-result-hashing, query-keys, function-args, args, llvm, artifact-sizes
-    -Z                          share-generics=val -- make the current crate share its generic instantiations
-    -Z                               show-span=val -- show spans for compiler debugging (expr|pat|ty)
-    -Z         simulate-remapped-rust-src-base=val -- simulate the effect of remap-debuginfo = true at bootstrapping by remapping path to rust's source base directory. only meant for testing purposes
-    -Z                              span-debug=val -- forward proc_macro::Span's `Debug` impl to `Span`
-    -Z                       span-free-formats=val -- exclude spans when debug-printing compiler state (default: no)
-    -Z                    split-dwarf-inlining=val -- provide minimal debug info in the object/executable to facilitate online symbolication/stack traces in the absence of .dwo/.dwp files when using Split DWARF
-    -Z                        split-dwarf-kind=val -- split dwarf variant (only if -Csplit-debuginfo is enabled and on relevant platform)
+    -Z                        share-generics=val -- make the current crate share its generic instantiations
+    -Z                             show-span=val -- show spans for compiler debugging (expr|pat|ty)
+    -Z       simulate-remapped-rust-src-base=val -- simulate the effect of remap-debuginfo = true at bootstrapping by remapping path to rust's source base directory. only meant for testing purposes
+    -Z                            span-debug=val -- forward proc_macro::Span's `Debug` impl to `Span`
+    -Z                     span-free-formats=val -- exclude spans when debug-printing compiler state (default: no)
+    -Z                  split-dwarf-inlining=val -- provide minimal debug info in the object/executable to facilitate online symbolication/stack traces in the absence of .dwo/.dwp files when using Split DWARF
+    -Z                      split-dwarf-kind=val -- split dwarf variant (only if -Csplit-debuginfo is enabled and on relevant platform)
         (default: `split`)
 
         `split`: sections which do not require relocation are written into a DWARF object (`.dwo`)
                  file which is ignored by the linker
         `single`: sections which do not require relocation are written into object file but ignored
                   by the linker
-    -Z                      src-hash-algorithm=val -- hash algorithm of source files in debug info (`md5`, `sha1`, or `sha256`)
-    -Z                         stack-protector=val -- control stack smash protection strategy (`rustc --print stack-protector-strategies` for details)
-    -Z                      strict-init-checks=val -- control if mem::uninitialized and mem::zeroed panic on more UB
-    -Z                                   strip=val -- tell the linker which information to strip (`none` (default), `debuginfo` or `symbols`)
-    -Z                 symbol-mangling-version=val -- which mangling version to use for symbol names ('legacy' (default) or 'v0')
-    -Z                                   teach=val -- show extended diagnostic help (default: no)
-    -Z                               temps-dir=val -- the directory the intermediate files are written to
-    -Z                           terminal-urls=val -- use the OSC 8 hyperlink terminal specification to print hyperlinks in the compiler output
-    -Z                                 thinlto=val -- enable ThinLTO when possible
-    -Z                           thir-unsafeck=val -- use the THIR unsafety checker (default: no)
-    -Z                                 threads=val -- use a thread pool with N threads
-    -Z                        time-llvm-passes=val -- measure time of each LLVM pass (default: no)
-    -Z                             time-passes=val -- measure time of each rustc pass (default: no)
-    -Z                   tiny-const-eval-limit=val -- sets a tiny, non-configurable limit for const eval; useful for compiler tests
-    -Z                               tls-model=val -- choose the TLS model to use (`rustc --print tls-models` for details)
-    -Z                            trace-macros=val -- for every macro invocation, print its name and arguments (default: no)
-    -Z                       track-diagnostics=val -- tracks where in rustc a diagnostic was emitted
-    -Z                            trait-solver=val -- specify the trait solver mode used by rustc (default: classic)
-    -Z                translate-additional-ftl=val -- additional fluent translation to preferentially use (for testing translation)
-    -Z        translate-directionality-markers=val -- emit directionality isolation markers in translated diagnostics
-    -Z                          translate-lang=val -- language identifier for diagnostic output
-    -Z   translate-remapped-path-to-local-path=val -- translate remapped paths into local paths when possible (default: yes)
-    -Z                        trap-unreachable=val -- generate trap instructions for unreachable intrinsics (default: use target setting, usually yes)
-    -Z                        treat-err-as-bug=val -- treat error number `val` that occurs as bug
-    -Z                   trim-diagnostic-paths=val -- in diagnostics, use heuristics to shorten paths referring to items
-    -Z                                tune-cpu=val -- select processor to schedule for (`rustc --print target-cpus` for details)
-    -Z                              ui-testing=val -- emit compiler diagnostics in a form suitable for UI testing (default: no)
-    -Z            uninit-const-chunk-threshold=val -- allow generating const initializers with mixed init/uninit chunks, and set the maximum number of chunks for which this is allowed (default: 16)
-    -Z          unleash-the-miri-inside-of-you=val -- take the brakes off const evaluation. NOTE: this is unsound (default: no)
-    -Z                                unpretty=val -- present the input source, unstable (and less-pretty) variants;
+    -Z                    src-hash-algorithm=val -- hash algorithm of source files in debug info (`md5`, `sha1`, or `sha256`)
+    -Z                       stack-protector=val -- control stack smash protection strategy (`rustc --print stack-protector-strategies` for details)
+    -Z                    strict-init-checks=val -- control if mem::uninitialized and mem::zeroed panic on more UB
+    -Z                                 strip=val -- tell the linker which information to strip (`none` (default), `debuginfo` or `symbols`)
+    -Z               symbol-mangling-version=val -- which mangling version to use for symbol names ('legacy' (default) or 'v0')
+    -Z                                 teach=val -- show extended diagnostic help (default: no)
+    -Z                             temps-dir=val -- the directory the intermediate files are written to
+    -Z                         terminal-urls=val -- use the OSC 8 hyperlink terminal specification to print hyperlinks in the compiler output
+    -Z                               thinlto=val -- enable ThinLTO when possible
+    -Z                         thir-unsafeck=val -- use the THIR unsafety checker (default: no)
+    -Z                               threads=val -- use a thread pool with N threads
+    -Z                      time-llvm-passes=val -- measure time of each LLVM pass (default: no)
+    -Z                           time-passes=val -- measure time of each rustc pass (default: no)
+    -Z                 tiny-const-eval-limit=val -- sets a tiny, non-configurable limit for const eval; useful for compiler tests
+    -Z                             tls-model=val -- choose the TLS model to use (`rustc --print tls-models` for details)
+    -Z                          trace-macros=val -- for every macro invocation, print its name and arguments (default: no)
+    -Z                     track-diagnostics=val -- tracks where in rustc a diagnostic was emitted
+    -Z                          trait-solver=val -- specify the trait solver mode used by rustc (default: classic)
+    -Z              translate-additional-ftl=val -- additional fluent translation to preferentially use (for testing translation)
+    -Z      translate-directionality-markers=val -- emit directionality isolation markers in translated diagnostics
+    -Z                        translate-lang=val -- language identifier for diagnostic output
+    -Z translate-remapped-path-to-local-path=val -- translate remapped paths into local paths when possible (default: yes)
+    -Z                      trap-unreachable=val -- generate trap instructions for unreachable intrinsics (default: use target setting, usually yes)
+    -Z                      treat-err-as-bug=val -- treat error number `val` that occurs as bug
+    -Z                 trim-diagnostic-paths=val -- in diagnostics, use heuristics to shorten paths referring to items
+    -Z                              tune-cpu=val -- select processor to schedule for (`rustc --print target-cpus` for details)
+    -Z                            ui-testing=val -- emit compiler diagnostics in a form suitable for UI testing (default: no)
+    -Z          uninit-const-chunk-threshold=val -- allow generating const initializers with mixed init/uninit chunks, and set the maximum number of chunks for which this is allowed (default: 16)
+    -Z        unleash-the-miri-inside-of-you=val -- take the brakes off const evaluation. NOTE: this is unsound (default: no)
+    -Z                              unpretty=val -- present the input source, unstable (and less-pretty) variants;
         `normal`, `identified`,
         `expanded`, `expanded,identified`,
         `expanded,hygiene` (with internal representations),
@@ -207,11 +207,11 @@
         `hir,typed` (HIR with types for each node),
         `hir-tree` (dump the raw HIR),
         `mir` (the MIR), or `mir-cfg` (graphviz formatted MIR)
-    -Z                        unsound-mir-opts=val -- enable unsound and buggy MIR optimizations (default: no)
-    -Z                        unstable-options=val -- adds unstable command line options to rustc interface (default: no)
-    -Z                       use-ctors-section=val -- use legacy .ctors section for initializers rather than .init_array
-    -Z                            validate-mir=val -- validate MIR after each transformation
-    -Z                                 verbose=val -- in general, enable more debug printouts (default: no)
-    -Z                          verify-llvm-ir=val -- verify LLVM IR (default: no)
-    -Z            virtual-function-elimination=val -- enables dead virtual function elimination optimization. Requires `-Clto[=[fat,yes]]`
-    -Z                         wasi-exec-model=val -- whether to build a wasi command or reactor
+    -Z                      unsound-mir-opts=val -- enable unsound and buggy MIR optimizations (default: no)
+    -Z                      unstable-options=val -- adds unstable command line options to rustc interface (default: no)
+    -Z                     use-ctors-section=val -- use legacy .ctors section for initializers rather than .init_array
+    -Z                          validate-mir=val -- validate MIR after each transformation
+    -Z                               verbose=val -- in general, enable more debug printouts (default: no)
+    -Z                        verify-llvm-ir=val -- verify LLVM IR (default: no)
+    -Z          virtual-function-elimination=val -- enables dead virtual function elimination optimization. Requires `-Clto[=[fat,yes]]`
+    -Z                       wasi-exec-model=val -- whether to build a wasi command or reactor
diff --git a/tests/rustdoc/intra-doc/basic.rs b/tests/rustdoc/intra-doc/basic.rs
index e2d3ef425cb..96e21137b2d 100644
--- a/tests/rustdoc/intra-doc/basic.rs
+++ b/tests/rustdoc/intra-doc/basic.rs
@@ -2,7 +2,9 @@
 // @has - '//a/@href' 'struct.ThisType.html'
 // @has - '//a/@title' 'struct basic::ThisType'
 // @has - '//a/@href' 'struct.ThisType.html#method.this_method'
-// @has - '//a/@title' 'associated function basic::ThisType::this_method'
+// @has - '//a/@title' 'method basic::ThisType::this_method'
+// @has - '//a/@href' 'struct.ThisType.html#method.this_assoc_fn'
+// @has - '//a/@title' 'associated function basic::ThisType::this_assoc_fn'
 // @has - '//a/@href' 'enum.ThisEnum.html'
 // @has - '//a/@title' 'enum basic::ThisEnum'
 // @has - '//a/@href' 'enum.ThisEnum.html#variant.ThisVariant'
@@ -10,7 +12,9 @@
 // @has - '//a/@href' 'trait.ThisTrait.html'
 // @has - '//a/@title' 'trait basic::ThisTrait'
 // @has - '//a/@href' 'trait.ThisTrait.html#tymethod.this_associated_method'
-// @has - '//a/@title' 'associated function basic::ThisTrait::this_associated_method'
+// @has - '//a/@title' 'method basic::ThisTrait::this_associated_method'
+// @has - '//a/@href' 'trait.ThisTrait.html#tymethod.this_associated_fn'
+// @has - '//a/@title' 'associated function basic::ThisTrait::this_associated_fn'
 // @has - '//a/@href' 'trait.ThisTrait.html#associatedtype.ThisAssociatedType'
 // @has - '//a/@title' 'associated type basic::ThisTrait::ThisAssociatedType'
 // @has - '//a/@href' 'trait.ThisTrait.html#associatedconstant.THIS_ASSOCIATED_CONST'
@@ -37,11 +41,13 @@
 //!
 //! * [`ThisType`](ThisType)
 //! * [`ThisType::this_method`](ThisType::this_method)
+//! * [`ThisType::this_assoc_fn`](ThisType::this_assoc_fn)
 //! * [`ThisEnum`](ThisEnum)
 //! * [`ThisEnum::ThisVariant`](ThisEnum::ThisVariant)
 //! * [`ThisEnum::ThisVariantCtor`](ThisEnum::ThisVariantCtor)
 //! * [`ThisTrait`](ThisTrait)
 //! * [`ThisTrait::this_associated_method`](ThisTrait::this_associated_method)
+//! * [`ThisTrait::this_associated_fn`](ThisTrait::this_associated_fn)
 //! * [`ThisTrait::ThisAssociatedType`](ThisTrait::ThisAssociatedType)
 //! * [`ThisTrait::THIS_ASSOCIATED_CONST`](ThisTrait::THIS_ASSOCIATED_CONST)
 //! * [`ThisAlias`](ThisAlias)
@@ -68,13 +74,15 @@ macro_rules! this_macro {
 pub struct ThisType;
 
 impl ThisType {
-    pub fn this_method() {}
+    pub fn this_assoc_fn() {}
+    pub fn this_method(self) {}
 }
 pub enum ThisEnum { ThisVariant, ThisVariantCtor(u32), }
 pub trait ThisTrait {
     type ThisAssociatedType;
     const THIS_ASSOCIATED_CONST: u8;
-    fn this_associated_method();
+    fn this_associated_fn();
+    fn this_associated_method(&self);
 }
 pub type ThisAlias = Result<(), ()>;
 pub union ThisUnion { this_field: usize, }
diff --git a/tests/rustdoc/issue-108281.rs b/tests/rustdoc/issue-108281.rs
new file mode 100644
index 00000000000..8e1b6ba88a6
--- /dev/null
+++ b/tests/rustdoc/issue-108281.rs
@@ -0,0 +1,25 @@
+// Regression test for <https://github.com/rust-lang/rust/issues/108281>.
+// It ensures that the attributes on the first reexport are not duplicated.
+
+#![crate_name = "foo"]
+
+// @has 'foo/index.html'
+
+#[doc(hidden)]
+pub fn bar() {}
+mod sub {
+    pub fn public() {}
+}
+
+// @matches - '//*[@class="desc docblock-short"]' '^Displayed$'
+/// Displayed
+#[doc(inline)]
+pub use crate::bar as Bar;
+// @matches - '//*[@class="desc docblock-short"]' '^Hello\sDisplayed$'
+#[doc(inline)]
+/// Hello
+pub use crate::Bar as Bar2;
+
+// @matches - '//*[@class="desc docblock-short"]' '^Public$'
+/// Public
+pub use crate::sub::public as Public;
diff --git a/tests/rustdoc/item-desc-list-at-start.item-table.html b/tests/rustdoc/item-desc-list-at-start.item-table.html
new file mode 100644
index 00000000000..72bde573cea
--- /dev/null
+++ b/tests/rustdoc/item-desc-list-at-start.item-table.html
@@ -0,0 +1 @@
+<ul class="item-table"><li><div class="item-name"><a class="constant" href="constant.MY_CONSTANT.html" title="constant item_desc_list_at_start::MY_CONSTANT">MY_CONSTANT</a></div><div class="desc docblock-short">Groups: <code>SamplePatternSGIS</code>, <code>SamplePatternEXT</code></div></li></ul>
\ No newline at end of file
diff --git a/tests/rustdoc/item-desc-list-at-start.rs b/tests/rustdoc/item-desc-list-at-start.rs
new file mode 100644
index 00000000000..d88c61d333e
--- /dev/null
+++ b/tests/rustdoc/item-desc-list-at-start.rs
@@ -0,0 +1,9 @@
+// @has item_desc_list_at_start/index.html
+// @count - '//ul[@class="item-table"]/li/div/li' 0
+// @count - '//ul[@class="item-table"]/li' 1
+// @snapshot item-table - '//ul[@class="item-table"]'
+
+// based on https://docs.rs/gl_constants/0.1.1/src/gl_constants/lib.rs.html#16
+
+/// * Groups: `SamplePatternSGIS`, `SamplePatternEXT`
+pub const MY_CONSTANT: usize = 0;
diff --git a/tests/rustdoc/reexports-of-same-name.rs b/tests/rustdoc/reexports-of-same-name.rs
new file mode 100644
index 00000000000..fe6f1b38ca6
--- /dev/null
+++ b/tests/rustdoc/reexports-of-same-name.rs
@@ -0,0 +1,26 @@
+// This test ensures that there are 4 imports as expected:
+// * 2 for `Foo`
+// * 2 for `Bar`
+
+#![crate_name = "foo"]
+
+// @has 'foo/index.html'
+
+pub mod nested {
+    /// Foo the struct
+    pub struct Foo {}
+
+    #[allow(non_snake_case)]
+    /// Foo the function
+    pub fn Foo() {}
+}
+
+// @count - '//*[@id="main-content"]//code' 'pub use nested::Foo;' 2
+// @has - '//*[@id="reexport.Foo"]//a[@href="nested/struct.Foo.html"]' 'Foo'
+// @has - '//*[@id="reexport.Foo-1"]//a[@href="nested/fn.Foo.html"]' 'Foo'
+pub use nested::Foo;
+
+// @count - '//*[@id="main-content"]//code' 'pub use Foo as Bar;' 2
+// @has - '//*[@id="reexport.Bar"]//a[@href="nested/struct.Foo.html"]' 'Foo'
+// @has - '//*[@id="reexport.Bar-1"]//a[@href="nested/fn.Foo.html"]' 'Foo'
+pub use Foo as Bar;
diff --git a/tests/ui-fulldeps/create-dir-all-bare.rs b/tests/ui-fulldeps/create-dir-all-bare.rs
deleted file mode 100644
index 4554680ec24..00000000000
--- a/tests/ui-fulldeps/create-dir-all-bare.rs
+++ /dev/null
@@ -1,11 +0,0 @@
-// run-pass
-
-use std::env;
-use std::fs;
-use std::path::PathBuf;
-
-fn main() {
-    let path = PathBuf::from(env::var_os("RUST_TEST_TMPDIR").unwrap());
-    env::set_current_dir(&path).unwrap();
-    fs::create_dir_all("create-dir-all-bare").unwrap();
-}
diff --git a/tests/ui-fulldeps/fluent-messages/duplicate.ftl b/tests/ui-fulldeps/fluent-messages/duplicate.ftl
new file mode 100644
index 00000000000..871550b231a
--- /dev/null
+++ b/tests/ui-fulldeps/fluent-messages/duplicate.ftl
@@ -0,0 +1,3 @@
+no_crate_a_b_key = Value
+
+no_crate_a_b_key = Another Value
diff --git a/tests/ui-fulldeps/fluent-messages/label-with-hyphens.ftl b/tests/ui-fulldeps/fluent-messages/label-with-hyphens.ftl
index 016cbeef662..3088b1f8dc8 100644
--- a/tests/ui-fulldeps/fluent-messages/label-with-hyphens.ftl
+++ b/tests/ui-fulldeps/fluent-messages/label-with-hyphens.ftl
@@ -1,2 +1,2 @@
-label_with_hyphens_some_slug = hi
+no_crate_some_slug = hi
     .label-has-hyphens = test
diff --git a/tests/ui-fulldeps/fluent-messages/missing-crate-name.ftl b/tests/ui-fulldeps/fluent-messages/missing-crate-name.ftl
index 9bd035c1bba..0a64e3894bd 100644
--- a/tests/ui-fulldeps/fluent-messages/missing-crate-name.ftl
+++ b/tests/ui-fulldeps/fluent-messages/missing-crate-name.ftl
@@ -1,2 +1,2 @@
 with-hyphens = 1234
-test-crate_foo = abcd
+no-crate_foo = abcd
diff --git a/tests/ui-fulldeps/fluent-messages/missing-message-ref.ftl b/tests/ui-fulldeps/fluent-messages/missing-message-ref.ftl
index 0cd8229b230..4c6514a9770 100644
--- a/tests/ui-fulldeps/fluent-messages/missing-message-ref.ftl
+++ b/tests/ui-fulldeps/fluent-messages/missing-message-ref.ftl
@@ -1 +1 @@
-missing_message_ref = {message}
+no_crate_missing_message_ref = {message}
diff --git a/tests/ui-fulldeps/fluent-messages/missing-message.ftl b/tests/ui-fulldeps/fluent-messages/missing-message.ftl
index 74b2aa1d44d..61f56fd4d57 100644
--- a/tests/ui-fulldeps/fluent-messages/missing-message.ftl
+++ b/tests/ui-fulldeps/fluent-messages/missing-message.ftl
@@ -1 +1 @@
-missing_message =
+no_crate_missing_message =
diff --git a/tests/ui-fulldeps/fluent-messages/slug-with-hyphens.ftl b/tests/ui-fulldeps/fluent-messages/slug-with-hyphens.ftl
index 86ba9a268f3..a64c85094f1 100644
--- a/tests/ui-fulldeps/fluent-messages/slug-with-hyphens.ftl
+++ b/tests/ui-fulldeps/fluent-messages/slug-with-hyphens.ftl
@@ -1 +1 @@
-slug_with_hyphens_this-slug-has-hyphens = hi
+no_crate_this-slug-has-hyphens = hi
diff --git a/tests/ui-fulldeps/fluent-messages/test.rs b/tests/ui-fulldeps/fluent-messages/test.rs
index 74303e97dba..66575eb8e30 100644
--- a/tests/ui-fulldeps/fluent-messages/test.rs
+++ b/tests/ui-fulldeps/fluent-messages/test.rs
@@ -21,87 +21,74 @@ pub enum SubdiagnosticMessage {
 mod missing_absolute {
     use super::fluent_messages;
 
-    fluent_messages! {
-        missing_absolute => "/definitely_does_not_exist.ftl",
-//~^ ERROR could not open Fluent resource
-    }
+    fluent_messages! { "/definitely_does_not_exist.ftl" }
+    //~^ ERROR could not open Fluent resource
 }
 
 mod missing_relative {
     use super::fluent_messages;
 
-    fluent_messages! {
-        missing_relative => "../definitely_does_not_exist.ftl",
-//~^ ERROR could not open Fluent resource
-    }
+    fluent_messages! { "../definitely_does_not_exist.ftl" }
+    //~^ ERROR could not open Fluent resource
 }
 
 mod missing_message {
     use super::fluent_messages;
 
-    fluent_messages! {
-        missing_message => "./missing-message.ftl",
-//~^ ERROR could not parse Fluent resource
-    }
+    fluent_messages! { "./missing-message.ftl" }
+    //~^ ERROR could not parse Fluent resource
 }
 
 mod duplicate {
     use super::fluent_messages;
 
-    fluent_messages! {
-//~^ ERROR the name `a_b_key` is defined multiple times
-        a => "./duplicate-a.ftl",
-        a_b => "./duplicate-a-b.ftl",
-//~^ ERROR overrides existing message: `a_b_key`
-    }
+    fluent_messages! { "./duplicate.ftl" }
+    //~^ ERROR overrides existing message: `no_crate_a_b_key`
 }
 
 mod slug_with_hyphens {
     use super::fluent_messages;
 
-    fluent_messages! {
-        slug_with_hyphens => "./slug-with-hyphens.ftl",
-//~^ ERROR name `slug_with_hyphens_this-slug-has-hyphens` contains a '-' character
-    }
+    fluent_messages! { "./slug-with-hyphens.ftl" }
+    //~^ ERROR name `no_crate_this-slug-has-hyphens` contains a '-' character
 }
 
 mod label_with_hyphens {
     use super::fluent_messages;
 
-    fluent_messages! {
-        label_with_hyphens => "./label-with-hyphens.ftl",
-//~^ ERROR attribute `label-has-hyphens` contains a '-' character
-    }
+    fluent_messages! { "./label-with-hyphens.ftl" }
+    //~^ ERROR attribute `label-has-hyphens` contains a '-' character
 }
 
 mod valid {
     use super::fluent_messages;
 
-    fluent_messages! {
-        valid => "./valid.ftl",
-    }
+    fluent_messages! { "./valid.ftl" }
 
-    use self::fluent_generated::{DEFAULT_LOCALE_RESOURCES, valid_key};
+    mod test_generated {
+        use super::{fluent_generated::no_crate_key, DEFAULT_LOCALE_RESOURCE};
+    }
 }
 
 mod missing_crate_name {
     use super::fluent_messages;
 
-    fluent_messages! {
-        test_crate => "./missing-crate-name.ftl",
-//~^ ERROR name `test-crate_foo` contains a '-' character
-//~| ERROR name `with-hyphens` contains a '-' character
-//~| ERROR name `with-hyphens` does not start with the crate name
-    }
+    fluent_messages! { "./missing-crate-name.ftl" }
+    //~^ ERROR name `no-crate_foo` contains a '-' character
+    //~| ERROR name `with-hyphens` contains a '-' character
+    //~| ERROR name `with-hyphens` does not start with the crate name
 
-    use self::fluent_generated::{DEFAULT_LOCALE_RESOURCES, test_crate_foo, with_hyphens};
+    mod test_generated {
+        use super::{
+            fluent_generated::{no_crate_foo, with_hyphens},
+            DEFAULT_LOCALE_RESOURCE,
+        };
+    }
 }
 
 mod missing_message_ref {
     use super::fluent_messages;
 
-    fluent_messages! {
-        missing => "./missing-message-ref.ftl"
-//~^ ERROR referenced message `message` does not exist
-    }
+    fluent_messages! { "./missing-message-ref.ftl" }
+    //~^ ERROR referenced message `message` does not exist
 }
diff --git a/tests/ui-fulldeps/fluent-messages/test.stderr b/tests/ui-fulldeps/fluent-messages/test.stderr
index 2631b0a6232..c7961ed22f2 100644
--- a/tests/ui-fulldeps/fluent-messages/test.stderr
+++ b/tests/ui-fulldeps/fluent-messages/test.stderr
@@ -1,106 +1,87 @@
 error: could not open Fluent resource
-  --> $DIR/test.rs:25:29
+  --> $DIR/test.rs:24:24
    |
-LL |         missing_absolute => "/definitely_does_not_exist.ftl",
-   |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |     fluent_messages! { "/definitely_does_not_exist.ftl" }
+   |                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: os-specific message
 
 error: could not open Fluent resource
-  --> $DIR/test.rs:34:29
+  --> $DIR/test.rs:31:24
    |
-LL |         missing_relative => "../definitely_does_not_exist.ftl",
-   |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |     fluent_messages! { "../definitely_does_not_exist.ftl" }
+   |                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: os-specific message
 
 error: could not parse Fluent resource
-  --> $DIR/test.rs:43:28
+  --> $DIR/test.rs:38:24
    |
-LL |         missing_message => "./missing-message.ftl",
-   |                            ^^^^^^^^^^^^^^^^^^^^^^^
+LL |     fluent_messages! { "./missing-message.ftl" }
+   |                        ^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: see additional errors emitted
 
-error: expected a message field for "missing_message"
+error: expected a message field for "no_crate_missing_message"
  --> ./missing-message.ftl:1:1
   |
-1 | missing_message =
-  | ^^^^^^^^^^^^^^^^^
+1 | no_crate_missing_message =
+  | ^^^^^^^^^^^^^^^^^^^^^^^^^^
   |
 
-error: overrides existing message: `a_b_key`
-  --> $DIR/test.rs:54:16
+error: overrides existing message: `no_crate_a_b_key`
+  --> $DIR/test.rs:45:24
    |
-LL |         a_b => "./duplicate-a-b.ftl",
-   |                ^^^^^^^^^^^^^^^^^^^^^
-   |
-help: previously defined in this resource
-  --> $DIR/test.rs:53:14
-   |
-LL |         a => "./duplicate-a.ftl",
-   |              ^^^^^^^^^^^^^^^^^^^
-
-error[E0428]: the name `a_b_key` is defined multiple times
-  --> $DIR/test.rs:51:5
-   |
-LL |     fluent_messages! {
-   |     ^^^^^^^^^^^^^^^^
-   |     |
-   |     `a_b_key` redefined here
-   |     previous definition of the value `a_b_key` here
-   |
-   = note: os-specific message
-   = note: os-specific message
+LL |     fluent_messages! { "./duplicate.ftl" }
+   |                        ^^^^^^^^^^^^^^^^^
 
-error: name `slug_with_hyphens_this-slug-has-hyphens` contains a '-' character
-  --> $DIR/test.rs:63:30
+error: name `no_crate_this-slug-has-hyphens` contains a '-' character
+  --> $DIR/test.rs:52:24
    |
-LL |         slug_with_hyphens => "./slug-with-hyphens.ftl",
-   |                              ^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |     fluent_messages! { "./slug-with-hyphens.ftl" }
+   |                        ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: replace any '-'s with '_'s
 
 error: attribute `label-has-hyphens` contains a '-' character
-  --> $DIR/test.rs:72:31
+  --> $DIR/test.rs:59:24
    |
-LL |         label_with_hyphens => "./label-with-hyphens.ftl",
-   |                               ^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |     fluent_messages! { "./label-with-hyphens.ftl" }
+   |                        ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: replace any '-'s with '_'s
 
 error: name `with-hyphens` contains a '-' character
-  --> $DIR/test.rs:91:23
+  --> $DIR/test.rs:76:24
    |
-LL |         test_crate => "./missing-crate-name.ftl",
-   |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |     fluent_messages! { "./missing-crate-name.ftl" }
+   |                        ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: replace any '-'s with '_'s
 
 error: name `with-hyphens` does not start with the crate name
-  --> $DIR/test.rs:91:23
+  --> $DIR/test.rs:76:24
    |
-LL |         test_crate => "./missing-crate-name.ftl",
-   |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |     fluent_messages! { "./missing-crate-name.ftl" }
+   |                        ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = help: prepend `test_crate_` to the slug name: `test_crate_with_hyphens`
+   = help: prepend `no_crate_` to the slug name: `no_crate_with_hyphens`
 
-error: name `test-crate_foo` contains a '-' character
-  --> $DIR/test.rs:91:23
+error: name `no-crate_foo` contains a '-' character
+  --> $DIR/test.rs:76:24
    |
-LL |         test_crate => "./missing-crate-name.ftl",
-   |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |     fluent_messages! { "./missing-crate-name.ftl" }
+   |                        ^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: replace any '-'s with '_'s
 
-error: referenced message `message` does not exist (in message `missing_message_ref`)
-  --> $DIR/test.rs:104:20
+error: referenced message `message` does not exist (in message `no_crate_missing_message_ref`)
+  --> $DIR/test.rs:92:24
    |
-LL |         missing => "./missing-message-ref.ftl"
-   |                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |     fluent_messages! { "./missing-message-ref.ftl" }
+   |                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: you may have meant to use a variable reference (`{$message}`)
 
-error: aborting due to 11 previous errors
+error: aborting due to 10 previous errors
 
-For more information about this error, try `rustc --explain E0428`.
diff --git a/tests/ui-fulldeps/fluent-messages/valid.ftl b/tests/ui-fulldeps/fluent-messages/valid.ftl
index 54927430600..598473adb68 100644
--- a/tests/ui-fulldeps/fluent-messages/valid.ftl
+++ b/tests/ui-fulldeps/fluent-messages/valid.ftl
@@ -1 +1 @@
-valid_key = Valid!
+no_crate_key = Valid!
diff --git a/tests/ui-fulldeps/internal-lints/diagnostics.ftl b/tests/ui-fulldeps/internal-lints/diagnostics.ftl
new file mode 100644
index 00000000000..cb2d476d815
--- /dev/null
+++ b/tests/ui-fulldeps/internal-lints/diagnostics.ftl
@@ -0,0 +1,5 @@
+no_crate_example = this is an example message used in testing
+    .note = with a note
+    .help = with a help
+    .suggestion = with a suggestion
+    .label = with a label
diff --git a/tests/ui-fulldeps/internal-lints/diagnostics.rs b/tests/ui-fulldeps/internal-lints/diagnostics.rs
index 643e81d99c6..3aa65d53d4e 100644
--- a/tests/ui-fulldeps/internal-lints/diagnostics.rs
+++ b/tests/ui-fulldeps/internal-lints/diagnostics.rs
@@ -13,20 +13,22 @@ extern crate rustc_span;
 
 use rustc_errors::{
     AddToDiagnostic, IntoDiagnostic, Diagnostic, DiagnosticBuilder,
-    ErrorGuaranteed, Handler, fluent, SubdiagnosticMessage,
+    ErrorGuaranteed, Handler, DiagnosticMessage, SubdiagnosticMessage,
 };
-use rustc_macros::{Diagnostic, Subdiagnostic};
+use rustc_macros::{fluent_messages, Diagnostic, Subdiagnostic};
 use rustc_span::Span;
 
+fluent_messages! { "./diagnostics.ftl" }
+
 #[derive(Diagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct DeriveDiagnostic {
     #[primary_span]
     span: Span,
 }
 
 #[derive(Subdiagnostic)]
-#[note(compiletest_example)]
+#[note(no_crate_example)]
 struct Note {
     #[primary_span]
     span: Span,
@@ -45,7 +47,7 @@ pub struct TranslatableInIntoDiagnostic;
 
 impl<'a> IntoDiagnostic<'a, ErrorGuaranteed> for TranslatableInIntoDiagnostic {
     fn into_diagnostic(self, handler: &'a Handler) -> DiagnosticBuilder<'a, ErrorGuaranteed> {
-        handler.struct_err(fluent::compiletest_example)
+        handler.struct_err(crate::fluent_generated::no_crate_example)
     }
 }
 
@@ -68,12 +70,12 @@ impl AddToDiagnostic for TranslatableInAddToDiagnostic {
     where
         F: Fn(&mut Diagnostic, SubdiagnosticMessage) -> SubdiagnosticMessage,
     {
-        diag.note(fluent::note);
+        diag.note(crate::fluent_generated::no_crate_note);
     }
 }
 
 pub fn make_diagnostics<'a>(handler: &'a Handler) {
-    let _diag = handler.struct_err(fluent::compiletest_example);
+    let _diag = handler.struct_err(crate::fluent_generated::no_crate_example);
     //~^ ERROR diagnostics should only be created in `IntoDiagnostic`/`AddToDiagnostic` impls
 
     let _diag = handler.struct_err("untranslatable diagnostic");
diff --git a/tests/ui-fulldeps/internal-lints/diagnostics.stderr b/tests/ui-fulldeps/internal-lints/diagnostics.stderr
index 510d6a17108..6f797ebc2dd 100644
--- a/tests/ui-fulldeps/internal-lints/diagnostics.stderr
+++ b/tests/ui-fulldeps/internal-lints/diagnostics.stderr
@@ -1,5 +1,5 @@
 error: diagnostics should be created using translatable messages
-  --> $DIR/diagnostics.rs:39:17
+  --> $DIR/diagnostics.rs:41:17
    |
 LL |         handler.struct_err("untranslatable diagnostic")
    |                 ^^^^^^^^^^
@@ -11,15 +11,15 @@ LL | #![deny(rustc::untranslatable_diagnostic)]
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: diagnostics should be created using translatable messages
-  --> $DIR/diagnostics.rs:59:14
+  --> $DIR/diagnostics.rs:61:14
    |
 LL |         diag.note("untranslatable diagnostic");
    |              ^^^^
 
 error: diagnostics should only be created in `IntoDiagnostic`/`AddToDiagnostic` impls
-  --> $DIR/diagnostics.rs:76:25
+  --> $DIR/diagnostics.rs:78:25
    |
-LL |     let _diag = handler.struct_err(fluent::compiletest_example);
+LL |     let _diag = handler.struct_err(crate::fluent_generated::no_crate_example);
    |                         ^^^^^^^^^^
    |
 note: the lint level is defined here
@@ -29,13 +29,13 @@ LL | #![deny(rustc::diagnostic_outside_of_impl)]
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: diagnostics should only be created in `IntoDiagnostic`/`AddToDiagnostic` impls
-  --> $DIR/diagnostics.rs:79:25
+  --> $DIR/diagnostics.rs:81:25
    |
 LL |     let _diag = handler.struct_err("untranslatable diagnostic");
    |                         ^^^^^^^^^^
 
 error: diagnostics should be created using translatable messages
-  --> $DIR/diagnostics.rs:79:25
+  --> $DIR/diagnostics.rs:81:25
    |
 LL |     let _diag = handler.struct_err("untranslatable diagnostic");
    |                         ^^^^^^^^^^
diff --git a/tests/ui-fulldeps/mod_dir_path_canonicalized.rs b/tests/ui-fulldeps/mod_dir_path_canonicalized.rs
index bdfd9628c48..ddc86c1dc31 100644
--- a/tests/ui-fulldeps/mod_dir_path_canonicalized.rs
+++ b/tests/ui-fulldeps/mod_dir_path_canonicalized.rs
@@ -31,7 +31,10 @@ pub fn main() {
 }
 
 fn parse() {
-    let parse_session = ParseSess::new(FilePathMapping::empty());
+    let parse_session = ParseSess::new(
+        vec![rustc_parse::DEFAULT_LOCALE_RESOURCE],
+        FilePathMapping::empty()
+    );
 
     let path = Path::new(file!());
     let path = path.canonicalize().unwrap();
diff --git a/tests/ui-fulldeps/pprust-expr-roundtrip.rs b/tests/ui-fulldeps/pprust-expr-roundtrip.rs
index 7a91dcf0dad..e417a6a833b 100644
--- a/tests/ui-fulldeps/pprust-expr-roundtrip.rs
+++ b/tests/ui-fulldeps/pprust-expr-roundtrip.rs
@@ -41,7 +41,7 @@ use rustc_session::parse::ParseSess;
 use rustc_span::source_map::FilePathMapping;
 use rustc_span::source_map::{FileName, Spanned, DUMMY_SP};
 use rustc_span::symbol::Ident;
-use thin_vec::thin_vec;
+use thin_vec::{thin_vec, ThinVec};
 
 fn parse_expr(ps: &ParseSess, src: &str) -> Option<P<Expr>> {
     let src_as_string = src.to_string();
@@ -76,17 +76,17 @@ fn iter_exprs(depth: usize, f: &mut dyn FnMut(P<Expr>)) {
     for kind in 0..=19 {
         match kind {
             0 => iter_exprs(depth - 1, &mut |e| g(ExprKind::Box(e))),
-            1 => iter_exprs(depth - 1, &mut |e| g(ExprKind::Call(e, vec![]))),
+            1 => iter_exprs(depth - 1, &mut |e| g(ExprKind::Call(e, thin_vec![]))),
             2 => {
                 let seg = PathSegment::from_ident(Ident::from_str("x"));
                 iter_exprs(depth - 1, &mut |e| {
                     g(ExprKind::MethodCall(Box::new(MethodCall {
-                        seg: seg.clone(), receiver: e, args: vec![make_x()], span: DUMMY_SP
+                        seg: seg.clone(), receiver: e, args: thin_vec![make_x()], span: DUMMY_SP
                     }))
                 )});
                 iter_exprs(depth - 1, &mut |e| {
                     g(ExprKind::MethodCall(Box::new(MethodCall {
-                        seg: seg.clone(), receiver: make_x(), args: vec![e], span: DUMMY_SP
+                        seg: seg.clone(), receiver: make_x(), args: thin_vec![e], span: DUMMY_SP
                     }))
                 )});
             }
@@ -111,7 +111,7 @@ fn iter_exprs(depth: usize, f: &mut dyn FnMut(P<Expr>)) {
             }
             10 => {
                 let block = P(Block {
-                    stmts: Vec::new(),
+                    stmts: ThinVec::new(),
                     id: DUMMY_NODE_ID,
                     rules: BlockCheckMode::Default,
                     span: DUMMY_SP,
@@ -121,7 +121,7 @@ fn iter_exprs(depth: usize, f: &mut dyn FnMut(P<Expr>)) {
                 iter_exprs(depth - 1, &mut |e| g(ExprKind::If(e, block.clone(), None)));
             }
             11 => {
-                let decl = P(FnDecl { inputs: vec![], output: FnRetTy::Default(DUMMY_SP) });
+                let decl = P(FnDecl { inputs: thin_vec![], output: FnRetTy::Default(DUMMY_SP) });
                 iter_exprs(depth - 1, &mut |e| {
                     g(ExprKind::Closure(Box::new(Closure {
                         binder: ClosureBinder::NotPresent,
@@ -165,7 +165,7 @@ fn iter_exprs(depth: usize, f: &mut dyn FnMut(P<Expr>)) {
                 g(ExprKind::Struct(P(StructExpr {
                     qself: None,
                     path,
-                    fields: vec![],
+                    fields: thin_vec![],
                     rest: StructRest::Base(make_x()),
                 })));
             }
@@ -220,7 +220,7 @@ fn main() {
 }
 
 fn run() {
-    let ps = ParseSess::new(FilePathMapping::empty());
+    let ps = ParseSess::new(vec![rustc_parse::DEFAULT_LOCALE_RESOURCE], FilePathMapping::empty());
 
     iter_exprs(2, &mut |mut e| {
         // If the pretty printer is correct, then `parse(print(e))` should be identical to `e`,
diff --git a/tests/ui-fulldeps/rename-directory.rs b/tests/ui-fulldeps/rename-directory.rs
deleted file mode 100644
index 8fc340cb918..00000000000
--- a/tests/ui-fulldeps/rename-directory.rs
+++ /dev/null
@@ -1,30 +0,0 @@
-// run-pass
-
-#![allow(unused_must_use)]
-#![allow(unused_imports)]
-// This test can't be a unit test in std,
-// because it needs TempDir, which is in extra
-
-// ignore-cross-compile
-
-use std::env;
-use std::ffi::CString;
-use std::fs::{self, File};
-use std::path::PathBuf;
-
-fn rename_directory() {
-    let tmpdir = PathBuf::from(env::var_os("RUST_TEST_TMPDIR").unwrap());
-    let old_path = tmpdir.join("foo/bar/baz");
-    fs::create_dir_all(&old_path).unwrap();
-    let test_file = &old_path.join("temp.txt");
-
-    File::create(test_file).unwrap();
-
-    let new_path = tmpdir.join("quux/blat");
-    fs::create_dir_all(&new_path).unwrap();
-    fs::rename(&old_path, &new_path.join("newdir"));
-    assert!(new_path.join("newdir").is_dir());
-    assert!(new_path.join("newdir/temp.txt").exists());
-}
-
-pub fn main() { rename_directory() }
diff --git a/tests/ui-fulldeps/session-diagnostic/diagnostic-derive.rs b/tests/ui-fulldeps/session-diagnostic/diagnostic-derive.rs
index 07f95d13937..01e6434b075 100644
--- a/tests/ui-fulldeps/session-diagnostic/diagnostic-derive.rs
+++ b/tests/ui-fulldeps/session-diagnostic/diagnostic-derive.rs
@@ -17,26 +17,28 @@ use rustc_span::symbol::Ident;
 use rustc_span::Span;
 
 extern crate rustc_macros;
-use rustc_macros::{Diagnostic, LintDiagnostic, Subdiagnostic};
+use rustc_macros::{fluent_messages, Diagnostic, LintDiagnostic, Subdiagnostic};
 
 extern crate rustc_middle;
 use rustc_middle::ty::Ty;
 
 extern crate rustc_errors;
-use rustc_errors::{Applicability, MultiSpan};
+use rustc_errors::{Applicability, DiagnosticMessage, MultiSpan, SubdiagnosticMessage};
 
 extern crate rustc_session;
 
+fluent_messages! { "./example.ftl" }
+
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct Hello {}
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct HelloWarn {}
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 //~^ ERROR unsupported type attribute for diagnostic derive enum
 enum DiagnosticOnEnum {
     Foo,
@@ -46,13 +48,13 @@ enum DiagnosticOnEnum {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 #[diag = "E0123"]
 //~^ ERROR `#[diag = ...]` is not a valid attribute
 struct WrongStructAttrStyle {}
 
 #[derive(Diagnostic)]
-#[nonsense(compiletest_example, code = "E0123")]
+#[nonsense(no_crate_example, code = "E0123")]
 //~^ ERROR `#[nonsense(...)]` is not a valid attribute
 //~^^ ERROR diagnostic slug not specified
 //~^^^ ERROR cannot find attribute `nonsense` in this scope
@@ -66,7 +68,7 @@ struct InvalidLitNestedAttr {}
 
 #[derive(Diagnostic)]
 #[diag(nonsense, code = "E0123")]
-//~^ ERROR cannot find value `nonsense` in module `rustc_errors::fluent`
+//~^ ERROR cannot find value `nonsense` in module `crate::fluent_generated`
 struct InvalidNestedStructAttr {}
 
 #[derive(Diagnostic)]
@@ -90,12 +92,12 @@ struct InvalidNestedStructAttr2 {}
 struct InvalidNestedStructAttr3 {}
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123", slug = "foo")]
+#[diag(no_crate_example, code = "E0123", slug = "foo")]
 //~^ ERROR `#[diag(slug = ...)]` is not a valid attribute
 struct InvalidNestedStructAttr4 {}
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct WrongPlaceField {
     #[suggestion = "bar"]
     //~^ ERROR `#[suggestion = ...]` is not a valid attribute
@@ -103,20 +105,20 @@ struct WrongPlaceField {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
-#[diag(compiletest_example, code = "E0456")]
+#[diag(no_crate_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0456")]
 //~^ ERROR specified multiple times
 //~^^ ERROR specified multiple times
 struct DiagSpecifiedTwice {}
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0456", code = "E0457")]
+#[diag(no_crate_example, code = "E0456", code = "E0457")]
 //~^ ERROR specified multiple times
 struct CodeSpecifiedTwice {}
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, compiletest_example, code = "E0456")]
-//~^ ERROR `#[diag(compiletest_example)]` is not a valid attribute
+#[diag(no_crate_example, no_crate::example, code = "E0456")]
+//~^ ERROR `#[diag(no_crate::example)]` is not a valid attribute
 struct SlugSpecifiedTwice {}
 
 #[derive(Diagnostic)]
@@ -128,11 +130,11 @@ struct KindNotProvided {} //~ ERROR diagnostic slug not specified
 struct SlugNotProvided {}
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct CodeNotProvided {}
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct MessageWrongType {
     #[primary_span]
     //~^ ERROR `#[primary_span]` attribute can only be applied to fields of type `Span` or `MultiSpan`
@@ -140,7 +142,7 @@ struct MessageWrongType {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct InvalidPathFieldAttr {
     #[nonsense]
     //~^ ERROR `#[nonsense]` is not a valid attribute
@@ -149,34 +151,34 @@ struct InvalidPathFieldAttr {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ErrorWithField {
     name: String,
-    #[label(label)]
+    #[label(no_crate_label)]
     span: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ErrorWithMessageAppliedToField {
-    #[label(label)]
+    #[label(no_crate_label)]
     //~^ ERROR the `#[label(...)]` attribute can only be applied to fields of type `Span` or `MultiSpan`
     name: String,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ErrorWithNonexistentField {
-    #[suggestion(suggestion, code = "{name}")]
+    #[suggestion(no_crate_suggestion, code = "{name}")]
     //~^ ERROR `name` doesn't refer to a field on this type
     suggestion: (Span, Applicability),
 }
 
 #[derive(Diagnostic)]
 //~^ ERROR invalid format string: expected `'}'`
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ErrorMissingClosingBrace {
-    #[suggestion(suggestion, code = "{name")]
+    #[suggestion(no_crate_suggestion, code = "{name")]
     suggestion: (Span, Applicability),
     name: String,
     val: usize,
@@ -184,50 +186,50 @@ struct ErrorMissingClosingBrace {
 
 #[derive(Diagnostic)]
 //~^ ERROR invalid format string: unmatched `}`
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ErrorMissingOpeningBrace {
-    #[suggestion(suggestion, code = "name}")]
+    #[suggestion(no_crate_suggestion, code = "name}")]
     suggestion: (Span, Applicability),
     name: String,
     val: usize,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct LabelOnSpan {
-    #[label(label)]
+    #[label(no_crate_label)]
     sp: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct LabelOnNonSpan {
-    #[label(label)]
+    #[label(no_crate_label)]
     //~^ ERROR the `#[label(...)]` attribute can only be applied to fields of type `Span` or `MultiSpan`
     id: u32,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct Suggest {
-    #[suggestion(suggestion, code = "This is the suggested code")]
-    #[suggestion(suggestion, code = "This is the suggested code", style = "normal")]
-    #[suggestion(suggestion, code = "This is the suggested code", style = "short")]
-    #[suggestion(suggestion, code = "This is the suggested code", style = "hidden")]
-    #[suggestion(suggestion, code = "This is the suggested code", style = "verbose")]
+    #[suggestion(no_crate_suggestion, code = "This is the suggested code")]
+    #[suggestion(no_crate_suggestion, code = "This is the suggested code", style = "normal")]
+    #[suggestion(no_crate_suggestion, code = "This is the suggested code", style = "short")]
+    #[suggestion(no_crate_suggestion, code = "This is the suggested code", style = "hidden")]
+    #[suggestion(no_crate_suggestion, code = "This is the suggested code", style = "verbose")]
     suggestion: (Span, Applicability),
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct SuggestWithoutCode {
-    #[suggestion(suggestion)]
+    #[suggestion(no_crate_suggestion)]
     //~^ ERROR suggestion without `code = "..."`
     suggestion: (Span, Applicability),
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct SuggestWithBadKey {
     #[suggestion(nonsense = "bar")]
     //~^ ERROR `#[suggestion(nonsense = ...)]` is not a valid attribute
@@ -236,7 +238,7 @@ struct SuggestWithBadKey {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct SuggestWithShorthandMsg {
     #[suggestion(msg = "bar")]
     //~^ ERROR `#[suggestion(msg = ...)]` is not a valid attribute
@@ -245,52 +247,52 @@ struct SuggestWithShorthandMsg {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct SuggestWithoutMsg {
     #[suggestion(code = "bar")]
     suggestion: (Span, Applicability),
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct SuggestWithTypesSwapped {
-    #[suggestion(suggestion, code = "This is suggested code")]
+    #[suggestion(no_crate_suggestion, code = "This is suggested code")]
     suggestion: (Applicability, Span),
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct SuggestWithWrongTypeApplicabilityOnly {
-    #[suggestion(suggestion, code = "This is suggested code")]
+    #[suggestion(no_crate_suggestion, code = "This is suggested code")]
     //~^ ERROR wrong field type for suggestion
     suggestion: Applicability,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct SuggestWithSpanOnly {
-    #[suggestion(suggestion, code = "This is suggested code")]
+    #[suggestion(no_crate_suggestion, code = "This is suggested code")]
     suggestion: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct SuggestWithDuplicateSpanAndApplicability {
-    #[suggestion(suggestion, code = "This is suggested code")]
+    #[suggestion(no_crate_suggestion, code = "This is suggested code")]
     suggestion: (Span, Span, Applicability),
     //~^ ERROR specified multiple times
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct SuggestWithDuplicateApplicabilityAndSpan {
-    #[suggestion(suggestion, code = "This is suggested code")]
+    #[suggestion(no_crate_suggestion, code = "This is suggested code")]
     suggestion: (Applicability, Applicability, Span),
     //~^ ERROR specified multiple times
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct WrongKindOfAnnotation {
     #[label = "bar"]
     //~^ ERROR `#[label = ...]` is not a valid attribute
@@ -298,38 +300,38 @@ struct WrongKindOfAnnotation {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct OptionsInErrors {
-    #[label(label)]
+    #[label(no_crate_label)]
     label: Option<Span>,
-    #[suggestion(suggestion, code = "...")]
+    #[suggestion(no_crate_suggestion, code = "...")]
     opt_sugg: Option<(Span, Applicability)>,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0456")]
+#[diag(no_crate_example, code = "E0456")]
 struct MoveOutOfBorrowError<'tcx> {
     name: Ident,
     ty: Ty<'tcx>,
     #[primary_span]
-    #[label(label)]
+    #[label(no_crate_label)]
     span: Span,
-    #[label(label)]
+    #[label(no_crate_label)]
     other_span: Span,
-    #[suggestion(suggestion, code = "{name}.clone()")]
+    #[suggestion(no_crate_suggestion, code = "{name}.clone()")]
     opt_sugg: Option<(Span, Applicability)>,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ErrorWithLifetime<'a> {
-    #[label(label)]
+    #[label(no_crate_label)]
     span: Span,
     name: &'a str,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ErrorWithDefaultLabelAttr<'a> {
     #[label]
     span: Span,
@@ -338,7 +340,7 @@ struct ErrorWithDefaultLabelAttr<'a> {
 
 #[derive(Diagnostic)]
 //~^ ERROR the trait bound `Hello: IntoDiagnosticArg` is not satisfied
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ArgFieldWithoutSkip {
     #[primary_span]
     span: Span,
@@ -346,7 +348,7 @@ struct ArgFieldWithoutSkip {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ArgFieldWithSkip {
     #[primary_span]
     span: Span,
@@ -357,132 +359,132 @@ struct ArgFieldWithSkip {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ErrorWithSpannedNote {
     #[note]
     span: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ErrorWithSpannedNoteCustom {
-    #[note(note)]
+    #[note(no_crate_note)]
     span: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 #[note]
 struct ErrorWithNote {
     val: String,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
-#[note(note)]
+#[diag(no_crate_example, code = "E0123")]
+#[note(no_crate_note)]
 struct ErrorWithNoteCustom {
     val: String,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ErrorWithSpannedHelp {
     #[help]
     span: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ErrorWithSpannedHelpCustom {
-    #[help(help)]
+    #[help(no_crate_help)]
     span: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 #[help]
 struct ErrorWithHelp {
     val: String,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
-#[help(help)]
+#[diag(no_crate_example, code = "E0123")]
+#[help(no_crate_help)]
 struct ErrorWithHelpCustom {
     val: String,
 }
 
 #[derive(Diagnostic)]
 #[help]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ErrorWithHelpWrongOrder {
     val: String,
 }
 
 #[derive(Diagnostic)]
-#[help(help)]
-#[diag(compiletest_example, code = "E0123")]
+#[help(no_crate_help)]
+#[diag(no_crate_example, code = "E0123")]
 struct ErrorWithHelpCustomWrongOrder {
     val: String,
 }
 
 #[derive(Diagnostic)]
 #[note]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ErrorWithNoteWrongOrder {
     val: String,
 }
 
 #[derive(Diagnostic)]
-#[note(note)]
-#[diag(compiletest_example, code = "E0123")]
+#[note(no_crate_note)]
+#[diag(no_crate_example, code = "E0123")]
 struct ErrorWithNoteCustomWrongOrder {
     val: String,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ApplicabilityInBoth {
-    #[suggestion(suggestion, code = "...", applicability = "maybe-incorrect")]
+    #[suggestion(no_crate_suggestion, code = "...", applicability = "maybe-incorrect")]
     //~^ ERROR specified multiple times
     suggestion: (Span, Applicability),
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct InvalidApplicability {
-    #[suggestion(suggestion, code = "...", applicability = "batman")]
+    #[suggestion(no_crate_suggestion, code = "...", applicability = "batman")]
     //~^ ERROR invalid applicability
     suggestion: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ValidApplicability {
-    #[suggestion(suggestion, code = "...", applicability = "maybe-incorrect")]
+    #[suggestion(no_crate_suggestion, code = "...", applicability = "maybe-incorrect")]
     suggestion: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct NoApplicability {
-    #[suggestion(suggestion, code = "...")]
+    #[suggestion(no_crate_suggestion, code = "...")]
     suggestion: Span,
 }
 
 #[derive(Subdiagnostic)]
-#[note(parse_add_paren)]
+#[note(no_crate_example)]
 struct Note;
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct Subdiagnostic {
     #[subdiagnostic]
     note: Note,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct VecField {
     #[primary_span]
     #[label]
@@ -490,57 +492,57 @@ struct VecField {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct UnitField {
     #[primary_span]
     spans: Span,
     #[help]
     foo: (),
-    #[help(help)]
+    #[help(no_crate_help)]
     bar: (),
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct OptUnitField {
     #[primary_span]
     spans: Span,
     #[help]
     foo: Option<()>,
-    #[help(help)]
+    #[help(no_crate_help)]
     bar: Option<()>,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct LabelWithTrailingPath {
-    #[label(label, foo)]
+    #[label(no_crate_label, foo)]
     //~^ ERROR `#[label(foo)]` is not a valid attribute
     span: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct LabelWithTrailingNameValue {
-    #[label(label, foo = "...")]
+    #[label(no_crate_label, foo = "...")]
     //~^ ERROR `#[label(foo = ...)]` is not a valid attribute
     span: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct LabelWithTrailingList {
-    #[label(label, foo("..."))]
+    #[label(no_crate_label, foo("..."))]
     //~^ ERROR `#[label(foo(...))]` is not a valid attribute
     span: Span,
 }
 
 #[derive(LintDiagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct LintsGood {}
 
 #[derive(LintDiagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct PrimarySpanOnLint {
     #[primary_span]
     //~^ ERROR `#[primary_span]` is not a valid attribute
@@ -548,42 +550,42 @@ struct PrimarySpanOnLint {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct ErrorWithMultiSpan {
     #[primary_span]
     span: MultiSpan,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 #[warning]
 struct ErrorWithWarn {
     val: String,
 }
 
 #[derive(Diagnostic)]
-#[error(compiletest_example, code = "E0123")]
+#[error(no_crate_example, code = "E0123")]
 //~^ ERROR `#[error(...)]` is not a valid attribute
 //~| ERROR diagnostic slug not specified
 //~| ERROR cannot find attribute `error` in this scope
 struct ErrorAttribute {}
 
 #[derive(Diagnostic)]
-#[warn_(compiletest_example, code = "E0123")]
+#[warn_(no_crate_example, code = "E0123")]
 //~^ ERROR `#[warn_(...)]` is not a valid attribute
 //~| ERROR diagnostic slug not specified
 //~| ERROR cannot find attribute `warn_` in this scope
 struct WarnAttribute {}
 
 #[derive(Diagnostic)]
-#[lint(compiletest_example, code = "E0123")]
+#[lint(no_crate_example, code = "E0123")]
 //~^ ERROR `#[lint(...)]` is not a valid attribute
 //~| ERROR diagnostic slug not specified
 //~| ERROR cannot find attribute `lint` in this scope
 struct LintAttributeOnSessionDiag {}
 
 #[derive(LintDiagnostic)]
-#[lint(compiletest_example, code = "E0123")]
+#[lint(no_crate_example, code = "E0123")]
 //~^ ERROR `#[lint(...)]` is not a valid attribute
 //~| ERROR `#[lint(...)]` is not a valid attribute
 //~| ERROR diagnostic slug not specified
@@ -591,55 +593,55 @@ struct LintAttributeOnSessionDiag {}
 struct LintAttributeOnLintDiag {}
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct DuplicatedSuggestionCode {
-    #[suggestion(suggestion, code = "...", code = ",,,")]
+    #[suggestion(no_crate_suggestion, code = "...", code = ",,,")]
     //~^ ERROR specified multiple times
     suggestion: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct InvalidTypeInSuggestionTuple {
-    #[suggestion(suggestion, code = "...")]
+    #[suggestion(no_crate_suggestion, code = "...")]
     suggestion: (Span, usize),
     //~^ ERROR wrong types for suggestion
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct MissingApplicabilityInSuggestionTuple {
-    #[suggestion(suggestion, code = "...")]
+    #[suggestion(no_crate_suggestion, code = "...")]
     suggestion: (Span,),
     //~^ ERROR wrong types for suggestion
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct MissingCodeInSuggestion {
-    #[suggestion(suggestion)]
+    #[suggestion(no_crate_suggestion)]
     //~^ ERROR suggestion without `code = "..."`
     suggestion: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
-#[multipart_suggestion(suggestion)]
+#[diag(no_crate_example, code = "E0123")]
+#[multipart_suggestion(no_crate_suggestion)]
 //~^ ERROR `#[multipart_suggestion(...)]` is not a valid attribute
 //~| ERROR cannot find attribute `multipart_suggestion` in this scope
 #[multipart_suggestion()]
 //~^ ERROR `#[multipart_suggestion(...)]` is not a valid attribute
 //~| ERROR cannot find attribute `multipart_suggestion` in this scope
 struct MultipartSuggestion {
-    #[multipart_suggestion(suggestion)]
+    #[multipart_suggestion(no_crate_suggestion)]
     //~^ ERROR `#[multipart_suggestion(...)]` is not a valid attribute
     //~| ERROR cannot find attribute `multipart_suggestion` in this scope
     suggestion: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
-#[suggestion(suggestion, code = "...")]
+#[diag(no_crate_example, code = "E0123")]
+#[suggestion(no_crate_suggestion, code = "...")]
 //~^ ERROR `#[suggestion(...)]` is not a valid attribute
 struct SuggestionOnStruct {
     #[primary_span]
@@ -647,7 +649,7 @@ struct SuggestionOnStruct {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 #[label]
 //~^ ERROR `#[label]` is not a valid attribute
 struct LabelOnStruct {
@@ -657,30 +659,30 @@ struct LabelOnStruct {
 
 #[derive(Diagnostic)]
 enum ExampleEnum {
-    #[diag(compiletest_example)]
+    #[diag(no_crate_example)]
     Foo {
         #[primary_span]
         sp: Span,
         #[note]
         note_sp: Span,
     },
-    #[diag(compiletest_example)]
+    #[diag(no_crate_example)]
     Bar {
         #[primary_span]
         sp: Span,
     },
-    #[diag(compiletest_example)]
+    #[diag(no_crate_example)]
     Baz,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct RawIdentDiagnosticArg {
     pub r#type: String,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct SubdiagnosticBad {
     #[subdiagnostic(bad)]
     //~^ ERROR `#[subdiagnostic(...)]` is not a valid attribute
@@ -688,7 +690,7 @@ struct SubdiagnosticBad {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct SubdiagnosticBadStr {
     #[subdiagnostic = "bad"]
     //~^ ERROR `#[subdiagnostic = ...]` is not a valid attribute
@@ -696,7 +698,7 @@ struct SubdiagnosticBadStr {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct SubdiagnosticBadTwice {
     #[subdiagnostic(bad, bad)]
     //~^ ERROR `#[subdiagnostic(...)]` is not a valid attribute
@@ -704,7 +706,7 @@ struct SubdiagnosticBadTwice {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct SubdiagnosticBadLitStr {
     #[subdiagnostic("bad")]
     //~^ ERROR `#[subdiagnostic(...)]` is not a valid attribute
@@ -712,7 +714,7 @@ struct SubdiagnosticBadLitStr {
 }
 
 #[derive(LintDiagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct SubdiagnosticEagerLint {
     #[subdiagnostic(eager)]
     //~^ ERROR `#[subdiagnostic(...)]` is not a valid attribute
@@ -720,7 +722,7 @@ struct SubdiagnosticEagerLint {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct SubdiagnosticEagerCorrect {
     #[subdiagnostic(eager)]
     note: Note,
@@ -731,7 +733,7 @@ struct SubdiagnosticEagerCorrect {
 // after the `span_suggestion` call - which breaks eager translation.
 
 #[derive(Subdiagnostic)]
-#[suggestion(use_instead, applicability = "machine-applicable", code = "{correct}")]
+#[suggestion(no_crate_example, applicability = "machine-applicable", code = "{correct}")]
 pub(crate) struct SubdiagnosticWithSuggestion {
     #[primary_span]
     span: Span,
@@ -740,7 +742,7 @@ pub(crate) struct SubdiagnosticWithSuggestion {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct SubdiagnosticEagerSuggestion {
     #[subdiagnostic(eager)]
     sub: SubdiagnosticWithSuggestion,
@@ -748,7 +750,7 @@ struct SubdiagnosticEagerSuggestion {
 
 /// with a doc comment on the type..
 #[derive(Diagnostic)]
-#[diag(compiletest_example, code = "E0123")]
+#[diag(no_crate_example, code = "E0123")]
 struct WithDocComment {
     /// ..and the field
     #[primary_span]
@@ -756,21 +758,21 @@ struct WithDocComment {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct SuggestionsGood {
     #[suggestion(code("foo", "bar"))]
     sub: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct SuggestionsSingleItem {
     #[suggestion(code("foo"))]
     sub: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct SuggestionsNoItem {
     #[suggestion(code())]
     //~^ ERROR expected at least one string literal for `code(...)`
@@ -778,7 +780,7 @@ struct SuggestionsNoItem {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct SuggestionsInvalidItem {
     #[suggestion(code(foo))]
     //~^ ERROR `code(...)` must contain only string literals
@@ -786,7 +788,7 @@ struct SuggestionsInvalidItem {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct SuggestionsInvalidLiteral {
     #[suggestion(code = 3)]
     //~^ ERROR `code = "..."`/`code(...)` must contain only string literals
@@ -794,16 +796,16 @@ struct SuggestionsInvalidLiteral {
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct SuggestionStyleGood {
     #[suggestion(code = "", style = "hidden")]
     sub: Span,
 }
 
 #[derive(Diagnostic)]
-#[diag(compiletest_example)]
+#[diag(no_crate_example)]
 struct SuggestionOnVec {
-    #[suggestion(suggestion, code = "")]
+    #[suggestion(no_crate_suggestion, code = "")]
     //~^ ERROR `#[suggestion(...)]` is not a valid attribute
     sub: Vec<Span>,
 }
diff --git a/tests/ui-fulldeps/session-diagnostic/diagnostic-derive.stderr b/tests/ui-fulldeps/session-diagnostic/diagnostic-derive.stderr
index 61806c80efc..fc0cd8419e4 100644
--- a/tests/ui-fulldeps/session-diagnostic/diagnostic-derive.stderr
+++ b/tests/ui-fulldeps/session-diagnostic/diagnostic-derive.stderr
@@ -1,11 +1,11 @@
 error: unsupported type attribute for diagnostic derive enum
-  --> $DIR/diagnostic-derive.rs:39:1
+  --> $DIR/diagnostic-derive.rs:41:1
    |
-LL | #[diag(compiletest_example, code = "E0123")]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL | #[diag(no_crate_example, code = "E0123")]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: diagnostic slug not specified
-  --> $DIR/diagnostic-derive.rs:42:5
+  --> $DIR/diagnostic-derive.rs:44:5
    |
 LL |     Foo,
    |     ^^^
@@ -13,7 +13,7 @@ LL |     Foo,
    = help: specify the slug as the first argument to the `#[diag(...)]` attribute, such as `#[diag(hir_analysis_example_error)]`
 
 error: diagnostic slug not specified
-  --> $DIR/diagnostic-derive.rs:44:5
+  --> $DIR/diagnostic-derive.rs:46:5
    |
 LL |     Bar,
    |     ^^^
@@ -21,21 +21,21 @@ LL |     Bar,
    = help: specify the slug as the first argument to the `#[diag(...)]` attribute, such as `#[diag(hir_analysis_example_error)]`
 
 error: `#[diag = ...]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:50:1
+  --> $DIR/diagnostic-derive.rs:52:1
    |
 LL | #[diag = "E0123"]
    | ^^^^^^^^^^^^^^^^^
 
 error: `#[nonsense(...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:55:1
+  --> $DIR/diagnostic-derive.rs:57:1
    |
-LL | #[nonsense(compiletest_example, code = "E0123")]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL | #[nonsense(no_crate_example, code = "E0123")]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: diagnostic slug not specified
-  --> $DIR/diagnostic-derive.rs:55:1
+  --> $DIR/diagnostic-derive.rs:57:1
    |
-LL | / #[nonsense(compiletest_example, code = "E0123")]
+LL | / #[nonsense(no_crate_example, code = "E0123")]
 LL | |
 LL | |
 LL | |
@@ -45,7 +45,7 @@ LL | | struct InvalidStructAttr {}
    = help: specify the slug as the first argument to the `#[diag(...)]` attribute, such as `#[diag(hir_analysis_example_error)]`
 
 error: `#[diag("...")]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:62:8
+  --> $DIR/diagnostic-derive.rs:64:8
    |
 LL | #[diag("E0123")]
    |        ^^^^^^^
@@ -53,7 +53,7 @@ LL | #[diag("E0123")]
    = help: a diagnostic slug is required as the first argument
 
 error: diagnostic slug not specified
-  --> $DIR/diagnostic-derive.rs:62:1
+  --> $DIR/diagnostic-derive.rs:64:1
    |
 LL | / #[diag("E0123")]
 LL | |
@@ -64,7 +64,7 @@ LL | | struct InvalidLitNestedAttr {}
    = help: specify the slug as the first argument to the `#[diag(...)]` attribute, such as `#[diag(hir_analysis_example_error)]`
 
 error: `#[diag(nonsense(...))]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:73:8
+  --> $DIR/diagnostic-derive.rs:75:8
    |
 LL | #[diag(nonsense("foo"), code = "E0123", slug = "foo")]
    |        ^^^^^^^^^^^^^^^
@@ -72,7 +72,7 @@ LL | #[diag(nonsense("foo"), code = "E0123", slug = "foo")]
    = help: a diagnostic slug is required as the first argument
 
 error: diagnostic slug not specified
-  --> $DIR/diagnostic-derive.rs:73:1
+  --> $DIR/diagnostic-derive.rs:75:1
    |
 LL | / #[diag(nonsense("foo"), code = "E0123", slug = "foo")]
 LL | |
@@ -83,7 +83,7 @@ LL | | struct InvalidNestedStructAttr1 {}
    = help: specify the slug as the first argument to the `#[diag(...)]` attribute, such as `#[diag(hir_analysis_example_error)]`
 
 error: `#[diag(nonsense = ...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:79:8
+  --> $DIR/diagnostic-derive.rs:81:8
    |
 LL | #[diag(nonsense = "...", code = "E0123", slug = "foo")]
    |        ^^^^^^^^^^^^^^^^
@@ -91,7 +91,7 @@ LL | #[diag(nonsense = "...", code = "E0123", slug = "foo")]
    = help: only `code` is a valid nested attributes following the slug
 
 error: `#[diag(slug = ...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:79:42
+  --> $DIR/diagnostic-derive.rs:81:42
    |
 LL | #[diag(nonsense = "...", code = "E0123", slug = "foo")]
    |                                          ^^^^^^^^^^^^
@@ -99,7 +99,7 @@ LL | #[diag(nonsense = "...", code = "E0123", slug = "foo")]
    = help: only `code` is a valid nested attributes following the slug
 
 error: diagnostic slug not specified
-  --> $DIR/diagnostic-derive.rs:79:1
+  --> $DIR/diagnostic-derive.rs:81:1
    |
 LL | / #[diag(nonsense = "...", code = "E0123", slug = "foo")]
 LL | |
@@ -111,13 +111,13 @@ LL | | struct InvalidNestedStructAttr2 {}
    = help: specify the slug as the first argument to the `#[diag(...)]` attribute, such as `#[diag(hir_analysis_example_error)]`
 
 error: `#[diag(nonsense = ...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:86:8
+  --> $DIR/diagnostic-derive.rs:88:8
    |
 LL | #[diag(nonsense = 4, code = "E0123", slug = "foo")]
    |        ^^^^^^^^^^^^
 
 error: `#[diag(slug = ...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:86:38
+  --> $DIR/diagnostic-derive.rs:88:38
    |
 LL | #[diag(nonsense = 4, code = "E0123", slug = "foo")]
    |                                      ^^^^^^^^^^^^
@@ -125,7 +125,7 @@ LL | #[diag(nonsense = 4, code = "E0123", slug = "foo")]
    = help: only `code` is a valid nested attributes following the slug
 
 error: diagnostic slug not specified
-  --> $DIR/diagnostic-derive.rs:86:1
+  --> $DIR/diagnostic-derive.rs:88:1
    |
 LL | / #[diag(nonsense = 4, code = "E0123", slug = "foo")]
 LL | |
@@ -137,65 +137,65 @@ LL | | struct InvalidNestedStructAttr3 {}
    = help: specify the slug as the first argument to the `#[diag(...)]` attribute, such as `#[diag(hir_analysis_example_error)]`
 
 error: `#[diag(slug = ...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:93:45
+  --> $DIR/diagnostic-derive.rs:95:42
    |
-LL | #[diag(compiletest_example, code = "E0123", slug = "foo")]
-   |                                             ^^^^^^^^^^^^
+LL | #[diag(no_crate_example, code = "E0123", slug = "foo")]
+   |                                          ^^^^^^^^^^^^
    |
    = help: only `code` is a valid nested attributes following the slug
 
 error: `#[suggestion = ...]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:100:5
+  --> $DIR/diagnostic-derive.rs:102:5
    |
 LL |     #[suggestion = "bar"]
    |     ^^^^^^^^^^^^^^^^^^^^^
 
 error: specified multiple times
-  --> $DIR/diagnostic-derive.rs:107:8
+  --> $DIR/diagnostic-derive.rs:109:8
    |
-LL | #[diag(compiletest_example, code = "E0456")]
-   |        ^^^^^^^^^^^^^^^^^^^
+LL | #[diag(no_crate_example, code = "E0456")]
+   |        ^^^^^^^^^^^^^^^^
    |
 note: previously specified here
-  --> $DIR/diagnostic-derive.rs:106:8
+  --> $DIR/diagnostic-derive.rs:108:8
    |
-LL | #[diag(compiletest_example, code = "E0123")]
-   |        ^^^^^^^^^^^^^^^^^^^
+LL | #[diag(no_crate_example, code = "E0123")]
+   |        ^^^^^^^^^^^^^^^^
 
 error: specified multiple times
-  --> $DIR/diagnostic-derive.rs:107:36
+  --> $DIR/diagnostic-derive.rs:109:33
    |
-LL | #[diag(compiletest_example, code = "E0456")]
-   |                                    ^^^^^^^
+LL | #[diag(no_crate_example, code = "E0456")]
+   |                                 ^^^^^^^
    |
 note: previously specified here
-  --> $DIR/diagnostic-derive.rs:106:36
+  --> $DIR/diagnostic-derive.rs:108:33
    |
-LL | #[diag(compiletest_example, code = "E0123")]
-   |                                    ^^^^^^^
+LL | #[diag(no_crate_example, code = "E0123")]
+   |                                 ^^^^^^^
 
 error: specified multiple times
-  --> $DIR/diagnostic-derive.rs:113:52
+  --> $DIR/diagnostic-derive.rs:115:49
    |
-LL | #[diag(compiletest_example, code = "E0456", code = "E0457")]
-   |                                                    ^^^^^^^
+LL | #[diag(no_crate_example, code = "E0456", code = "E0457")]
+   |                                                 ^^^^^^^
    |
 note: previously specified here
-  --> $DIR/diagnostic-derive.rs:113:36
+  --> $DIR/diagnostic-derive.rs:115:33
    |
-LL | #[diag(compiletest_example, code = "E0456", code = "E0457")]
-   |                                    ^^^^^^^
+LL | #[diag(no_crate_example, code = "E0456", code = "E0457")]
+   |                                 ^^^^^^^
 
-error: `#[diag(compiletest_example)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:118:29
+error: `#[diag(no_crate::example)]` is not a valid attribute
+  --> $DIR/diagnostic-derive.rs:120:26
    |
-LL | #[diag(compiletest_example, compiletest_example, code = "E0456")]
-   |                             ^^^^^^^^^^^^^^^^^^^
+LL | #[diag(no_crate_example, no_crate::example, code = "E0456")]
+   |                          ^^^^^^^^^^^^^^^^^
    |
    = help: diagnostic slug must be the first argument
 
 error: diagnostic slug not specified
-  --> $DIR/diagnostic-derive.rs:123:1
+  --> $DIR/diagnostic-derive.rs:125:1
    |
 LL | struct KindNotProvided {}
    | ^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -203,7 +203,7 @@ LL | struct KindNotProvided {}
    = help: specify the slug as the first argument to the `#[diag(...)]` attribute, such as `#[diag(hir_analysis_example_error)]`
 
 error: diagnostic slug not specified
-  --> $DIR/diagnostic-derive.rs:126:1
+  --> $DIR/diagnostic-derive.rs:128:1
    |
 LL | / #[diag(code = "E0456")]
 LL | |
@@ -213,31 +213,31 @@ LL | | struct SlugNotProvided {}
    = help: specify the slug as the first argument to the `#[diag(...)]` attribute, such as `#[diag(hir_analysis_example_error)]`
 
 error: the `#[primary_span]` attribute can only be applied to fields of type `Span` or `MultiSpan`
-  --> $DIR/diagnostic-derive.rs:137:5
+  --> $DIR/diagnostic-derive.rs:139:5
    |
 LL |     #[primary_span]
    |     ^^^^^^^^^^^^^^^
 
 error: `#[nonsense]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:145:5
+  --> $DIR/diagnostic-derive.rs:147:5
    |
 LL |     #[nonsense]
    |     ^^^^^^^^^^^
 
 error: the `#[label(...)]` attribute can only be applied to fields of type `Span` or `MultiSpan`
-  --> $DIR/diagnostic-derive.rs:162:5
+  --> $DIR/diagnostic-derive.rs:164:5
    |
-LL |     #[label(label)]
-   |     ^^^^^^^^^^^^^^^
+LL |     #[label(no_crate_label)]
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: `name` doesn't refer to a field on this type
-  --> $DIR/diagnostic-derive.rs:170:37
+  --> $DIR/diagnostic-derive.rs:172:46
    |
-LL |     #[suggestion(suggestion, code = "{name}")]
-   |                                     ^^^^^^^^
+LL |     #[suggestion(no_crate_suggestion, code = "{name}")]
+   |                                              ^^^^^^^^
 
 error: invalid format string: expected `'}'` but string was terminated
-  --> $DIR/diagnostic-derive.rs:175:10
+  --> $DIR/diagnostic-derive.rs:177:10
    |
 LL | #[derive(Diagnostic)]
    |          ^^^^^^^^^^ expected `'}'` in format string
@@ -246,7 +246,7 @@ LL | #[derive(Diagnostic)]
    = note: this error originates in the derive macro `Diagnostic` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: invalid format string: unmatched `}` found
-  --> $DIR/diagnostic-derive.rs:185:10
+  --> $DIR/diagnostic-derive.rs:187:10
    |
 LL | #[derive(Diagnostic)]
    |          ^^^^^^^^^^ unmatched `}` in format string
@@ -255,19 +255,19 @@ LL | #[derive(Diagnostic)]
    = note: this error originates in the derive macro `Diagnostic` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: the `#[label(...)]` attribute can only be applied to fields of type `Span` or `MultiSpan`
-  --> $DIR/diagnostic-derive.rs:205:5
+  --> $DIR/diagnostic-derive.rs:207:5
    |
-LL |     #[label(label)]
-   |     ^^^^^^^^^^^^^^^
+LL |     #[label(no_crate_label)]
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: suggestion without `code = "..."`
-  --> $DIR/diagnostic-derive.rs:224:5
+  --> $DIR/diagnostic-derive.rs:226:5
    |
-LL |     #[suggestion(suggestion)]
-   |     ^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |     #[suggestion(no_crate_suggestion)]
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: `#[suggestion(nonsense = ...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:232:18
+  --> $DIR/diagnostic-derive.rs:234:18
    |
 LL |     #[suggestion(nonsense = "bar")]
    |                  ^^^^^^^^^^^^^^^^
@@ -275,13 +275,13 @@ LL |     #[suggestion(nonsense = "bar")]
    = help: only `style`, `code` and `applicability` are valid nested attributes
 
 error: suggestion without `code = "..."`
-  --> $DIR/diagnostic-derive.rs:232:5
+  --> $DIR/diagnostic-derive.rs:234:5
    |
 LL |     #[suggestion(nonsense = "bar")]
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: `#[suggestion(msg = ...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:241:18
+  --> $DIR/diagnostic-derive.rs:243:18
    |
 LL |     #[suggestion(msg = "bar")]
    |                  ^^^^^^^^^^^
@@ -289,15 +289,15 @@ LL |     #[suggestion(msg = "bar")]
    = help: only `style`, `code` and `applicability` are valid nested attributes
 
 error: suggestion without `code = "..."`
-  --> $DIR/diagnostic-derive.rs:241:5
+  --> $DIR/diagnostic-derive.rs:243:5
    |
 LL |     #[suggestion(msg = "bar")]
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: wrong field type for suggestion
-  --> $DIR/diagnostic-derive.rs:264:5
+  --> $DIR/diagnostic-derive.rs:266:5
    |
-LL | /     #[suggestion(suggestion, code = "This is suggested code")]
+LL | /     #[suggestion(no_crate_suggestion, code = "This is suggested code")]
 LL | |
 LL | |     suggestion: Applicability,
    | |_____________________________^
@@ -305,75 +305,75 @@ LL | |     suggestion: Applicability,
    = help: `#[suggestion(...)]` should be applied to fields of type `Span` or `(Span, Applicability)`
 
 error: specified multiple times
-  --> $DIR/diagnostic-derive.rs:280:24
+  --> $DIR/diagnostic-derive.rs:282:24
    |
 LL |     suggestion: (Span, Span, Applicability),
    |                        ^^^^
    |
 note: previously specified here
-  --> $DIR/diagnostic-derive.rs:280:18
+  --> $DIR/diagnostic-derive.rs:282:18
    |
 LL |     suggestion: (Span, Span, Applicability),
    |                  ^^^^
 
 error: specified multiple times
-  --> $DIR/diagnostic-derive.rs:288:33
+  --> $DIR/diagnostic-derive.rs:290:33
    |
 LL |     suggestion: (Applicability, Applicability, Span),
    |                                 ^^^^^^^^^^^^^
    |
 note: previously specified here
-  --> $DIR/diagnostic-derive.rs:288:18
+  --> $DIR/diagnostic-derive.rs:290:18
    |
 LL |     suggestion: (Applicability, Applicability, Span),
    |                  ^^^^^^^^^^^^^
 
 error: `#[label = ...]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:295:5
+  --> $DIR/diagnostic-derive.rs:297:5
    |
 LL |     #[label = "bar"]
    |     ^^^^^^^^^^^^^^^^
 
 error: specified multiple times
-  --> $DIR/diagnostic-derive.rs:446:44
+  --> $DIR/diagnostic-derive.rs:448:53
    |
-LL |     #[suggestion(suggestion, code = "...", applicability = "maybe-incorrect")]
-   |                                            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |     #[suggestion(no_crate_suggestion, code = "...", applicability = "maybe-incorrect")]
+   |                                                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
 note: previously specified here
-  --> $DIR/diagnostic-derive.rs:448:24
+  --> $DIR/diagnostic-derive.rs:450:24
    |
 LL |     suggestion: (Span, Applicability),
    |                        ^^^^^^^^^^^^^
 
 error: invalid applicability
-  --> $DIR/diagnostic-derive.rs:454:44
+  --> $DIR/diagnostic-derive.rs:456:53
    |
-LL |     #[suggestion(suggestion, code = "...", applicability = "batman")]
-   |                                            ^^^^^^^^^^^^^^^^^^^^^^^^
+LL |     #[suggestion(no_crate_suggestion, code = "...", applicability = "batman")]
+   |                                                     ^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: `#[label(foo)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:517:20
+  --> $DIR/diagnostic-derive.rs:519:29
    |
-LL |     #[label(label, foo)]
-   |                    ^^^
+LL |     #[label(no_crate_label, foo)]
+   |                             ^^^
    |
    = help: a diagnostic slug must be the first argument to the attribute
 
 error: `#[label(foo = ...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:525:20
+  --> $DIR/diagnostic-derive.rs:527:29
    |
-LL |     #[label(label, foo = "...")]
-   |                    ^^^^^^^^^^^
+LL |     #[label(no_crate_label, foo = "...")]
+   |                             ^^^^^^^^^^^
 
 error: `#[label(foo(...))]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:533:20
+  --> $DIR/diagnostic-derive.rs:535:29
    |
-LL |     #[label(label, foo("..."))]
-   |                    ^^^^^^^^^^
+LL |     #[label(no_crate_label, foo("..."))]
+   |                             ^^^^^^^^^^
 
 error: `#[primary_span]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:545:5
+  --> $DIR/diagnostic-derive.rs:547:5
    |
 LL |     #[primary_span]
    |     ^^^^^^^^^^^^^^^
@@ -381,15 +381,15 @@ LL |     #[primary_span]
    = help: the `primary_span` field attribute is not valid for lint diagnostics
 
 error: `#[error(...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:565:1
+  --> $DIR/diagnostic-derive.rs:567:1
    |
-LL | #[error(compiletest_example, code = "E0123")]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL | #[error(no_crate_example, code = "E0123")]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: diagnostic slug not specified
-  --> $DIR/diagnostic-derive.rs:565:1
+  --> $DIR/diagnostic-derive.rs:567:1
    |
-LL | / #[error(compiletest_example, code = "E0123")]
+LL | / #[error(no_crate_example, code = "E0123")]
 LL | |
 LL | |
 LL | |
@@ -399,15 +399,15 @@ LL | | struct ErrorAttribute {}
    = help: specify the slug as the first argument to the `#[diag(...)]` attribute, such as `#[diag(hir_analysis_example_error)]`
 
 error: `#[warn_(...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:572:1
+  --> $DIR/diagnostic-derive.rs:574:1
    |
-LL | #[warn_(compiletest_example, code = "E0123")]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL | #[warn_(no_crate_example, code = "E0123")]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: diagnostic slug not specified
-  --> $DIR/diagnostic-derive.rs:572:1
+  --> $DIR/diagnostic-derive.rs:574:1
    |
-LL | / #[warn_(compiletest_example, code = "E0123")]
+LL | / #[warn_(no_crate_example, code = "E0123")]
 LL | |
 LL | |
 LL | |
@@ -417,15 +417,15 @@ LL | | struct WarnAttribute {}
    = help: specify the slug as the first argument to the `#[diag(...)]` attribute, such as `#[diag(hir_analysis_example_error)]`
 
 error: `#[lint(...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:579:1
+  --> $DIR/diagnostic-derive.rs:581:1
    |
-LL | #[lint(compiletest_example, code = "E0123")]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL | #[lint(no_crate_example, code = "E0123")]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: diagnostic slug not specified
-  --> $DIR/diagnostic-derive.rs:579:1
+  --> $DIR/diagnostic-derive.rs:581:1
    |
-LL | / #[lint(compiletest_example, code = "E0123")]
+LL | / #[lint(no_crate_example, code = "E0123")]
 LL | |
 LL | |
 LL | |
@@ -435,21 +435,21 @@ LL | | struct LintAttributeOnSessionDiag {}
    = help: specify the slug as the first argument to the `#[diag(...)]` attribute, such as `#[diag(hir_analysis_example_error)]`
 
 error: `#[lint(...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:586:1
+  --> $DIR/diagnostic-derive.rs:588:1
    |
-LL | #[lint(compiletest_example, code = "E0123")]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL | #[lint(no_crate_example, code = "E0123")]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: `#[lint(...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:586:1
+  --> $DIR/diagnostic-derive.rs:588:1
    |
-LL | #[lint(compiletest_example, code = "E0123")]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL | #[lint(no_crate_example, code = "E0123")]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: diagnostic slug not specified
-  --> $DIR/diagnostic-derive.rs:586:1
+  --> $DIR/diagnostic-derive.rs:588:1
    |
-LL | / #[lint(compiletest_example, code = "E0123")]
+LL | / #[lint(no_crate_example, code = "E0123")]
 LL | |
 LL | |
 LL | |
@@ -460,19 +460,19 @@ LL | | struct LintAttributeOnLintDiag {}
    = help: specify the slug as the first argument to the attribute, such as `#[diag(compiletest_example)]`
 
 error: specified multiple times
-  --> $DIR/diagnostic-derive.rs:596:44
+  --> $DIR/diagnostic-derive.rs:598:53
    |
-LL |     #[suggestion(suggestion, code = "...", code = ",,,")]
-   |                                            ^^^^^^^^^^^^
+LL |     #[suggestion(no_crate_suggestion, code = "...", code = ",,,")]
+   |                                                     ^^^^^^^^^^^^
    |
 note: previously specified here
-  --> $DIR/diagnostic-derive.rs:596:30
+  --> $DIR/diagnostic-derive.rs:598:39
    |
-LL |     #[suggestion(suggestion, code = "...", code = ",,,")]
-   |                              ^^^^^^^^^^^^
+LL |     #[suggestion(no_crate_suggestion, code = "...", code = ",,,")]
+   |                                       ^^^^^^^^^^^^
 
 error: wrong types for suggestion
-  --> $DIR/diagnostic-derive.rs:605:24
+  --> $DIR/diagnostic-derive.rs:607:24
    |
 LL |     suggestion: (Span, usize),
    |                        ^^^^^
@@ -480,7 +480,7 @@ LL |     suggestion: (Span, usize),
    = help: `#[suggestion(...)]` on a tuple field must be applied to fields of type `(Span, Applicability)`
 
 error: wrong types for suggestion
-  --> $DIR/diagnostic-derive.rs:613:17
+  --> $DIR/diagnostic-derive.rs:615:17
    |
 LL |     suggestion: (Span,),
    |                 ^^^^^^^
@@ -488,21 +488,21 @@ LL |     suggestion: (Span,),
    = help: `#[suggestion(...)]` on a tuple field must be applied to fields of type `(Span, Applicability)`
 
 error: suggestion without `code = "..."`
-  --> $DIR/diagnostic-derive.rs:620:5
+  --> $DIR/diagnostic-derive.rs:622:5
    |
-LL |     #[suggestion(suggestion)]
-   |     ^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |     #[suggestion(no_crate_suggestion)]
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: `#[multipart_suggestion(...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:627:1
+  --> $DIR/diagnostic-derive.rs:629:1
    |
-LL | #[multipart_suggestion(suggestion)]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL | #[multipart_suggestion(no_crate_suggestion)]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: consider creating a `Subdiagnostic` instead
 
 error: `#[multipart_suggestion(...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:630:1
+  --> $DIR/diagnostic-derive.rs:632:1
    |
 LL | #[multipart_suggestion()]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -510,23 +510,23 @@ LL | #[multipart_suggestion()]
    = help: consider creating a `Subdiagnostic` instead
 
 error: `#[multipart_suggestion(...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:634:5
+  --> $DIR/diagnostic-derive.rs:636:5
    |
-LL |     #[multipart_suggestion(suggestion)]
-   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |     #[multipart_suggestion(no_crate_suggestion)]
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: consider creating a `Subdiagnostic` instead
 
 error: `#[suggestion(...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:642:1
+  --> $DIR/diagnostic-derive.rs:644:1
    |
-LL | #[suggestion(suggestion, code = "...")]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL | #[suggestion(no_crate_suggestion, code = "...")]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: `#[label]` and `#[suggestion]` can only be applied to fields
 
 error: `#[label]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:651:1
+  --> $DIR/diagnostic-derive.rs:653:1
    |
 LL | #[label]
    | ^^^^^^^^
@@ -534,7 +534,7 @@ LL | #[label]
    = help: `#[label]` and `#[suggestion]` can only be applied to fields
 
 error: `#[subdiagnostic(...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:685:5
+  --> $DIR/diagnostic-derive.rs:687:5
    |
 LL |     #[subdiagnostic(bad)]
    |     ^^^^^^^^^^^^^^^^^^^^^
@@ -542,13 +542,13 @@ LL |     #[subdiagnostic(bad)]
    = help: `eager` is the only supported nested attribute for `subdiagnostic`
 
 error: `#[subdiagnostic = ...]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:693:5
+  --> $DIR/diagnostic-derive.rs:695:5
    |
 LL |     #[subdiagnostic = "bad"]
    |     ^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: `#[subdiagnostic(...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:701:5
+  --> $DIR/diagnostic-derive.rs:703:5
    |
 LL |     #[subdiagnostic(bad, bad)]
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -556,7 +556,7 @@ LL |     #[subdiagnostic(bad, bad)]
    = help: `eager` is the only supported nested attribute for `subdiagnostic`
 
 error: `#[subdiagnostic(...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:709:5
+  --> $DIR/diagnostic-derive.rs:711:5
    |
 LL |     #[subdiagnostic("bad")]
    |     ^^^^^^^^^^^^^^^^^^^^^^^
@@ -564,7 +564,7 @@ LL |     #[subdiagnostic("bad")]
    = help: `eager` is the only supported nested attribute for `subdiagnostic`
 
 error: `#[subdiagnostic(...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:717:5
+  --> $DIR/diagnostic-derive.rs:719:5
    |
 LL |     #[subdiagnostic(eager)]
    |     ^^^^^^^^^^^^^^^^^^^^^^^
@@ -572,95 +572,95 @@ LL |     #[subdiagnostic(eager)]
    = help: eager subdiagnostics are not supported on lints
 
 error: expected at least one string literal for `code(...)`
-  --> $DIR/diagnostic-derive.rs:775:18
+  --> $DIR/diagnostic-derive.rs:777:18
    |
 LL |     #[suggestion(code())]
    |                  ^^^^^^
 
 error: `code(...)` must contain only string literals
-  --> $DIR/diagnostic-derive.rs:783:23
+  --> $DIR/diagnostic-derive.rs:785:23
    |
 LL |     #[suggestion(code(foo))]
    |                       ^^^
 
 error: `code = "..."`/`code(...)` must contain only string literals
-  --> $DIR/diagnostic-derive.rs:791:18
+  --> $DIR/diagnostic-derive.rs:793:18
    |
 LL |     #[suggestion(code = 3)]
    |                  ^^^^^^^^
 
 error: `#[suggestion(...)]` is not a valid attribute
-  --> $DIR/diagnostic-derive.rs:806:5
+  --> $DIR/diagnostic-derive.rs:808:5
    |
-LL |     #[suggestion(suggestion, code = "")]
-   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |     #[suggestion(no_crate_suggestion, code = "")]
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: `#[suggestion(...)]` applied to `Vec` field is ambiguous
    = help: to show a suggestion consisting of multiple parts, use a `Subdiagnostic` annotated with `#[multipart_suggestion(...)]`
    = help: to show a variable set of suggestions, use a `Vec` of `Subdiagnostic`s annotated with `#[suggestion(...)]`
 
 error: cannot find attribute `nonsense` in this scope
-  --> $DIR/diagnostic-derive.rs:55:3
+  --> $DIR/diagnostic-derive.rs:57:3
    |
-LL | #[nonsense(compiletest_example, code = "E0123")]
+LL | #[nonsense(no_crate_example, code = "E0123")]
    |   ^^^^^^^^
 
 error: cannot find attribute `nonsense` in this scope
-  --> $DIR/diagnostic-derive.rs:145:7
+  --> $DIR/diagnostic-derive.rs:147:7
    |
 LL |     #[nonsense]
    |       ^^^^^^^^
 
 error: cannot find attribute `error` in this scope
-  --> $DIR/diagnostic-derive.rs:565:3
+  --> $DIR/diagnostic-derive.rs:567:3
    |
-LL | #[error(compiletest_example, code = "E0123")]
+LL | #[error(no_crate_example, code = "E0123")]
    |   ^^^^^
 
 error: cannot find attribute `warn_` in this scope
-  --> $DIR/diagnostic-derive.rs:572:3
+  --> $DIR/diagnostic-derive.rs:574:3
    |
-LL | #[warn_(compiletest_example, code = "E0123")]
+LL | #[warn_(no_crate_example, code = "E0123")]
    |   ^^^^^ help: a built-in attribute with a similar name exists: `warn`
 
 error: cannot find attribute `lint` in this scope
-  --> $DIR/diagnostic-derive.rs:579:3
+  --> $DIR/diagnostic-derive.rs:581:3
    |
-LL | #[lint(compiletest_example, code = "E0123")]
+LL | #[lint(no_crate_example, code = "E0123")]
    |   ^^^^ help: a built-in attribute with a similar name exists: `link`
 
 error: cannot find attribute `lint` in this scope
-  --> $DIR/diagnostic-derive.rs:586:3
+  --> $DIR/diagnostic-derive.rs:588:3
    |
-LL | #[lint(compiletest_example, code = "E0123")]
+LL | #[lint(no_crate_example, code = "E0123")]
    |   ^^^^ help: a built-in attribute with a similar name exists: `link`
 
 error: cannot find attribute `multipart_suggestion` in this scope
-  --> $DIR/diagnostic-derive.rs:627:3
+  --> $DIR/diagnostic-derive.rs:629:3
    |
-LL | #[multipart_suggestion(suggestion)]
+LL | #[multipart_suggestion(no_crate_suggestion)]
    |   ^^^^^^^^^^^^^^^^^^^^
 
 error: cannot find attribute `multipart_suggestion` in this scope
-  --> $DIR/diagnostic-derive.rs:630:3
+  --> $DIR/diagnostic-derive.rs:632:3
    |
 LL | #[multipart_suggestion()]
    |   ^^^^^^^^^^^^^^^^^^^^
 
 error: cannot find attribute `multipart_suggestion` in this scope
-  --> $DIR/diagnostic-derive.rs:634:7
+  --> $DIR/diagnostic-derive.rs:636:7
    |
-LL |     #[multipart_suggestion(suggestion)]
+LL |     #[multipart_suggestion(no_crate_suggestion)]
    |       ^^^^^^^^^^^^^^^^^^^^
 
-error[E0425]: cannot find value `nonsense` in module `rustc_errors::fluent`
-  --> $DIR/diagnostic-derive.rs:68:8
+error[E0425]: cannot find value `nonsense` in module `crate::fluent_generated`
+  --> $DIR/diagnostic-derive.rs:70:8
    |
 LL | #[diag(nonsense, code = "E0123")]
-   |        ^^^^^^^^ not found in `rustc_errors::fluent`
+   |        ^^^^^^^^ not found in `crate::fluent_generated`
 
 error[E0277]: the trait bound `Hello: IntoDiagnosticArg` is not satisfied
-  --> $DIR/diagnostic-derive.rs:339:10
+  --> $DIR/diagnostic-derive.rs:341:10
    |
 LL | #[derive(Diagnostic)]
    |          ^^^^^^^^^^ the trait `IntoDiagnosticArg` is not implemented for `Hello`
diff --git a/tests/ui-fulldeps/session-diagnostic/example.ftl b/tests/ui-fulldeps/session-diagnostic/example.ftl
new file mode 100644
index 00000000000..cb2d476d815
--- /dev/null
+++ b/tests/ui-fulldeps/session-diagnostic/example.ftl
@@ -0,0 +1,5 @@
+no_crate_example = this is an example message used in testing
+    .note = with a note
+    .help = with a help
+    .suggestion = with a suggestion
+    .label = with a label
diff --git a/tests/ui-fulldeps/session-diagnostic/subdiagnostic-derive.rs b/tests/ui-fulldeps/session-diagnostic/subdiagnostic-derive.rs
index 09ad6964909..c882f7792d5 100644
--- a/tests/ui-fulldeps/session-diagnostic/subdiagnostic-derive.rs
+++ b/tests/ui-fulldeps/session-diagnostic/subdiagnostic-derive.rs
@@ -15,12 +15,14 @@ extern crate rustc_macros;
 extern crate rustc_session;
 extern crate rustc_span;
 
-use rustc_errors::Applicability;
-use rustc_macros::Subdiagnostic;
+use rustc_errors::{Applicability, DiagnosticMessage, SubdiagnosticMessage};
+use rustc_macros::{fluent_messages, Subdiagnostic};
 use rustc_span::Span;
 
+fluent_messages! { "./example.ftl" }
+
 #[derive(Subdiagnostic)]
-#[label(parse_add_paren)]
+#[label(no_crate_example)]
 struct A {
     #[primary_span]
     span: Span,
@@ -29,13 +31,13 @@ struct A {
 
 #[derive(Subdiagnostic)]
 enum B {
-    #[label(parse_add_paren)]
+    #[label(no_crate_example)]
     A {
         #[primary_span]
         span: Span,
         var: String,
     },
-    #[label(parse_add_paren)]
+    #[label(no_crate_example)]
     B {
         #[primary_span]
         span: Span,
@@ -44,7 +46,7 @@ enum B {
 }
 
 #[derive(Subdiagnostic)]
-#[label(parse_add_paren)]
+#[label(no_crate_example)]
 //~^ ERROR label without `#[primary_span]` field
 struct C {
     var: String,
@@ -120,8 +122,8 @@ struct K {
 
 #[derive(Subdiagnostic)]
 #[label(slug)]
-//~^ ERROR cannot find value `slug` in module `rustc_errors::fluent`
-//~^^ NOTE not found in `rustc_errors::fluent`
+//~^ ERROR cannot find value `slug` in module `crate::fluent_generated`
+//~^^ NOTE not found in `crate::fluent_generated`
 struct L {
     #[primary_span]
     span: Span,
@@ -138,7 +140,7 @@ struct M {
 }
 
 #[derive(Subdiagnostic)]
-#[label(parse_add_paren, code = "...")]
+#[label(no_crate_example, code = "...")]
 //~^ ERROR `#[label(code = ...)]` is not a valid attribute
 struct N {
     #[primary_span]
@@ -147,7 +149,7 @@ struct N {
 }
 
 #[derive(Subdiagnostic)]
-#[label(parse_add_paren, applicability = "machine-applicable")]
+#[label(no_crate_example, applicability = "machine-applicable")]
 //~^ ERROR `#[label(applicability = ...)]` is not a valid attribute
 struct O {
     #[primary_span]
@@ -160,7 +162,7 @@ struct O {
 //~^ ERROR cannot find attribute `foo` in this scope
 //~^^ ERROR unsupported type attribute for subdiagnostic enum
 enum P {
-    #[label(parse_add_paren)]
+    #[label(no_crate_example)]
     A {
         #[primary_span]
         span: Span,
@@ -230,7 +232,7 @@ enum U {
 
 #[derive(Subdiagnostic)]
 enum V {
-    #[label(parse_add_paren)]
+    #[label(no_crate_example)]
     A {
         #[primary_span]
         span: Span,
@@ -244,7 +246,7 @@ enum V {
 }
 
 #[derive(Subdiagnostic)]
-#[label(parse_add_paren)]
+#[label(no_crate_example)]
 //~^ ERROR label without `#[primary_span]` field
 struct W {
     #[primary_span]
@@ -253,7 +255,7 @@ struct W {
 }
 
 #[derive(Subdiagnostic)]
-#[label(parse_add_paren)]
+#[label(no_crate_example)]
 struct X {
     #[primary_span]
     span: Span,
@@ -263,7 +265,7 @@ struct X {
 }
 
 #[derive(Subdiagnostic)]
-#[label(parse_add_paren)]
+#[label(no_crate_example)]
 struct Y {
     #[primary_span]
     span: Span,
@@ -274,7 +276,7 @@ struct Y {
 }
 
 #[derive(Subdiagnostic)]
-#[label(parse_add_paren)]
+#[label(no_crate_example)]
 struct Z {
     #[primary_span]
     span: Span,
@@ -285,7 +287,7 @@ struct Z {
 }
 
 #[derive(Subdiagnostic)]
-#[label(parse_add_paren)]
+#[label(no_crate_example)]
 struct AA {
     #[primary_span]
     span: Span,
@@ -296,7 +298,7 @@ struct AA {
 }
 
 #[derive(Subdiagnostic)]
-#[label(parse_add_paren)]
+#[label(no_crate_example)]
 struct AB {
     #[primary_span]
     span: Span,
@@ -312,23 +314,23 @@ union AC {
 }
 
 #[derive(Subdiagnostic)]
-#[label(parse_add_paren)]
-#[label(parse_add_paren)]
+#[label(no_crate_example)]
+#[label(no_crate_example)]
 struct AD {
     #[primary_span]
     span: Span,
 }
 
 #[derive(Subdiagnostic)]
-#[label(parse_add_paren, parse_add_paren)]
-//~^ ERROR `#[label(parse_add_paren)]` is not a valid attribute
+#[label(no_crate_example, no_crate::example)]
+//~^ ERROR `#[label(no_crate::example)]` is not a valid attribute
 struct AE {
     #[primary_span]
     span: Span,
 }
 
 #[derive(Subdiagnostic)]
-#[label(parse_add_paren)]
+#[label(no_crate_example)]
 struct AF {
     #[primary_span]
     //~^ NOTE previously specified here
@@ -346,7 +348,7 @@ struct AG {
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "...")]
+#[suggestion(no_crate_example, code = "...")]
 struct AH {
     #[primary_span]
     span: Span,
@@ -357,7 +359,7 @@ struct AH {
 
 #[derive(Subdiagnostic)]
 enum AI {
-    #[suggestion(parse_add_paren, code = "...")]
+    #[suggestion(no_crate_example, code = "...")]
     A {
         #[primary_span]
         span: Span,
@@ -365,7 +367,7 @@ enum AI {
         applicability: Applicability,
         var: String,
     },
-    #[suggestion(parse_add_paren, code = "...")]
+    #[suggestion(no_crate_example, code = "...")]
     B {
         #[primary_span]
         span: Span,
@@ -376,7 +378,7 @@ enum AI {
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "...", code = "...")]
+#[suggestion(no_crate_example, code = "...", code = "...")]
 //~^ ERROR specified multiple times
 //~^^ NOTE previously specified here
 struct AJ {
@@ -387,7 +389,7 @@ struct AJ {
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "...")]
+#[suggestion(no_crate_example, code = "...")]
 struct AK {
     #[primary_span]
     span: Span,
@@ -400,7 +402,7 @@ struct AK {
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "...")]
+#[suggestion(no_crate_example, code = "...")]
 struct AL {
     #[primary_span]
     span: Span,
@@ -410,14 +412,14 @@ struct AL {
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "...")]
+#[suggestion(no_crate_example, code = "...")]
 struct AM {
     #[primary_span]
     span: Span,
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren)]
+#[suggestion(no_crate_example)]
 //~^ ERROR suggestion without `code = "..."`
 struct AN {
     #[primary_span]
@@ -427,7 +429,7 @@ struct AN {
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "...", applicability = "foo")]
+#[suggestion(no_crate_example, code = "...", applicability = "foo")]
 //~^ ERROR invalid applicability
 struct AO {
     #[primary_span]
@@ -435,24 +437,24 @@ struct AO {
 }
 
 #[derive(Subdiagnostic)]
-#[help(parse_add_paren)]
+#[help(no_crate_example)]
 struct AP {
     var: String,
 }
 
 #[derive(Subdiagnostic)]
-#[note(parse_add_paren)]
+#[note(no_crate_example)]
 struct AQ;
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "...")]
+#[suggestion(no_crate_example, code = "...")]
 //~^ ERROR suggestion without `#[primary_span]` field
 struct AR {
     var: String,
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "...", applicability = "machine-applicable")]
+#[suggestion(no_crate_example, code = "...", applicability = "machine-applicable")]
 struct AS {
     #[primary_span]
     span: Span,
@@ -462,7 +464,7 @@ struct AS {
 #[label]
 //~^ ERROR unsupported type attribute for subdiagnostic enum
 enum AT {
-    #[label(parse_add_paren)]
+    #[label(no_crate_example)]
     A {
         #[primary_span]
         span: Span,
@@ -471,7 +473,7 @@ enum AT {
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "{var}", applicability = "machine-applicable")]
+#[suggestion(no_crate_example, code = "{var}", applicability = "machine-applicable")]
 struct AU {
     #[primary_span]
     span: Span,
@@ -479,7 +481,7 @@ struct AU {
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "{var}", applicability = "machine-applicable")]
+#[suggestion(no_crate_example, code = "{var}", applicability = "machine-applicable")]
 //~^ ERROR `var` doesn't refer to a field on this type
 struct AV {
     #[primary_span]
@@ -488,7 +490,7 @@ struct AV {
 
 #[derive(Subdiagnostic)]
 enum AW {
-    #[suggestion(parse_add_paren, code = "{var}", applicability = "machine-applicable")]
+    #[suggestion(no_crate_example, code = "{var}", applicability = "machine-applicable")]
     A {
         #[primary_span]
         span: Span,
@@ -498,7 +500,7 @@ enum AW {
 
 #[derive(Subdiagnostic)]
 enum AX {
-    #[suggestion(parse_add_paren, code = "{var}", applicability = "machine-applicable")]
+    #[suggestion(no_crate_example, code = "{var}", applicability = "machine-applicable")]
     //~^ ERROR `var` doesn't refer to a field on this type
     A {
         #[primary_span]
@@ -507,18 +509,18 @@ enum AX {
 }
 
 #[derive(Subdiagnostic)]
-#[warning(parse_add_paren)]
+#[warning(no_crate_example)]
 struct AY {}
 
 #[derive(Subdiagnostic)]
-#[warning(parse_add_paren)]
+#[warning(no_crate_example)]
 struct AZ {
     #[primary_span]
     span: Span,
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "...")]
+#[suggestion(no_crate_example, code = "...")]
 //~^ ERROR suggestion without `#[primary_span]` field
 struct BA {
     #[suggestion_part]
@@ -533,7 +535,7 @@ struct BA {
 }
 
 #[derive(Subdiagnostic)]
-#[multipart_suggestion(parse_add_paren, code = "...", applicability = "machine-applicable")]
+#[multipart_suggestion(no_crate_example, code = "...", applicability = "machine-applicable")]
 //~^ ERROR multipart suggestion without any `#[suggestion_part(...)]` fields
 //~| ERROR `#[multipart_suggestion(code = ...)]` is not a valid attribute
 struct BBa {
@@ -541,7 +543,7 @@ struct BBa {
 }
 
 #[derive(Subdiagnostic)]
-#[multipart_suggestion(parse_add_paren, applicability = "machine-applicable")]
+#[multipart_suggestion(no_crate_example, applicability = "machine-applicable")]
 struct BBb {
     #[suggestion_part]
     //~^ ERROR `#[suggestion_part(...)]` attribute without `code = "..."`
@@ -549,7 +551,7 @@ struct BBb {
 }
 
 #[derive(Subdiagnostic)]
-#[multipart_suggestion(parse_add_paren, applicability = "machine-applicable")]
+#[multipart_suggestion(no_crate_example, applicability = "machine-applicable")]
 struct BBc {
     #[suggestion_part()]
     //~^ ERROR `#[suggestion_part(...)]` attribute without `code = "..."`
@@ -557,7 +559,7 @@ struct BBc {
 }
 
 #[derive(Subdiagnostic)]
-#[multipart_suggestion(parse_add_paren)]
+#[multipart_suggestion(no_crate_example)]
 //~^ ERROR multipart suggestion without any `#[suggestion_part(...)]` fields
 struct BC {
     #[primary_span]
@@ -566,7 +568,7 @@ struct BC {
 }
 
 #[derive(Subdiagnostic)]
-#[multipart_suggestion(parse_add_paren)]
+#[multipart_suggestion(no_crate_example)]
 struct BD {
     #[suggestion_part]
     //~^ ERROR `#[suggestion_part(...)]` attribute without `code = "..."`
@@ -586,7 +588,7 @@ struct BD {
 }
 
 #[derive(Subdiagnostic)]
-#[multipart_suggestion(parse_add_paren, applicability = "machine-applicable")]
+#[multipart_suggestion(no_crate_example, applicability = "machine-applicable")]
 struct BE {
     #[suggestion_part(code = "...", code = ",,,")]
     //~^ ERROR specified multiple times
@@ -595,7 +597,7 @@ struct BE {
 }
 
 #[derive(Subdiagnostic)]
-#[multipart_suggestion(parse_add_paren, applicability = "machine-applicable")]
+#[multipart_suggestion(no_crate_example, applicability = "machine-applicable")]
 struct BF {
     #[suggestion_part(code = "(")]
     first: Span,
@@ -604,7 +606,7 @@ struct BF {
 }
 
 #[derive(Subdiagnostic)]
-#[multipart_suggestion(parse_add_paren)]
+#[multipart_suggestion(no_crate_example)]
 struct BG {
     #[applicability]
     appl: Applicability,
@@ -615,7 +617,7 @@ struct BG {
 }
 
 #[derive(Subdiagnostic)]
-#[multipart_suggestion(parse_add_paren, applicability = "machine-applicable")]
+#[multipart_suggestion(no_crate_example, applicability = "machine-applicable")]
 struct BH {
     #[applicability]
     //~^ ERROR `#[applicability]` has no effect
@@ -627,14 +629,14 @@ struct BH {
 }
 
 #[derive(Subdiagnostic)]
-#[multipart_suggestion(parse_add_paren, applicability = "machine-applicable")]
+#[multipart_suggestion(no_crate_example, applicability = "machine-applicable")]
 struct BI {
     #[suggestion_part(code = "")]
     spans: Vec<Span>,
 }
 
 #[derive(Subdiagnostic)]
-#[label(parse_add_paren)]
+#[label(no_crate_example)]
 struct BJ {
     #[primary_span]
     span: Span,
@@ -643,7 +645,7 @@ struct BJ {
 
 /// with a doc comment on the type..
 #[derive(Subdiagnostic)]
-#[label(parse_add_paren)]
+#[label(no_crate_example)]
 struct BK {
     /// ..and the field
     #[primary_span]
@@ -654,7 +656,7 @@ struct BK {
 #[derive(Subdiagnostic)]
 enum BL {
     /// ..and the variant..
-    #[label(parse_add_paren)]
+    #[label(no_crate_example)]
     Foo {
         /// ..and the field
         #[primary_span]
@@ -663,7 +665,7 @@ enum BL {
 }
 
 #[derive(Subdiagnostic)]
-#[multipart_suggestion(parse_add_paren)]
+#[multipart_suggestion(no_crate_example)]
 struct BM {
     #[suggestion_part(code("foo"))]
     //~^ ERROR expected exactly one string literal for `code = ...`
@@ -672,7 +674,7 @@ struct BM {
 }
 
 #[derive(Subdiagnostic)]
-#[multipart_suggestion(parse_add_paren)]
+#[multipart_suggestion(no_crate_example)]
 struct BN {
     #[suggestion_part(code("foo", "bar"))]
     //~^ ERROR expected exactly one string literal for `code = ...`
@@ -681,7 +683,7 @@ struct BN {
 }
 
 #[derive(Subdiagnostic)]
-#[multipart_suggestion(parse_add_paren)]
+#[multipart_suggestion(no_crate_example)]
 struct BO {
     #[suggestion_part(code(3))]
     //~^ ERROR expected exactly one string literal for `code = ...`
@@ -690,7 +692,7 @@ struct BO {
 }
 
 #[derive(Subdiagnostic)]
-#[multipart_suggestion(parse_add_paren)]
+#[multipart_suggestion(no_crate_example)]
 struct BP {
     #[suggestion_part(code())]
     //~^ ERROR expected exactly one string literal for `code = ...`
@@ -699,7 +701,7 @@ struct BP {
 }
 
 #[derive(Subdiagnostic)]
-#[multipart_suggestion(parse_add_paren)]
+#[multipart_suggestion(no_crate_example)]
 struct BQ {
     #[suggestion_part(code = 3)]
     //~^ ERROR `code = "..."`/`code(...)` must contain only string literals
@@ -708,42 +710,42 @@ struct BQ {
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "")]
+#[suggestion(no_crate_example, code = "")]
 struct SuggestionStyleDefault {
     #[primary_span]
     sub: Span,
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "", style = "short")]
+#[suggestion(no_crate_example, code = "", style = "short")]
 struct SuggestionStyleShort {
     #[primary_span]
     sub: Span,
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "", style = "hidden")]
+#[suggestion(no_crate_example, code = "", style = "hidden")]
 struct SuggestionStyleHidden {
     #[primary_span]
     sub: Span,
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "", style = "verbose")]
+#[suggestion(no_crate_example, code = "", style = "verbose")]
 struct SuggestionStyleVerbose {
     #[primary_span]
     sub: Span,
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "", style = "tool-only")]
+#[suggestion(no_crate_example, code = "", style = "tool-only")]
 struct SuggestionStyleToolOnly {
     #[primary_span]
     sub: Span,
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "", style = "hidden", style = "normal")]
+#[suggestion(no_crate_example, code = "", style = "hidden", style = "normal")]
 //~^ ERROR specified multiple times
 //~| NOTE previously specified here
 struct SuggestionStyleTwice {
@@ -752,7 +754,7 @@ struct SuggestionStyleTwice {
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion_hidden(parse_add_paren, code = "")]
+#[suggestion_hidden(no_crate_example, code = "")]
 //~^ ERROR #[suggestion_hidden(...)]` is not a valid attribute
 struct SuggestionStyleOldSyntax {
     #[primary_span]
@@ -760,7 +762,7 @@ struct SuggestionStyleOldSyntax {
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion_hidden(parse_add_paren, code = "", style = "normal")]
+#[suggestion_hidden(no_crate_example, code = "", style = "normal")]
 //~^ ERROR #[suggestion_hidden(...)]` is not a valid attribute
 struct SuggestionStyleOldAndNewSyntax {
     #[primary_span]
@@ -768,7 +770,7 @@ struct SuggestionStyleOldAndNewSyntax {
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "", style = "foo")]
+#[suggestion(no_crate_example, code = "", style = "foo")]
 //~^ ERROR invalid suggestion style
 struct SuggestionStyleInvalid1 {
     #[primary_span]
@@ -776,7 +778,7 @@ struct SuggestionStyleInvalid1 {
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "", style = 42)]
+#[suggestion(no_crate_example, code = "", style = 42)]
 //~^ ERROR `#[suggestion(style = ...)]` is not a valid attribute
 struct SuggestionStyleInvalid2 {
     #[primary_span]
@@ -784,7 +786,7 @@ struct SuggestionStyleInvalid2 {
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "", style)]
+#[suggestion(no_crate_example, code = "", style)]
 //~^ ERROR `#[suggestion(style)]` is not a valid attribute
 struct SuggestionStyleInvalid3 {
     #[primary_span]
@@ -792,7 +794,7 @@ struct SuggestionStyleInvalid3 {
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "", style("foo"))]
+#[suggestion(no_crate_example, code = "", style("foo"))]
 //~^ ERROR `#[suggestion(style(...))]` is not a valid attribute
 struct SuggestionStyleInvalid4 {
     #[primary_span]
@@ -800,7 +802,7 @@ struct SuggestionStyleInvalid4 {
 }
 
 #[derive(Subdiagnostic)]
-#[suggestion(parse_add_paren, code = "")]
+#[suggestion(no_crate_example, code = "")]
 //~^ ERROR suggestion without `#[primary_span]` field
 struct PrimarySpanOnVec {
     #[primary_span]
diff --git a/tests/ui-fulldeps/session-diagnostic/subdiagnostic-derive.stderr b/tests/ui-fulldeps/session-diagnostic/subdiagnostic-derive.stderr
index f9d1a63031d..343134af6bc 100644
--- a/tests/ui-fulldeps/session-diagnostic/subdiagnostic-derive.stderr
+++ b/tests/ui-fulldeps/session-diagnostic/subdiagnostic-derive.stderr
@@ -1,7 +1,7 @@
 error: label without `#[primary_span]` field
-  --> $DIR/subdiagnostic-derive.rs:47:1
+  --> $DIR/subdiagnostic-derive.rs:49:1
    |
-LL | / #[label(parse_add_paren)]
+LL | / #[label(no_crate_example)]
 LL | |
 LL | | struct C {
 LL | |     var: String,
@@ -9,141 +9,141 @@ LL | | }
    | |_^
 
 error: diagnostic slug must be first argument of a `#[label(...)]` attribute
-  --> $DIR/subdiagnostic-derive.rs:54:1
+  --> $DIR/subdiagnostic-derive.rs:56:1
    |
 LL | #[label]
    | ^^^^^^^^
 
 error: `#[foo]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:63:1
+  --> $DIR/subdiagnostic-derive.rs:65:1
    |
 LL | #[foo]
    | ^^^^^^
 
 error: `#[label = ...]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:73:1
+  --> $DIR/subdiagnostic-derive.rs:75:1
    |
 LL | #[label = "..."]
    | ^^^^^^^^^^^^^^^^
 
 error: `#[label(bug = ...)]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:82:9
+  --> $DIR/subdiagnostic-derive.rs:84:9
    |
 LL | #[label(bug = "...")]
    |         ^^^^^^^^^^^
 
 error: diagnostic slug must be first argument of a `#[label(...)]` attribute
-  --> $DIR/subdiagnostic-derive.rs:82:1
+  --> $DIR/subdiagnostic-derive.rs:84:1
    |
 LL | #[label(bug = "...")]
    | ^^^^^^^^^^^^^^^^^^^^^
 
 error: `#[label("...")]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:92:9
+  --> $DIR/subdiagnostic-derive.rs:94:9
    |
 LL | #[label("...")]
    |         ^^^^^
 
 error: diagnostic slug must be first argument of a `#[label(...)]` attribute
-  --> $DIR/subdiagnostic-derive.rs:92:1
+  --> $DIR/subdiagnostic-derive.rs:94:1
    |
 LL | #[label("...")]
    | ^^^^^^^^^^^^^^^
 
 error: `#[label(slug = ...)]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:102:9
+  --> $DIR/subdiagnostic-derive.rs:104:9
    |
 LL | #[label(slug = 4)]
    |         ^^^^^^^^
 
 error: diagnostic slug must be first argument of a `#[label(...)]` attribute
-  --> $DIR/subdiagnostic-derive.rs:102:1
+  --> $DIR/subdiagnostic-derive.rs:104:1
    |
 LL | #[label(slug = 4)]
    | ^^^^^^^^^^^^^^^^^^
 
 error: `#[label(slug(...))]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:112:9
+  --> $DIR/subdiagnostic-derive.rs:114:9
    |
 LL | #[label(slug("..."))]
    |         ^^^^^^^^^^^
 
 error: diagnostic slug must be first argument of a `#[label(...)]` attribute
-  --> $DIR/subdiagnostic-derive.rs:112:1
+  --> $DIR/subdiagnostic-derive.rs:114:1
    |
 LL | #[label(slug("..."))]
    | ^^^^^^^^^^^^^^^^^^^^^
 
 error: diagnostic slug must be first argument of a `#[label(...)]` attribute
-  --> $DIR/subdiagnostic-derive.rs:132:1
+  --> $DIR/subdiagnostic-derive.rs:134:1
    |
 LL | #[label()]
    | ^^^^^^^^^^
 
 error: `#[label(code = ...)]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:141:26
+  --> $DIR/subdiagnostic-derive.rs:143:27
    |
-LL | #[label(parse_add_paren, code = "...")]
-   |                          ^^^^^^^^^^^^
+LL | #[label(no_crate_example, code = "...")]
+   |                           ^^^^^^^^^^^^
 
 error: `#[label(applicability = ...)]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:150:26
+  --> $DIR/subdiagnostic-derive.rs:152:27
    |
-LL | #[label(parse_add_paren, applicability = "machine-applicable")]
-   |                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL | #[label(no_crate_example, applicability = "machine-applicable")]
+   |                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: unsupported type attribute for subdiagnostic enum
-  --> $DIR/subdiagnostic-derive.rs:159:1
+  --> $DIR/subdiagnostic-derive.rs:161:1
    |
 LL | #[foo]
    | ^^^^^^
 
 error: `#[bar]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:173:5
+  --> $DIR/subdiagnostic-derive.rs:175:5
    |
 LL |     #[bar]
    |     ^^^^^^
 
 error: `#[bar = ...]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:185:5
+  --> $DIR/subdiagnostic-derive.rs:187:5
    |
 LL |     #[bar = "..."]
    |     ^^^^^^^^^^^^^^
 
 error: `#[bar = ...]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:197:5
+  --> $DIR/subdiagnostic-derive.rs:199:5
    |
 LL |     #[bar = 4]
    |     ^^^^^^^^^^
 
 error: `#[bar(...)]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:209:5
+  --> $DIR/subdiagnostic-derive.rs:211:5
    |
 LL |     #[bar("...")]
    |     ^^^^^^^^^^^^^
 
 error: `#[label(code = ...)]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:221:13
+  --> $DIR/subdiagnostic-derive.rs:223:13
    |
 LL |     #[label(code = "...")]
    |             ^^^^^^^^^^^^
 
 error: diagnostic slug must be first argument of a `#[label(...)]` attribute
-  --> $DIR/subdiagnostic-derive.rs:221:5
+  --> $DIR/subdiagnostic-derive.rs:223:5
    |
 LL |     #[label(code = "...")]
    |     ^^^^^^^^^^^^^^^^^^^^^^
 
 error: the `#[primary_span]` attribute can only be applied to fields of type `Span` or `MultiSpan`
-  --> $DIR/subdiagnostic-derive.rs:250:5
+  --> $DIR/subdiagnostic-derive.rs:252:5
    |
 LL |     #[primary_span]
    |     ^^^^^^^^^^^^^^^
 
 error: label without `#[primary_span]` field
-  --> $DIR/subdiagnostic-derive.rs:247:1
+  --> $DIR/subdiagnostic-derive.rs:249:1
    |
-LL | / #[label(parse_add_paren)]
+LL | / #[label(no_crate_example)]
 LL | |
 LL | | struct W {
 LL | |     #[primary_span]
@@ -153,13 +153,13 @@ LL | | }
    | |_^
 
 error: `#[applicability]` is only valid on suggestions
-  --> $DIR/subdiagnostic-derive.rs:260:5
+  --> $DIR/subdiagnostic-derive.rs:262:5
    |
 LL |     #[applicability]
    |     ^^^^^^^^^^^^^^^^
 
 error: `#[bar]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:270:5
+  --> $DIR/subdiagnostic-derive.rs:272:5
    |
 LL |     #[bar]
    |     ^^^^^^
@@ -167,13 +167,13 @@ LL |     #[bar]
    = help: only `primary_span`, `applicability` and `skip_arg` are valid field attributes
 
 error: `#[bar = ...]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:281:5
+  --> $DIR/subdiagnostic-derive.rs:283:5
    |
 LL |     #[bar = "..."]
    |     ^^^^^^^^^^^^^^
 
 error: `#[bar(...)]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:292:5
+  --> $DIR/subdiagnostic-derive.rs:294:5
    |
 LL |     #[bar("...")]
    |     ^^^^^^^^^^^^^
@@ -181,7 +181,7 @@ LL |     #[bar("...")]
    = help: only `primary_span`, `applicability` and `skip_arg` are valid field attributes
 
 error: unexpected unsupported untagged union
-  --> $DIR/subdiagnostic-derive.rs:308:1
+  --> $DIR/subdiagnostic-derive.rs:310:1
    |
 LL | / union AC {
 LL | |
@@ -190,78 +190,78 @@ LL | |     b: u64,
 LL | | }
    | |_^
 
-error: `#[label(parse_add_paren)]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:323:26
+error: `#[label(no_crate::example)]` is not a valid attribute
+  --> $DIR/subdiagnostic-derive.rs:325:27
    |
-LL | #[label(parse_add_paren, parse_add_paren)]
-   |                          ^^^^^^^^^^^^^^^
+LL | #[label(no_crate_example, no_crate::example)]
+   |                           ^^^^^^^^^^^^^^^^^
    |
    = help: a diagnostic slug must be the first argument to the attribute
 
 error: specified multiple times
-  --> $DIR/subdiagnostic-derive.rs:336:5
+  --> $DIR/subdiagnostic-derive.rs:338:5
    |
 LL |     #[primary_span]
    |     ^^^^^^^^^^^^^^^
    |
 note: previously specified here
-  --> $DIR/subdiagnostic-derive.rs:333:5
+  --> $DIR/subdiagnostic-derive.rs:335:5
    |
 LL |     #[primary_span]
    |     ^^^^^^^^^^^^^^^
 
 error: subdiagnostic kind not specified
-  --> $DIR/subdiagnostic-derive.rs:342:8
+  --> $DIR/subdiagnostic-derive.rs:344:8
    |
 LL | struct AG {
    |        ^^
 
 error: specified multiple times
-  --> $DIR/subdiagnostic-derive.rs:379:45
+  --> $DIR/subdiagnostic-derive.rs:381:46
    |
-LL | #[suggestion(parse_add_paren, code = "...", code = "...")]
-   |                                             ^^^^^^^^^^^^
+LL | #[suggestion(no_crate_example, code = "...", code = "...")]
+   |                                              ^^^^^^^^^^^^
    |
 note: previously specified here
-  --> $DIR/subdiagnostic-derive.rs:379:31
+  --> $DIR/subdiagnostic-derive.rs:381:32
    |
-LL | #[suggestion(parse_add_paren, code = "...", code = "...")]
-   |                               ^^^^^^^^^^^^
+LL | #[suggestion(no_crate_example, code = "...", code = "...")]
+   |                                ^^^^^^^^^^^^
 
 error: specified multiple times
-  --> $DIR/subdiagnostic-derive.rs:397:5
+  --> $DIR/subdiagnostic-derive.rs:399:5
    |
 LL |     #[applicability]
    |     ^^^^^^^^^^^^^^^^
    |
 note: previously specified here
-  --> $DIR/subdiagnostic-derive.rs:394:5
+  --> $DIR/subdiagnostic-derive.rs:396:5
    |
 LL |     #[applicability]
    |     ^^^^^^^^^^^^^^^^
 
 error: the `#[applicability]` attribute can only be applied to fields of type `Applicability`
-  --> $DIR/subdiagnostic-derive.rs:407:5
+  --> $DIR/subdiagnostic-derive.rs:409:5
    |
 LL |     #[applicability]
    |     ^^^^^^^^^^^^^^^^
 
 error: suggestion without `code = "..."`
-  --> $DIR/subdiagnostic-derive.rs:420:1
+  --> $DIR/subdiagnostic-derive.rs:422:1
    |
-LL | #[suggestion(parse_add_paren)]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL | #[suggestion(no_crate_example)]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: invalid applicability
-  --> $DIR/subdiagnostic-derive.rs:430:45
+  --> $DIR/subdiagnostic-derive.rs:432:46
    |
-LL | #[suggestion(parse_add_paren, code = "...", applicability = "foo")]
-   |                                             ^^^^^^^^^^^^^^^^^^^^^
+LL | #[suggestion(no_crate_example, code = "...", applicability = "foo")]
+   |                                              ^^^^^^^^^^^^^^^^^^^^^
 
 error: suggestion without `#[primary_span]` field
-  --> $DIR/subdiagnostic-derive.rs:448:1
+  --> $DIR/subdiagnostic-derive.rs:450:1
    |
-LL | / #[suggestion(parse_add_paren, code = "...")]
+LL | / #[suggestion(no_crate_example, code = "...")]
 LL | |
 LL | | struct AR {
 LL | |     var: String,
@@ -269,25 +269,25 @@ LL | | }
    | |_^
 
 error: unsupported type attribute for subdiagnostic enum
-  --> $DIR/subdiagnostic-derive.rs:462:1
+  --> $DIR/subdiagnostic-derive.rs:464:1
    |
 LL | #[label]
    | ^^^^^^^^
 
 error: `var` doesn't refer to a field on this type
-  --> $DIR/subdiagnostic-derive.rs:482:38
+  --> $DIR/subdiagnostic-derive.rs:484:39
    |
-LL | #[suggestion(parse_add_paren, code = "{var}", applicability = "machine-applicable")]
-   |                                      ^^^^^^^
+LL | #[suggestion(no_crate_example, code = "{var}", applicability = "machine-applicable")]
+   |                                       ^^^^^^^
 
 error: `var` doesn't refer to a field on this type
-  --> $DIR/subdiagnostic-derive.rs:501:42
+  --> $DIR/subdiagnostic-derive.rs:503:43
    |
-LL |     #[suggestion(parse_add_paren, code = "{var}", applicability = "machine-applicable")]
-   |                                          ^^^^^^^
+LL |     #[suggestion(no_crate_example, code = "{var}", applicability = "machine-applicable")]
+   |                                           ^^^^^^^
 
 error: `#[suggestion_part]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:524:5
+  --> $DIR/subdiagnostic-derive.rs:526:5
    |
 LL |     #[suggestion_part]
    |     ^^^^^^^^^^^^^^^^^^
@@ -295,7 +295,7 @@ LL |     #[suggestion_part]
    = help: `#[suggestion_part(...)]` is only valid in multipart suggestions, use `#[primary_span]` instead
 
 error: `#[suggestion_part(...)]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:527:5
+  --> $DIR/subdiagnostic-derive.rs:529:5
    |
 LL |     #[suggestion_part(code = "...")]
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -303,9 +303,9 @@ LL |     #[suggestion_part(code = "...")]
    = help: `#[suggestion_part(...)]` is only valid in multipart suggestions
 
 error: suggestion without `#[primary_span]` field
-  --> $DIR/subdiagnostic-derive.rs:521:1
+  --> $DIR/subdiagnostic-derive.rs:523:1
    |
-LL | / #[suggestion(parse_add_paren, code = "...")]
+LL | / #[suggestion(no_crate_example, code = "...")]
 LL | |
 LL | | struct BA {
 LL | |     #[suggestion_part]
@@ -315,17 +315,17 @@ LL | | }
    | |_^
 
 error: `#[multipart_suggestion(code = ...)]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:536:41
+  --> $DIR/subdiagnostic-derive.rs:538:42
    |
-LL | #[multipart_suggestion(parse_add_paren, code = "...", applicability = "machine-applicable")]
-   |                                         ^^^^^^^^^^^^
+LL | #[multipart_suggestion(no_crate_example, code = "...", applicability = "machine-applicable")]
+   |                                          ^^^^^^^^^^^^
    |
    = help: only `style` and `applicability` are valid nested attributes
 
 error: multipart suggestion without any `#[suggestion_part(...)]` fields
-  --> $DIR/subdiagnostic-derive.rs:536:1
+  --> $DIR/subdiagnostic-derive.rs:538:1
    |
-LL | / #[multipart_suggestion(parse_add_paren, code = "...", applicability = "machine-applicable")]
+LL | / #[multipart_suggestion(no_crate_example, code = "...", applicability = "machine-applicable")]
 LL | |
 LL | |
 LL | | struct BBa {
@@ -334,19 +334,19 @@ LL | | }
    | |_^
 
 error: `#[suggestion_part(...)]` attribute without `code = "..."`
-  --> $DIR/subdiagnostic-derive.rs:546:5
+  --> $DIR/subdiagnostic-derive.rs:548:5
    |
 LL |     #[suggestion_part]
    |     ^^^^^^^^^^^^^^^^^^
 
 error: `#[suggestion_part(...)]` attribute without `code = "..."`
-  --> $DIR/subdiagnostic-derive.rs:554:5
+  --> $DIR/subdiagnostic-derive.rs:556:5
    |
 LL |     #[suggestion_part()]
    |     ^^^^^^^^^^^^^^^^^^^^
 
 error: `#[primary_span]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:563:5
+  --> $DIR/subdiagnostic-derive.rs:565:5
    |
 LL |     #[primary_span]
    |     ^^^^^^^^^^^^^^^
@@ -354,9 +354,9 @@ LL |     #[primary_span]
    = help: multipart suggestions use one or more `#[suggestion_part]`s rather than one `#[primary_span]`
 
 error: multipart suggestion without any `#[suggestion_part(...)]` fields
-  --> $DIR/subdiagnostic-derive.rs:560:1
+  --> $DIR/subdiagnostic-derive.rs:562:1
    |
-LL | / #[multipart_suggestion(parse_add_paren)]
+LL | / #[multipart_suggestion(no_crate_example)]
 LL | |
 LL | | struct BC {
 LL | |     #[primary_span]
@@ -366,19 +366,19 @@ LL | | }
    | |_^
 
 error: `#[suggestion_part(...)]` attribute without `code = "..."`
-  --> $DIR/subdiagnostic-derive.rs:571:5
+  --> $DIR/subdiagnostic-derive.rs:573:5
    |
 LL |     #[suggestion_part]
    |     ^^^^^^^^^^^^^^^^^^
 
 error: `#[suggestion_part(...)]` attribute without `code = "..."`
-  --> $DIR/subdiagnostic-derive.rs:574:5
+  --> $DIR/subdiagnostic-derive.rs:576:5
    |
 LL |     #[suggestion_part()]
    |     ^^^^^^^^^^^^^^^^^^^^
 
 error: `#[suggestion_part(foo = ...)]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:577:23
+  --> $DIR/subdiagnostic-derive.rs:579:23
    |
 LL |     #[suggestion_part(foo = "bar")]
    |                       ^^^^^^^^^^^
@@ -386,123 +386,123 @@ LL |     #[suggestion_part(foo = "bar")]
    = help: `code` is the only valid nested attribute
 
 error: the `#[suggestion_part(...)]` attribute can only be applied to fields of type `Span` or `MultiSpan`
-  --> $DIR/subdiagnostic-derive.rs:580:5
+  --> $DIR/subdiagnostic-derive.rs:582:5
    |
 LL |     #[suggestion_part(code = "...")]
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: the `#[suggestion_part(...)]` attribute can only be applied to fields of type `Span` or `MultiSpan`
-  --> $DIR/subdiagnostic-derive.rs:583:5
+  --> $DIR/subdiagnostic-derive.rs:585:5
    |
 LL |     #[suggestion_part()]
    |     ^^^^^^^^^^^^^^^^^^^^
 
 error: specified multiple times
-  --> $DIR/subdiagnostic-derive.rs:591:37
+  --> $DIR/subdiagnostic-derive.rs:593:37
    |
 LL |     #[suggestion_part(code = "...", code = ",,,")]
    |                                     ^^^^^^^^^^^^
    |
 note: previously specified here
-  --> $DIR/subdiagnostic-derive.rs:591:23
+  --> $DIR/subdiagnostic-derive.rs:593:23
    |
 LL |     #[suggestion_part(code = "...", code = ",,,")]
    |                       ^^^^^^^^^^^^
 
 error: `#[applicability]` has no effect if all `#[suggestion]`/`#[multipart_suggestion]` attributes have a static `applicability = "..."`
-  --> $DIR/subdiagnostic-derive.rs:620:5
+  --> $DIR/subdiagnostic-derive.rs:622:5
    |
 LL |     #[applicability]
    |     ^^^^^^^^^^^^^^^^
 
 error: expected exactly one string literal for `code = ...`
-  --> $DIR/subdiagnostic-derive.rs:668:23
+  --> $DIR/subdiagnostic-derive.rs:670:23
    |
 LL |     #[suggestion_part(code("foo"))]
    |                       ^^^^^^^^^^^
 
 error: expected exactly one string literal for `code = ...`
-  --> $DIR/subdiagnostic-derive.rs:677:23
+  --> $DIR/subdiagnostic-derive.rs:679:23
    |
 LL |     #[suggestion_part(code("foo", "bar"))]
    |                       ^^^^^^^^^^^^^^^^^^
 
 error: expected exactly one string literal for `code = ...`
-  --> $DIR/subdiagnostic-derive.rs:686:23
+  --> $DIR/subdiagnostic-derive.rs:688:23
    |
 LL |     #[suggestion_part(code(3))]
    |                       ^^^^^^^
 
 error: expected exactly one string literal for `code = ...`
-  --> $DIR/subdiagnostic-derive.rs:695:23
+  --> $DIR/subdiagnostic-derive.rs:697:23
    |
 LL |     #[suggestion_part(code())]
    |                       ^^^^^^
 
 error: `code = "..."`/`code(...)` must contain only string literals
-  --> $DIR/subdiagnostic-derive.rs:704:23
+  --> $DIR/subdiagnostic-derive.rs:706:23
    |
 LL |     #[suggestion_part(code = 3)]
    |                       ^^^^^^^^
 
 error: specified multiple times
-  --> $DIR/subdiagnostic-derive.rs:746:60
+  --> $DIR/subdiagnostic-derive.rs:748:61
    |
-LL | #[suggestion(parse_add_paren, code = "", style = "hidden", style = "normal")]
-   |                                                            ^^^^^^^^^^^^^^^^
+LL | #[suggestion(no_crate_example, code = "", style = "hidden", style = "normal")]
+   |                                                             ^^^^^^^^^^^^^^^^
    |
 note: previously specified here
-  --> $DIR/subdiagnostic-derive.rs:746:42
+  --> $DIR/subdiagnostic-derive.rs:748:43
    |
-LL | #[suggestion(parse_add_paren, code = "", style = "hidden", style = "normal")]
-   |                                          ^^^^^^^^^^^^^^^^
+LL | #[suggestion(no_crate_example, code = "", style = "hidden", style = "normal")]
+   |                                           ^^^^^^^^^^^^^^^^
 
 error: `#[suggestion_hidden(...)]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:755:1
+  --> $DIR/subdiagnostic-derive.rs:757:1
    |
-LL | #[suggestion_hidden(parse_add_paren, code = "")]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL | #[suggestion_hidden(no_crate_example, code = "")]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: Use `#[suggestion(..., style = "hidden")]` instead
 
 error: `#[suggestion_hidden(...)]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:763:1
+  --> $DIR/subdiagnostic-derive.rs:765:1
    |
-LL | #[suggestion_hidden(parse_add_paren, code = "", style = "normal")]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL | #[suggestion_hidden(no_crate_example, code = "", style = "normal")]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: Use `#[suggestion(..., style = "hidden")]` instead
 
 error: invalid suggestion style
-  --> $DIR/subdiagnostic-derive.rs:771:50
+  --> $DIR/subdiagnostic-derive.rs:773:51
    |
-LL | #[suggestion(parse_add_paren, code = "", style = "foo")]
-   |                                                  ^^^^^
+LL | #[suggestion(no_crate_example, code = "", style = "foo")]
+   |                                                   ^^^^^
    |
    = help: valid styles are `normal`, `short`, `hidden`, `verbose` and `tool-only`
 
 error: `#[suggestion(style = ...)]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:779:42
+  --> $DIR/subdiagnostic-derive.rs:781:43
    |
-LL | #[suggestion(parse_add_paren, code = "", style = 42)]
-   |                                          ^^^^^^^^^^
+LL | #[suggestion(no_crate_example, code = "", style = 42)]
+   |                                           ^^^^^^^^^^
 
 error: `#[suggestion(style)]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:787:42
+  --> $DIR/subdiagnostic-derive.rs:789:43
    |
-LL | #[suggestion(parse_add_paren, code = "", style)]
-   |                                          ^^^^^
+LL | #[suggestion(no_crate_example, code = "", style)]
+   |                                           ^^^^^
    |
    = help: a diagnostic slug must be the first argument to the attribute
 
 error: `#[suggestion(style(...))]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:795:42
+  --> $DIR/subdiagnostic-derive.rs:797:43
    |
-LL | #[suggestion(parse_add_paren, code = "", style("foo"))]
-   |                                          ^^^^^^^^^^^^
+LL | #[suggestion(no_crate_example, code = "", style("foo"))]
+   |                                           ^^^^^^^^^^^^
 
 error: `#[primary_span]` is not a valid attribute
-  --> $DIR/subdiagnostic-derive.rs:806:5
+  --> $DIR/subdiagnostic-derive.rs:808:5
    |
 LL |     #[primary_span]
    |     ^^^^^^^^^^^^^^^
@@ -511,9 +511,9 @@ LL |     #[primary_span]
    = help: to create a suggestion with multiple spans, use `#[multipart_suggestion]` instead
 
 error: suggestion without `#[primary_span]` field
-  --> $DIR/subdiagnostic-derive.rs:803:1
+  --> $DIR/subdiagnostic-derive.rs:805:1
    |
-LL | / #[suggestion(parse_add_paren, code = "")]
+LL | / #[suggestion(no_crate_example, code = "")]
 LL | |
 LL | | struct PrimarySpanOnVec {
 LL | |     #[primary_span]
@@ -523,64 +523,64 @@ LL | | }
    | |_^
 
 error: cannot find attribute `foo` in this scope
-  --> $DIR/subdiagnostic-derive.rs:63:3
+  --> $DIR/subdiagnostic-derive.rs:65:3
    |
 LL | #[foo]
    |   ^^^
 
 error: cannot find attribute `foo` in this scope
-  --> $DIR/subdiagnostic-derive.rs:159:3
+  --> $DIR/subdiagnostic-derive.rs:161:3
    |
 LL | #[foo]
    |   ^^^
 
 error: cannot find attribute `bar` in this scope
-  --> $DIR/subdiagnostic-derive.rs:173:7
+  --> $DIR/subdiagnostic-derive.rs:175:7
    |
 LL |     #[bar]
    |       ^^^
 
 error: cannot find attribute `bar` in this scope
-  --> $DIR/subdiagnostic-derive.rs:185:7
+  --> $DIR/subdiagnostic-derive.rs:187:7
    |
 LL |     #[bar = "..."]
    |       ^^^
 
 error: cannot find attribute `bar` in this scope
-  --> $DIR/subdiagnostic-derive.rs:197:7
+  --> $DIR/subdiagnostic-derive.rs:199:7
    |
 LL |     #[bar = 4]
    |       ^^^
 
 error: cannot find attribute `bar` in this scope
-  --> $DIR/subdiagnostic-derive.rs:209:7
+  --> $DIR/subdiagnostic-derive.rs:211:7
    |
 LL |     #[bar("...")]
    |       ^^^
 
 error: cannot find attribute `bar` in this scope
-  --> $DIR/subdiagnostic-derive.rs:270:7
+  --> $DIR/subdiagnostic-derive.rs:272:7
    |
 LL |     #[bar]
    |       ^^^
 
 error: cannot find attribute `bar` in this scope
-  --> $DIR/subdiagnostic-derive.rs:281:7
+  --> $DIR/subdiagnostic-derive.rs:283:7
    |
 LL |     #[bar = "..."]
    |       ^^^
 
 error: cannot find attribute `bar` in this scope
-  --> $DIR/subdiagnostic-derive.rs:292:7
+  --> $DIR/subdiagnostic-derive.rs:294:7
    |
 LL |     #[bar("...")]
    |       ^^^
 
-error[E0425]: cannot find value `slug` in module `rustc_errors::fluent`
-  --> $DIR/subdiagnostic-derive.rs:122:9
+error[E0425]: cannot find value `slug` in module `crate::fluent_generated`
+  --> $DIR/subdiagnostic-derive.rs:124:9
    |
 LL | #[label(slug)]
-   |         ^^^^ not found in `rustc_errors::fluent`
+   |         ^^^^ not found in `crate::fluent_generated`
 
 error: aborting due to 81 previous errors
 
diff --git a/tests/ui-fulldeps/issue-15149.rs b/tests/ui-fulldeps/std/issue-15149.rs
index 064472f5785..064472f5785 100644
--- a/tests/ui-fulldeps/issue-15149.rs
+++ b/tests/ui-fulldeps/std/issue-15149.rs
diff --git a/tests/ui-fulldeps/issue-81357-unsound-file-methods.rs b/tests/ui-fulldeps/std/issue-81357-unsound-file-methods.rs
index fdf1150f8d2..fdf1150f8d2 100644
--- a/tests/ui-fulldeps/issue-81357-unsound-file-methods.rs
+++ b/tests/ui-fulldeps/std/issue-81357-unsound-file-methods.rs
diff --git a/tests/ui-fulldeps/stdio-from.rs b/tests/ui-fulldeps/std/stdio-from.rs
index fef9f27fcdf..fef9f27fcdf 100644
--- a/tests/ui-fulldeps/stdio-from.rs
+++ b/tests/ui-fulldeps/std/stdio-from.rs
diff --git a/tests/ui-fulldeps/switch-stdout.rs b/tests/ui-fulldeps/std/switch-stdout.rs
index e9501a80930..e9501a80930 100644
--- a/tests/ui-fulldeps/switch-stdout.rs
+++ b/tests/ui-fulldeps/std/switch-stdout.rs
diff --git a/tests/ui/alloc-error/alloc-error-handler-bad-signature-3.stderr b/tests/ui/alloc-error/alloc-error-handler-bad-signature-3.stderr
index d1b9d7a40b4..eb739b149a1 100644
--- a/tests/ui/alloc-error/alloc-error-handler-bad-signature-3.stderr
+++ b/tests/ui/alloc-error/alloc-error-handler-bad-signature-3.stderr
@@ -7,10 +7,7 @@ LL |   fn oom() -> ! {
    |  _-^^^^^^^^^^^^
 LL | |     loop {}
 LL | | }
-   | | -
-   | | |
-   | |_unexpected argument of type `core::alloc::Layout`
-   |   help: remove the extra argument
+   | |_- unexpected argument of type `core::alloc::Layout`
    |
 note: function defined here
   --> $DIR/alloc-error-handler-bad-signature-3.rs:10:4
diff --git a/tests/ui/argument-suggestions/extra_arguments.rs b/tests/ui/argument-suggestions/extra_arguments.rs
index 3f83de95e2d..1442062326d 100644
--- a/tests/ui/argument-suggestions/extra_arguments.rs
+++ b/tests/ui/argument-suggestions/extra_arguments.rs
@@ -3,8 +3,15 @@ fn one_arg(_a: i32) {}
 fn two_arg_same(_a: i32, _b: i32) {}
 fn two_arg_diff(_a: i32, _b: &str) {}
 
+macro_rules! foo {
+    ($x:expr) => {
+        empty($x, 1); //~ ERROR function takes
+    }
+}
+
 fn main() {
   empty(""); //~ ERROR function takes
+  empty(1, 1); //~ ERROR function takes
 
   one_arg(1, 1); //~ ERROR function takes
   one_arg(1, ""); //~ ERROR function takes
@@ -32,4 +39,5 @@ fn main() {
     1,
     ""
   );
+  foo!(1);
 }
diff --git a/tests/ui/argument-suggestions/extra_arguments.stderr b/tests/ui/argument-suggestions/extra_arguments.stderr
index 0911685b428..11c71099743 100644
--- a/tests/ui/argument-suggestions/extra_arguments.stderr
+++ b/tests/ui/argument-suggestions/extra_arguments.stderr
@@ -1,5 +1,5 @@
 error[E0061]: this function takes 0 arguments but 1 argument was supplied
-  --> $DIR/extra_arguments.rs:7:3
+  --> $DIR/extra_arguments.rs:13:3
    |
 LL |   empty("");
    |   ^^^^^ --
@@ -13,8 +13,27 @@ note: function defined here
 LL | fn empty() {}
    |    ^^^^^
 
+error[E0061]: this function takes 0 arguments but 2 arguments were supplied
+  --> $DIR/extra_arguments.rs:14:3
+   |
+LL |   empty(1, 1);
+   |   ^^^^^ -  - unexpected argument of type `{integer}`
+   |         |
+   |         unexpected argument of type `{integer}`
+   |
+note: function defined here
+  --> $DIR/extra_arguments.rs:1:4
+   |
+LL | fn empty() {}
+   |    ^^^^^
+help: remove the extra arguments
+   |
+LL -   empty(1, 1);
+LL +   empty();
+   |
+
 error[E0061]: this function takes 1 argument but 2 arguments were supplied
-  --> $DIR/extra_arguments.rs:9:3
+  --> $DIR/extra_arguments.rs:16:3
    |
 LL |   one_arg(1, 1);
    |   ^^^^^^^  ---
@@ -29,7 +48,7 @@ LL | fn one_arg(_a: i32) {}
    |    ^^^^^^^ -------
 
 error[E0061]: this function takes 1 argument but 2 arguments were supplied
-  --> $DIR/extra_arguments.rs:10:3
+  --> $DIR/extra_arguments.rs:17:3
    |
 LL |   one_arg(1, "");
    |   ^^^^^^^  ----
@@ -44,7 +63,7 @@ LL | fn one_arg(_a: i32) {}
    |    ^^^^^^^ -------
 
 error[E0061]: this function takes 1 argument but 3 arguments were supplied
-  --> $DIR/extra_arguments.rs:11:3
+  --> $DIR/extra_arguments.rs:18:3
    |
 LL |   one_arg(1, "", 1.0);
    |   ^^^^^^^    --  --- unexpected argument of type `{float}`
@@ -63,7 +82,7 @@ LL +   one_arg(1);
    |
 
 error[E0061]: this function takes 2 arguments but 3 arguments were supplied
-  --> $DIR/extra_arguments.rs:13:3
+  --> $DIR/extra_arguments.rs:20:3
    |
 LL |   two_arg_same(1, 1, 1);
    |   ^^^^^^^^^^^^     ---
@@ -78,7 +97,7 @@ LL | fn two_arg_same(_a: i32, _b: i32) {}
    |    ^^^^^^^^^^^^ -------  -------
 
 error[E0061]: this function takes 2 arguments but 3 arguments were supplied
-  --> $DIR/extra_arguments.rs:14:3
+  --> $DIR/extra_arguments.rs:21:3
    |
 LL |   two_arg_same(1, 1, 1.0);
    |   ^^^^^^^^^^^^     -----
@@ -93,7 +112,7 @@ LL | fn two_arg_same(_a: i32, _b: i32) {}
    |    ^^^^^^^^^^^^ -------  -------
 
 error[E0061]: this function takes 2 arguments but 3 arguments were supplied
-  --> $DIR/extra_arguments.rs:16:3
+  --> $DIR/extra_arguments.rs:23:3
    |
 LL |   two_arg_diff(1, 1, "");
    |   ^^^^^^^^^^^^  ---
@@ -108,7 +127,7 @@ LL | fn two_arg_diff(_a: i32, _b: &str) {}
    |    ^^^^^^^^^^^^ -------  --------
 
 error[E0061]: this function takes 2 arguments but 3 arguments were supplied
-  --> $DIR/extra_arguments.rs:17:3
+  --> $DIR/extra_arguments.rs:24:3
    |
 LL |   two_arg_diff(1, "", "");
    |   ^^^^^^^^^^^^      ----
@@ -123,7 +142,7 @@ LL | fn two_arg_diff(_a: i32, _b: &str) {}
    |    ^^^^^^^^^^^^ -------  --------
 
 error[E0061]: this function takes 2 arguments but 4 arguments were supplied
-  --> $DIR/extra_arguments.rs:18:3
+  --> $DIR/extra_arguments.rs:25:3
    |
 LL |   two_arg_diff(1, 1, "", "");
    |   ^^^^^^^^^^^^    -      -- unexpected argument of type `&'static str`
@@ -142,7 +161,7 @@ LL +   two_arg_diff(1, "");
    |
 
 error[E0061]: this function takes 2 arguments but 4 arguments were supplied
-  --> $DIR/extra_arguments.rs:19:3
+  --> $DIR/extra_arguments.rs:26:3
    |
 LL |   two_arg_diff(1, "", 1, "");
    |   ^^^^^^^^^^^^        -  -- unexpected argument of type `&'static str`
@@ -161,7 +180,7 @@ LL +   two_arg_diff(1, "");
    |
 
 error[E0061]: this function takes 2 arguments but 3 arguments were supplied
-  --> $DIR/extra_arguments.rs:22:3
+  --> $DIR/extra_arguments.rs:29:3
    |
 LL |   two_arg_same(1, 1,     "");
    |   ^^^^^^^^^^^^     --------
@@ -176,7 +195,7 @@ LL | fn two_arg_same(_a: i32, _b: i32) {}
    |    ^^^^^^^^^^^^ -------  -------
 
 error[E0061]: this function takes 2 arguments but 3 arguments were supplied
-  --> $DIR/extra_arguments.rs:23:3
+  --> $DIR/extra_arguments.rs:30:3
    |
 LL |   two_arg_diff(1, 1,     "");
    |   ^^^^^^^^^^^^  ---
@@ -191,7 +210,7 @@ LL | fn two_arg_diff(_a: i32, _b: &str) {}
    |    ^^^^^^^^^^^^ -------  --------
 
 error[E0061]: this function takes 2 arguments but 3 arguments were supplied
-  --> $DIR/extra_arguments.rs:24:3
+  --> $DIR/extra_arguments.rs:31:3
    |
 LL |     two_arg_same(
    |     ^^^^^^^^^^^^
@@ -211,7 +230,7 @@ LL | fn two_arg_same(_a: i32, _b: i32) {}
    |    ^^^^^^^^^^^^ -------  -------
 
 error[E0061]: this function takes 2 arguments but 3 arguments were supplied
-  --> $DIR/extra_arguments.rs:30:3
+  --> $DIR/extra_arguments.rs:37:3
    |
 LL |     two_arg_diff(
    |     ^^^^^^^^^^^^
@@ -229,6 +248,26 @@ note: function defined here
 LL | fn two_arg_diff(_a: i32, _b: &str) {}
    |    ^^^^^^^^^^^^ -------  --------
 
-error: aborting due to 14 previous errors
+error[E0061]: this function takes 0 arguments but 2 arguments were supplied
+  --> $DIR/extra_arguments.rs:8:9
+   |
+LL |         empty($x, 1);
+   |         ^^^^^     - unexpected argument of type `{integer}`
+...
+LL |   foo!(1);
+   |   -------
+   |   |    |
+   |   |    unexpected argument of type `{integer}`
+   |   |    help: remove the extra argument
+   |   in this macro invocation
+   |
+note: function defined here
+  --> $DIR/extra_arguments.rs:1:4
+   |
+LL | fn empty() {}
+   |    ^^^^^
+   = note: this error originates in the macro `foo` (in Nightly builds, run with -Z macro-backtrace for more info)
+
+error: aborting due to 16 previous errors
 
 For more information about this error, try `rustc --explain E0061`.
diff --git a/tests/ui/argument-suggestions/issue-100154.stderr b/tests/ui/argument-suggestions/issue-100154.stderr
index 1499229c3ce..2504f616fb7 100644
--- a/tests/ui/argument-suggestions/issue-100154.stderr
+++ b/tests/ui/argument-suggestions/issue-100154.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this function takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: function takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/issue-100154.rs:4:5
    |
 LL |     foo::<()>(());
diff --git a/tests/ui/argument-suggestions/too-long.stderr b/tests/ui/argument-suggestions/too-long.stderr
index 4928943294b..bb6f06a35c6 100644
--- a/tests/ui/argument-suggestions/too-long.stderr
+++ b/tests/ui/argument-suggestions/too-long.stderr
@@ -6,7 +6,7 @@ LL |     qux.foo(a, b, c, d, e, f, g, h, i, j, k, l);
    |         |
    |         arguments to this method are incorrect
    |
-note: associated function defined here
+note: method defined here
   --> $DIR/too-long.rs:4:8
    |
 LL |     fn foo(
diff --git a/tests/ui/associated-consts/issue-105330.stderr b/tests/ui/associated-consts/issue-105330.stderr
index 08570d4a5d9..bbafc55dac3 100644
--- a/tests/ui/associated-consts/issue-105330.stderr
+++ b/tests/ui/associated-consts/issue-105330.stderr
@@ -33,7 +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
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in impl header
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in impl headers
   --> $DIR/issue-105330.rs:6:27
    |
 LL | impl TraitWAssocConst for impl Demo {
diff --git a/tests/ui/associated-type-bounds/bad-universal-in-dyn-in-where-clause.rs b/tests/ui/associated-type-bounds/bad-universal-in-dyn-in-where-clause.rs
new file mode 100644
index 00000000000..8cab1f66c27
--- /dev/null
+++ b/tests/ui/associated-type-bounds/bad-universal-in-dyn-in-where-clause.rs
@@ -0,0 +1,14 @@
+#![feature(associated_type_bounds)]
+
+trait B {
+    type AssocType;
+}
+
+fn f()
+where
+    dyn for<'j> B<AssocType: 'j>:,
+    //~^ ERROR associated type bounds are only allowed in where clauses and function signatures
+{
+}
+
+fn main() {}
diff --git a/tests/ui/associated-type-bounds/bad-universal-in-dyn-in-where-clause.stderr b/tests/ui/associated-type-bounds/bad-universal-in-dyn-in-where-clause.stderr
new file mode 100644
index 00000000000..6fa266d23d4
--- /dev/null
+++ b/tests/ui/associated-type-bounds/bad-universal-in-dyn-in-where-clause.stderr
@@ -0,0 +1,8 @@
+error: associated type bounds are only allowed in where clauses and function signatures, not in bounds
+  --> $DIR/bad-universal-in-dyn-in-where-clause.rs:9:19
+   |
+LL |     dyn for<'j> B<AssocType: 'j>:,
+   |                   ^^^^^^^^^^^^^
+
+error: aborting due to previous error
+
diff --git a/tests/ui/associated-type-bounds/bad-universal-in-impl-sig.rs b/tests/ui/associated-type-bounds/bad-universal-in-impl-sig.rs
new file mode 100644
index 00000000000..1d5d181efcc
--- /dev/null
+++ b/tests/ui/associated-type-bounds/bad-universal-in-impl-sig.rs
@@ -0,0 +1,13 @@
+#![feature(associated_type_bounds)]
+
+trait Trait {
+    type Item;
+}
+
+trait Trait2 {}
+
+// It's not possible to insert a universal `impl Trait` here!
+impl dyn Trait<Item: Trait2> {}
+//~^ ERROR associated type bounds are only allowed in where clauses and function signatures
+
+fn main() {}
diff --git a/tests/ui/associated-type-bounds/bad-universal-in-impl-sig.stderr b/tests/ui/associated-type-bounds/bad-universal-in-impl-sig.stderr
new file mode 100644
index 00000000000..8b66627d57f
--- /dev/null
+++ b/tests/ui/associated-type-bounds/bad-universal-in-impl-sig.stderr
@@ -0,0 +1,8 @@
+error: associated type bounds are only allowed in where clauses and function signatures, not in impl headers
+  --> $DIR/bad-universal-in-impl-sig.rs:10:16
+   |
+LL | impl dyn Trait<Item: Trait2> {}
+   |                ^^^^^^^^^^^^
+
+error: aborting due to previous error
+
diff --git a/tests/ui/associated-type-bounds/inside-adt.rs b/tests/ui/associated-type-bounds/inside-adt.rs
index 8eb8c44bb42..057966941dc 100644
--- a/tests/ui/associated-type-bounds/inside-adt.rs
+++ b/tests/ui/associated-type-bounds/inside-adt.rs
@@ -3,28 +3,24 @@
 use std::mem::ManuallyDrop;
 
 struct S1 { f: dyn Iterator<Item: Copy> }
-//~^ ERROR associated type bounds are not allowed within structs, enums, or unions
+//~^ ERROR associated type bounds are only allowed in where clauses and function signatures
 struct S2 { f: Box<dyn Iterator<Item: Copy>> }
-//~^ ERROR associated type bounds are not allowed within structs, enums, or unions
+//~^ ERROR associated type bounds are only allowed in where clauses and function signatures
 struct S3 { f: dyn Iterator<Item: 'static> }
-//~^ ERROR associated type bounds are not allowed within structs, enums, or unions
+//~^ ERROR associated type bounds are only allowed in where clauses and function signatures
 
 enum E1 { V(dyn Iterator<Item: Copy>) }
-//~^ ERROR associated type bounds are not allowed within structs, enums, or unions
-//~| ERROR the size for values of type `(dyn Iterator<Item = impl Copy> + 'static)`
+//~^ ERROR associated type bounds are only allowed in where clauses and function signatures
 enum E2 { V(Box<dyn Iterator<Item: Copy>>) }
-//~^ ERROR associated type bounds are not allowed within structs, enums, or unions
+//~^ ERROR associated type bounds are only allowed in where clauses and function signatures
 enum E3 { V(dyn Iterator<Item: 'static>) }
-//~^ ERROR associated type bounds are not allowed within structs, enums, or unions
-//~| ERROR the size for values of type `(dyn Iterator<Item = impl Sized + 'static> + 'static)`
+//~^ ERROR associated type bounds are only allowed in where clauses and function signatures
 
 union U1 { f: ManuallyDrop<dyn Iterator<Item: Copy>> }
-//~^ ERROR associated type bounds are not allowed within structs, enums, or unions
-//~| ERROR the size for values of type `(dyn Iterator<Item = impl Copy> + 'static)`
+//~^ ERROR associated type bounds are only allowed in where clauses and function signatures
 union U2 { f: ManuallyDrop<Box<dyn Iterator<Item: Copy>>> }
-//~^ ERROR associated type bounds are not allowed within structs, enums, or unions
+//~^ ERROR associated type bounds are only allowed in where clauses and function signatures
 union U3 { f: ManuallyDrop<dyn Iterator<Item: 'static>> }
-//~^ ERROR associated type bounds are not allowed within structs, enums, or unions
-//~| ERROR the size for values of type `(dyn Iterator<Item = impl Sized + 'static> + 'static)`
+//~^ ERROR associated type bounds are only allowed in where clauses and function signatures
 
 fn main() {}
diff --git a/tests/ui/associated-type-bounds/inside-adt.stderr b/tests/ui/associated-type-bounds/inside-adt.stderr
index 1668b613b25..f848bd798ee 100644
--- a/tests/ui/associated-type-bounds/inside-adt.stderr
+++ b/tests/ui/associated-type-bounds/inside-adt.stderr
@@ -1,131 +1,56 @@
-error: associated type bounds are not allowed within structs, enums, or unions
+error: associated type bounds are only allowed in where clauses and function signatures, not in field types
   --> $DIR/inside-adt.rs:5:29
    |
 LL | struct S1 { f: dyn Iterator<Item: Copy> }
    |                             ^^^^^^^^^^
 
-error: associated type bounds are not allowed within structs, enums, or unions
+error: associated type bounds are only allowed in where clauses and function signatures, not in field types
   --> $DIR/inside-adt.rs:7:33
    |
 LL | struct S2 { f: Box<dyn Iterator<Item: Copy>> }
    |                                 ^^^^^^^^^^
 
-error: associated type bounds are not allowed within structs, enums, or unions
+error: associated type bounds are only allowed in where clauses and function signatures, not in field types
   --> $DIR/inside-adt.rs:9:29
    |
 LL | struct S3 { f: dyn Iterator<Item: 'static> }
    |                             ^^^^^^^^^^^^^
 
-error: associated type bounds are not allowed within structs, enums, or unions
+error: associated type bounds are only allowed in where clauses and function signatures, not in field types
   --> $DIR/inside-adt.rs:12:26
    |
 LL | enum E1 { V(dyn Iterator<Item: Copy>) }
    |                          ^^^^^^^^^^
 
-error: associated type bounds are not allowed within structs, enums, or unions
-  --> $DIR/inside-adt.rs:15:30
+error: associated type bounds are only allowed in where clauses and function signatures, not in field types
+  --> $DIR/inside-adt.rs:14:30
    |
 LL | enum E2 { V(Box<dyn Iterator<Item: Copy>>) }
    |                              ^^^^^^^^^^
 
-error: associated type bounds are not allowed within structs, enums, or unions
-  --> $DIR/inside-adt.rs:17:26
+error: associated type bounds are only allowed in where clauses and function signatures, not in field types
+  --> $DIR/inside-adt.rs:16:26
    |
 LL | enum E3 { V(dyn Iterator<Item: 'static>) }
    |                          ^^^^^^^^^^^^^
 
-error: associated type bounds are not allowed within structs, enums, or unions
-  --> $DIR/inside-adt.rs:21:41
+error: associated type bounds are only allowed in where clauses and function signatures, not in field types
+  --> $DIR/inside-adt.rs:19:41
    |
 LL | union U1 { f: ManuallyDrop<dyn Iterator<Item: Copy>> }
    |                                         ^^^^^^^^^^
 
-error: associated type bounds are not allowed within structs, enums, or unions
-  --> $DIR/inside-adt.rs:24:45
+error: associated type bounds are only allowed in where clauses and function signatures, not in field types
+  --> $DIR/inside-adt.rs:21:45
    |
 LL | union U2 { f: ManuallyDrop<Box<dyn Iterator<Item: Copy>>> }
    |                                             ^^^^^^^^^^
 
-error: associated type bounds are not allowed within structs, enums, or unions
-  --> $DIR/inside-adt.rs:26:41
+error: associated type bounds are only allowed in where clauses and function signatures, not in field types
+  --> $DIR/inside-adt.rs:23:41
    |
 LL | union U3 { f: ManuallyDrop<dyn Iterator<Item: 'static>> }
    |                                         ^^^^^^^^^^^^^
 
-error[E0277]: the size for values of type `(dyn Iterator<Item = impl Copy> + 'static)` cannot be known at compilation time
-  --> $DIR/inside-adt.rs:12:13
-   |
-LL | enum E1 { V(dyn Iterator<Item: Copy>) }
-   |             ^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
-   |
-   = help: the trait `Sized` is not implemented for `(dyn Iterator<Item = impl Copy> + 'static)`
-   = note: no field of an enum variant may have a dynamically sized type
-   = help: change the field's type to have a statically known size
-help: borrowed types always have a statically known size
-   |
-LL | enum E1 { V(&dyn Iterator<Item: Copy>) }
-   |             +
-help: the `Box` type always has a statically known size and allocates its contents in the heap
-   |
-LL | enum E1 { V(Box<dyn Iterator<Item: Copy>>) }
-   |             ++++                        +
-
-error[E0277]: the size for values of type `(dyn Iterator<Item = impl Sized + 'static> + 'static)` cannot be known at compilation time
-  --> $DIR/inside-adt.rs:17:13
-   |
-LL | enum E3 { V(dyn Iterator<Item: 'static>) }
-   |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
-   |
-   = help: the trait `Sized` is not implemented for `(dyn Iterator<Item = impl Sized + 'static> + 'static)`
-   = note: no field of an enum variant may have a dynamically sized type
-   = help: change the field's type to have a statically known size
-help: borrowed types always have a statically known size
-   |
-LL | enum E3 { V(&dyn Iterator<Item: 'static>) }
-   |             +
-help: the `Box` type always has a statically known size and allocates its contents in the heap
-   |
-LL | enum E3 { V(Box<dyn Iterator<Item: 'static>>) }
-   |             ++++                           +
-
-error[E0277]: the size for values of type `(dyn Iterator<Item = impl Copy> + 'static)` cannot be known at compilation time
-  --> $DIR/inside-adt.rs:21:15
-   |
-LL | union U1 { f: ManuallyDrop<dyn Iterator<Item: Copy>> }
-   |               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
-   |
-   = help: within `ManuallyDrop<(dyn Iterator<Item = impl Copy> + 'static)>`, the trait `Sized` is not implemented for `(dyn Iterator<Item = impl Copy> + 'static)`
-   = note: required because it appears within the type `ManuallyDrop<dyn Iterator<Item = impl Copy>>`
-   = note: no field of a union may have a dynamically sized type
-   = help: change the field's type to have a statically known size
-help: borrowed types always have a statically known size
-   |
-LL | union U1 { f: &ManuallyDrop<dyn Iterator<Item: Copy>> }
-   |               +
-help: the `Box` type always has a statically known size and allocates its contents in the heap
-   |
-LL | union U1 { f: Box<ManuallyDrop<dyn Iterator<Item: Copy>>> }
-   |               ++++                                      +
-
-error[E0277]: the size for values of type `(dyn Iterator<Item = impl Sized + 'static> + 'static)` cannot be known at compilation time
-  --> $DIR/inside-adt.rs:26:15
-   |
-LL | union U3 { f: ManuallyDrop<dyn Iterator<Item: 'static>> }
-   |               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
-   |
-   = help: within `ManuallyDrop<(dyn Iterator<Item = impl Sized + 'static> + 'static)>`, the trait `Sized` is not implemented for `(dyn Iterator<Item = impl Sized + 'static> + 'static)`
-   = note: required because it appears within the type `ManuallyDrop<dyn Iterator<Item = impl Sized>>`
-   = note: no field of a union may have a dynamically sized type
-   = help: change the field's type to have a statically known size
-help: borrowed types always have a statically known size
-   |
-LL | union U3 { f: &ManuallyDrop<dyn Iterator<Item: 'static>> }
-   |               +
-help: the `Box` type always has a statically known size and allocates its contents in the heap
-   |
-LL | union U3 { f: Box<ManuallyDrop<dyn Iterator<Item: 'static>>> }
-   |               ++++                                         +
-
-error: aborting due to 13 previous errors
+error: aborting due to 9 previous errors
 
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/associated-types/associated-type-projection-from-supertrait.stderr b/tests/ui/associated-types/associated-type-projection-from-supertrait.stderr
index 5fe53a27eb8..3f3bf22b0c4 100644
--- a/tests/ui/associated-types/associated-type-projection-from-supertrait.stderr
+++ b/tests/ui/associated-types/associated-type-projection-from-supertrait.stderr
@@ -34,7 +34,7 @@ LL | fn f() { ModelT.chip_paint(Blue); }
    |                 |
    |                 arguments to this method are incorrect
    |
-note: associated function defined here
+note: method defined here
   --> $DIR/associated-type-projection-from-supertrait.rs:12:8
    |
 LL |     fn chip_paint(&self, c: Self::Color) { }
@@ -48,7 +48,7 @@ LL | fn g() { ModelU.chip_paint(Black); }
    |                 |
    |                 arguments to this method are incorrect
    |
-note: associated function defined here
+note: method defined here
   --> $DIR/associated-type-projection-from-supertrait.rs:12:8
    |
 LL |     fn chip_paint(&self, c: Self::Color) { }
diff --git a/tests/ui/associated-types/associated-types-eq-hr.stderr b/tests/ui/associated-types/associated-types-eq-hr.stderr
index 99db0c1bf3b..3e1142d5d95 100644
--- a/tests/ui/associated-types/associated-types-eq-hr.stderr
+++ b/tests/ui/associated-types/associated-types-eq-hr.stderr
@@ -15,7 +15,7 @@ note: required by a bound in `foo`
   --> $DIR/associated-types-eq-hr.rs:45:36
    |
 LL | fn foo<T>()
-   |    --- required by a bound in this
+   |    --- required by a bound in this function
 LL | where
 LL |     T: for<'x> TheTrait<&'x isize, A = &'x isize>,
    |                                    ^^^^^^^^^^^^^ required by this bound in `foo`
@@ -37,7 +37,7 @@ note: required by a bound in `bar`
   --> $DIR/associated-types-eq-hr.rs:52:36
    |
 LL | fn bar<T>()
-   |    --- required by a bound in this
+   |    --- required by a bound in this function
 LL | where
 LL |     T: for<'x> TheTrait<&'x isize, A = &'x usize>,
    |                                    ^^^^^^^^^^^^^ required by this bound in `bar`
diff --git a/tests/ui/associated-types/defaults-suitability.stderr b/tests/ui/associated-types/defaults-suitability.stderr
index eadad4cd572..2485758757b 100644
--- a/tests/ui/associated-types/defaults-suitability.stderr
+++ b/tests/ui/associated-types/defaults-suitability.stderr
@@ -27,7 +27,7 @@ LL |     Self::Ty: Clone,
    |               ^^^^^ required by this bound in `Tr2::Ty`
 LL | {
 LL |     type Ty = NotClone;
-   |          -- required by a bound in this
+   |          -- required by a bound in this associated type
 help: consider annotating `NotClone` with `#[derive(Clone)]`
    |
 LL | #[derive(Clone)]
@@ -75,7 +75,7 @@ LL |     Self::Assoc: IsU8<Self::Assoc>,
    |                  ^^^^^^^^^^^^^^^^^ required by this bound in `D::Assoc`
 ...
 LL |     type Assoc = NotClone;
-   |          ----- required by a bound in this
+   |          ----- required by a bound in this associated type
 
 error[E0277]: the trait bound `<Self as Foo2<T>>::Baz: Clone` is not satisfied
   --> $DIR/defaults-suitability.rs:65:23
@@ -124,7 +124,7 @@ LL |     Self::Baz: Clone,
    |                ^^^^^ required by this bound in `Foo3::Baz`
 ...
 LL |     type Baz = T;
-   |          --- required by a bound in this
+   |          --- required by a bound in this associated type
 help: consider further restricting type parameter `T`
    |
 LL |     Self::Baz: Clone, T: std::clone::Clone
diff --git a/tests/ui/associated-types/hr-associated-type-bound-1.stderr b/tests/ui/associated-types/hr-associated-type-bound-1.stderr
index 73b5e1053fb..b380a1b6f06 100644
--- a/tests/ui/associated-types/hr-associated-type-bound-1.stderr
+++ b/tests/ui/associated-types/hr-associated-type-bound-1.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `X`
   --> $DIR/hr-associated-type-bound-1.rs:3:33
    |
 LL | trait X<'a>
-   |       - required by a bound in this
+   |       - required by a bound in this trait
 LL | where
 LL |     for<'b> <Self as X<'b>>::U: Clone,
    |                                 ^^^^^ required by this bound in `X`
diff --git a/tests/ui/associated-types/hr-associated-type-bound-object.stderr b/tests/ui/associated-types/hr-associated-type-bound-object.stderr
index 6d19186bde4..a0a6f76a583 100644
--- a/tests/ui/associated-types/hr-associated-type-bound-object.stderr
+++ b/tests/ui/associated-types/hr-associated-type-bound-object.stderr
@@ -8,7 +8,7 @@ note: required by a bound in `X`
   --> $DIR/hr-associated-type-bound-object.rs:3:33
    |
 LL | trait X<'a>
-   |       - required by a bound in this
+   |       - required by a bound in this trait
 LL | where
 LL |     for<'b> <Self as X<'b>>::U: Clone,
    |                                 ^^^^^ required by this bound in `X`
diff --git a/tests/ui/associated-types/hr-associated-type-bound-param-1.stderr b/tests/ui/associated-types/hr-associated-type-bound-param-1.stderr
index af2e616896a..e249f2e0c27 100644
--- a/tests/ui/associated-types/hr-associated-type-bound-param-1.stderr
+++ b/tests/ui/associated-types/hr-associated-type-bound-param-1.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `Y`
   --> $DIR/hr-associated-type-bound-param-1.rs:4:36
    |
 LL | trait Y<'a, T: ?Sized>
-   |       - required by a bound in this
+   |       - required by a bound in this trait
 ...
 LL |     for<'b> <Self as Y<'b, T>>::V: Clone,
    |                                    ^^^^^ required by this bound in `Y`
diff --git a/tests/ui/associated-types/hr-associated-type-bound-param-2.stderr b/tests/ui/associated-types/hr-associated-type-bound-param-2.stderr
index 52294f8c94a..366670269d7 100644
--- a/tests/ui/associated-types/hr-associated-type-bound-param-2.stderr
+++ b/tests/ui/associated-types/hr-associated-type-bound-param-2.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `Z`
   --> $DIR/hr-associated-type-bound-param-2.rs:6:35
    |
 LL | trait Z<'a, T: ?Sized>
-   |       - required by a bound in this
+   |       - required by a bound in this trait
 ...
 LL |     for<'b> <T as Z<'b, u16>>::W: Clone,
    |                                   ^^^^^ required by this bound in `Z`
@@ -25,7 +25,7 @@ note: required by a bound in `Z`
   --> $DIR/hr-associated-type-bound-param-2.rs:6:35
    |
 LL | trait Z<'a, T: ?Sized>
-   |       - required by a bound in this
+   |       - required by a bound in this trait
 ...
 LL |     for<'b> <T as Z<'b, u16>>::W: Clone,
    |                                   ^^^^^ required by this bound in `Z`
@@ -41,7 +41,7 @@ note: required by a bound in `Z`
   --> $DIR/hr-associated-type-bound-param-2.rs:6:35
    |
 LL | trait Z<'a, T: ?Sized>
-   |       - required by a bound in this
+   |       - required by a bound in this trait
 ...
 LL |     for<'b> <T as Z<'b, u16>>::W: Clone,
    |                                   ^^^^^ required by this bound in `Z`
diff --git a/tests/ui/associated-types/hr-associated-type-bound-param-3.stderr b/tests/ui/associated-types/hr-associated-type-bound-param-3.stderr
index 84d5e0494cb..f49439d3573 100644
--- a/tests/ui/associated-types/hr-associated-type-bound-param-3.stderr
+++ b/tests/ui/associated-types/hr-associated-type-bound-param-3.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `X`
   --> $DIR/hr-associated-type-bound-param-3.rs:4:33
    |
 LL | trait X<'a, T>
-   |       - required by a bound in this
+   |       - required by a bound in this trait
 ...
 LL |     for<'b> <T as X<'b, T>>::U: Clone,
    |                                 ^^^^^ required by this bound in `X`
diff --git a/tests/ui/associated-types/hr-associated-type-bound-param-4.stderr b/tests/ui/associated-types/hr-associated-type-bound-param-4.stderr
index ee1d5d32495..f8733b423d7 100644
--- a/tests/ui/associated-types/hr-associated-type-bound-param-4.stderr
+++ b/tests/ui/associated-types/hr-associated-type-bound-param-4.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `X`
   --> $DIR/hr-associated-type-bound-param-4.rs:4:36
    |
 LL | trait X<'a, T>
-   |       - required by a bound in this
+   |       - required by a bound in this trait
 ...
 LL |     for<'b> <(T,) as X<'b, T>>::U: Clone,
    |                                    ^^^^^ required by this bound in `X`
diff --git a/tests/ui/associated-types/hr-associated-type-bound-param-5.stderr b/tests/ui/associated-types/hr-associated-type-bound-param-5.stderr
index ece3151ba97..aae80a9b2e1 100644
--- a/tests/ui/associated-types/hr-associated-type-bound-param-5.stderr
+++ b/tests/ui/associated-types/hr-associated-type-bound-param-5.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `X`
   --> $DIR/hr-associated-type-bound-param-5.rs:17:45
    |
 LL | trait X<'a, T: Cycle + for<'b> X<'b, T>>
-   |       - required by a bound in this
+   |       - required by a bound in this trait
 ...
 LL |     for<'b> <T::Next as X<'b, T::Next>>::U: Clone,
    |                                             ^^^^^ required by this bound in `X`
@@ -25,7 +25,7 @@ note: required by a bound in `X`
   --> $DIR/hr-associated-type-bound-param-5.rs:17:45
    |
 LL | trait X<'a, T: Cycle + for<'b> X<'b, T>>
-   |       - required by a bound in this
+   |       - required by a bound in this trait
 ...
 LL |     for<'b> <T::Next as X<'b, T::Next>>::U: Clone,
    |                                             ^^^^^ required by this bound in `X`
diff --git a/tests/ui/associated-types/hr-associated-type-projection-1.stderr b/tests/ui/associated-types/hr-associated-type-projection-1.stderr
index 2281d9419b4..dd0389c34e6 100644
--- a/tests/ui/associated-types/hr-associated-type-projection-1.stderr
+++ b/tests/ui/associated-types/hr-associated-type-projection-1.stderr
@@ -10,7 +10,7 @@ note: required by a bound in `UnsafeCopy`
   --> $DIR/hr-associated-type-projection-1.rs:3:64
    |
 LL | trait UnsafeCopy<'a, T: Copy>
-   |       ---------- required by a bound in this
+   |       ---------- required by a bound in this trait
 LL | where
 LL |     for<'b> <Self as UnsafeCopy<'b, T>>::Item: std::ops::Deref<Target = T>,
    |                                                                ^^^^^^^^^^ required by this bound in `UnsafeCopy`
diff --git a/tests/ui/associated-types/point-at-type-on-obligation-failure-2.stderr b/tests/ui/associated-types/point-at-type-on-obligation-failure-2.stderr
index 2e7a1dd2a31..3b4689e08cc 100644
--- a/tests/ui/associated-types/point-at-type-on-obligation-failure-2.stderr
+++ b/tests/ui/associated-types/point-at-type-on-obligation-failure-2.stderr
@@ -23,7 +23,7 @@ LL |     Self::Assoc: Bar,
    |                  ^^^ required by this bound in `Baz::Assoc`
 LL | {
 LL |     type Assoc;
-   |          ----- required by a bound in this
+   |          ----- required by a bound in this associated type
 
 error[E0277]: the trait bound `bool: Bar` is not satisfied
   --> $DIR/point-at-type-on-obligation-failure-2.rs:30:18
@@ -38,7 +38,7 @@ LL |     <Self as Bat>::Assoc: Bar,
    |                           ^^^ required by this bound in `Bat::Assoc`
 LL | {
 LL |     type Assoc;
-   |          ----- required by a bound in this
+   |          ----- required by a bound in this associated type
 
 error: aborting due to 3 previous errors
 
diff --git a/tests/ui/async-await/in-trait/fn-not-async-err2.rs b/tests/ui/async-await/in-trait/fn-not-async-err2.rs
index 2c4ed553580..78017429f73 100644
--- a/tests/ui/async-await/in-trait/fn-not-async-err2.rs
+++ b/tests/ui/async-await/in-trait/fn-not-async-err2.rs
@@ -11,7 +11,7 @@ trait MyTrait {
 
 impl MyTrait for i32 {
     fn foo(&self) -> impl Future<Output = i32> {
-        //~^ ERROR `impl Trait` only allowed in function and inherent method return types, not in `impl` method return [E0562]
+        //~^ ERROR `impl Trait` only allowed in function and inherent method return types, not in `impl` method return types
         async { *self }
     }
 }
diff --git a/tests/ui/async-await/in-trait/fn-not-async-err2.stderr b/tests/ui/async-await/in-trait/fn-not-async-err2.stderr
index f591f184772..37d9669c012 100644
--- a/tests/ui/async-await/in-trait/fn-not-async-err2.stderr
+++ b/tests/ui/async-await/in-trait/fn-not-async-err2.stderr
@@ -1,4 +1,4 @@
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `impl` method return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `impl` method return types
   --> $DIR/fn-not-async-err2.rs:13:22
    |
 LL |     fn foo(&self) -> impl Future<Output = i32> {
diff --git a/tests/ui/async-await/issues/issue-62097.rs b/tests/ui/async-await/issues/issue-62097.rs
index a24c84cffc7..13c72abb136 100644
--- a/tests/ui/async-await/issues/issue-62097.rs
+++ b/tests/ui/async-await/issues/issue-62097.rs
@@ -12,7 +12,7 @@ impl Struct {
     pub async fn run_dummy_fn(&self) {
         foo(|| self.bar()).await;
         //~^ ERROR closure may outlive the current function
-        //~| ERROR borrowed data escapes outside of associated function
+        //~| ERROR borrowed data escapes outside of method
     }
 
     pub fn bar(&self) {}
diff --git a/tests/ui/async-await/issues/issue-62097.stderr b/tests/ui/async-await/issues/issue-62097.stderr
index 786f6213260..21a61548d01 100644
--- a/tests/ui/async-await/issues/issue-62097.stderr
+++ b/tests/ui/async-await/issues/issue-62097.stderr
@@ -16,18 +16,18 @@ help: to force the closure to take ownership of `self` (and any other referenced
 LL |         foo(move || self.bar()).await;
    |             ++++
 
-error[E0521]: borrowed data escapes outside of associated function
+error[E0521]: borrowed data escapes outside of method
   --> $DIR/issue-62097.rs:13:9
    |
 LL |     pub async fn run_dummy_fn(&self) {
    |                               -----
    |                               |
-   |                               `self` is a reference that is only valid in the associated function body
+   |                               `self` is a reference that is only valid in the method body
    |                               let's call the lifetime of this reference `'1`
 LL |         foo(|| self.bar()).await;
    |         ^^^^^^^^^^^^^^^^^^
    |         |
-   |         `self` escapes the associated function body here
+   |         `self` escapes the method body here
    |         argument requires that `'1` must outlive `'static`
 
 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 df2ca025705..6e547508bd4 100644
--- a/tests/ui/async-await/issues/issue-65159.rs
+++ b/tests/ui/async-await/issues/issue-65159.rs
@@ -3,7 +3,7 @@
 // edition:2018
 
 async fn copy() -> Result<()>
-//~^ ERROR this enum takes 2 generic arguments
+//~^ ERROR enum takes 2 generic arguments
 {
     Ok(())
 }
diff --git a/tests/ui/async-await/issues/issue-65159.stderr b/tests/ui/async-await/issues/issue-65159.stderr
index 40c0e72b203..b8741333c32 100644
--- a/tests/ui/async-await/issues/issue-65159.stderr
+++ b/tests/ui/async-await/issues/issue-65159.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this enum takes 2 generic arguments but 1 generic argument was supplied
+error[E0107]: enum takes 2 generic arguments but 1 generic argument was supplied
   --> $DIR/issue-65159.rs:5:20
    |
 LL | async fn copy() -> Result<()>
diff --git a/tests/ui/async-await/issues/issue-72312.stderr b/tests/ui/async-await/issues/issue-72312.stderr
index aa947b69003..679272858bd 100644
--- a/tests/ui/async-await/issues/issue-72312.stderr
+++ b/tests/ui/async-await/issues/issue-72312.stderr
@@ -1,10 +1,10 @@
-error[E0521]: borrowed data escapes outside of associated function
+error[E0521]: borrowed data escapes outside of method
   --> $DIR/issue-72312.rs:12:9
    |
 LL |       pub async fn start(&self) {
    |                          -----
    |                          |
-   |                          `self` is a reference that is only valid in the associated function body
+   |                          `self` is a reference that is only valid in the method body
    |                          let's call the lifetime of this reference `'1`
 ...
 LL | /         require_static(async move {
@@ -15,7 +15,7 @@ LL | |             &self;
 LL | |         });
    | |          ^
    | |          |
-   | |__________`self` escapes the associated function body here
+   | |__________`self` escapes the method body here
    |            argument requires that `'1` must outlive `'static`
 
 error: aborting due to previous error
diff --git a/tests/ui/attributes/invalid_macro_export_argument.rs b/tests/ui/attributes/invalid_macro_export_argument.rs
new file mode 100644
index 00000000000..85d009f11a6
--- /dev/null
+++ b/tests/ui/attributes/invalid_macro_export_argument.rs
@@ -0,0 +1,26 @@
+// check-pass
+#[macro_export(hello, world)] //~ WARN `#[macro_export]` can only take 1 or 0 arguments
+macro_rules! a {
+    () => ()
+}
+
+#[macro_export(not_local_inner_macros)] //~ WARN `not_local_inner_macros` isn't a valid `#[macro_export]` argument
+macro_rules! b {
+    () => ()
+}
+
+#[macro_export]
+macro_rules! c {
+    () => ()
+}
+#[macro_export(local_inner_macros)]
+macro_rules! d {
+    () => ()
+}
+
+#[macro_export()]
+macro_rules! e {
+    () => ()
+}
+
+fn main() {}
diff --git a/tests/ui/attributes/invalid_macro_export_argument.stderr b/tests/ui/attributes/invalid_macro_export_argument.stderr
new file mode 100644
index 00000000000..a4e17642c2a
--- /dev/null
+++ b/tests/ui/attributes/invalid_macro_export_argument.stderr
@@ -0,0 +1,16 @@
+warning: `#[macro_export]` can only take 1 or 0 arguments
+  --> $DIR/invalid_macro_export_argument.rs:2:1
+   |
+LL | #[macro_export(hello, world)]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |
+   = note: `#[warn(invalid_macro_export_arguments)]` on by default
+
+warning: `not_local_inner_macros` isn't a valid `#[macro_export]` argument
+  --> $DIR/invalid_macro_export_argument.rs:7:16
+   |
+LL | #[macro_export(not_local_inner_macros)]
+   |                ^^^^^^^^^^^^^^^^^^^^^^
+
+warning: 2 warnings emitted
+
diff --git a/tests/ui/auto-traits/auto-trait-validation.stderr b/tests/ui/auto-traits/auto-trait-validation.stderr
index 2c380e5b09a..89b63d23d4c 100644
--- a/tests/ui/auto-traits/auto-trait-validation.stderr
+++ b/tests/ui/auto-traits/auto-trait-validation.stderr
@@ -12,7 +12,7 @@ error[E0568]: auto traits cannot have super traits or lifetime bounds
 LL | auto trait Bound : Copy {}
    |            -----^^^^^^^ help: remove the super traits or lifetime bounds
    |            |
-   |            auto trait cannot have super traits or lifetime bounds
+   |            auto traits cannot have super traits or lifetime bounds
 
 error[E0568]: auto traits cannot have super traits or lifetime bounds
   --> $DIR/auto-trait-validation.rs:9:25
@@ -20,7 +20,7 @@ error[E0568]: auto traits cannot have super traits or lifetime bounds
 LL | auto trait LifetimeBound : 'static {}
    |            -------------^^^^^^^^^^ help: remove the super traits or lifetime bounds
    |            |
-   |            auto trait cannot have super traits or lifetime bounds
+   |            auto traits cannot have super traits or lifetime bounds
 
 error[E0380]: auto traits cannot have associated items
   --> $DIR/auto-trait-validation.rs:11:25
@@ -29,7 +29,7 @@ LL | auto trait MyTrait { fn foo() {} }
    |            -------   ---^^^-----
    |            |         |
    |            |         help: remove these associated items
-   |            auto trait cannot have associated items
+   |            auto traits cannot have associated items
 
 error: aborting due to 4 previous errors
 
diff --git a/tests/ui/auto-traits/issue-23080-2.stderr b/tests/ui/auto-traits/issue-23080-2.stderr
index 267a712f62f..fed485612da 100644
--- a/tests/ui/auto-traits/issue-23080-2.stderr
+++ b/tests/ui/auto-traits/issue-23080-2.stderr
@@ -2,7 +2,7 @@ error[E0380]: auto traits cannot have associated items
   --> $DIR/issue-23080-2.rs:5:10
    |
 LL | unsafe auto trait Trait {
-   |                   ----- auto trait cannot have associated items
+   |                   ----- auto traits cannot have associated items
 LL |     type Output;
    |     -----^^^^^^- help: remove these associated items
 
diff --git a/tests/ui/auto-traits/issue-23080.stderr b/tests/ui/auto-traits/issue-23080.stderr
index c1b16b2f403..f5d607298b7 100644
--- a/tests/ui/auto-traits/issue-23080.stderr
+++ b/tests/ui/auto-traits/issue-23080.stderr
@@ -2,7 +2,7 @@ error[E0380]: auto traits cannot have associated items
   --> $DIR/issue-23080.rs:5:8
    |
 LL |   unsafe auto trait Trait {
-   |                     ----- auto trait cannot have associated items
+   |                     ----- auto traits cannot have associated items
 LL |       fn method(&self) {
    |  _____-  ^^^^^^
 LL | |         println!("Hello");
diff --git a/tests/ui/auto-traits/issue-84075.stderr b/tests/ui/auto-traits/issue-84075.stderr
index 02dca598ec2..6fbdc669b6f 100644
--- a/tests/ui/auto-traits/issue-84075.stderr
+++ b/tests/ui/auto-traits/issue-84075.stderr
@@ -4,7 +4,7 @@ error[E0568]: auto traits cannot have super traits or lifetime bounds
 LL | auto trait Magic where Self: Copy {}
    |            ----- ^^^^^^^^^^^^^^^^ help: remove the super traits or lifetime bounds
    |            |
-   |            auto trait cannot have super traits or lifetime bounds
+   |            auto traits cannot have super traits or lifetime bounds
 
 error: aborting due to previous error
 
diff --git a/tests/ui/auto-traits/str-contains-slice-conceptually.rs b/tests/ui/auto-traits/str-contains-slice-conceptually.rs
new file mode 100644
index 00000000000..6a16fdcf284
--- /dev/null
+++ b/tests/ui/auto-traits/str-contains-slice-conceptually.rs
@@ -0,0 +1,13 @@
+#![feature(negative_impls)]
+#![feature(auto_traits)]
+
+auto trait AutoTrait {}
+
+impl<T> !AutoTrait for [T] {}
+
+fn needs_auto_trait<T: AutoTrait + ?Sized>() {}
+
+fn main() {
+  needs_auto_trait::<str>();
+  //~^ ERROR the trait bound `[u8]: AutoTrait` is not satisfied in `str`
+}
diff --git a/tests/ui/auto-traits/str-contains-slice-conceptually.stderr b/tests/ui/auto-traits/str-contains-slice-conceptually.stderr
new file mode 100644
index 00000000000..1cf16cebddd
--- /dev/null
+++ b/tests/ui/auto-traits/str-contains-slice-conceptually.stderr
@@ -0,0 +1,16 @@
+error[E0277]: the trait bound `[u8]: AutoTrait` is not satisfied in `str`
+  --> $DIR/str-contains-slice-conceptually.rs:11:22
+   |
+LL |   needs_auto_trait::<str>();
+   |                      ^^^ within `str`, the trait `AutoTrait` is not implemented for `[u8]`
+   |
+   = note: `str` is considered to contain a `[u8]` slice for auto trait purposes
+note: required by a bound in `needs_auto_trait`
+  --> $DIR/str-contains-slice-conceptually.rs:8:24
+   |
+LL | fn needs_auto_trait<T: AutoTrait + ?Sized>() {}
+   |                        ^^^^^^^^^ required by this bound in `needs_auto_trait`
+
+error: aborting due to previous error
+
+For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/auto-traits/typeck-auto-trait-no-supertraits-2.stderr b/tests/ui/auto-traits/typeck-auto-trait-no-supertraits-2.stderr
index 4827916fa5c..547b4bb5448 100644
--- a/tests/ui/auto-traits/typeck-auto-trait-no-supertraits-2.stderr
+++ b/tests/ui/auto-traits/typeck-auto-trait-no-supertraits-2.stderr
@@ -4,7 +4,7 @@ error[E0568]: auto traits cannot have super traits or lifetime bounds
 LL | auto trait Magic : Sized where Option<Self> : Magic {}
    |            -----^^^^^^^^ help: remove the super traits or lifetime bounds
    |            |
-   |            auto trait cannot have super traits or lifetime bounds
+   |            auto traits cannot have super traits or lifetime bounds
 
 error[E0568]: auto traits cannot have super traits or lifetime bounds
   --> $DIR/typeck-auto-trait-no-supertraits-2.rs:4:26
@@ -12,7 +12,7 @@ error[E0568]: auto traits cannot have super traits or lifetime bounds
 LL | auto trait Magic : Sized where Option<Self> : Magic {}
    |            -----         ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove the super traits or lifetime bounds
    |            |
-   |            auto trait cannot have super traits or lifetime bounds
+   |            auto traits cannot have super traits or lifetime bounds
 
 error: aborting due to 2 previous errors
 
diff --git a/tests/ui/auto-traits/typeck-auto-trait-no-supertraits.stderr b/tests/ui/auto-traits/typeck-auto-trait-no-supertraits.stderr
index d7716f4b61f..80f07410381 100644
--- a/tests/ui/auto-traits/typeck-auto-trait-no-supertraits.stderr
+++ b/tests/ui/auto-traits/typeck-auto-trait-no-supertraits.stderr
@@ -4,7 +4,7 @@ error[E0568]: auto traits cannot have super traits or lifetime bounds
 LL | auto trait Magic: Copy {}
    |            -----^^^^^^ help: remove the super traits or lifetime bounds
    |            |
-   |            auto trait cannot have super traits or lifetime bounds
+   |            auto traits cannot have super traits or lifetime bounds
 
 error: aborting due to previous error
 
diff --git a/tests/ui/borrowck/issue-103624.rs b/tests/ui/borrowck/issue-103624.rs
index f1fa95f9246..d95a40bd4a0 100644
--- a/tests/ui/borrowck/issue-103624.rs
+++ b/tests/ui/borrowck/issue-103624.rs
@@ -12,7 +12,7 @@ impl StructA {
     async fn foo(&self) {
         let bar = self.b.bar().await;
         spawn_blocking(move || {
-            //~^ ERROR borrowed data escapes outside of associated function
+            //~^ ERROR borrowed data escapes outside of method
             self.b;
             //~^ ERROR cannot move out of `self.b`, as `self` is a captured variable in an `Fn` closure
         })
diff --git a/tests/ui/borrowck/issue-103624.stderr b/tests/ui/borrowck/issue-103624.stderr
index e6a35dd8801..7a281e8aa30 100644
--- a/tests/ui/borrowck/issue-103624.stderr
+++ b/tests/ui/borrowck/issue-103624.stderr
@@ -10,13 +10,13 @@ LL |
 LL |             self.b;
    |             ^^^^^^ move occurs because `self.b` has type `StructB`, which does not implement the `Copy` trait
 
-error[E0521]: borrowed data escapes outside of associated function
+error[E0521]: borrowed data escapes outside of method
   --> $DIR/issue-103624.rs:14:9
    |
 LL |       async fn foo(&self) {
    |                    -----
    |                    |
-   |                    `self` is a reference that is only valid in the associated function body
+   |                    `self` is a reference that is only valid in the method body
    |                    let's call the lifetime of this reference `'1`
 LL |           let bar = self.b.bar().await;
 LL | /         spawn_blocking(move || {
@@ -26,7 +26,7 @@ LL | |
 LL | |         })
    | |          ^
    | |          |
-   | |__________`self` escapes the associated function body here
+   | |__________`self` escapes the method body here
    |            argument requires that `'1` must outlive `'static`
 
 error: aborting due to 2 previous errors
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 dd0320bc53b..d067ff44704 100644
--- a/tests/ui/borrowck/issue-82126-mismatched-subst-and-hir.rs
+++ b/tests/ui/borrowck/issue-82126-mismatched-subst-and-hir.rs
@@ -14,8 +14,8 @@ impl MarketMultiplier {
 }
 
 async fn buy_lock(generator: &Mutex<MarketMultiplier>) -> LockedMarket<'_> {
-    //~^ ERROR this struct takes 0 lifetime arguments but 1 lifetime argument was supplied
-    //~^^ ERROR this struct takes 1 generic argument but 0 generic arguments were supplied
+    //~^ 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(generator.lock().unwrap().buy())
 }
 
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 d2b927fb664..73e0aaf1e45 100644
--- a/tests/ui/borrowck/issue-82126-mismatched-subst-and-hir.stderr
+++ b/tests/ui/borrowck/issue-82126-mismatched-subst-and-hir.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this struct takes 0 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: struct takes 0 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/issue-82126-mismatched-subst-and-hir.rs:16:59
    |
 LL | async fn buy_lock(generator: &Mutex<MarketMultiplier>) -> LockedMarket<'_> {
@@ -12,7 +12,7 @@ note: struct defined here, with 0 lifetime parameters
 LL | struct LockedMarket<T>(T);
    |        ^^^^^^^^^^^^
 
-error[E0107]: this struct takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: struct takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/issue-82126-mismatched-subst-and-hir.rs:16:59
    |
 LL | async fn buy_lock(generator: &Mutex<MarketMultiplier>) -> LockedMarket<'_> {
diff --git a/tests/ui/closure-expected-type/expect-infer-var-appearing-twice.stderr b/tests/ui/closure-expected-type/expect-infer-var-appearing-twice.stderr
index 8dccf929b2b..c5089295063 100644
--- a/tests/ui/closure-expected-type/expect-infer-var-appearing-twice.stderr
+++ b/tests/ui/closure-expected-type/expect-infer-var-appearing-twice.stderr
@@ -12,7 +12,7 @@ note: required by a bound in `with_closure`
   --> $DIR/expect-infer-var-appearing-twice.rs:2:14
    |
 LL | fn with_closure<F, A>(_: F)
-   |    ------------ required by a bound in this
+   |    ------------ required by a bound in this function
 LL |     where F: FnOnce(A, A)
    |              ^^^^^^^^^^^^ required by this bound in `with_closure`
 
diff --git a/tests/ui/const-generics/defaults/wfness.stderr b/tests/ui/const-generics/defaults/wfness.stderr
index 25038f830be..bd9bfcd7dad 100644
--- a/tests/ui/const-generics/defaults/wfness.stderr
+++ b/tests/ui/const-generics/defaults/wfness.stderr
@@ -23,7 +23,7 @@ note: required by a bound in `WhereClause`
   --> $DIR/wfness.rs:8:9
    |
 LL | struct WhereClause<const N: u8 = 2>
-   |        ----------- required by a bound in this
+   |        ----------- required by a bound in this struct
 LL | where
 LL |     (): Trait<N>;
    |         ^^^^^^^^ required by this bound in `WhereClause`
diff --git a/tests/ui/const-generics/ensure_is_evaluatable.stderr b/tests/ui/const-generics/ensure_is_evaluatable.stderr
index bf6c35ad8fd..ab2871ff281 100644
--- a/tests/ui/const-generics/ensure_is_evaluatable.stderr
+++ b/tests/ui/const-generics/ensure_is_evaluatable.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `bar`
   --> $DIR/ensure_is_evaluatable.rs:15:10
    |
 LL | fn bar<const N: usize>() -> [(); N]
-   |    --- required by a bound in this
+   |    --- required by a bound in this function
 LL | where
 LL |     [(); N + 1]:,
    |          ^^^^^ required by this bound in `bar`
diff --git a/tests/ui/const-generics/fn_with_two_const_inputs.stderr b/tests/ui/const-generics/fn_with_two_const_inputs.stderr
index 614e7e0d2fc..c124010aab0 100644
--- a/tests/ui/const-generics/fn_with_two_const_inputs.stderr
+++ b/tests/ui/const-generics/fn_with_two_const_inputs.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `bar`
   --> $DIR/fn_with_two_const_inputs.rs:18:10
    |
 LL | fn bar<const N: usize>() -> [(); N]
-   |    --- required by a bound in this
+   |    --- required by a bound in this function
 LL | where
 LL |     [(); N + 1]:,
    |          ^^^^^ required by this bound in `bar`
diff --git a/tests/ui/const-generics/generic_const_exprs/issue-102768.rs b/tests/ui/const-generics/generic_const_exprs/issue-102768.rs
index 7aea0d30d1a..18a9b53cf76 100644
--- a/tests/ui/const-generics/generic_const_exprs/issue-102768.rs
+++ b/tests/ui/const-generics/generic_const_exprs/issue-102768.rs
@@ -7,8 +7,8 @@ trait X {
 
 const _: () = {
     fn f2<'a>(arg: Box<dyn X<Y<1> = &'a ()>>) {}
-    //~^ ERROR this associated type takes 1 lifetime argument but 0 lifetime arguments
-    //~| ERROR this associated type takes 0 generic arguments but 1 generic argument
+    //~^ ERROR associated type takes 1 lifetime argument but 0 lifetime arguments
+    //~| ERROR associated type takes 0 generic arguments but 1 generic argument
 };
 
 fn main() {}
diff --git a/tests/ui/const-generics/generic_const_exprs/issue-102768.stderr b/tests/ui/const-generics/generic_const_exprs/issue-102768.stderr
index 8278edabe3a..175d54e4184 100644
--- a/tests/ui/const-generics/generic_const_exprs/issue-102768.stderr
+++ b/tests/ui/const-generics/generic_const_exprs/issue-102768.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this associated type takes 1 lifetime argument but 0 lifetime arguments were supplied
+error[E0107]: associated type takes 1 lifetime argument but 0 lifetime arguments were supplied
   --> $DIR/issue-102768.rs:9:30
    |
 LL |     fn f2<'a>(arg: Box<dyn X<Y<1> = &'a ()>>) {}
@@ -14,7 +14,7 @@ help: add missing lifetime argument
 LL |     fn f2<'a>(arg: Box<dyn X<Y<'_, 1> = &'a ()>>) {}
    |                                +++
 
-error[E0107]: this associated type takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: associated type takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/issue-102768.rs:9:30
    |
 LL |     fn f2<'a>(arg: Box<dyn X<Y<1> = &'a ()>>) {}
diff --git a/tests/ui/const-generics/generic_const_exprs/issue-105608.stderr b/tests/ui/const-generics/generic_const_exprs/issue-105608.stderr
index 0be4c43daac..827dd59d9ad 100644
--- a/tests/ui/const-generics/generic_const_exprs/issue-105608.stderr
+++ b/tests/ui/const-generics/generic_const_exprs/issue-105608.stderr
@@ -2,7 +2,7 @@ error[E0282]: type annotations needed
   --> $DIR/issue-105608.rs:13:22
    |
 LL |     Combination::<0>.and::<_>().and::<_>();
-   |                      ^^^ cannot infer type of the type parameter `M` declared on the associated function `and`
+   |                      ^^^ cannot infer type of the type parameter `M` declared on the method `and`
    |
 help: consider specifying the generic argument
    |
diff --git a/tests/ui/const-generics/generic_const_exprs/issue-72819-generic-in-const-eval.full.stderr b/tests/ui/const-generics/generic_const_exprs/issue-72819-generic-in-const-eval.full.stderr
index f2fddfbfbb5..996b75493e6 100644
--- a/tests/ui/const-generics/generic_const_exprs/issue-72819-generic-in-const-eval.full.stderr
+++ b/tests/ui/const-generics/generic_const_exprs/issue-72819-generic-in-const-eval.full.stderr
@@ -10,7 +10,7 @@ note: required by a bound in `Arr`
   --> $DIR/issue-72819-generic-in-const-eval.rs:8:39
    |
 LL | struct Arr<const N: usize>
-   |        --- required by a bound in this
+   |        --- required by a bound in this struct
 LL | where Assert::<{N < usize::MAX / 2}>: IsTrue,
    |                                       ^^^^^^ required by this bound in `Arr`
 
@@ -26,7 +26,7 @@ note: required by a bound in `Arr`
   --> $DIR/issue-72819-generic-in-const-eval.rs:8:39
    |
 LL | struct Arr<const N: usize>
-   |        --- required by a bound in this
+   |        --- required by a bound in this struct
 LL | where Assert::<{N < usize::MAX / 2}>: IsTrue,
    |                                       ^^^^^^ required by this bound in `Arr`
 
diff --git a/tests/ui/const-generics/generic_const_exprs/issue-76595.stderr b/tests/ui/const-generics/generic_const_exprs/issue-76595.stderr
index c587a7e153f..302da59651c 100644
--- a/tests/ui/const-generics/generic_const_exprs/issue-76595.stderr
+++ b/tests/ui/const-generics/generic_const_exprs/issue-76595.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this function takes 2 generic arguments but 1 generic argument was supplied
+error[E0107]: function takes 2 generic arguments but 1 generic argument was supplied
   --> $DIR/issue-76595.rs:15:5
    |
 LL |     test::<2>();
diff --git a/tests/ui/const-generics/generic_const_exprs/obligation-cause.stderr b/tests/ui/const-generics/generic_const_exprs/obligation-cause.stderr
index a253ec676f7..63e6fcc8e11 100644
--- a/tests/ui/const-generics/generic_const_exprs/obligation-cause.stderr
+++ b/tests/ui/const-generics/generic_const_exprs/obligation-cause.stderr
@@ -10,7 +10,7 @@ note: required by a bound in `g`
   --> $DIR/obligation-cause.rs:13:44
    |
 LL | fn g<T>()
-   |    - required by a bound in this
+   |    - required by a bound in this function
 ...
 LL |     Is<{ std::mem::size_of::<T>() == 0 }>: True,
    |                                            ^^^^ required by this bound in `g`
diff --git a/tests/ui/const-generics/incorrect-number-of-const-args.stderr b/tests/ui/const-generics/incorrect-number-of-const-args.stderr
index a845454f762..01ac4e69a05 100644
--- a/tests/ui/const-generics/incorrect-number-of-const-args.stderr
+++ b/tests/ui/const-generics/incorrect-number-of-const-args.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this function takes 2 generic arguments but 1 generic argument was supplied
+error[E0107]: function takes 2 generic arguments but 1 generic argument was supplied
   --> $DIR/incorrect-number-of-const-args.rs:6:5
    |
 LL |     foo::<0>();
@@ -16,7 +16,7 @@ help: add missing generic argument
 LL |     foo::<0, Y>();
    |            +++
 
-error[E0107]: this function takes 2 generic arguments but 3 generic arguments were supplied
+error[E0107]: function takes 2 generic arguments but 3 generic arguments were supplied
   --> $DIR/incorrect-number-of-const-args.rs:9:5
    |
 LL |     foo::<0, 0, 0>();
diff --git a/tests/ui/const-generics/infer/method-chain.stderr b/tests/ui/const-generics/infer/method-chain.stderr
index ff6da535bd2..f527ee6e4f5 100644
--- a/tests/ui/const-generics/infer/method-chain.stderr
+++ b/tests/ui/const-generics/infer/method-chain.stderr
@@ -2,7 +2,7 @@ error[E0282]: type annotations needed
   --> $DIR/method-chain.rs:15:33
    |
 LL |     Foo.bar().bar().bar().bar().baz();
-   |                                 ^^^ cannot infer the value of the const parameter `N` declared on the associated function `baz`
+   |                                 ^^^ cannot infer the value of the const parameter `N` declared on the method `baz`
    |
 help: consider specifying the generic argument
    |
diff --git a/tests/ui/const-generics/infer/uninferred-consts.stderr b/tests/ui/const-generics/infer/uninferred-consts.stderr
index 3980ecea863..20daf45706b 100644
--- a/tests/ui/const-generics/infer/uninferred-consts.stderr
+++ b/tests/ui/const-generics/infer/uninferred-consts.stderr
@@ -2,7 +2,7 @@ error[E0282]: type annotations needed
   --> $DIR/uninferred-consts.rs:9:9
    |
 LL |     Foo.foo();
-   |         ^^^ cannot infer the value of the const parameter `A` declared on the associated function `foo`
+   |         ^^^ cannot infer the value of the const parameter `A` declared on the method `foo`
    |
 help: consider specifying the generic arguments
    |
diff --git a/tests/ui/const-generics/invalid-const-arg-for-type-param.rs b/tests/ui/const-generics/invalid-const-arg-for-type-param.rs
index 7d4dc98f396..bf10f471dc5 100644
--- a/tests/ui/const-generics/invalid-const-arg-for-type-param.rs
+++ b/tests/ui/const-generics/invalid-const-arg-for-type-param.rs
@@ -4,11 +4,11 @@ struct S;
 
 fn main() {
     let _: u32 = 5i32.try_into::<32>().unwrap();
-    //~^ ERROR this associated function takes
+    //~^ ERROR method takes
 
     S.f::<0>();
     //~^ ERROR no method named `f`
 
     S::<0>;
-    //~^ ERROR this struct takes 0
+    //~^ ERROR struct takes 0
 }
diff --git a/tests/ui/const-generics/invalid-const-arg-for-type-param.stderr b/tests/ui/const-generics/invalid-const-arg-for-type-param.stderr
index 8c76ca69029..4a649d8a7e8 100644
--- a/tests/ui/const-generics/invalid-const-arg-for-type-param.stderr
+++ b/tests/ui/const-generics/invalid-const-arg-for-type-param.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this associated function takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: method takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/invalid-const-arg-for-type-param.rs:6:23
    |
 LL |     let _: u32 = 5i32.try_into::<32>().unwrap();
@@ -23,7 +23,7 @@ LL | struct S;
 LL |     S.f::<0>();
    |       ^ method not found in `S`
 
-error[E0107]: this struct takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: struct takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/invalid-const-arg-for-type-param.rs:12:5
    |
 LL |     S::<0>;
diff --git a/tests/ui/const-generics/invalid-constant-in-args.rs b/tests/ui/const-generics/invalid-constant-in-args.rs
index 7419d4a25ce..fd259197d29 100644
--- a/tests/ui/const-generics/invalid-constant-in-args.rs
+++ b/tests/ui/const-generics/invalid-constant-in-args.rs
@@ -2,5 +2,5 @@ use std::cell::Cell;
 
 fn main() {
     let _: Cell<&str, "a"> = Cell::new("");
-    //~^ ERROR this struct takes 1 generic argument but 2 generic arguments were supplied
+    //~^ ERROR struct takes 1 generic argument but 2 generic arguments were supplied
 }
diff --git a/tests/ui/const-generics/invalid-constant-in-args.stderr b/tests/ui/const-generics/invalid-constant-in-args.stderr
index 993b63518e4..2545cc6f396 100644
--- a/tests/ui/const-generics/invalid-constant-in-args.stderr
+++ b/tests/ui/const-generics/invalid-constant-in-args.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this struct takes 1 generic argument but 2 generic arguments were supplied
+error[E0107]: struct takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/invalid-constant-in-args.rs:4:12
    |
 LL |     let _: Cell<&str, "a"> = Cell::new("");
diff --git a/tests/ui/const-generics/issues/issue-67185-2.stderr b/tests/ui/const-generics/issues/issue-67185-2.stderr
index c7be8e14a10..032b0c41047 100644
--- a/tests/ui/const-generics/issues/issue-67185-2.stderr
+++ b/tests/ui/const-generics/issues/issue-67185-2.stderr
@@ -35,7 +35,7 @@ note: required by a bound in `Foo`
   --> $DIR/issue-67185-2.rs:15:25
    |
 LL | trait Foo
-   |       --- required by a bound in this
+   |       --- required by a bound in this trait
 ...
 LL |     <u8 as Baz>::Quaks: Bar,
    |                         ^^^ required by this bound in `Foo`
@@ -53,7 +53,7 @@ note: required by a bound in `Foo`
   --> $DIR/issue-67185-2.rs:14:30
    |
 LL | trait Foo
-   |       --- required by a bound in this
+   |       --- required by a bound in this trait
 LL | where
 LL |     [<u8 as Baz>::Quaks; 2]: Bar,
    |                              ^^^ required by this bound in `Foo`
@@ -71,7 +71,7 @@ note: required by a bound in `Foo`
   --> $DIR/issue-67185-2.rs:14:30
    |
 LL | trait Foo
-   |       --- required by a bound in this
+   |       --- required by a bound in this trait
 LL | where
 LL |     [<u8 as Baz>::Quaks; 2]: Bar,
    |                              ^^^ required by this bound in `Foo`
@@ -89,7 +89,7 @@ note: required by a bound in `Foo`
   --> $DIR/issue-67185-2.rs:15:25
    |
 LL | trait Foo
-   |       --- required by a bound in this
+   |       --- required by a bound in this trait
 ...
 LL |     <u8 as Baz>::Quaks: Bar,
    |                         ^^^ required by this bound in `Foo`
diff --git a/tests/ui/const-generics/issues/issue-73260.stderr b/tests/ui/const-generics/issues/issue-73260.stderr
index f9ff0f28d51..c56b45cc8fa 100644
--- a/tests/ui/const-generics/issues/issue-73260.stderr
+++ b/tests/ui/const-generics/issues/issue-73260.stderr
@@ -10,7 +10,7 @@ note: required by a bound in `Arr`
   --> $DIR/issue-73260.rs:5:37
    |
 LL | struct Arr<const N: usize>
-   |        --- required by a bound in this
+   |        --- required by a bound in this struct
 LL | where
 LL |     Assert::<{N < usize::MAX / 2}>: IsTrue,
    |                                     ^^^^^^ required by this bound in `Arr`
@@ -27,7 +27,7 @@ note: required by a bound in `Arr`
   --> $DIR/issue-73260.rs:5:37
    |
 LL | struct Arr<const N: usize>
-   |        --- required by a bound in this
+   |        --- required by a bound in this struct
 LL | where
 LL |     Assert::<{N < usize::MAX / 2}>: IsTrue,
    |                                     ^^^^^^ required by this bound in `Arr`
diff --git a/tests/ui/const-generics/issues/issue-79674.stderr b/tests/ui/const-generics/issues/issue-79674.stderr
index 02b48b55f8b..ba7fd2ca3cc 100644
--- a/tests/ui/const-generics/issues/issue-79674.stderr
+++ b/tests/ui/const-generics/issues/issue-79674.stderr
@@ -10,7 +10,7 @@ note: required by a bound in `requires_distinct`
   --> $DIR/issue-79674.rs:23:37
    |
 LL | fn requires_distinct<A, B>(_a: A, _b: B) where
-   |    ----------------- required by a bound in this
+   |    ----------------- required by a bound in this function
 LL |     A: MiniTypeId, B: MiniTypeId,
 LL |     Lift<{is_same_type::<A, B>()}>: IsFalse {}
    |                                     ^^^^^^^ required by this bound in `requires_distinct`
diff --git a/tests/ui/const-generics/issues/issue-86530.stderr b/tests/ui/const-generics/issues/issue-86530.stderr
index c63857b2314..620ed4f0fb2 100644
--- a/tests/ui/const-generics/issues/issue-86530.stderr
+++ b/tests/ui/const-generics/issues/issue-86530.stderr
@@ -10,7 +10,7 @@ note: required by a bound in `z`
   --> $DIR/issue-86530.rs:10:8
    |
 LL | fn z<T>(t: T)
-   |    - required by a bound in this
+   |    - required by a bound in this function
 LL | where
 LL |     T: X,
    |        ^ required by this bound in `z`
diff --git a/tests/ui/const-generics/issues/issue-87493.rs b/tests/ui/const-generics/issues/issue-87493.rs
index d8599ab22a3..80472e6bd9c 100644
--- a/tests/ui/const-generics/issues/issue-87493.rs
+++ b/tests/ui/const-generics/issues/issue-87493.rs
@@ -7,7 +7,7 @@ where
     S: MyTrait,
     T: MyTrait<Assoc == S::Assoc>,
     //~^ ERROR: expected one of `,` or `>`, found `==`
-    //~| ERROR: this trait takes 0 generic arguments but 1 generic argument was supplied
+    //~| ERROR: trait takes 0 generic arguments but 1 generic argument was supplied
 {
 }
 
diff --git a/tests/ui/const-generics/issues/issue-87493.stderr b/tests/ui/const-generics/issues/issue-87493.stderr
index 653afae2191..73bd6ed73e6 100644
--- a/tests/ui/const-generics/issues/issue-87493.stderr
+++ b/tests/ui/const-generics/issues/issue-87493.stderr
@@ -9,7 +9,7 @@ help: if you meant to use an associated type binding, replace `==` with `=`
 LL |     T: MyTrait<Assoc = S::Assoc>,
    |                      ~
 
-error[E0107]: this trait takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/issue-87493.rs:8:8
    |
 LL |     T: MyTrait<Assoc == S::Assoc>,
diff --git a/tests/ui/const-generics/occurs-check/unused-substs-1.stderr b/tests/ui/const-generics/occurs-check/unused-substs-1.stderr
index a3c011d927b..51ef354e3ed 100644
--- a/tests/ui/const-generics/occurs-check/unused-substs-1.stderr
+++ b/tests/ui/const-generics/occurs-check/unused-substs-1.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `A`
   --> $DIR/unused-substs-1.rs:9:11
    |
 LL | struct A<const N: usize>
-   |        - required by a bound in this
+   |        - required by a bound in this unit struct
 LL | where
 LL |     A<N>: Bar<N>;
    |           ^^^^^^ required by this bound in `A`
diff --git a/tests/ui/const-generics/parser-error-recovery/issue-89013-no-kw.rs b/tests/ui/const-generics/parser-error-recovery/issue-89013-no-kw.rs
index b126b24853f..79743abe409 100644
--- a/tests/ui/const-generics/parser-error-recovery/issue-89013-no-kw.rs
+++ b/tests/ui/const-generics/parser-error-recovery/issue-89013-no-kw.rs
@@ -7,7 +7,7 @@ struct Bar;
 const T: usize = 42;
 
 impl Foo<N = 3> for Bar {
-//~^ ERROR this trait takes 1 generic argument but 0 generic arguments were supplied
+//~^ ERROR trait takes 1 generic argument but 0 generic arguments were supplied
 //~| ERROR associated type bindings are not allowed here
 //~| ERROR associated const equality is incomplete
     fn do_x(&self) -> [u8; 3] {
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 acfdde8e1a0..4f4e1aa3a04 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
@@ -7,7 +7,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
 
-error[E0107]: this trait takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: trait takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/issue-89013-no-kw.rs:9:6
    |
 LL | impl Foo<N = 3> for Bar {
diff --git a/tests/ui/const-generics/parser-error-recovery/issue-89013.rs b/tests/ui/const-generics/parser-error-recovery/issue-89013.rs
index 9431779faf8..335d0d94e83 100644
--- a/tests/ui/const-generics/parser-error-recovery/issue-89013.rs
+++ b/tests/ui/const-generics/parser-error-recovery/issue-89013.rs
@@ -8,7 +8,7 @@ const T: usize = 42;
 
 impl Foo<N = const 3> for Bar {
 //~^ ERROR expected lifetime, type, or constant, found keyword `const`
-//~| ERROR this trait takes 1 generic
+//~| ERROR trait takes 1 generic
 //~| ERROR associated type bindings are not allowed here
 //~| ERROR associated const equality is incomplete
     fn do_x(&self) -> [u8; 3] {
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 583749a8573..3d2b98feb39 100644
--- a/tests/ui/const-generics/parser-error-recovery/issue-89013.stderr
+++ b/tests/ui/const-generics/parser-error-recovery/issue-89013.stderr
@@ -19,7 +19,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
 
-error[E0107]: this trait takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: trait takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/issue-89013.rs:9:6
    |
 LL | impl Foo<N = const 3> for Bar {
diff --git a/tests/ui/const-generics/unify_with_nested_expr.stderr b/tests/ui/const-generics/unify_with_nested_expr.stderr
index 8bab0dff7f2..d4d78b59627 100644
--- a/tests/ui/const-generics/unify_with_nested_expr.stderr
+++ b/tests/ui/const-generics/unify_with_nested_expr.stderr
@@ -8,7 +8,7 @@ note: required by a bound in `bar`
   --> $DIR/unify_with_nested_expr.rs:14:10
    |
 LL | fn bar<const N: usize>()
-   |    --- required by a bound in this
+   |    --- required by a bound in this function
 LL | where
 LL |     [(); N + 1]:,
    |          ^^^^^ required by this bound in `bar`
diff --git a/tests/ui/constructor-lifetime-args.rs b/tests/ui/constructor-lifetime-args.rs
index a824a44c9c2..f5802e7d8b1 100644
--- a/tests/ui/constructor-lifetime-args.rs
+++ b/tests/ui/constructor-lifetime-args.rs
@@ -15,12 +15,12 @@ enum E<'a, 'b> {
 fn main() {
     S(&0, &0); // OK
     S::<'static>(&0, &0);
-    //~^ ERROR this struct takes 2 lifetime arguments
+    //~^ ERROR struct takes 2 lifetime arguments
     S::<'static, 'static, 'static>(&0, &0);
-    //~^ ERROR this struct takes 2 lifetime arguments
+    //~^ ERROR struct takes 2 lifetime arguments
     E::V(&0); // OK
     E::V::<'static>(&0);
-    //~^ ERROR this enum takes 2 lifetime arguments
+    //~^ ERROR enum takes 2 lifetime arguments
     E::V::<'static, 'static, 'static>(&0);
-    //~^ ERROR this enum takes 2 lifetime arguments
+    //~^ ERROR enum takes 2 lifetime arguments
 }
diff --git a/tests/ui/constructor-lifetime-args.stderr b/tests/ui/constructor-lifetime-args.stderr
index bc1141b16c5..a18123fe19c 100644
--- a/tests/ui/constructor-lifetime-args.stderr
+++ b/tests/ui/constructor-lifetime-args.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this struct takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: struct takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/constructor-lifetime-args.rs:17:5
    |
 LL |     S::<'static>(&0, &0);
@@ -16,7 +16,7 @@ help: add missing lifetime argument
 LL |     S::<'static, 'static>(&0, &0);
    |                +++++++++
 
-error[E0107]: this struct takes 2 lifetime arguments but 3 lifetime arguments were supplied
+error[E0107]: struct takes 2 lifetime arguments but 3 lifetime arguments were supplied
   --> $DIR/constructor-lifetime-args.rs:19:5
    |
 LL |     S::<'static, 'static, 'static>(&0, &0);
@@ -30,7 +30,7 @@ note: struct defined here, with 2 lifetime parameters: `'a`, `'b`
 LL | struct S<'a, 'b>(&'a u8, &'b u8);
    |        ^ --  --
 
-error[E0107]: this enum takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: enum takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/constructor-lifetime-args.rs:22:8
    |
 LL |     E::V::<'static>(&0);
@@ -48,7 +48,7 @@ help: add missing lifetime argument
 LL |     E::V::<'static, 'static>(&0);
    |                   +++++++++
 
-error[E0107]: this enum takes 2 lifetime arguments but 3 lifetime arguments were supplied
+error[E0107]: enum takes 2 lifetime arguments but 3 lifetime arguments were supplied
   --> $DIR/constructor-lifetime-args.rs:24:8
    |
 LL |     E::V::<'static, 'static, 'static>(&0);
diff --git a/tests/ui/consts/const-eval/validate_uninhabited_zsts.32bit.stderr b/tests/ui/consts/const-eval/validate_uninhabited_zsts.32bit.stderr
index 9710bf476ec..69fb1a59d4f 100644
--- a/tests/ui/consts/const-eval/validate_uninhabited_zsts.32bit.stderr
+++ b/tests/ui/consts/const-eval/validate_uninhabited_zsts.32bit.stderr
@@ -2,10 +2,7 @@ warning: the type `!` does not permit zero-initialization
   --> $DIR/validate_uninhabited_zsts.rs:4:14
    |
 LL |     unsafe { std::mem::transmute(()) }
-   |              ^^^^^^^^^^^^^^^^^^^^^^^
-   |              |
-   |              this code causes undefined behavior when executed
-   |              help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
+   |              ^^^^^^^^^^^^^^^^^^^^^^^ this code causes undefined behavior when executed
    |
    = note: the `!` type has no valid value
    = note: `#[warn(invalid_value)]` on by default
@@ -40,10 +37,7 @@ warning: the type `empty::Empty` does not permit zero-initialization
   --> $DIR/validate_uninhabited_zsts.rs:21:42
    |
 LL | const BAR: [empty::Empty; 3] = [unsafe { std::mem::transmute(()) }; 3];
-   |                                          ^^^^^^^^^^^^^^^^^^^^^^^
-   |                                          |
-   |                                          this code causes undefined behavior when executed
-   |                                          help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
+   |                                          ^^^^^^^^^^^^^^^^^^^^^^^ this code causes undefined behavior when executed
    |
 note: in this struct field
   --> $DIR/validate_uninhabited_zsts.rs:16:22
diff --git a/tests/ui/consts/const-eval/validate_uninhabited_zsts.64bit.stderr b/tests/ui/consts/const-eval/validate_uninhabited_zsts.64bit.stderr
index 9710bf476ec..69fb1a59d4f 100644
--- a/tests/ui/consts/const-eval/validate_uninhabited_zsts.64bit.stderr
+++ b/tests/ui/consts/const-eval/validate_uninhabited_zsts.64bit.stderr
@@ -2,10 +2,7 @@ warning: the type `!` does not permit zero-initialization
   --> $DIR/validate_uninhabited_zsts.rs:4:14
    |
 LL |     unsafe { std::mem::transmute(()) }
-   |              ^^^^^^^^^^^^^^^^^^^^^^^
-   |              |
-   |              this code causes undefined behavior when executed
-   |              help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
+   |              ^^^^^^^^^^^^^^^^^^^^^^^ this code causes undefined behavior when executed
    |
    = note: the `!` type has no valid value
    = note: `#[warn(invalid_value)]` on by default
@@ -40,10 +37,7 @@ warning: the type `empty::Empty` does not permit zero-initialization
   --> $DIR/validate_uninhabited_zsts.rs:21:42
    |
 LL | const BAR: [empty::Empty; 3] = [unsafe { std::mem::transmute(()) }; 3];
-   |                                          ^^^^^^^^^^^^^^^^^^^^^^^
-   |                                          |
-   |                                          this code causes undefined behavior when executed
-   |                                          help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
+   |                                          ^^^^^^^^^^^^^^^^^^^^^^^ this code causes undefined behavior when executed
    |
 note: in this struct field
   --> $DIR/validate_uninhabited_zsts.rs:16:22
diff --git a/tests/ui/consts/ct-var-in-collect_all_mismatches.stderr b/tests/ui/consts/ct-var-in-collect_all_mismatches.stderr
index 43fba2573ff..fa20077da7e 100644
--- a/tests/ui/consts/ct-var-in-collect_all_mismatches.stderr
+++ b/tests/ui/consts/ct-var-in-collect_all_mismatches.stderr
@@ -8,7 +8,7 @@ note: required by a bound in `Foo::<T, N>::unsatisfied`
   --> $DIR/ct-var-in-collect_all_mismatches.rs:15:12
    |
 LL |     fn unsatisfied(self)
-   |        ----------- required by a bound in this
+   |        ----------- required by a bound in this associated function
 LL |     where
 LL |         T: Bar<N>,
    |            ^^^^^^ required by this bound in `Foo::<T, N>::unsatisfied`
diff --git a/tests/ui/consts/gate-do-not-const-check.rs b/tests/ui/consts/gate-do-not-const-check.rs
new file mode 100644
index 00000000000..be7e70dfabb
--- /dev/null
+++ b/tests/ui/consts/gate-do-not-const-check.rs
@@ -0,0 +1,5 @@
+#[rustc_do_not_const_check]
+//~^ ERROR this is an internal attribute that will never be stable
+const fn foo() {}
+
+fn main() {}
diff --git a/tests/ui/consts/gate-do-not-const-check.stderr b/tests/ui/consts/gate-do-not-const-check.stderr
new file mode 100644
index 00000000000..3bb1360166a
--- /dev/null
+++ b/tests/ui/consts/gate-do-not-const-check.stderr
@@ -0,0 +1,11 @@
+error[E0658]: this is an internal attribute that will never be stable
+  --> $DIR/gate-do-not-const-check.rs:1:1
+   |
+LL | #[rustc_do_not_const_check]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |
+   = help: add `#![feature(rustc_attrs)]` to the crate attributes to enable
+
+error: aborting due to previous error
+
+For more information about this error, try `rustc --explain E0658`.
diff --git a/tests/ui/deprecation/deprecation-lint.rs b/tests/ui/deprecation/deprecation-lint.rs
index 0417e952eb7..83056feaf27 100644
--- a/tests/ui/deprecation/deprecation-lint.rs
+++ b/tests/ui/deprecation/deprecation-lint.rs
@@ -14,22 +14,22 @@ mod cross_crate {
         let foo = MethodTester;
 
         deprecated(); //~ ERROR use of deprecated function `deprecation_lint::deprecated`
-        foo.method_deprecated(); //~ ERROR use of deprecated associated function `deprecation_lint::MethodTester::method_deprecated`
-        Foo::method_deprecated(&foo); //~ ERROR use of deprecated associated function `deprecation_lint::MethodTester::method_deprecated`
-        <Foo>::method_deprecated(&foo); //~ ERROR use of deprecated associated function `deprecation_lint::MethodTester::method_deprecated`
-        foo.trait_deprecated(); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`
-        Trait::trait_deprecated(&foo); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`
-        <Foo>::trait_deprecated(&foo); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`
-        <Foo as Trait>::trait_deprecated(&foo); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`
+        foo.method_deprecated(); //~ ERROR use of deprecated method `deprecation_lint::MethodTester::method_deprecated`
+        Foo::method_deprecated(&foo); //~ ERROR use of deprecated method `deprecation_lint::MethodTester::method_deprecated`
+        <Foo>::method_deprecated(&foo); //~ ERROR use of deprecated method `deprecation_lint::MethodTester::method_deprecated`
+        foo.trait_deprecated(); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated`
+        Trait::trait_deprecated(&foo); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated`
+        <Foo>::trait_deprecated(&foo); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated`
+        <Foo as Trait>::trait_deprecated(&foo); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated`
 
         deprecated_text(); //~ ERROR use of deprecated function `deprecation_lint::deprecated_text`: text
-        foo.method_deprecated_text(); //~ ERROR use of deprecated associated function `deprecation_lint::MethodTester::method_deprecated_text`: text
-        Foo::method_deprecated_text(&foo); //~ ERROR use of deprecated associated function `deprecation_lint::MethodTester::method_deprecated_text`: text
-        <Foo>::method_deprecated_text(&foo); //~ ERROR use of deprecated associated function `deprecation_lint::MethodTester::method_deprecated_text`: text
-        foo.trait_deprecated_text(); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
-        Trait::trait_deprecated_text(&foo); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
-        <Foo>::trait_deprecated_text(&foo); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
-        <Foo as Trait>::trait_deprecated_text(&foo); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
+        foo.method_deprecated_text(); //~ ERROR use of deprecated method `deprecation_lint::MethodTester::method_deprecated_text`: text
+        Foo::method_deprecated_text(&foo); //~ ERROR use of deprecated method `deprecation_lint::MethodTester::method_deprecated_text`: text
+        <Foo>::method_deprecated_text(&foo); //~ ERROR use of deprecated method `deprecation_lint::MethodTester::method_deprecated_text`: text
+        foo.trait_deprecated_text(); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
+        Trait::trait_deprecated_text(&foo); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
+        <Foo>::trait_deprecated_text(&foo); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
+        <Foo as Trait>::trait_deprecated_text(&foo); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
 
         let _ = DeprecatedStruct { //~ ERROR use of deprecated struct `deprecation_lint::DeprecatedStruct`: text
             i: 0 //~ ERROR use of deprecated field `deprecation_lint::DeprecatedStruct::i`: text
@@ -61,19 +61,19 @@ mod cross_crate {
     }
 
     fn test_method_param<Foo: Trait>(foo: Foo) {
-        foo.trait_deprecated(); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`
-        Trait::trait_deprecated(&foo); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`
-        <Foo>::trait_deprecated(&foo); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`
-        <Foo as Trait>::trait_deprecated(&foo); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`
-        foo.trait_deprecated_text(); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
-        Trait::trait_deprecated_text(&foo); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
-        <Foo>::trait_deprecated_text(&foo); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
-        <Foo as Trait>::trait_deprecated_text(&foo); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
+        foo.trait_deprecated(); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated`
+        Trait::trait_deprecated(&foo); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated`
+        <Foo>::trait_deprecated(&foo); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated`
+        <Foo as Trait>::trait_deprecated(&foo); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated`
+        foo.trait_deprecated_text(); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
+        Trait::trait_deprecated_text(&foo); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
+        <Foo>::trait_deprecated_text(&foo); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
+        <Foo as Trait>::trait_deprecated_text(&foo); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
     }
 
     fn test_method_object(foo: &Trait) {
-        foo.trait_deprecated(); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`
-        foo.trait_deprecated_text(); //~ ERROR use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
+        foo.trait_deprecated(); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated`
+        foo.trait_deprecated_text(); //~ ERROR use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
     }
 
     struct S;
@@ -243,22 +243,22 @@ mod this_crate {
         let foo = MethodTester;
 
         deprecated(); //~ ERROR use of deprecated function `this_crate::deprecated`
-        foo.method_deprecated(); //~ ERROR use of deprecated associated function `this_crate::MethodTester::method_deprecated`
-        Foo::method_deprecated(&foo); //~ ERROR use of deprecated associated function `this_crate::MethodTester::method_deprecated`
-        <Foo>::method_deprecated(&foo); //~ ERROR use of deprecated associated function `this_crate::MethodTester::method_deprecated`
-        foo.trait_deprecated(); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated`
-        Trait::trait_deprecated(&foo); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated`
-        <Foo>::trait_deprecated(&foo); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated`
-        <Foo as Trait>::trait_deprecated(&foo); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated`
+        foo.method_deprecated(); //~ ERROR use of deprecated method `this_crate::MethodTester::method_deprecated`
+        Foo::method_deprecated(&foo); //~ ERROR use of deprecated method `this_crate::MethodTester::method_deprecated`
+        <Foo>::method_deprecated(&foo); //~ ERROR use of deprecated method `this_crate::MethodTester::method_deprecated`
+        foo.trait_deprecated(); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated`
+        Trait::trait_deprecated(&foo); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated`
+        <Foo>::trait_deprecated(&foo); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated`
+        <Foo as Trait>::trait_deprecated(&foo); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated`
 
         deprecated_text(); //~ ERROR use of deprecated function `this_crate::deprecated_text`: text
-        foo.method_deprecated_text(); //~ ERROR use of deprecated associated function `this_crate::MethodTester::method_deprecated_text`: text
-        Foo::method_deprecated_text(&foo); //~ ERROR use of deprecated associated function `this_crate::MethodTester::method_deprecated_text`: text
-        <Foo>::method_deprecated_text(&foo); //~ ERROR use of deprecated associated function `this_crate::MethodTester::method_deprecated_text`: text
-        foo.trait_deprecated_text(); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
-        Trait::trait_deprecated_text(&foo); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
-        <Foo>::trait_deprecated_text(&foo); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
-        <Foo as Trait>::trait_deprecated_text(&foo); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+        foo.method_deprecated_text(); //~ ERROR use of deprecated method `this_crate::MethodTester::method_deprecated_text`: text
+        Foo::method_deprecated_text(&foo); //~ ERROR use of deprecated method `this_crate::MethodTester::method_deprecated_text`: text
+        <Foo>::method_deprecated_text(&foo); //~ ERROR use of deprecated method `this_crate::MethodTester::method_deprecated_text`: text
+        foo.trait_deprecated_text(); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
+        Trait::trait_deprecated_text(&foo); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
+        <Foo>::trait_deprecated_text(&foo); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
+        <Foo as Trait>::trait_deprecated_text(&foo); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
 
         // Future deprecations are only permitted with `#![feature(staged_api)]`
         deprecated_future(); //~ ERROR use of deprecated function
@@ -289,19 +289,19 @@ mod this_crate {
     }
 
     fn test_method_param<Foo: Trait>(foo: Foo) {
-        foo.trait_deprecated(); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated`
-        Trait::trait_deprecated(&foo); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated`
-        <Foo>::trait_deprecated(&foo); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated`
-        <Foo as Trait>::trait_deprecated(&foo); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated`
-        foo.trait_deprecated_text(); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
-        Trait::trait_deprecated_text(&foo); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
-        <Foo>::trait_deprecated_text(&foo); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
-        <Foo as Trait>::trait_deprecated_text(&foo); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+        foo.trait_deprecated(); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated`
+        Trait::trait_deprecated(&foo); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated`
+        <Foo>::trait_deprecated(&foo); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated`
+        <Foo as Trait>::trait_deprecated(&foo); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated`
+        foo.trait_deprecated_text(); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
+        Trait::trait_deprecated_text(&foo); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
+        <Foo>::trait_deprecated_text(&foo); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
+        <Foo as Trait>::trait_deprecated_text(&foo); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
     }
 
     fn test_method_object(foo: &Trait) {
-        foo.trait_deprecated(); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated`
-        foo.trait_deprecated_text(); //~ ERROR use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+        foo.trait_deprecated(); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated`
+        foo.trait_deprecated_text(); //~ ERROR use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
     }
 
     #[deprecated(since = "1.0.0", note = "text")]
diff --git a/tests/ui/deprecation/deprecation-lint.stderr b/tests/ui/deprecation/deprecation-lint.stderr
index 3842f849295..2098073409d 100644
--- a/tests/ui/deprecation/deprecation-lint.stderr
+++ b/tests/ui/deprecation/deprecation-lint.stderr
@@ -10,13 +10,13 @@ note: the lint level is defined here
 LL | #![deny(deprecated)]
    |         ^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:21:16
    |
 LL |         Trait::trait_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:23:25
    |
 LL |         <Foo as Trait>::trait_deprecated(&foo);
@@ -28,13 +28,13 @@ error: use of deprecated function `deprecation_lint::deprecated_text`: text
 LL |         deprecated_text();
    |         ^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:30:16
    |
-LL | ...   Trait::trait_deprecated_text(&foo);
-   |              ^^^^^^^^^^^^^^^^^^^^^
+LL |         Trait::trait_deprecated_text(&foo);
+   |                ^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:32:25
    |
 LL | ...   <Foo as Trait>::trait_deprecated_text(&foo);
@@ -100,25 +100,25 @@ error: use of deprecated function `deprecation_lint::deprecated_text`: text
 LL |         macro_test_arg!(macro_test_arg!(deprecated_text()));
    |                                         ^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:65:16
    |
 LL |         Trait::trait_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:67:25
    |
 LL |         <Foo as Trait>::trait_deprecated(&foo);
    |                         ^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:69:16
    |
-LL | ...   Trait::trait_deprecated_text(&foo);
-   |              ^^^^^^^^^^^^^^^^^^^^^
+LL |         Trait::trait_deprecated_text(&foo);
+   |                ^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:71:25
    |
 LL | ...   <Foo as Trait>::trait_deprecated_text(&foo);
@@ -184,13 +184,13 @@ error: use of deprecated function `this_crate::deprecated`: text
 LL |         deprecated();
    |         ^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:250:16
    |
 LL |         Trait::trait_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:252:25
    |
 LL |         <Foo as Trait>::trait_deprecated(&foo);
@@ -202,17 +202,17 @@ error: use of deprecated function `this_crate::deprecated_text`: text
 LL |         deprecated_text();
    |         ^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:259:16
    |
 LL |         Trait::trait_deprecated_text(&foo);
    |                ^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:261:25
    |
-LL | ...   <Foo as Trait>::trait_deprecated_text(&foo);
-   |                       ^^^^^^^^^^^^^^^^^^^^^
+LL |         <Foo as Trait>::trait_deprecated_text(&foo);
+   |                         ^^^^^^^^^^^^^^^^^^^^^
 
 error: use of deprecated function `this_crate::deprecated_future`: text
   --> $DIR/deprecation-lint.rs:264:9
@@ -274,29 +274,29 @@ error: use of deprecated tuple struct `this_crate::nested::DeprecatedTupleStruct
 LL | ...   let _ = nested::DeprecatedTupleStruct (1);
    |                       ^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:293:16
    |
 LL |         Trait::trait_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:295:25
    |
 LL |         <Foo as Trait>::trait_deprecated(&foo);
    |                         ^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:297:16
    |
 LL |         Trait::trait_deprecated_text(&foo);
    |                ^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:299:25
    |
-LL | ...   <Foo as Trait>::trait_deprecated_text(&foo);
-   |                       ^^^^^^^^^^^^^^^^^^^^^
+LL |         <Foo as Trait>::trait_deprecated_text(&foo);
+   |                         ^^^^^^^^^^^^^^^^^^^^^
 
 error: use of deprecated function `this_crate::test_fn_closure_body::{closure#0}::bar`
   --> $DIR/deprecation-lint.rs:317:13
@@ -352,65 +352,65 @@ error: use of deprecated tuple struct `this_crate2::Deprecated2`: text
 LL |         let Deprecated2
    |             ^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::MethodTester::method_deprecated`: text
+error: use of deprecated method `deprecation_lint::MethodTester::method_deprecated`: text
   --> $DIR/deprecation-lint.rs:17:13
    |
 LL |         foo.method_deprecated();
    |             ^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::MethodTester::method_deprecated`: text
+error: use of deprecated method `deprecation_lint::MethodTester::method_deprecated`: text
   --> $DIR/deprecation-lint.rs:18:14
    |
 LL |         Foo::method_deprecated(&foo);
    |              ^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::MethodTester::method_deprecated`: text
+error: use of deprecated method `deprecation_lint::MethodTester::method_deprecated`: text
   --> $DIR/deprecation-lint.rs:19:16
    |
 LL |         <Foo>::method_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:20:13
    |
 LL |         foo.trait_deprecated();
    |             ^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:22:16
    |
 LL |         <Foo>::trait_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::MethodTester::method_deprecated_text`: text
+error: use of deprecated method `deprecation_lint::MethodTester::method_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:26:13
    |
-LL | ...   foo.method_deprecated_text();
-   |           ^^^^^^^^^^^^^^^^^^^^^^
+LL |         foo.method_deprecated_text();
+   |             ^^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::MethodTester::method_deprecated_text`: text
+error: use of deprecated method `deprecation_lint::MethodTester::method_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:27:14
    |
-LL | ...   Foo::method_deprecated_text(&foo);
-   |            ^^^^^^^^^^^^^^^^^^^^^^
+LL |         Foo::method_deprecated_text(&foo);
+   |              ^^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::MethodTester::method_deprecated_text`: text
+error: use of deprecated method `deprecation_lint::MethodTester::method_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:28:16
    |
 LL | ...   <Foo>::method_deprecated_text(&foo);
    |              ^^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:29:13
    |
 LL |         foo.trait_deprecated_text();
    |             ^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:31:16
    |
-LL | ...   <Foo>::trait_deprecated_text(&foo);
-   |              ^^^^^^^^^^^^^^^^^^^^^
+LL |         <Foo>::trait_deprecated_text(&foo);
+   |                ^^^^^^^^^^^^^^^^^^^^^
 
 error: use of deprecated field `deprecation_lint::DeprecatedStruct::i`: text
   --> $DIR/deprecation-lint.rs:35:13
@@ -424,37 +424,37 @@ error: use of deprecated field `deprecation_lint::nested::DeprecatedStruct::i`:
 LL |             i: 0
    |             ^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:64:13
    |
 LL |         foo.trait_deprecated();
    |             ^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:66:16
    |
 LL |         <Foo>::trait_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:68:13
    |
 LL |         foo.trait_deprecated_text();
    |             ^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:70:16
    |
-LL | ...   <Foo>::trait_deprecated_text(&foo);
-   |              ^^^^^^^^^^^^^^^^^^^^^
+LL |         <Foo>::trait_deprecated_text(&foo);
+   |                ^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:75:13
    |
 LL |         foo.trait_deprecated();
    |             ^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `deprecation_lint::Trait::trait_deprecated_text`: text
+error: use of deprecated method `deprecation_lint::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:76:13
    |
 LL |         foo.trait_deprecated_text();
@@ -544,61 +544,61 @@ error: use of deprecated field `deprecation_lint::Deprecated2::2`: text
 LL |              _)
    |              ^
 
-error: use of deprecated associated function `this_crate::MethodTester::method_deprecated`: text
+error: use of deprecated method `this_crate::MethodTester::method_deprecated`: text
   --> $DIR/deprecation-lint.rs:246:13
    |
 LL |         foo.method_deprecated();
    |             ^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::MethodTester::method_deprecated`: text
+error: use of deprecated method `this_crate::MethodTester::method_deprecated`: text
   --> $DIR/deprecation-lint.rs:247:14
    |
 LL |         Foo::method_deprecated(&foo);
    |              ^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::MethodTester::method_deprecated`: text
+error: use of deprecated method `this_crate::MethodTester::method_deprecated`: text
   --> $DIR/deprecation-lint.rs:248:16
    |
 LL |         <Foo>::method_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:249:13
    |
 LL |         foo.trait_deprecated();
    |             ^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:251:16
    |
 LL |         <Foo>::trait_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::MethodTester::method_deprecated_text`: text
+error: use of deprecated method `this_crate::MethodTester::method_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:255:13
    |
-LL | ...   foo.method_deprecated_text();
-   |           ^^^^^^^^^^^^^^^^^^^^^^
+LL |         foo.method_deprecated_text();
+   |             ^^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::MethodTester::method_deprecated_text`: text
+error: use of deprecated method `this_crate::MethodTester::method_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:256:14
    |
-LL | ...   Foo::method_deprecated_text(&foo);
-   |            ^^^^^^^^^^^^^^^^^^^^^^
+LL |         Foo::method_deprecated_text(&foo);
+   |              ^^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::MethodTester::method_deprecated_text`: text
+error: use of deprecated method `this_crate::MethodTester::method_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:257:16
    |
-LL | ...   <Foo>::method_deprecated_text(&foo);
-   |              ^^^^^^^^^^^^^^^^^^^^^^
+LL |         <Foo>::method_deprecated_text(&foo);
+   |                ^^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:258:13
    |
 LL |         foo.trait_deprecated_text();
    |             ^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:260:16
    |
 LL |         <Foo>::trait_deprecated_text(&foo);
@@ -616,37 +616,37 @@ error: use of deprecated field `this_crate::nested::DeprecatedStruct::i`: text
 LL |             i: 0
    |             ^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:292:13
    |
 LL |         foo.trait_deprecated();
    |             ^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:294:16
    |
 LL |         <Foo>::trait_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:296:13
    |
 LL |         foo.trait_deprecated_text();
    |             ^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:298:16
    |
 LL |         <Foo>::trait_deprecated_text(&foo);
    |                ^^^^^^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/deprecation-lint.rs:303:13
    |
 LL |         foo.trait_deprecated();
    |             ^^^^^^^^^^^^^^^^
 
-error: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+error: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/deprecation-lint.rs:304:13
    |
 LL |         foo.trait_deprecated_text();
diff --git a/tests/ui/deprecation/issue-84637-deprecated-associated-function.fixed b/tests/ui/deprecation/issue-84637-deprecated-associated-function.fixed
index 99a2b09614f..85e88287094 100644
--- a/tests/ui/deprecation/issue-84637-deprecated-associated-function.fixed
+++ b/tests/ui/deprecation/issue-84637-deprecated-associated-function.fixed
@@ -3,7 +3,7 @@
 #![deny(deprecated)]
 
 fn main() {
-    let _foo = str::trim_start("   aoeu"); //~ ERROR use of deprecated associated function `core::str::<impl str>::trim_left`: superseded by `trim_start` [deprecated]
+    let _foo = str::trim_start("   aoeu"); //~ ERROR use of deprecated method `core::str::<impl str>::trim_left`: superseded by `trim_start` [deprecated]
 
-    let _bar = "   aoeu".trim_start(); //~ ERROR use of deprecated associated function `core::str::<impl str>::trim_left`: superseded by `trim_start` [deprecated]
+    let _bar = "   aoeu".trim_start(); //~ ERROR use of deprecated method `core::str::<impl str>::trim_left`: superseded by `trim_start` [deprecated]
 }
diff --git a/tests/ui/deprecation/issue-84637-deprecated-associated-function.rs b/tests/ui/deprecation/issue-84637-deprecated-associated-function.rs
index 62bf84aa3ea..246de2f5e4b 100644
--- a/tests/ui/deprecation/issue-84637-deprecated-associated-function.rs
+++ b/tests/ui/deprecation/issue-84637-deprecated-associated-function.rs
@@ -3,7 +3,7 @@
 #![deny(deprecated)]
 
 fn main() {
-    let _foo = str::trim_left("   aoeu"); //~ ERROR use of deprecated associated function `core::str::<impl str>::trim_left`: superseded by `trim_start` [deprecated]
+    let _foo = str::trim_left("   aoeu"); //~ ERROR use of deprecated method `core::str::<impl str>::trim_left`: superseded by `trim_start` [deprecated]
 
-    let _bar = "   aoeu".trim_left(); //~ ERROR use of deprecated associated function `core::str::<impl str>::trim_left`: superseded by `trim_start` [deprecated]
+    let _bar = "   aoeu".trim_left(); //~ ERROR use of deprecated method `core::str::<impl str>::trim_left`: superseded by `trim_start` [deprecated]
 }
diff --git a/tests/ui/deprecation/issue-84637-deprecated-associated-function.stderr b/tests/ui/deprecation/issue-84637-deprecated-associated-function.stderr
index 8d4529526e3..3b518d1802b 100644
--- a/tests/ui/deprecation/issue-84637-deprecated-associated-function.stderr
+++ b/tests/ui/deprecation/issue-84637-deprecated-associated-function.stderr
@@ -1,4 +1,4 @@
-error: use of deprecated associated function `core::str::<impl str>::trim_left`: superseded by `trim_start`
+error: use of deprecated method `core::str::<impl str>::trim_left`: superseded by `trim_start`
   --> $DIR/issue-84637-deprecated-associated-function.rs:6:21
    |
 LL |     let _foo = str::trim_left("   aoeu");
@@ -9,18 +9,18 @@ note: the lint level is defined here
    |
 LL | #![deny(deprecated)]
    |         ^^^^^^^^^^
-help: replace the use of the deprecated associated function
+help: replace the use of the deprecated method
    |
 LL |     let _foo = str::trim_start("   aoeu");
    |                     ~~~~~~~~~~
 
-error: use of deprecated associated function `core::str::<impl str>::trim_left`: superseded by `trim_start`
+error: use of deprecated method `core::str::<impl str>::trim_left`: superseded by `trim_start`
   --> $DIR/issue-84637-deprecated-associated-function.rs:8:26
    |
 LL |     let _bar = "   aoeu".trim_left();
    |                          ^^^^^^^^^
    |
-help: replace the use of the deprecated associated function
+help: replace the use of the deprecated method
    |
 LL |     let _bar = "   aoeu".trim_start();
    |                          ~~~~~~~~~~
diff --git a/tests/ui/deprecation/suggestion.stderr b/tests/ui/deprecation/suggestion.stderr
index c5f2fc09125..5584b6d2f8f 100644
--- a/tests/ui/deprecation/suggestion.stderr
+++ b/tests/ui/deprecation/suggestion.stderr
@@ -14,13 +14,13 @@ help: replace the use of the deprecated function
 LL |     bar::replacement();
    |          ~~~~~~~~~~~
 
-error: use of deprecated associated function `Foo::deprecated`: replaced by `replacement`
+error: use of deprecated method `Foo::deprecated`: replaced by `replacement`
   --> $DIR/suggestion.rs:40:9
    |
 LL |     foo.deprecated();
    |         ^^^^^^^^^^
    |
-help: replace the use of the deprecated associated function
+help: replace the use of the deprecated method
    |
 LL |     foo.replacement();
    |         ~~~~~~~~~~~
diff --git a/tests/ui/error-codes/E0107.rs b/tests/ui/error-codes/E0107.rs
index d369fc2a565..fd23e7c00f2 100644
--- a/tests/ui/error-codes/E0107.rs
+++ b/tests/ui/error-codes/E0107.rs
@@ -11,39 +11,39 @@ enum Bar {
 
 struct Baz<'a, 'b, 'c> {
     buzz: Buzz<'a>,
-    //~^ ERROR this struct takes 2 lifetime arguments
+    //~^ ERROR struct takes 2 lifetime arguments
     //~| HELP add missing lifetime argument
 
     bar: Bar<'a>,
-    //~^ ERROR this enum takes 0 lifetime arguments
+    //~^ ERROR enum takes 0 lifetime arguments
     //~| HELP remove these generics
 
     foo2: Foo<'a, 'b, 'c>,
-    //~^ ERROR this struct takes 1 lifetime argument
+    //~^ ERROR struct takes 1 lifetime argument
     //~| HELP remove these lifetime arguments
 
     qux1: Qux<'a, 'b, i32>,
-    //~^ ERROR this struct takes 1 lifetime argument
+    //~^ ERROR struct takes 1 lifetime argument
     //~| HELP remove this lifetime argument
 
     qux2: Qux<'a, i32, 'b>,
-    //~^ ERROR this struct takes 1 lifetime argument
+    //~^ ERROR struct takes 1 lifetime argument
     //~| HELP remove this lifetime argument
 
     qux3: Qux<'a, 'b, 'c, i32>,
-    //~^ ERROR this struct takes 1 lifetime argument
+    //~^ ERROR struct takes 1 lifetime argument
     //~| HELP remove these lifetime arguments
 
     qux4: Qux<'a, i32, 'b, 'c>,
-    //~^ ERROR this struct takes 1 lifetime argument
+    //~^ ERROR struct takes 1 lifetime argument
     //~| HELP remove these lifetime arguments
 
     qux5: Qux<'a, 'b, i32, 'c>,
-    //~^ ERROR this struct takes 1 lifetime argument
+    //~^ ERROR struct takes 1 lifetime argument
     //~| HELP remove this lifetime argument
 
     quux: Quux<'a, i32, 'b>,
-    //~^ ERROR this struct takes 0 lifetime arguments
+    //~^ ERROR struct takes 0 lifetime arguments
     //~| HELP remove this lifetime argument
 }
 
@@ -53,7 +53,7 @@ pub trait T {
 }
 
 fn trait_bound_generic<I: T<u8, u16>>(_i: I) {
-    //~^ ERROR this trait takes 0 generic arguments
+    //~^ ERROR trait takes 0 generic arguments
     //~| HELP replace the generic bounds with the associated types
 }
 
diff --git a/tests/ui/error-codes/E0107.stderr b/tests/ui/error-codes/E0107.stderr
index 03430f8fa3a..3f540eb08bc 100644
--- a/tests/ui/error-codes/E0107.stderr
+++ b/tests/ui/error-codes/E0107.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this struct takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: struct takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/E0107.rs:13:11
    |
 LL |     buzz: Buzz<'a>,
@@ -16,7 +16,7 @@ help: add missing lifetime argument
 LL |     buzz: Buzz<'a, 'a>,
    |                  ++++
 
-error[E0107]: this enum takes 0 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: enum takes 0 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/E0107.rs:17:10
    |
 LL |     bar: Bar<'a>,
@@ -30,7 +30,7 @@ note: enum defined here, with 0 lifetime parameters
 LL | enum Bar {
    |      ^^^
 
-error[E0107]: this struct takes 1 lifetime argument but 3 lifetime arguments were supplied
+error[E0107]: struct takes 1 lifetime argument but 3 lifetime arguments were supplied
   --> $DIR/E0107.rs:21:11
    |
 LL |     foo2: Foo<'a, 'b, 'c>,
@@ -44,7 +44,7 @@ note: struct defined here, with 1 lifetime parameter: `'a`
 LL | struct Foo<'a>(&'a str);
    |        ^^^ --
 
-error[E0107]: this struct takes 1 lifetime argument but 2 lifetime arguments were supplied
+error[E0107]: struct takes 1 lifetime argument but 2 lifetime arguments were supplied
   --> $DIR/E0107.rs:25:11
    |
 LL |     qux1: Qux<'a, 'b, i32>,
@@ -58,7 +58,7 @@ note: struct defined here, with 1 lifetime parameter: `'a`
 LL | struct Qux<'a, T>(&'a T);
    |        ^^^ --
 
-error[E0107]: this struct takes 1 lifetime argument but 2 lifetime arguments were supplied
+error[E0107]: struct takes 1 lifetime argument but 2 lifetime arguments were supplied
   --> $DIR/E0107.rs:29:11
    |
 LL |     qux2: Qux<'a, i32, 'b>,
@@ -72,7 +72,7 @@ note: struct defined here, with 1 lifetime parameter: `'a`
 LL | struct Qux<'a, T>(&'a T);
    |        ^^^ --
 
-error[E0107]: this struct takes 1 lifetime argument but 3 lifetime arguments were supplied
+error[E0107]: struct takes 1 lifetime argument but 3 lifetime arguments were supplied
   --> $DIR/E0107.rs:33:11
    |
 LL |     qux3: Qux<'a, 'b, 'c, i32>,
@@ -86,7 +86,7 @@ note: struct defined here, with 1 lifetime parameter: `'a`
 LL | struct Qux<'a, T>(&'a T);
    |        ^^^ --
 
-error[E0107]: this struct takes 1 lifetime argument but 3 lifetime arguments were supplied
+error[E0107]: struct takes 1 lifetime argument but 3 lifetime arguments were supplied
   --> $DIR/E0107.rs:37:11
    |
 LL |     qux4: Qux<'a, i32, 'b, 'c>,
@@ -100,7 +100,7 @@ note: struct defined here, with 1 lifetime parameter: `'a`
 LL | struct Qux<'a, T>(&'a T);
    |        ^^^ --
 
-error[E0107]: this struct takes 1 lifetime argument but 3 lifetime arguments were supplied
+error[E0107]: struct takes 1 lifetime argument but 3 lifetime arguments were supplied
   --> $DIR/E0107.rs:41:11
    |
 LL |     qux5: Qux<'a, 'b, i32, 'c>,
@@ -114,7 +114,7 @@ note: struct defined here, with 1 lifetime parameter: `'a`
 LL | struct Qux<'a, T>(&'a T);
    |        ^^^ --
 
-error[E0107]: this struct takes 0 lifetime arguments but 2 lifetime arguments were supplied
+error[E0107]: struct takes 0 lifetime arguments but 2 lifetime arguments were supplied
   --> $DIR/E0107.rs:45:11
    |
 LL |     quux: Quux<'a, i32, 'b>,
@@ -128,7 +128,7 @@ note: struct defined here, with 0 lifetime parameters
 LL | struct Quux<T>(T);
    |        ^^^^
 
-error[E0107]: this trait takes 0 generic arguments but 2 generic arguments were supplied
+error[E0107]: trait takes 0 generic arguments but 2 generic arguments were supplied
   --> $DIR/E0107.rs:55:27
    |
 LL | fn trait_bound_generic<I: T<u8, u16>>(_i: I) {
diff --git a/tests/ui/error-codes/E0476.rs b/tests/ui/error-codes/E0476.rs
new file mode 100644
index 00000000000..d5e4b8d2372
--- /dev/null
+++ b/tests/ui/error-codes/E0476.rs
@@ -0,0 +1,13 @@
+#![feature(coerce_unsized)]
+#![feature(unsize)]
+
+use std::marker::Unsize;
+use std::ops::CoerceUnsized;
+
+struct Wrapper<T>(T);
+
+impl<'a, 'b, T, S> CoerceUnsized<&'a Wrapper<T>> for &'b Wrapper<S> where S: Unsize<T> {}
+//~^ ERROR lifetime of the source pointer does not outlive lifetime bound of the object type [E0476]
+//~^^ ERROR E0119
+
+fn main() {}
diff --git a/tests/ui/error-codes/E0476.stderr b/tests/ui/error-codes/E0476.stderr
new file mode 100644
index 00000000000..a4bb26532a2
--- /dev/null
+++ b/tests/ui/error-codes/E0476.stderr
@@ -0,0 +1,31 @@
+error[E0119]: conflicting implementations of trait `CoerceUnsized<&Wrapper<_>>` for type `&Wrapper<_>`
+  --> $DIR/E0476.rs:9:1
+   |
+LL | impl<'a, 'b, T, S> CoerceUnsized<&'a Wrapper<T>> for &'b Wrapper<S> where S: Unsize<T> {}
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |
+   = note: conflicting implementation in crate `core`:
+           - impl<'a, 'b, T, U> CoerceUnsized<&'a U> for &'b T
+             where 'b: 'a, T: Unsize<U>, T: ?Sized, U: ?Sized;
+
+error[E0476]: lifetime of the source pointer does not outlive lifetime bound of the object type
+  --> $DIR/E0476.rs:9:1
+   |
+LL | impl<'a, 'b, T, S> CoerceUnsized<&'a Wrapper<T>> for &'b Wrapper<S> where S: Unsize<T> {}
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |
+note: object type is valid for the lifetime `'a` as defined here
+  --> $DIR/E0476.rs:9:6
+   |
+LL | impl<'a, 'b, T, S> CoerceUnsized<&'a Wrapper<T>> for &'b Wrapper<S> where S: Unsize<T> {}
+   |      ^^
+note: source pointer is only valid for the lifetime `'b` as defined here
+  --> $DIR/E0476.rs:9:10
+   |
+LL | impl<'a, 'b, T, S> CoerceUnsized<&'a Wrapper<T>> for &'b Wrapper<S> where S: Unsize<T> {}
+   |          ^^
+
+error: aborting due to 2 previous errors
+
+Some errors have detailed explanations: E0119, E0476.
+For more information about an error, try `rustc --explain E0119`.
diff --git a/tests/ui/error-codes/E0624.rs b/tests/ui/error-codes/E0624.rs
index 4c68b70fb16..45f72a565ca 100644
--- a/tests/ui/error-codes/E0624.rs
+++ b/tests/ui/error-codes/E0624.rs
@@ -8,5 +8,5 @@ mod inner {
 
 fn main() {
     let foo = inner::Foo;
-    foo.method(); //~ ERROR associated function `method` is private [E0624]
+    foo.method(); //~ ERROR method `method` is private [E0624]
 }
diff --git a/tests/ui/error-codes/E0624.stderr b/tests/ui/error-codes/E0624.stderr
index e59b8a8ae35..23a8ea8a8c9 100644
--- a/tests/ui/error-codes/E0624.stderr
+++ b/tests/ui/error-codes/E0624.stderr
@@ -1,11 +1,11 @@
-error[E0624]: associated function `method` is private
+error[E0624]: method `method` is private
   --> $DIR/E0624.rs:11:9
    |
 LL |         fn method(&self) {}
-   |         ---------------- private associated function defined here
+   |         ---------------- private method defined here
 ...
 LL |     foo.method();
-   |         ^^^^^^ private associated function
+   |         ^^^^^^ private method
 
 error: aborting due to previous error
 
diff --git a/tests/ui/explore-issue-38412.stderr b/tests/ui/explore-issue-38412.stderr
index 08dadb4db85..d8b485c9dc3 100644
--- a/tests/ui/explore-issue-38412.stderr
+++ b/tests/ui/explore-issue-38412.stderr
@@ -79,38 +79,38 @@ 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
 
-error[E0624]: associated function `pub_crate` is private
+error[E0624]: method `pub_crate` is private
   --> $DIR/explore-issue-38412.rs:48:7
    |
 LL |     r.pub_crate();
-   |       ^^^^^^^^^ private associated function
+   |       ^^^^^^^^^ private method
    |
   ::: $DIR/auxiliary/pub-and-stability.rs:114:9
    |
 LL |         pub(crate) fn pub_crate(&self) -> i32 { self.d_priv }
-   |         ------------------------------------- private associated function defined here
+   |         ------------------------------------- private method defined here
 
-error[E0624]: associated function `pub_mod` is private
+error[E0624]: method `pub_mod` is private
   --> $DIR/explore-issue-38412.rs:49:7
    |
 LL |     r.pub_mod();
-   |       ^^^^^^^ private associated function
+   |       ^^^^^^^ private method
    |
   ::: $DIR/auxiliary/pub-and-stability.rs:116:9
    |
 LL |         pub(in m) fn pub_mod(&self) -> i32 { self.d_priv }
-   |         ---------------------------------- private associated function defined here
+   |         ---------------------------------- private method defined here
 
-error[E0624]: associated function `private` is private
+error[E0624]: method `private` is private
   --> $DIR/explore-issue-38412.rs:50:7
    |
 LL |     r.private();
-   |       ^^^^^^^ private associated function
+   |       ^^^^^^^ private method
    |
   ::: $DIR/auxiliary/pub-and-stability.rs:118:9
    |
 LL |         fn private(&self) -> i32 { self.d_priv }
-   |         ------------------------ private associated function defined here
+   |         ------------------------ private method defined here
 
 error[E0658]: use of unstable library feature 'unstable_undeclared'
   --> $DIR/explore-issue-38412.rs:55:7
@@ -130,38 +130,38 @@ 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
 
-error[E0624]: associated function `pub_crate` is private
+error[E0624]: method `pub_crate` is private
   --> $DIR/explore-issue-38412.rs:61:7
    |
 LL |     t.pub_crate();
-   |       ^^^^^^^^^ private associated function
+   |       ^^^^^^^^^ private method
    |
   ::: $DIR/auxiliary/pub-and-stability.rs:129:9
    |
 LL |         pub(crate) fn pub_crate(&self) -> i32 { self.0 }
-   |         ------------------------------------- private associated function defined here
+   |         ------------------------------------- private method defined here
 
-error[E0624]: associated function `pub_mod` is private
+error[E0624]: method `pub_mod` is private
   --> $DIR/explore-issue-38412.rs:62:7
    |
 LL |     t.pub_mod();
-   |       ^^^^^^^ private associated function
+   |       ^^^^^^^ private method
    |
   ::: $DIR/auxiliary/pub-and-stability.rs:130:9
    |
 LL |         pub(in m) fn pub_mod(&self) -> i32 { self.0 }
-   |         ---------------------------------- private associated function defined here
+   |         ---------------------------------- private method defined here
 
-error[E0624]: associated function `private` is private
+error[E0624]: method `private` is private
   --> $DIR/explore-issue-38412.rs:63:7
    |
 LL |     t.private();
-   |       ^^^^^^^ private associated function
+   |       ^^^^^^^ private method
    |
   ::: $DIR/auxiliary/pub-and-stability.rs:131:9
    |
 LL |         fn private(&self) -> i32 { self.0 }
-   |         ------------------------ private associated function defined here
+   |         ------------------------ private method defined here
 
 error: aborting due to 19 previous errors
 
diff --git a/tests/ui/expr/malformed_closure/missing_braces_around_block.fixed b/tests/ui/expr/malformed_closure/missing_braces_around_block.fixed
index c50b9a12b6d..a7a9db7d977 100644
--- a/tests/ui/expr/malformed_closure/missing_braces_around_block.fixed
+++ b/tests/ui/expr/malformed_closure/missing_braces_around_block.fixed
@@ -4,16 +4,23 @@
 // If this recovery happens, then plenty of errors are emitted. Here, we expect
 // only one error.
 //
-// This is part of issue #88065:
+// This is part of the following issues:
 // https://github.com/rust-lang/rust/issues/88065
+// https://github.com/rust-lang/rust/issues/107959
 
 // run-rustfix
 
 fn main() {
+    // Closure with multiple expressions delimited by semicolon.
     let num = 5;
     (1..num).reduce(|a, b| {
         //~^ ERROR: closure bodies that contain statements must be surrounded by braces
         println!("{}", a);
         a * b
     }).unwrap();
+
+    // Closure with a single expression ended by a semicolon.
+    let mut v = vec![1, 2, 3];
+    v.iter_mut().for_each(|x| {*x = *x+1;});
+        //~^ ERROR: closure bodies that contain statements must be surrounded by braces
 }
diff --git a/tests/ui/expr/malformed_closure/missing_braces_around_block.rs b/tests/ui/expr/malformed_closure/missing_braces_around_block.rs
index 58c81f3a6e2..b5690b2eca7 100644
--- a/tests/ui/expr/malformed_closure/missing_braces_around_block.rs
+++ b/tests/ui/expr/malformed_closure/missing_braces_around_block.rs
@@ -4,16 +4,23 @@
 // If this recovery happens, then plenty of errors are emitted. Here, we expect
 // only one error.
 //
-// This is part of issue #88065:
+// This is part of the following issues:
 // https://github.com/rust-lang/rust/issues/88065
+// https://github.com/rust-lang/rust/issues/107959
 
 // run-rustfix
 
 fn main() {
+    // Closure with multiple expressions delimited by semicolon.
     let num = 5;
     (1..num).reduce(|a, b|
         //~^ ERROR: closure bodies that contain statements must be surrounded by braces
         println!("{}", a);
         a * b
     ).unwrap();
+
+    // Closure with a single expression ended by a semicolon.
+    let mut v = vec![1, 2, 3];
+    v.iter_mut().for_each(|x|*x = *x+1;);
+        //~^ ERROR: closure bodies that contain statements must be surrounded by braces
 }
diff --git a/tests/ui/expr/malformed_closure/missing_braces_around_block.stderr b/tests/ui/expr/malformed_closure/missing_braces_around_block.stderr
index dac9a8cfc69..039eef909fc 100644
--- a/tests/ui/expr/malformed_closure/missing_braces_around_block.stderr
+++ b/tests/ui/expr/malformed_closure/missing_braces_around_block.stderr
@@ -1,5 +1,5 @@
 error: closure bodies that contain statements must be surrounded by braces
-  --> $DIR/missing_braces_around_block.rs:14:26
+  --> $DIR/missing_braces_around_block.rs:16:26
    |
 LL |     (1..num).reduce(|a, b|
    |                          ^
@@ -8,14 +8,14 @@ LL |     ).unwrap();
    |     ^
    |
 note: statement found outside of a block
-  --> $DIR/missing_braces_around_block.rs:16:26
+  --> $DIR/missing_braces_around_block.rs:18:26
    |
 LL |         println!("{}", a);
    |         -----------------^ this `;` turns the preceding closure into a statement
    |         |
    |         this expression is a statement because of the trailing semicolon
 note: the closure body may be incorrectly delimited
-  --> $DIR/missing_braces_around_block.rs:14:21
+  --> $DIR/missing_braces_around_block.rs:16:21
    |
 LL |       (1..num).reduce(|a, b|
    |  _____________________^
@@ -34,5 +34,30 @@ LL |         a * b
 LL ~     }).unwrap();
    |
 
-error: aborting due to previous error
+error: closure bodies that contain statements must be surrounded by braces
+  --> $DIR/missing_braces_around_block.rs:24:29
+   |
+LL |     v.iter_mut().for_each(|x|*x = *x+1;);
+   |                             ^          ^
+   |
+note: statement found outside of a block
+  --> $DIR/missing_braces_around_block.rs:24:39
+   |
+LL |     v.iter_mut().for_each(|x|*x = *x+1;);
+   |                              ---------^ this `;` turns the preceding closure into a statement
+   |                              |
+   |                              this expression is a statement because of the trailing semicolon
+note: the closure body may be incorrectly delimited
+  --> $DIR/missing_braces_around_block.rs:24:27
+   |
+LL |     v.iter_mut().for_each(|x|*x = *x+1;);
+   |                           ^^^^^^^^^^^^ - ...but likely you meant the closure to end here
+   |                           |
+   |                           this is the parsed closure...
+help: try adding braces
+   |
+LL |     v.iter_mut().for_each(|x| {*x = *x+1;});
+   |                               +          +
+
+error: aborting due to 2 previous errors
 
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 edbbf7db565..4233a8af9b6 100644
--- a/tests/ui/feature-gates/feature-gate-associated_type_bounds.stderr
+++ b/tests/ui/feature-gates/feature-gate-associated_type_bounds.stderr
@@ -115,19 +115,19 @@ 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
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in const type
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in const types
   --> $DIR/feature-gate-associated_type_bounds.rs:55:14
    |
 LL | const _cdef: impl Tr1<As1: Copy> = S1;
    |              ^^^^^^^^^^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in const type
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in const types
   --> $DIR/feature-gate-associated_type_bounds.rs:61:15
    |
 LL | static _sdef: impl Tr1<As1: Copy> = S1;
    |               ^^^^^^^^^^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable binding
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable bindings
   --> $DIR/feature-gate-associated_type_bounds.rs:68:12
    |
 LL |     let _: impl Tr1<As1: Copy> = S1;
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 760dcb615c8..c8c3e13d7fc 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
@@ -1,4 +1,4 @@
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait return types
   --> $DIR/feature-gate-impl_trait_in_fn_trait_return.rs:1:24
    |
 LL | fn f() -> impl Fn() -> impl Sized { || () }
@@ -7,7 +7,7 @@ LL | fn f() -> impl Fn() -> impl Sized { || () }
    = 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
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait return types
   --> $DIR/feature-gate-impl_trait_in_fn_trait_return.rs:3:32
    |
 LL | fn g() -> &'static dyn Fn() -> impl Sized { &|| () }
diff --git a/tests/ui/feature-gates/feature-gate-return_position_impl_trait_in_trait.stderr b/tests/ui/feature-gates/feature-gate-return_position_impl_trait_in_trait.stderr
index aeabed4a6ab..0082b6fafee 100644
--- a/tests/ui/feature-gates/feature-gate-return_position_impl_trait_in_trait.stderr
+++ b/tests/ui/feature-gates/feature-gate-return_position_impl_trait_in_trait.stderr
@@ -1,4 +1,4 @@
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in trait method return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in trait method return types
   --> $DIR/feature-gate-return_position_impl_trait_in_trait.rs:8:17
    |
 LL |     fn bar() -> impl Sized;
@@ -7,7 +7,7 @@ LL |     fn bar() -> impl Sized;
    = note: see issue #91611 <https://github.com/rust-lang/rust/issues/91611> for more information
    = help: add `#![feature(return_position_impl_trait_in_trait)]` to the crate attributes to enable
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in trait method return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in trait method return types
   --> $DIR/feature-gate-return_position_impl_trait_in_trait.rs:9:21
    |
 LL |     fn baz() -> Box<impl std::fmt::Display>;
@@ -16,7 +16,7 @@ LL |     fn baz() -> Box<impl std::fmt::Display>;
    = note: see issue #91611 <https://github.com/rust-lang/rust/issues/91611> for more information
    = help: add `#![feature(return_position_impl_trait_in_trait)]` to the crate attributes to enable
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in trait method return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in trait method return types
   --> $DIR/feature-gate-return_position_impl_trait_in_trait.rs:15:23
    |
 LL |     async fn bar() -> impl Sized;
diff --git a/tests/ui/fn/issue-3044.stderr b/tests/ui/fn/issue-3044.stderr
index 2690ad71176..219029e2afd 100644
--- a/tests/ui/fn/issue-3044.stderr
+++ b/tests/ui/fn/issue-3044.stderr
@@ -7,7 +7,7 @@ LL | |
 LL | |     });
    | |______- an argument is missing
    |
-note: associated function defined here
+note: method defined here
   --> $SRC_DIR/core/src/iter/traits/iterator.rs:LL:COL
 help: provide the argument
    |
diff --git a/tests/ui/generator/generator-yielding-or-returning-itself.stderr b/tests/ui/generator/generator-yielding-or-returning-itself.stderr
index 8f5d2429a28..a26dbf3f27c 100644
--- a/tests/ui/generator/generator-yielding-or-returning-itself.stderr
+++ b/tests/ui/generator/generator-yielding-or-returning-itself.stderr
@@ -19,7 +19,7 @@ note: required by a bound in `want_cyclic_generator_return`
   --> $DIR/generator-yielding-or-returning-itself.rs:10:36
    |
 LL | pub fn want_cyclic_generator_return<T>(_: T)
-   |        ---------------------------- required by a bound in this
+   |        ---------------------------- required by a bound in this function
 LL |     where T: Generator<Yield = (), Return = T>
    |                                    ^^^^^^^^^^ required by this bound in `want_cyclic_generator_return`
 
@@ -44,7 +44,7 @@ note: required by a bound in `want_cyclic_generator_yield`
   --> $DIR/generator-yielding-or-returning-itself.rs:23:24
    |
 LL | pub fn want_cyclic_generator_yield<T>(_: T)
-   |        --------------------------- required by a bound in this
+   |        --------------------------- required by a bound in this function
 LL |     where T: Generator<Yield = T, Return = ()>
    |                        ^^^^^^^^^ required by this bound in `want_cyclic_generator_yield`
 
diff --git a/tests/ui/generator/issue-102645.stderr b/tests/ui/generator/issue-102645.stderr
index f6d2440295e..3f9a4c2f3c5 100644
--- a/tests/ui/generator/issue-102645.stderr
+++ b/tests/ui/generator/issue-102645.stderr
@@ -4,7 +4,7 @@ error[E0061]: this method takes 1 argument but 0 arguments were supplied
 LL |     Pin::new(&mut b).resume();
    |                      ^^^^^^-- an argument of type `()` is missing
    |
-note: associated function defined here
+note: method defined here
   --> $SRC_DIR/core/src/ops/generator.rs:LL:COL
 help: provide the argument
    |
diff --git a/tests/ui/generic-associated-types/bugs/issue-88460.stderr b/tests/ui/generic-associated-types/bugs/issue-88460.stderr
index 6612c4b4944..a2047f103d4 100644
--- a/tests/ui/generic-associated-types/bugs/issue-88460.stderr
+++ b/tests/ui/generic-associated-types/bugs/issue-88460.stderr
@@ -11,7 +11,7 @@ note: required by a bound in `test`
   --> $DIR/issue-88460.rs:15:27
    |
 LL | fn test<T>(value: T)
-   |    ---- required by a bound in this
+   |    ---- required by a bound in this function
 ...
 LL |     for<'a> T::Assoc<'a>: Marker,
    |                           ^^^^^^ required by this bound in `test`
diff --git a/tests/ui/generic-associated-types/gat-trait-path-parenthesised-args.rs b/tests/ui/generic-associated-types/gat-trait-path-parenthesised-args.rs
index 9eb069637c6..5738dfa83ee 100644
--- a/tests/ui/generic-associated-types/gat-trait-path-parenthesised-args.rs
+++ b/tests/ui/generic-associated-types/gat-trait-path-parenthesised-args.rs
@@ -5,12 +5,12 @@ trait X {
 fn foo<'a>(arg: Box<dyn X<Y('a) = &'a ()>>) {}
   //~^ ERROR: lifetime in trait object type must be followed by `+`
   //~| ERROR: parenthesized generic arguments cannot be used
-  //~| ERROR this associated type takes 0 generic arguments but 1 generic argument
-  //~| ERROR this associated type takes 1 lifetime argument but 0 lifetime arguments
+  //~| ERROR associated type takes 0 generic arguments but 1 generic argument
+  //~| ERROR associated type takes 1 lifetime argument but 0 lifetime arguments
 
 
 fn bar<'a>(arg: Box<dyn X<Y() = ()>>) {}
   //~^ ERROR: parenthesized generic arguments cannot be used
-  //~| ERROR this associated type takes 1 lifetime argument but 0 lifetime arguments
+  //~| ERROR associated type takes 1 lifetime argument but 0 lifetime arguments
 
 fn main() {}
diff --git a/tests/ui/generic-associated-types/gat-trait-path-parenthesised-args.stderr b/tests/ui/generic-associated-types/gat-trait-path-parenthesised-args.stderr
index 165779796e0..461853379b5 100644
--- a/tests/ui/generic-associated-types/gat-trait-path-parenthesised-args.stderr
+++ b/tests/ui/generic-associated-types/gat-trait-path-parenthesised-args.stderr
@@ -23,7 +23,7 @@ LL | fn bar<'a>(arg: Box<dyn X<Y() = ()>>) {}
    |                            |
    |                            help: remove these parentheses
 
-error[E0107]: this associated type takes 1 lifetime argument but 0 lifetime arguments were supplied
+error[E0107]: associated type takes 1 lifetime argument but 0 lifetime arguments were supplied
   --> $DIR/gat-trait-path-parenthesised-args.rs:5:27
    |
 LL | fn foo<'a>(arg: Box<dyn X<Y('a) = &'a ()>>) {}
@@ -39,7 +39,7 @@ help: add missing lifetime argument
 LL | fn foo<'a>(arg: Box<dyn X<Y('_, 'a) = &'a ()>>) {}
    |                             +++
 
-error[E0107]: this associated type takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: associated type takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/gat-trait-path-parenthesised-args.rs:5:27
    |
 LL | fn foo<'a>(arg: Box<dyn X<Y('a) = &'a ()>>) {}
@@ -53,7 +53,7 @@ note: associated type defined here, with 0 generic parameters
 LL |   type Y<'a>;
    |        ^
 
-error[E0107]: this associated type takes 1 lifetime argument but 0 lifetime arguments were supplied
+error[E0107]: associated type takes 1 lifetime argument but 0 lifetime arguments were supplied
   --> $DIR/gat-trait-path-parenthesised-args.rs:12:27
    |
 LL | fn bar<'a>(arg: Box<dyn X<Y() = ()>>) {}
diff --git a/tests/ui/generic-associated-types/issue-101020.stderr b/tests/ui/generic-associated-types/issue-101020.stderr
index 1f9273a8c4a..5c8db617c17 100644
--- a/tests/ui/generic-associated-types/issue-101020.stderr
+++ b/tests/ui/generic-associated-types/issue-101020.stderr
@@ -13,7 +13,7 @@ note: required by a bound in `LendingIterator::consume`
   --> $DIR/issue-101020.rs:9:33
    |
 LL |     fn consume<F>(self, _f: F)
-   |        ------- required by a bound in this
+   |        ------- required by a bound in this associated function
 ...
 LL |         for<'a> Self::Item<'a>: FuncInput<'a, Self::Item<'a>>,
    |                                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `LendingIterator::consume`
diff --git a/tests/ui/generic-associated-types/method-unsatified-assoc-type-predicate.rs b/tests/ui/generic-associated-types/method-unsatisfied-assoc-type-predicate.rs
index 83655341d6a..83655341d6a 100644
--- a/tests/ui/generic-associated-types/method-unsatified-assoc-type-predicate.rs
+++ b/tests/ui/generic-associated-types/method-unsatisfied-assoc-type-predicate.rs
diff --git a/tests/ui/generic-associated-types/method-unsatified-assoc-type-predicate.stderr b/tests/ui/generic-associated-types/method-unsatisfied-assoc-type-predicate.stderr
index baef38f6b80..4246f8c069d 100644
--- a/tests/ui/generic-associated-types/method-unsatified-assoc-type-predicate.stderr
+++ b/tests/ui/generic-associated-types/method-unsatisfied-assoc-type-predicate.stderr
@@ -1,5 +1,5 @@
 error[E0599]: the method `f` exists for struct `S`, but its trait bounds were not satisfied
-  --> $DIR/method-unsatified-assoc-type-predicate.rs:28:7
+  --> $DIR/method-unsatisfied-assoc-type-predicate.rs:28:7
    |
 LL | struct S;
    | --------
@@ -12,7 +12,7 @@ LL |     a.f();
    |       ^ method cannot be called on `S` due to unsatisfied trait bounds
    |
 note: trait bound `<S as X>::Y<i32> = i32` was not satisfied
-  --> $DIR/method-unsatified-assoc-type-predicate.rs:12:11
+  --> $DIR/method-unsatisfied-assoc-type-predicate.rs:12:11
    |
 LL | impl<T: X<Y<i32> = i32>> M for T {}
    |           ^^^^^^^^^^^^   -     -
diff --git a/tests/ui/generic-associated-types/missing_lifetime_args.rs b/tests/ui/generic-associated-types/missing_lifetime_args.rs
index 78def80925a..331511ba61a 100644
--- a/tests/ui/generic-associated-types/missing_lifetime_args.rs
+++ b/tests/ui/generic-associated-types/missing_lifetime_args.rs
@@ -12,9 +12,9 @@ fn foo<'c, 'd>(_arg: Box<dyn X<Y = (&'c u32, &'d u32)>>) {}
 //~^ ERROR missing generics for associated type
 
 fn bar<'a, 'b, 'c>(_arg: Foo<'a, 'b>) {}
-//~^ ERROR this struct takes 3 lifetime arguments but 2 lifetime
+//~^ ERROR struct takes 3 lifetime arguments but 2 lifetime
 
 fn f<'a>(_arg: Foo<'a>) {}
-//~^ ERROR this struct takes 3 lifetime arguments but 1 lifetime
+//~^ ERROR struct takes 3 lifetime arguments but 1 lifetime
 
 fn main() {}
diff --git a/tests/ui/generic-associated-types/missing_lifetime_args.stderr b/tests/ui/generic-associated-types/missing_lifetime_args.stderr
index 8f74b12c008..1a7a2e787a1 100644
--- a/tests/ui/generic-associated-types/missing_lifetime_args.stderr
+++ b/tests/ui/generic-associated-types/missing_lifetime_args.stderr
@@ -14,7 +14,7 @@ help: add missing lifetime arguments
 LL | fn foo<'c, 'd>(_arg: Box<dyn X<Y<'_, '_> = (&'c u32, &'d u32)>>) {}
    |                                 ++++++++
 
-error[E0107]: this struct takes 3 lifetime arguments but 2 lifetime arguments were supplied
+error[E0107]: struct takes 3 lifetime arguments but 2 lifetime arguments were supplied
   --> $DIR/missing_lifetime_args.rs:14:26
    |
 LL | fn bar<'a, 'b, 'c>(_arg: Foo<'a, 'b>) {}
@@ -32,7 +32,7 @@ help: add missing lifetime argument
 LL | fn bar<'a, 'b, 'c>(_arg: Foo<'a, 'b, 'a>) {}
    |                                    ++++
 
-error[E0107]: this struct takes 3 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: struct takes 3 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/missing_lifetime_args.rs:17:16
    |
 LL | fn f<'a>(_arg: Foo<'a>) {}
diff --git a/tests/ui/generic-associated-types/missing_lifetime_const.rs b/tests/ui/generic-associated-types/missing_lifetime_const.rs
index 8b174b9e971..6e395dfdec1 100644
--- a/tests/ui/generic-associated-types/missing_lifetime_const.rs
+++ b/tests/ui/generic-associated-types/missing_lifetime_const.rs
@@ -4,7 +4,7 @@ trait Foo {
 
 fn foo<T: Foo>() {
     let _: <T as Foo>::Assoc<3>;
-      //~^ ERROR  this associated type
+      //~^ ERROR  associated type
 }
 
 fn main() {}
diff --git a/tests/ui/generic-associated-types/missing_lifetime_const.stderr b/tests/ui/generic-associated-types/missing_lifetime_const.stderr
index 62d2e9f49dd..41945aabfb5 100644
--- a/tests/ui/generic-associated-types/missing_lifetime_const.stderr
+++ b/tests/ui/generic-associated-types/missing_lifetime_const.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this associated type takes 1 lifetime argument but 0 lifetime arguments were supplied
+error[E0107]: associated type takes 1 lifetime argument but 0 lifetime arguments were supplied
   --> $DIR/missing_lifetime_const.rs:6:24
    |
 LL |     let _: <T as Foo>::Assoc<3>;
diff --git a/tests/ui/generic-associated-types/parameter_number_and_kind.rs b/tests/ui/generic-associated-types/parameter_number_and_kind.rs
index 8428e7763fb..ae2f7c00ea4 100644
--- a/tests/ui/generic-associated-types/parameter_number_and_kind.rs
+++ b/tests/ui/generic-associated-types/parameter_number_and_kind.rs
@@ -9,10 +9,10 @@ trait Foo {
     // Test parameters in default values
     type FOk<T> = Self::E<'static, T>;
     type FErr1 = Self::E<'static, 'static>;
-    //~^ ERROR this associated type takes 1 lifetime argument but 2 lifetime arguments were supplied
-    //~| ERROR this associated type takes 1
+    //~^ ERROR associated type takes 1 lifetime argument but 2 lifetime arguments were supplied
+    //~| ERROR associated type takes 1
     type FErr2<T> = Self::E<'static, T, u32>;
-    //~^ ERROR this associated type takes 1
+    //~^ ERROR associated type takes 1
 }
 
 fn main() {}
diff --git a/tests/ui/generic-associated-types/parameter_number_and_kind.stderr b/tests/ui/generic-associated-types/parameter_number_and_kind.stderr
index c20b9669e81..4523044b588 100644
--- a/tests/ui/generic-associated-types/parameter_number_and_kind.stderr
+++ b/tests/ui/generic-associated-types/parameter_number_and_kind.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this associated type takes 1 lifetime argument but 2 lifetime arguments were supplied
+error[E0107]: associated type takes 1 lifetime argument but 2 lifetime arguments were supplied
   --> $DIR/parameter_number_and_kind.rs:11:24
    |
 LL |     type FErr1 = Self::E<'static, 'static>;
@@ -12,7 +12,7 @@ note: associated type defined here, with 1 lifetime parameter: `'a`
 LL |     type E<'a, T>;
    |          ^ --
 
-error[E0107]: this associated type takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: associated type takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/parameter_number_and_kind.rs:11:24
    |
 LL |     type FErr1 = Self::E<'static, 'static>;
@@ -28,7 +28,7 @@ help: add missing generic argument
 LL |     type FErr1 = Self::E<'static, 'static, T>;
    |                                          +++
 
-error[E0107]: this associated type takes 1 generic argument but 2 generic arguments were supplied
+error[E0107]: associated type takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/parameter_number_and_kind.rs:14:27
    |
 LL |     type FErr2<T> = Self::E<'static, T, u32>;
diff --git a/tests/ui/generic-associated-types/parse/trait-path-type-error-once-implemented.rs b/tests/ui/generic-associated-types/parse/trait-path-type-error-once-implemented.rs
index 1622b92aa0c..c58f9cf1dfc 100644
--- a/tests/ui/generic-associated-types/parse/trait-path-type-error-once-implemented.rs
+++ b/tests/ui/generic-associated-types/parse/trait-path-type-error-once-implemented.rs
@@ -4,8 +4,8 @@ trait X {
 
 const _: () = {
   fn f2<'a>(arg : Box<dyn X<Y<1> = &'a ()>>) {}
-      //~^ ERROR this associated type takes 1 lifetime argument but 0 lifetime arguments
-      //~| ERROR this associated type takes 0 generic arguments but 1 generic argument
+      //~^ ERROR associated type takes 1 lifetime argument but 0 lifetime arguments
+      //~| ERROR associated type takes 0 generic arguments but 1 generic argument
 };
 
 fn main() {}
diff --git a/tests/ui/generic-associated-types/parse/trait-path-type-error-once-implemented.stderr b/tests/ui/generic-associated-types/parse/trait-path-type-error-once-implemented.stderr
index 0a09ec5dc49..fab5b474d92 100644
--- a/tests/ui/generic-associated-types/parse/trait-path-type-error-once-implemented.stderr
+++ b/tests/ui/generic-associated-types/parse/trait-path-type-error-once-implemented.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this associated type takes 1 lifetime argument but 0 lifetime arguments were supplied
+error[E0107]: associated type takes 1 lifetime argument but 0 lifetime arguments were supplied
   --> $DIR/trait-path-type-error-once-implemented.rs:6:29
    |
 LL |   fn f2<'a>(arg : Box<dyn X<Y<1> = &'a ()>>) {}
@@ -14,7 +14,7 @@ help: add missing lifetime argument
 LL |   fn f2<'a>(arg : Box<dyn X<Y<'_, 1> = &'a ()>>) {}
    |                               +++
 
-error[E0107]: this associated type takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: associated type takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/trait-path-type-error-once-implemented.rs:6:29
    |
 LL |   fn f2<'a>(arg : Box<dyn X<Y<1> = &'a ()>>) {}
diff --git a/tests/ui/generic-associated-types/unsatified-item-lifetime-bound.rs b/tests/ui/generic-associated-types/unsatisfied-item-lifetime-bound.rs
index 1cc09aa6dd4..060ee8821d8 100644
--- a/tests/ui/generic-associated-types/unsatified-item-lifetime-bound.rs
+++ b/tests/ui/generic-associated-types/unsatisfied-item-lifetime-bound.rs
@@ -1,3 +1,5 @@
+#![warn(unused_lifetimes)]
+
 pub trait X {
     type Y<'a: 'static>;
     //~^ WARNING unnecessary lifetime parameter
diff --git a/tests/ui/generic-associated-types/unsatified-item-lifetime-bound.stderr b/tests/ui/generic-associated-types/unsatisfied-item-lifetime-bound.stderr
index fbd79879d0f..a69cd0028c1 100644
--- a/tests/ui/generic-associated-types/unsatified-item-lifetime-bound.stderr
+++ b/tests/ui/generic-associated-types/unsatisfied-item-lifetime-bound.stderr
@@ -1,45 +1,50 @@
 warning: unnecessary lifetime parameter `'a`
-  --> $DIR/unsatified-item-lifetime-bound.rs:2:12
+  --> $DIR/unsatisfied-item-lifetime-bound.rs:4:12
    |
 LL |     type Y<'a: 'static>;
    |            ^^
    |
    = help: you can use the `'static` lifetime directly, in place of `'a`
+note: the lint level is defined here
+  --> $DIR/unsatisfied-item-lifetime-bound.rs:1:9
+   |
+LL | #![warn(unused_lifetimes)]
+   |         ^^^^^^^^^^^^^^^^
 
 error[E0478]: lifetime bound not satisfied
-  --> $DIR/unsatified-item-lifetime-bound.rs:11:8
+  --> $DIR/unsatisfied-item-lifetime-bound.rs:13:8
    |
 LL |     f: <T as X>::Y<'a>,
    |        ^^^^^^^^^^^^^^^
    |
 note: lifetime parameter instantiated with the lifetime `'a` as defined here
-  --> $DIR/unsatified-item-lifetime-bound.rs:10:10
+  --> $DIR/unsatisfied-item-lifetime-bound.rs:12:10
    |
 LL | struct B<'a, T: for<'r> X<Y<'r> = &'r ()>> {
    |          ^^
    = note: but lifetime parameter must outlive the static lifetime
 
 error[E0478]: lifetime bound not satisfied
-  --> $DIR/unsatified-item-lifetime-bound.rs:16:8
+  --> $DIR/unsatisfied-item-lifetime-bound.rs:18:8
    |
 LL |     f: <T as X>::Y<'a>,
    |        ^^^^^^^^^^^^^^^
    |
 note: lifetime parameter instantiated with the lifetime `'a` as defined here
-  --> $DIR/unsatified-item-lifetime-bound.rs:15:10
+  --> $DIR/unsatisfied-item-lifetime-bound.rs:17:10
    |
 LL | struct C<'a, T: X> {
    |          ^^
    = note: but lifetime parameter must outlive the static lifetime
 
 error[E0478]: lifetime bound not satisfied
-  --> $DIR/unsatified-item-lifetime-bound.rs:21:8
+  --> $DIR/unsatisfied-item-lifetime-bound.rs:23:8
    |
 LL |     f: <() as X>::Y<'a>,
    |        ^^^^^^^^^^^^^^^^
    |
 note: lifetime parameter instantiated with the lifetime `'a` as defined here
-  --> $DIR/unsatified-item-lifetime-bound.rs:20:10
+  --> $DIR/unsatisfied-item-lifetime-bound.rs:22:10
    |
 LL | struct D<'a> {
    |          ^^
diff --git a/tests/ui/generics/bad-mid-path-type-params.rs b/tests/ui/generics/bad-mid-path-type-params.rs
index 23a5d1525d9..37d484cba0b 100644
--- a/tests/ui/generics/bad-mid-path-type-params.rs
+++ b/tests/ui/generics/bad-mid-path-type-params.rs
@@ -28,17 +28,17 @@ impl Trait<isize> for S2 {
 
 fn foo<'a>() {
     let _ = S::new::<isize,f64>(1, 1.0);
-    //~^ ERROR this associated function takes 1
+    //~^ ERROR associated function takes 1
 
     let _ = S::<'a,isize>::new::<f64>(1, 1.0);
-    //~^ ERROR this struct takes 0 lifetime arguments but 1 lifetime argument was supplied
+    //~^ ERROR struct takes 0 lifetime arguments but 1 lifetime argument was supplied
 
     let _: S2 = Trait::new::<isize,f64>(1, 1.0);
-    //~^ ERROR this associated function takes 1
+    //~^ ERROR associated function takes 1
 
     let _: S2 = Trait::<'a,isize>::new::<f64,f64>(1, 1.0);
-    //~^ ERROR this trait takes 0 lifetime arguments but 1 lifetime argument was supplied
-    //~| ERROR this associated function takes 1
+    //~^ ERROR trait takes 0 lifetime arguments but 1 lifetime argument was supplied
+    //~| ERROR associated function takes 1
 }
 
 fn main() {}
diff --git a/tests/ui/generics/bad-mid-path-type-params.stderr b/tests/ui/generics/bad-mid-path-type-params.stderr
index aee2b60159f..71e15dd4c92 100644
--- a/tests/ui/generics/bad-mid-path-type-params.stderr
+++ b/tests/ui/generics/bad-mid-path-type-params.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this associated function takes 1 generic argument but 2 generic arguments were supplied
+error[E0107]: associated function takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/bad-mid-path-type-params.rs:30:16
    |
 LL |     let _ = S::new::<isize,f64>(1, 1.0);
@@ -12,7 +12,7 @@ note: associated function defined here, with 1 generic parameter: `U`
 LL |     fn new<U>(x: T, _: U) -> S<T> {
    |        ^^^ -
 
-error[E0107]: this struct takes 0 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: struct takes 0 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/bad-mid-path-type-params.rs:33:13
    |
 LL |     let _ = S::<'a,isize>::new::<f64>(1, 1.0);
@@ -26,7 +26,7 @@ note: struct defined here, with 0 lifetime parameters
 LL | struct S<T> {
    |        ^
 
-error[E0107]: this associated function takes 1 generic argument but 2 generic arguments were supplied
+error[E0107]: associated function takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/bad-mid-path-type-params.rs:36:24
    |
 LL |     let _: S2 = Trait::new::<isize,f64>(1, 1.0);
@@ -40,7 +40,7 @@ note: associated function defined here, with 1 generic parameter: `U`
 LL |     fn new<U>(x: T, y: U) -> Self;
    |        ^^^ -
 
-error[E0107]: this trait takes 0 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: trait takes 0 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/bad-mid-path-type-params.rs:39:17
    |
 LL |     let _: S2 = Trait::<'a,isize>::new::<f64,f64>(1, 1.0);
@@ -54,7 +54,7 @@ note: trait defined here, with 0 lifetime parameters
 LL | trait Trait<T> {
    |       ^^^^^
 
-error[E0107]: this associated function takes 1 generic argument but 2 generic arguments were supplied
+error[E0107]: associated function takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/bad-mid-path-type-params.rs:39:36
    |
 LL |     let _: S2 = Trait::<'a,isize>::new::<f64,f64>(1, 1.0);
diff --git a/tests/ui/generics/generic-arg-mismatch-recover.rs b/tests/ui/generics/generic-arg-mismatch-recover.rs
index 2cf7f1d657b..947f33414db 100644
--- a/tests/ui/generics/generic-arg-mismatch-recover.rs
+++ b/tests/ui/generics/generic-arg-mismatch-recover.rs
@@ -4,9 +4,9 @@ struct Bar<'a>(&'a ());
 
 fn main() {
     Foo::<'static, 'static, ()>(&0);
-    //~^ ERROR this struct takes 1 lifetime argument but 2 lifetime arguments were supplied
+    //~^ ERROR struct takes 1 lifetime argument but 2 lifetime arguments were supplied
 
     Bar::<'static, 'static, ()>(&());
-    //~^ ERROR this struct takes 1 lifetime argument but 2 lifetime arguments were supplied
-    //~| ERROR this struct takes 0
+    //~^ ERROR struct takes 1 lifetime argument but 2 lifetime arguments were supplied
+    //~| ERROR struct takes 0
 }
diff --git a/tests/ui/generics/generic-arg-mismatch-recover.stderr b/tests/ui/generics/generic-arg-mismatch-recover.stderr
index 45fea925f27..f549a7180fc 100644
--- a/tests/ui/generics/generic-arg-mismatch-recover.stderr
+++ b/tests/ui/generics/generic-arg-mismatch-recover.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this struct takes 1 lifetime argument but 2 lifetime arguments were supplied
+error[E0107]: struct takes 1 lifetime argument but 2 lifetime arguments were supplied
   --> $DIR/generic-arg-mismatch-recover.rs:6:5
    |
 LL |     Foo::<'static, 'static, ()>(&0);
@@ -12,7 +12,7 @@ note: struct defined here, with 1 lifetime parameter: `'a`
 LL | struct Foo<'a, T: 'a>(&'a T);
    |        ^^^ --
 
-error[E0107]: this struct takes 1 lifetime argument but 2 lifetime arguments were supplied
+error[E0107]: struct takes 1 lifetime argument but 2 lifetime arguments were supplied
   --> $DIR/generic-arg-mismatch-recover.rs:9:5
    |
 LL |     Bar::<'static, 'static, ()>(&());
@@ -26,7 +26,7 @@ note: struct defined here, with 1 lifetime parameter: `'a`
 LL | struct Bar<'a>(&'a ());
    |        ^^^ --
 
-error[E0107]: this struct takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: struct takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/generic-arg-mismatch-recover.rs:9:5
    |
 LL |     Bar::<'static, 'static, ()>(&());
diff --git a/tests/ui/generics/generic-impl-less-params-with-defaults.rs b/tests/ui/generics/generic-impl-less-params-with-defaults.rs
index 66afbb58ad4..6c00411561e 100644
--- a/tests/ui/generics/generic-impl-less-params-with-defaults.rs
+++ b/tests/ui/generics/generic-impl-less-params-with-defaults.rs
@@ -9,5 +9,5 @@ impl<A, B, C> Foo<A, B, C> {
 
 fn main() {
     Foo::<isize>::new();
-    //~^ ERROR this struct takes at least 2 generic arguments but 1 generic argument
+    //~^ ERROR struct takes at least 2 generic arguments but 1 generic argument
 }
diff --git a/tests/ui/generics/generic-impl-less-params-with-defaults.stderr b/tests/ui/generics/generic-impl-less-params-with-defaults.stderr
index cdbb57902e4..262561fa81e 100644
--- a/tests/ui/generics/generic-impl-less-params-with-defaults.stderr
+++ b/tests/ui/generics/generic-impl-less-params-with-defaults.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this struct takes at least 2 generic arguments but 1 generic argument was supplied
+error[E0107]: struct takes at least 2 generic arguments but 1 generic argument was supplied
   --> $DIR/generic-impl-less-params-with-defaults.rs:11:5
    |
 LL |     Foo::<isize>::new();
diff --git a/tests/ui/generics/generic-impl-more-params-with-defaults.rs b/tests/ui/generics/generic-impl-more-params-with-defaults.rs
index a283323742a..be633ec464f 100644
--- a/tests/ui/generics/generic-impl-more-params-with-defaults.rs
+++ b/tests/ui/generics/generic-impl-more-params-with-defaults.rs
@@ -11,5 +11,5 @@ impl<T, A> Vec<T, A> {
 
 fn main() {
     Vec::<isize, Heap, bool>::new();
-    //~^ ERROR this struct takes at most 2 generic arguments but 3 generic arguments were supplied
+    //~^ ERROR struct takes at most 2 generic arguments but 3 generic arguments were supplied
 }
diff --git a/tests/ui/generics/generic-impl-more-params-with-defaults.stderr b/tests/ui/generics/generic-impl-more-params-with-defaults.stderr
index fe9b670da79..2f4682c4e5a 100644
--- a/tests/ui/generics/generic-impl-more-params-with-defaults.stderr
+++ b/tests/ui/generics/generic-impl-more-params-with-defaults.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this struct takes at most 2 generic arguments but 3 generic arguments were supplied
+error[E0107]: struct takes at most 2 generic arguments but 3 generic arguments were supplied
   --> $DIR/generic-impl-more-params-with-defaults.rs:13:5
    |
 LL |     Vec::<isize, Heap, bool>::new();
diff --git a/tests/ui/generics/generic-type-more-params-with-defaults.rs b/tests/ui/generics/generic-type-more-params-with-defaults.rs
index 3dab03297c9..b83fdb5c455 100644
--- a/tests/ui/generics/generic-type-more-params-with-defaults.rs
+++ b/tests/ui/generics/generic-type-more-params-with-defaults.rs
@@ -7,5 +7,5 @@ struct Vec<T, A = Heap>(
 
 fn main() {
     let _: Vec<isize, Heap, bool>;
-    //~^ ERROR this struct takes at most 2 generic arguments but 3 generic arguments
+    //~^ ERROR struct takes at most 2 generic arguments but 3 generic arguments
 }
diff --git a/tests/ui/generics/generic-type-more-params-with-defaults.stderr b/tests/ui/generics/generic-type-more-params-with-defaults.stderr
index 7f0198f0e84..4d01ba1f453 100644
--- a/tests/ui/generics/generic-type-more-params-with-defaults.stderr
+++ b/tests/ui/generics/generic-type-more-params-with-defaults.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this struct takes at most 2 generic arguments but 3 generic arguments were supplied
+error[E0107]: struct takes at most 2 generic arguments but 3 generic arguments were supplied
   --> $DIR/generic-type-more-params-with-defaults.rs:9:12
    |
 LL |     let _: Vec<isize, Heap, bool>;
diff --git a/tests/ui/generics/wrong-number-of-args.rs b/tests/ui/generics/wrong-number-of-args.rs
index cd2f96a1819..e4eaff21af1 100644
--- a/tests/ui/generics/wrong-number-of-args.rs
+++ b/tests/ui/generics/wrong-number-of-args.rs
@@ -4,18 +4,18 @@ mod no_generics {
     type A = Ty;
 
     type B = Ty<'static>;
-    //~^ ERROR this struct takes 0 lifetime arguments but 1 lifetime argument
+    //~^ ERROR struct takes 0 lifetime arguments but 1 lifetime argument
     //~| HELP remove these generics
 
     type C = Ty<'static, usize>;
-    //~^ ERROR this struct takes 0 lifetime arguments but 1 lifetime argument
-    //~| ERROR this struct takes 0 generic arguments but 1 generic argument
+    //~^ ERROR struct takes 0 lifetime arguments but 1 lifetime argument
+    //~| ERROR struct takes 0 generic arguments but 1 generic argument
     //~| HELP remove this lifetime argument
     //~| HELP remove this generic argument
 
     type D = Ty<'static, usize, { 0 }>;
-    //~^ ERROR this struct takes 0 lifetime arguments but 1 lifetime argument
-    //~| ERROR this struct takes 0 generic arguments but 2 generic arguments
+    //~^ ERROR struct takes 0 lifetime arguments but 1 lifetime argument
+    //~| ERROR struct takes 0 generic arguments but 2 generic arguments
     //~| HELP remove this lifetime argument
     //~| HELP remove these generic arguments
 }
@@ -28,17 +28,17 @@ mod type_and_type {
     //~| HELP add missing
 
     type B = Ty<usize>;
-    //~^ ERROR this struct takes 2 generic arguments but 1 generic argument
+    //~^ ERROR struct takes 2 generic arguments but 1 generic argument
     //~| HELP add missing
 
     type C = Ty<usize, String>;
 
     type D = Ty<usize, String, char>;
-    //~^ ERROR this struct takes 2 generic arguments but 3 generic arguments
+    //~^ ERROR struct takes 2 generic arguments but 3 generic arguments
     //~| HELP remove this
 
     type E = Ty<>;
-    //~^ ERROR this struct takes 2 generic arguments but 0 generic arguments were supplied
+    //~^ ERROR struct takes 2 generic arguments but 0 generic arguments were supplied
     //~| HELP add missing
 }
 
@@ -52,7 +52,7 @@ mod lifetime_and_type {
     //~| HELP consider introducing
 
     type B = Ty<'static>;
-    //~^ ERROR this struct takes 1 generic argument but 0 generic arguments
+    //~^ ERROR struct takes 1 generic argument but 0 generic arguments
     //~| HELP add missing
 
     type C = Ty<usize>;
@@ -62,14 +62,14 @@ mod lifetime_and_type {
     type D = Ty<'static, usize>;
 
     type E = Ty<>;
-    //~^ ERROR this struct takes 1 generic argument but 0 generic arguments
+    //~^ ERROR struct takes 1 generic argument but 0 generic arguments
     //~| ERROR missing lifetime specifier
     //~| HELP consider introducing
     //~| HELP add missing
 
     type F = Ty<'static, usize, 'static, usize>;
-    //~^ ERROR this struct takes 1 lifetime argument but 2 lifetime arguments
-    //~| ERROR this struct takes 1 generic argument but 2 generic arguments
+    //~^ ERROR struct takes 1 lifetime argument but 2 lifetime arguments
+    //~| ERROR struct takes 1 generic argument but 2 generic arguments
     //~| HELP remove this lifetime argument
     //~| HELP remove this generic argument
 }
@@ -82,7 +82,7 @@ mod type_and_type_and_type {
     //~| HELP add missing
 
     type B = Ty<usize>;
-    //~^ ERROR this struct takes at least 2
+    //~^ ERROR struct takes at least 2
     //~| HELP add missing
 
     type C = Ty<usize, String>;
@@ -90,11 +90,11 @@ mod type_and_type_and_type {
     type D = Ty<usize, String, char>;
 
     type E = Ty<usize, String, char, f64>;
-    //~^ ERROR this struct takes at most 3
+    //~^ ERROR struct takes at most 3
     //~| HELP remove
 
     type F = Ty<>;
-    //~^ ERROR this struct takes at least 2 generic arguments but 0 generic arguments
+    //~^ ERROR struct takes at least 2 generic arguments but 0 generic arguments
     //~| HELP add missing
 }
 
@@ -114,7 +114,7 @@ mod r#trait {
     }
 
     type A = Box<dyn NonGeneric<usize>>;
-    //~^ ERROR this trait takes 0 generic arguments but 1 generic argument
+    //~^ ERROR trait takes 0 generic arguments but 1 generic argument
     //~| HELP remove
 
     type B = Box<dyn GenericLifetime>;
@@ -123,7 +123,7 @@ mod r#trait {
     //~| HELP consider making the bound lifetime-generic
 
     type C = Box<dyn GenericLifetime<'static, 'static>>;
-    //~^ ERROR this trait takes 1 lifetime argument but 2 lifetime arguments were supplied
+    //~^ ERROR trait takes 1 lifetime argument but 2 lifetime arguments were supplied
     //~| HELP remove
 
     type D = Box<dyn GenericType>;
@@ -131,7 +131,7 @@ mod r#trait {
     //~| HELP add missing
 
     type E = Box<dyn GenericType<String, usize>>;
-    //~^ ERROR this trait takes 1 generic argument but 2 generic arguments
+    //~^ ERROR trait takes 1 generic argument but 2 generic arguments
     //~| HELP remove
 
     type F = Box<dyn GenericLifetime<>>;
@@ -140,7 +140,7 @@ mod r#trait {
     //~| HELP consider making the bound lifetime-generic
 
     type G = Box<dyn GenericType<>>;
-    //~^ ERROR this trait takes 1 generic argument but 0 generic arguments
+    //~^ ERROR trait takes 1 generic argument but 0 generic arguments
     //~| HELP add missing
 }
 
@@ -151,7 +151,7 @@ mod associated_item {
         }
 
         type A = Box<dyn NonGenericAT<usize, AssocTy=()>>;
-        //~^ ERROR this trait takes 0 generic arguments but 1 generic argument
+        //~^ ERROR trait takes 0 generic arguments but 1 generic argument
         //~| HELP remove
     }
 
@@ -166,14 +166,14 @@ mod associated_item {
         //~| HELP consider making the bound lifetime-generic
 
         type B = Box<dyn GenericLifetimeAT<'static, 'static, AssocTy=()>>;
-        //~^ ERROR this trait takes 1 lifetime argument but 2 lifetime arguments were supplied
+        //~^ ERROR trait takes 1 lifetime argument but 2 lifetime arguments were supplied
         //~| HELP remove
 
         type C = Box<dyn GenericLifetimeAT<(), AssocTy=()>>;
         //~^ ERROR missing lifetime specifier
         //~| HELP consider introducing
         //~| HELP consider making the bound lifetime-generic
-        //~| ERROR this trait takes 0 generic arguments but 1 generic argument
+        //~| ERROR trait takes 0 generic arguments but 1 generic argument
         //~| HELP remove
     }
 
@@ -183,17 +183,17 @@ mod associated_item {
         }
 
         type A = Box<dyn GenericTypeAT<AssocTy=()>>;
-        //~^ ERROR this trait takes 1 generic argument but 0 generic arguments
+        //~^ ERROR trait takes 1 generic argument but 0 generic arguments
         //~| HELP add missing
 
         type B = Box<dyn GenericTypeAT<(), (), AssocTy=()>>;
-        //~^ ERROR this trait takes 1 generic argument but 2 generic arguments
+        //~^ ERROR trait takes 1 generic argument but 2 generic arguments
         //~| HELP remove
 
         type C = Box<dyn GenericTypeAT<'static, AssocTy=()>>;
-        //~^ ERROR this trait takes 1 generic argument but 0 generic arguments
+        //~^ ERROR trait takes 1 generic argument but 0 generic arguments
         //~| HELP add missing
-        //~| ERROR this trait takes 0 lifetime arguments but 1 lifetime argument was supplied
+        //~| ERROR trait takes 0 lifetime arguments but 1 lifetime argument was supplied
         //~| HELP remove
     }
 
@@ -203,20 +203,20 @@ mod associated_item {
         }
 
         type A = Box<dyn GenericLifetimeTypeAT<AssocTy=()>>;
-        //~^ ERROR this trait takes 1 generic argument but 0 generic arguments
+        //~^ ERROR trait takes 1 generic argument but 0 generic arguments
         //~| HELP add missing
         //~| ERROR missing lifetime specifier
         //~| HELP consider introducing
         //~| HELP consider making the bound lifetime-generic
 
         type B = Box<dyn GenericLifetimeTypeAT<'static, AssocTy=()>>;
-        //~^ ERROR this trait takes 1 generic argument but 0 generic arguments were supplied
+        //~^ ERROR trait takes 1 generic argument but 0 generic arguments were supplied
         //~| HELP add missing
 
         type C = Box<dyn GenericLifetimeTypeAT<'static, 'static, AssocTy=()>>;
-        //~^ ERROR this trait takes 1 lifetime argument but 2 lifetime arguments were supplied
+        //~^ ERROR trait takes 1 lifetime argument but 2 lifetime arguments were supplied
         //~| HELP remove
-        //~| ERROR this trait takes 1 generic argument but 0 generic arguments
+        //~| ERROR trait takes 1 generic argument but 0 generic arguments
         //~| HELP add missing
 
         type D = Box<dyn GenericLifetimeTypeAT<(), AssocTy=()>>;
@@ -228,21 +228,21 @@ mod associated_item {
         //~^ ERROR missing lifetime specifier
         //~| HELP consider introducing
         //~| HELP consider making the bound lifetime-generic
-        //~| ERROR this trait takes 1 generic argument but 2 generic arguments
+        //~| ERROR trait takes 1 generic argument but 2 generic arguments
         //~| HELP remove
 
         type F = Box<dyn GenericLifetimeTypeAT<'static, 'static, (), AssocTy=()>>;
-        //~^ ERROR this trait takes 1 lifetime argument but 2 lifetime arguments were supplied
+        //~^ ERROR trait takes 1 lifetime argument but 2 lifetime arguments were supplied
         //~| HELP remove
 
         type G = Box<dyn GenericLifetimeTypeAT<'static, (), (), AssocTy=()>>;
-        //~^ ERROR this trait takes 1 generic argument but 2 generic arguments
+        //~^ ERROR trait takes 1 generic argument but 2 generic arguments
         //~| HELP remove
 
         type H = Box<dyn GenericLifetimeTypeAT<'static, 'static, (), (), AssocTy=()>>;
-        //~^ ERROR this trait takes 1 lifetime argument but 2 lifetime arguments were supplied
+        //~^ ERROR trait takes 1 lifetime argument but 2 lifetime arguments were supplied
         //~| HELP remove
-        //~| ERROR this trait takes 1 generic argument but 2 generic arguments
+        //~| ERROR trait takes 1 generic argument but 2 generic arguments
         //~| HELP remove
     }
 
@@ -252,15 +252,15 @@ mod associated_item {
         }
 
         type A = Box<dyn GenericTypeTypeAT<AssocTy=()>>;
-        //~^ ERROR this trait takes 2 generic arguments but 0 generic arguments
+        //~^ ERROR trait takes 2 generic arguments but 0 generic arguments
         //~| HELP add missing
 
         type B = Box<dyn GenericTypeTypeAT<(), AssocTy=()>>;
-        //~^ ERROR this trait takes 2 generic arguments but 1 generic argument
+        //~^ ERROR trait takes 2 generic arguments but 1 generic argument
         //~| HELP add missing
 
         type C = Box<dyn GenericTypeTypeAT<(), (), (), AssocTy=()>>;
-        //~^ ERROR this trait takes 2 generic arguments but 3 generic arguments
+        //~^ ERROR trait takes 2 generic arguments but 3 generic arguments
         //~| HELP remove
     }
 
@@ -275,7 +275,7 @@ mod associated_item {
         //~| HELP consider making the bound lifetime-generic
 
         type B = Box<dyn GenericLifetimeLifetimeAT<'static, AssocTy=()>>;
-        //~^ ERROR this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
+        //~^ ERROR trait takes 2 lifetime arguments but 1 lifetime argument was supplied
         //~| HELP add missing lifetime argument
     }
 
@@ -288,17 +288,17 @@ mod associated_item {
         //~^ ERROR missing lifetime specifier
         //~| HELP consider introducing
         //~| HELP consider making the bound lifetime-generic
-        //~| ERROR this trait takes 1 generic argument but 0 generic arguments
+        //~| ERROR trait takes 1 generic argument but 0 generic arguments
         //~| HELP add missing
 
         type B = Box<dyn GenericLifetimeLifetimeTypeAT<'static, AssocTy=()>>;
-        //~^ ERROR this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
+        //~^ ERROR trait takes 2 lifetime arguments but 1 lifetime argument was supplied
         //~| HELP add missing lifetime argument
-        //~| ERROR this trait takes 1 generic argument but 0 generic arguments
+        //~| ERROR trait takes 1 generic argument but 0 generic arguments
         //~| HELP add missing
 
         type C = Box<dyn GenericLifetimeLifetimeTypeAT<'static, (), AssocTy=()>>;
-        //~^ ERROR this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
+        //~^ ERROR trait takes 2 lifetime arguments but 1 lifetime argument was supplied
         //~| HELP add missing lifetime argument
     }
 }
@@ -312,21 +312,21 @@ mod stdlib {
         //~| HELP add missing
 
         type B = HashMap<String>;
-        //~^ ERROR this struct takes at least
+        //~^ ERROR struct takes at least
         //~| HELP add missing
 
         type C = HashMap<'static>;
-        //~^ ERROR this struct takes 0 lifetime arguments but 1 lifetime argument
+        //~^ ERROR struct takes 0 lifetime arguments but 1 lifetime argument
         //~| HELP remove these generics
-        //~| ERROR this struct takes at least 2
+        //~| ERROR struct takes at least 2
         //~| HELP add missing
 
         type D = HashMap<usize, String, char, f64>;
-        //~^ ERROR this struct takes at most 3
+        //~^ ERROR struct takes at most 3
         //~| HELP remove this
 
         type E = HashMap<>;
-        //~^ ERROR this struct takes at least 2 generic arguments but 0 generic arguments
+        //~^ ERROR struct takes at least 2 generic arguments but 0 generic arguments
         //~| HELP add missing
     }
 
@@ -336,21 +336,21 @@ mod stdlib {
         //~| HELP add missing
 
         type B = Result<String>;
-        //~^ ERROR this enum takes 2 generic arguments but 1 generic argument
+        //~^ ERROR enum takes 2 generic arguments but 1 generic argument
         //~| HELP add missing
 
         type C = Result<'static>;
-        //~^ ERROR this enum takes 0 lifetime arguments but 1 lifetime argument
+        //~^ ERROR enum takes 0 lifetime arguments but 1 lifetime argument
         //~| HELP remove these generics
-        //~| ERROR this enum takes 2 generic arguments but 0 generic arguments
+        //~| ERROR enum takes 2 generic arguments but 0 generic arguments
         //~| HELP add missing
 
         type D = Result<usize, String, char>;
-        //~^ ERROR this enum takes 2 generic arguments but 3 generic arguments
+        //~^ ERROR enum takes 2 generic arguments but 3 generic arguments
         //~| HELP remove
 
         type E = Result<>;
-        //~^ ERROR this enum takes 2 generic arguments but 0 generic arguments
+        //~^ ERROR enum takes 2 generic arguments but 0 generic arguments
         //~| HELP add missing
     }
 }
diff --git a/tests/ui/generics/wrong-number-of-args.stderr b/tests/ui/generics/wrong-number-of-args.stderr
index 75e33f680ea..9006fb10b67 100644
--- a/tests/ui/generics/wrong-number-of-args.stderr
+++ b/tests/ui/generics/wrong-number-of-args.stderr
@@ -167,7 +167,7 @@ help: consider introducing a named lifetime parameter
 LL |         type A<'a> = Box<dyn GenericLifetimeLifetimeTypeAT<'a, 'a, AssocTy=()>>;
    |               ++++                                         +++++++
 
-error[E0107]: this struct takes 0 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: struct takes 0 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/wrong-number-of-args.rs:6:14
    |
 LL |     type B = Ty<'static>;
@@ -181,7 +181,7 @@ note: struct defined here, with 0 lifetime parameters
 LL |     struct Ty;
    |            ^^
 
-error[E0107]: this struct takes 0 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: struct takes 0 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/wrong-number-of-args.rs:10:14
    |
 LL |     type C = Ty<'static, usize>;
@@ -195,7 +195,7 @@ note: struct defined here, with 0 lifetime parameters
 LL |     struct Ty;
    |            ^^
 
-error[E0107]: this struct takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: struct takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/wrong-number-of-args.rs:10:14
    |
 LL |     type C = Ty<'static, usize>;
@@ -209,7 +209,7 @@ note: struct defined here, with 0 generic parameters
 LL |     struct Ty;
    |            ^^
 
-error[E0107]: this struct takes 0 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: struct takes 0 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/wrong-number-of-args.rs:16:14
    |
 LL |     type D = Ty<'static, usize, { 0 }>;
@@ -223,7 +223,7 @@ note: struct defined here, with 0 lifetime parameters
 LL |     struct Ty;
    |            ^^
 
-error[E0107]: this struct takes 0 generic arguments but 2 generic arguments were supplied
+error[E0107]: struct takes 0 generic arguments but 2 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:16:14
    |
 LL |     type D = Ty<'static, usize, { 0 }>;
@@ -253,7 +253,7 @@ help: add missing generic arguments
 LL |     type A = Ty<A, B>;
    |                ++++++
 
-error[E0107]: this struct takes 2 generic arguments but 1 generic argument was supplied
+error[E0107]: struct takes 2 generic arguments but 1 generic argument was supplied
   --> $DIR/wrong-number-of-args.rs:30:14
    |
 LL |     type B = Ty<usize>;
@@ -271,7 +271,7 @@ help: add missing generic argument
 LL |     type B = Ty<usize, B>;
    |                      +++
 
-error[E0107]: this struct takes 2 generic arguments but 3 generic arguments were supplied
+error[E0107]: struct takes 2 generic arguments but 3 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:36:14
    |
 LL |     type D = Ty<usize, String, char>;
@@ -285,7 +285,7 @@ note: struct defined here, with 2 generic parameters: `A`, `B`
 LL |     struct Ty<A, B>;
    |            ^^ -  -
 
-error[E0107]: this struct takes 2 generic arguments but 0 generic arguments were supplied
+error[E0107]: struct takes 2 generic arguments but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:40:14
    |
 LL |     type E = Ty<>;
@@ -317,7 +317,7 @@ help: add missing generic argument
 LL |     type A = Ty<T>;
    |                +++
 
-error[E0107]: this struct takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: struct takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:54:14
    |
 LL |     type B = Ty<'static>;
@@ -333,7 +333,7 @@ help: add missing generic argument
 LL |     type B = Ty<'static, T>;
    |                        +++
 
-error[E0107]: this struct takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: struct takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:64:14
    |
 LL |     type E = Ty<>;
@@ -349,7 +349,7 @@ help: add missing generic argument
 LL |     type E = Ty<T>;
    |                 +
 
-error[E0107]: this struct takes 1 lifetime argument but 2 lifetime arguments were supplied
+error[E0107]: struct takes 1 lifetime argument but 2 lifetime arguments were supplied
   --> $DIR/wrong-number-of-args.rs:70:14
    |
 LL |     type F = Ty<'static, usize, 'static, usize>;
@@ -363,7 +363,7 @@ note: struct defined here, with 1 lifetime parameter: `'a`
 LL |     struct Ty<'a, T>;
    |            ^^ --
 
-error[E0107]: this struct takes 1 generic argument but 2 generic arguments were supplied
+error[E0107]: struct takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:70:14
    |
 LL |     type F = Ty<'static, usize, 'static, usize>;
@@ -393,7 +393,7 @@ help: add missing generic arguments
 LL |     type A = Ty<A, B>;
    |                ++++++
 
-error[E0107]: this struct takes at least 2 generic arguments but 1 generic argument was supplied
+error[E0107]: struct takes at least 2 generic arguments but 1 generic argument was supplied
   --> $DIR/wrong-number-of-args.rs:84:14
    |
 LL |     type B = Ty<usize>;
@@ -411,7 +411,7 @@ help: add missing generic argument
 LL |     type B = Ty<usize, B>;
    |                      +++
 
-error[E0107]: this struct takes at most 3 generic arguments but 4 generic arguments were supplied
+error[E0107]: struct takes at most 3 generic arguments but 4 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:92:14
    |
 LL |     type E = Ty<usize, String, char, f64>;
@@ -425,7 +425,7 @@ note: struct defined here, with at most 3 generic parameters: `A`, `B`, `C`
 LL |     struct Ty<A, B, C = &'static str>;
    |            ^^ -  -  ----------------
 
-error[E0107]: this struct takes at least 2 generic arguments but 0 generic arguments were supplied
+error[E0107]: struct takes at least 2 generic arguments but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:96:14
    |
 LL |     type F = Ty<>;
@@ -441,7 +441,7 @@ help: add missing generic arguments
 LL |     type F = Ty<A, B>;
    |                 ++++
 
-error[E0107]: this trait takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/wrong-number-of-args.rs:116:22
    |
 LL |     type A = Box<dyn NonGeneric<usize>>;
@@ -455,7 +455,7 @@ note: trait defined here, with 0 generic parameters
 LL |     trait NonGeneric {
    |           ^^^^^^^^^^
 
-error[E0107]: this trait takes 1 lifetime argument but 2 lifetime arguments were supplied
+error[E0107]: trait takes 1 lifetime argument but 2 lifetime arguments were supplied
   --> $DIR/wrong-number-of-args.rs:125:22
    |
 LL |     type C = Box<dyn GenericLifetime<'static, 'static>>;
@@ -485,7 +485,7 @@ help: add missing generic argument
 LL |     type D = Box<dyn GenericType<A>>;
    |                                 +++
 
-error[E0107]: this trait takes 1 generic argument but 2 generic arguments were supplied
+error[E0107]: trait takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:133:22
    |
 LL |     type E = Box<dyn GenericType<String, usize>>;
@@ -499,7 +499,7 @@ note: trait defined here, with 1 generic parameter: `A`
 LL |     trait GenericType<A> {
    |           ^^^^^^^^^^^ -
 
-error[E0107]: this trait takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: trait takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:142:22
    |
 LL |     type G = Box<dyn GenericType<>>;
@@ -515,7 +515,7 @@ help: add missing generic argument
 LL |     type G = Box<dyn GenericType<A>>;
    |                                  +
 
-error[E0107]: this trait takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/wrong-number-of-args.rs:153:26
    |
 LL |         type A = Box<dyn NonGenericAT<usize, AssocTy=()>>;
@@ -529,7 +529,7 @@ note: trait defined here, with 0 generic parameters
 LL |         trait NonGenericAT {
    |               ^^^^^^^^^^^^
 
-error[E0107]: this trait takes 1 lifetime argument but 2 lifetime arguments were supplied
+error[E0107]: trait takes 1 lifetime argument but 2 lifetime arguments were supplied
   --> $DIR/wrong-number-of-args.rs:168:26
    |
 LL |         type B = Box<dyn GenericLifetimeAT<'static, 'static, AssocTy=()>>;
@@ -543,7 +543,7 @@ note: trait defined here, with 1 lifetime parameter: `'a`
 LL |         trait GenericLifetimeAT<'a> {
    |               ^^^^^^^^^^^^^^^^^ --
 
-error[E0107]: this trait takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/wrong-number-of-args.rs:172:26
    |
 LL |         type C = Box<dyn GenericLifetimeAT<(), AssocTy=()>>;
@@ -557,7 +557,7 @@ note: trait defined here, with 0 generic parameters
 LL |         trait GenericLifetimeAT<'a> {
    |               ^^^^^^^^^^^^^^^^^
 
-error[E0107]: this trait takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: trait takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:185:26
    |
 LL |         type A = Box<dyn GenericTypeAT<AssocTy=()>>;
@@ -573,7 +573,7 @@ help: add missing generic argument
 LL |         type A = Box<dyn GenericTypeAT<A, AssocTy=()>>;
    |                                        ++
 
-error[E0107]: this trait takes 1 generic argument but 2 generic arguments were supplied
+error[E0107]: trait takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:189:26
    |
 LL |         type B = Box<dyn GenericTypeAT<(), (), AssocTy=()>>;
@@ -587,7 +587,7 @@ note: trait defined here, with 1 generic parameter: `A`
 LL |         trait GenericTypeAT<A> {
    |               ^^^^^^^^^^^^^ -
 
-error[E0107]: this trait takes 0 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: trait takes 0 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/wrong-number-of-args.rs:193:26
    |
 LL |         type C = Box<dyn GenericTypeAT<'static, AssocTy=()>>;
@@ -601,7 +601,7 @@ note: trait defined here, with 0 lifetime parameters
 LL |         trait GenericTypeAT<A> {
    |               ^^^^^^^^^^^^^
 
-error[E0107]: this trait takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: trait takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:193:26
    |
 LL |         type C = Box<dyn GenericTypeAT<'static, AssocTy=()>>;
@@ -617,7 +617,7 @@ help: add missing generic argument
 LL |         type C = Box<dyn GenericTypeAT<'static, A, AssocTy=()>>;
    |                                               +++
 
-error[E0107]: this trait takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: trait takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:205:26
    |
 LL |         type A = Box<dyn GenericLifetimeTypeAT<AssocTy=()>>;
@@ -633,7 +633,7 @@ help: add missing generic argument
 LL |         type A = Box<dyn GenericLifetimeTypeAT<A, AssocTy=()>>;
    |                                                ++
 
-error[E0107]: this trait takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: trait takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:212:26
    |
 LL |         type B = Box<dyn GenericLifetimeTypeAT<'static, AssocTy=()>>;
@@ -649,7 +649,7 @@ help: add missing generic argument
 LL |         type B = Box<dyn GenericLifetimeTypeAT<'static, A, AssocTy=()>>;
    |                                                       +++
 
-error[E0107]: this trait takes 1 lifetime argument but 2 lifetime arguments were supplied
+error[E0107]: trait takes 1 lifetime argument but 2 lifetime arguments were supplied
   --> $DIR/wrong-number-of-args.rs:216:26
    |
 LL |         type C = Box<dyn GenericLifetimeTypeAT<'static, 'static, AssocTy=()>>;
@@ -663,7 +663,7 @@ note: trait defined here, with 1 lifetime parameter: `'a`
 LL |         trait GenericLifetimeTypeAT<'a, A> {
    |               ^^^^^^^^^^^^^^^^^^^^^ --
 
-error[E0107]: this trait takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: trait takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:216:26
    |
 LL |         type C = Box<dyn GenericLifetimeTypeAT<'static, 'static, AssocTy=()>>;
@@ -679,7 +679,7 @@ help: add missing generic argument
 LL |         type C = Box<dyn GenericLifetimeTypeAT<'static, 'static, A, AssocTy=()>>;
    |                                                                +++
 
-error[E0107]: this trait takes 1 generic argument but 2 generic arguments were supplied
+error[E0107]: trait takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:227:26
    |
 LL |         type E = Box<dyn GenericLifetimeTypeAT<(), (), AssocTy=()>>;
@@ -693,7 +693,7 @@ note: trait defined here, with 1 generic parameter: `A`
 LL |         trait GenericLifetimeTypeAT<'a, A> {
    |               ^^^^^^^^^^^^^^^^^^^^^     -
 
-error[E0107]: this trait takes 1 lifetime argument but 2 lifetime arguments were supplied
+error[E0107]: trait takes 1 lifetime argument but 2 lifetime arguments were supplied
   --> $DIR/wrong-number-of-args.rs:234:26
    |
 LL |         type F = Box<dyn GenericLifetimeTypeAT<'static, 'static, (), AssocTy=()>>;
@@ -707,7 +707,7 @@ note: trait defined here, with 1 lifetime parameter: `'a`
 LL |         trait GenericLifetimeTypeAT<'a, A> {
    |               ^^^^^^^^^^^^^^^^^^^^^ --
 
-error[E0107]: this trait takes 1 generic argument but 2 generic arguments were supplied
+error[E0107]: trait takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:238:26
    |
 LL |         type G = Box<dyn GenericLifetimeTypeAT<'static, (), (), AssocTy=()>>;
@@ -721,7 +721,7 @@ note: trait defined here, with 1 generic parameter: `A`
 LL |         trait GenericLifetimeTypeAT<'a, A> {
    |               ^^^^^^^^^^^^^^^^^^^^^     -
 
-error[E0107]: this trait takes 1 lifetime argument but 2 lifetime arguments were supplied
+error[E0107]: trait takes 1 lifetime argument but 2 lifetime arguments were supplied
   --> $DIR/wrong-number-of-args.rs:242:26
    |
 LL |         type H = Box<dyn GenericLifetimeTypeAT<'static, 'static, (), (), AssocTy=()>>;
@@ -735,7 +735,7 @@ note: trait defined here, with 1 lifetime parameter: `'a`
 LL |         trait GenericLifetimeTypeAT<'a, A> {
    |               ^^^^^^^^^^^^^^^^^^^^^ --
 
-error[E0107]: this trait takes 1 generic argument but 2 generic arguments were supplied
+error[E0107]: trait takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:242:26
    |
 LL |         type H = Box<dyn GenericLifetimeTypeAT<'static, 'static, (), (), AssocTy=()>>;
@@ -749,7 +749,7 @@ note: trait defined here, with 1 generic parameter: `A`
 LL |         trait GenericLifetimeTypeAT<'a, A> {
    |               ^^^^^^^^^^^^^^^^^^^^^     -
 
-error[E0107]: this trait takes 2 generic arguments but 0 generic arguments were supplied
+error[E0107]: trait takes 2 generic arguments but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:254:26
    |
 LL |         type A = Box<dyn GenericTypeTypeAT<AssocTy=()>>;
@@ -765,7 +765,7 @@ help: add missing generic arguments
 LL |         type A = Box<dyn GenericTypeTypeAT<A, B, AssocTy=()>>;
    |                                            +++++
 
-error[E0107]: this trait takes 2 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 2 generic arguments but 1 generic argument was supplied
   --> $DIR/wrong-number-of-args.rs:258:26
    |
 LL |         type B = Box<dyn GenericTypeTypeAT<(), AssocTy=()>>;
@@ -783,7 +783,7 @@ help: add missing generic argument
 LL |         type B = Box<dyn GenericTypeTypeAT<(), B, AssocTy=()>>;
    |                                              +++
 
-error[E0107]: this trait takes 2 generic arguments but 3 generic arguments were supplied
+error[E0107]: trait takes 2 generic arguments but 3 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:262:26
    |
 LL |         type C = Box<dyn GenericTypeTypeAT<(), (), (), AssocTy=()>>;
@@ -797,7 +797,7 @@ note: trait defined here, with 2 generic parameters: `A`, `B`
 LL |         trait GenericTypeTypeAT<A, B> {
    |               ^^^^^^^^^^^^^^^^^ -  -
 
-error[E0107]: this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: trait takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/wrong-number-of-args.rs:277:26
    |
 LL |         type B = Box<dyn GenericLifetimeLifetimeAT<'static, AssocTy=()>>;
@@ -815,7 +815,7 @@ help: add missing lifetime argument
 LL |         type B = Box<dyn GenericLifetimeLifetimeAT<'static, 'static, AssocTy=()>>;
    |                                                           +++++++++
 
-error[E0107]: this trait takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: trait takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:287:26
    |
 LL |         type A = Box<dyn GenericLifetimeLifetimeTypeAT<AssocTy=()>>;
@@ -831,7 +831,7 @@ help: add missing generic argument
 LL |         type A = Box<dyn GenericLifetimeLifetimeTypeAT<A, AssocTy=()>>;
    |                                                        ++
 
-error[E0107]: this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: trait takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/wrong-number-of-args.rs:294:26
    |
 LL |         type B = Box<dyn GenericLifetimeLifetimeTypeAT<'static, AssocTy=()>>;
@@ -849,7 +849,7 @@ help: add missing lifetime argument
 LL |         type B = Box<dyn GenericLifetimeLifetimeTypeAT<'static, 'static, AssocTy=()>>;
    |                                                               +++++++++
 
-error[E0107]: this trait takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: trait takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:294:26
    |
 LL |         type B = Box<dyn GenericLifetimeLifetimeTypeAT<'static, AssocTy=()>>;
@@ -865,7 +865,7 @@ help: add missing generic argument
 LL |         type B = Box<dyn GenericLifetimeLifetimeTypeAT<'static, A, AssocTy=()>>;
    |                                                               +++
 
-error[E0107]: this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: trait takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/wrong-number-of-args.rs:300:26
    |
 LL |         type C = Box<dyn GenericLifetimeLifetimeTypeAT<'static, (), AssocTy=()>>;
@@ -894,7 +894,7 @@ help: add missing generic arguments
 LL |         type A = HashMap<K, V>;
    |                         ++++++
 
-error[E0107]: this struct takes at least 2 generic arguments but 1 generic argument was supplied
+error[E0107]: struct takes at least 2 generic arguments but 1 generic argument was supplied
   --> $DIR/wrong-number-of-args.rs:314:18
    |
 LL |         type B = HashMap<String>;
@@ -907,7 +907,7 @@ help: add missing generic argument
 LL |         type B = HashMap<String, V>;
    |                                +++
 
-error[E0107]: this struct takes 0 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: struct takes 0 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/wrong-number-of-args.rs:318:18
    |
 LL |         type C = HashMap<'static>;
@@ -915,7 +915,7 @@ LL |         type C = HashMap<'static>;
    |                  |
    |                  expected 0 lifetime arguments
 
-error[E0107]: this struct takes at least 2 generic arguments but 0 generic arguments were supplied
+error[E0107]: struct takes at least 2 generic arguments but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:318:18
    |
 LL |         type C = HashMap<'static>;
@@ -926,7 +926,7 @@ help: add missing generic arguments
 LL |         type C = HashMap<'static, K, V>;
    |                                 ++++++
 
-error[E0107]: this struct takes at most 3 generic arguments but 4 generic arguments were supplied
+error[E0107]: struct takes at most 3 generic arguments but 4 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:324:18
    |
 LL |         type D = HashMap<usize, String, char, f64>;
@@ -934,7 +934,7 @@ LL |         type D = HashMap<usize, String, char, f64>;
    |                  |
    |                  expected at most 3 generic arguments
 
-error[E0107]: this struct takes at least 2 generic arguments but 0 generic arguments were supplied
+error[E0107]: struct takes at least 2 generic arguments but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:328:18
    |
 LL |         type E = HashMap<>;
@@ -956,7 +956,7 @@ help: add missing generic arguments
 LL |         type A = Result<T, E>;
    |                        ++++++
 
-error[E0107]: this enum takes 2 generic arguments but 1 generic argument was supplied
+error[E0107]: enum takes 2 generic arguments but 1 generic argument was supplied
   --> $DIR/wrong-number-of-args.rs:338:18
    |
 LL |         type B = Result<String>;
@@ -969,7 +969,7 @@ help: add missing generic argument
 LL |         type B = Result<String, E>;
    |                               +++
 
-error[E0107]: this enum takes 0 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: enum takes 0 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/wrong-number-of-args.rs:342:18
    |
 LL |         type C = Result<'static>;
@@ -977,7 +977,7 @@ LL |         type C = Result<'static>;
    |                  |
    |                  expected 0 lifetime arguments
 
-error[E0107]: this enum takes 2 generic arguments but 0 generic arguments were supplied
+error[E0107]: enum takes 2 generic arguments but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:342:18
    |
 LL |         type C = Result<'static>;
@@ -988,7 +988,7 @@ help: add missing generic arguments
 LL |         type C = Result<'static, T, E>;
    |                                ++++++
 
-error[E0107]: this enum takes 2 generic arguments but 3 generic arguments were supplied
+error[E0107]: enum takes 2 generic arguments but 3 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:348:18
    |
 LL |         type D = Result<usize, String, char>;
@@ -996,7 +996,7 @@ LL |         type D = Result<usize, String, char>;
    |                  |
    |                  expected 2 generic arguments
 
-error[E0107]: this enum takes 2 generic arguments but 0 generic arguments were supplied
+error[E0107]: enum takes 2 generic arguments but 0 generic arguments were supplied
   --> $DIR/wrong-number-of-args.rs:352:18
    |
 LL |         type E = Result<>;
diff --git a/tests/ui/higher-rank-trait-bounds/hrtb-higher-ranker-supertraits-transitive.stderr b/tests/ui/higher-rank-trait-bounds/hrtb-higher-ranker-supertraits-transitive.stderr
index 8cda76b9490..b1b8ffa8c54 100644
--- a/tests/ui/higher-rank-trait-bounds/hrtb-higher-ranker-supertraits-transitive.stderr
+++ b/tests/ui/higher-rank-trait-bounds/hrtb-higher-ranker-supertraits-transitive.stderr
@@ -10,7 +10,7 @@ note: required by a bound in `want_bar_for_any_ccx`
   --> $DIR/hrtb-higher-ranker-supertraits-transitive.rs:32:15
    |
 LL | fn want_bar_for_any_ccx<B>(b: &B)
-   |    -------------------- required by a bound in this
+   |    -------------------- required by a bound in this function
 LL |     where B : for<'ccx> Bar<'ccx>
    |               ^^^^^^^^^^^^^^^^^^^ required by this bound in `want_bar_for_any_ccx`
 help: consider further restricting this bound
diff --git a/tests/ui/higher-rank-trait-bounds/hrtb-higher-ranker-supertraits.stderr b/tests/ui/higher-rank-trait-bounds/hrtb-higher-ranker-supertraits.stderr
index 88793a1525b..7f96909b6e7 100644
--- a/tests/ui/higher-rank-trait-bounds/hrtb-higher-ranker-supertraits.stderr
+++ b/tests/ui/higher-rank-trait-bounds/hrtb-higher-ranker-supertraits.stderr
@@ -10,7 +10,7 @@ note: required by a bound in `want_foo_for_any_tcx`
   --> $DIR/hrtb-higher-ranker-supertraits.rs:22:15
    |
 LL | fn want_foo_for_any_tcx<F>(f: &F)
-   |    -------------------- required by a bound in this
+   |    -------------------- required by a bound in this function
 LL |     where F : for<'tcx> Foo<'tcx>
    |               ^^^^^^^^^^^^^^^^^^^ required by this bound in `want_foo_for_any_tcx`
 help: consider further restricting this bound
@@ -30,7 +30,7 @@ note: required by a bound in `want_bar_for_any_ccx`
   --> $DIR/hrtb-higher-ranker-supertraits.rs:39:15
    |
 LL | fn want_bar_for_any_ccx<B>(b: &B)
-   |    -------------------- required by a bound in this
+   |    -------------------- required by a bound in this function
 LL |     where B : for<'ccx> Bar<'ccx>
    |               ^^^^^^^^^^^^^^^^^^^ required by this bound in `want_bar_for_any_ccx`
 help: consider further restricting this bound
diff --git a/tests/ui/higher-rank-trait-bounds/issue-62203-hrtb-ice.stderr b/tests/ui/higher-rank-trait-bounds/issue-62203-hrtb-ice.stderr
index 86198c3f7fd..4d470ae7022 100644
--- a/tests/ui/higher-rank-trait-bounds/issue-62203-hrtb-ice.stderr
+++ b/tests/ui/higher-rank-trait-bounds/issue-62203-hrtb-ice.stderr
@@ -25,7 +25,7 @@ note: required by a bound in `T1::m`
   --> $DIR/issue-62203-hrtb-ice.rs:27:51
    |
 LL |     fn m<'a, B: Ty<'a>, F>(&self, f: F) -> Unit1
-   |        - required by a bound in this
+   |        - required by a bound in this associated function
 LL |     where
 LL |         F: for<'r> T0<'r, (<Self as Ty<'r>>::V,), O = <B as Ty<'r>>::V>,
    |                                                   ^^^^^^^^^^^^^^^^^^^^ required by this bound in `T1::m`
@@ -56,7 +56,7 @@ note: required by a bound in `T1::m`
   --> $DIR/issue-62203-hrtb-ice.rs:27:12
    |
 LL |     fn m<'a, B: Ty<'a>, F>(&self, f: F) -> Unit1
-   |        - required by a bound in this
+   |        - required by a bound in this associated function
 LL |     where
 LL |         F: for<'r> T0<'r, (<Self as Ty<'r>>::V,), O = <B as Ty<'r>>::V>,
    |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `T1::m`
diff --git a/tests/ui/higher-rank-trait-bounds/normalize-under-binder/issue-89118.stderr b/tests/ui/higher-rank-trait-bounds/normalize-under-binder/issue-89118.stderr
index 62d0128fd85..edef6ccd34e 100644
--- a/tests/ui/higher-rank-trait-bounds/normalize-under-binder/issue-89118.stderr
+++ b/tests/ui/higher-rank-trait-bounds/normalize-under-binder/issue-89118.stderr
@@ -15,7 +15,7 @@ note: required by a bound in `StackContext`
   --> $DIR/issue-89118.rs:9:14
    |
 LL | trait StackContext
-   |       ------------ required by a bound in this
+   |       ------------ required by a bound in this trait
 LL | where
 LL |     Ctx<()>: for<'a> BufferUdpStateContext<&'a ()>,
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `StackContext`
@@ -37,7 +37,7 @@ note: required by a bound in `EthernetWorker`
   --> $DIR/issue-89118.rs:28:14
    |
 LL | struct EthernetWorker<C>(C)
-   |        -------------- required by a bound in this
+   |        -------------- required by a bound in this struct
 LL | where
 LL |     Ctx<()>: for<'a> BufferUdpStateContext<&'a ()>;
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `EthernetWorker`
@@ -59,7 +59,7 @@ note: required by a bound in `StackContext`
   --> $DIR/issue-89118.rs:9:14
    |
 LL | trait StackContext
-   |       ------------ required by a bound in this
+   |       ------------ required by a bound in this trait
 LL | where
 LL |     Ctx<()>: for<'a> BufferUdpStateContext<&'a ()>,
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `StackContext`
diff --git a/tests/ui/higher-rank-trait-bounds/normalize-under-binder/issue-90950.stderr b/tests/ui/higher-rank-trait-bounds/normalize-under-binder/issue-90950.stderr
index 6206b167b0b..5be33bccdc3 100644
--- a/tests/ui/higher-rank-trait-bounds/normalize-under-binder/issue-90950.stderr
+++ b/tests/ui/higher-rank-trait-bounds/normalize-under-binder/issue-90950.stderr
@@ -11,7 +11,7 @@ note: required by a bound in `upcast`
   --> $DIR/issue-90950.rs:27:42
    |
 LL | fn upcast<Y>(x: Yoke<Y>) -> Yoke<Box<dyn IsCovariant<'static> + 'static>> where
-   |    ------ required by a bound in this
+   |    ------ required by a bound in this function
 LL |     Y: for<'a> Yokeable<'a>,
 LL |     for<'a> <Y as Yokeable<'a>>::Output: IsCovariant<'a>
    |                                          ^^^^^^^^^^^^^^^ required by this bound in `upcast`
diff --git a/tests/ui/higher-rank-trait-bounds/normalize-under-binder/norm-before-method-resolution.stderr b/tests/ui/higher-rank-trait-bounds/normalize-under-binder/norm-before-method-resolution.stderr
index 51c9646004a..73388a72574 100644
--- a/tests/ui/higher-rank-trait-bounds/normalize-under-binder/norm-before-method-resolution.stderr
+++ b/tests/ui/higher-rank-trait-bounds/normalize-under-binder/norm-before-method-resolution.stderr
@@ -8,7 +8,7 @@ note: required by a bound in `weird_bound`
   --> $DIR/norm-before-method-resolution.rs:18:40
    |
 LL | fn weird_bound<X>() -> X
-   |    ----------- required by a bound in this
+   |    ----------- required by a bound in this function
 ...
 LL |         for<'a> <X as Trait<'a>>::Out: Copy
    |                                        ^^^^ required by this bound in `weird_bound`
diff --git a/tests/ui/impl-trait/equal-hidden-lifetimes.rs b/tests/ui/impl-trait/equal-hidden-lifetimes.rs
index 79db88828b9..a6dbf3f08f2 100644
--- a/tests/ui/impl-trait/equal-hidden-lifetimes.rs
+++ b/tests/ui/impl-trait/equal-hidden-lifetimes.rs
@@ -5,7 +5,6 @@
 
 // `'a == 'static` so `&'a i32` is fine as the return type
 fn equal_regions_static<'a: 'static>(x: &'a i32) -> impl Sized {
-    //~^ WARNING unnecessary lifetime parameter `'a`
     x
 }
 
diff --git a/tests/ui/impl-trait/equal-hidden-lifetimes.stderr b/tests/ui/impl-trait/equal-hidden-lifetimes.stderr
deleted file mode 100644
index 3e48aef553b..00000000000
--- a/tests/ui/impl-trait/equal-hidden-lifetimes.stderr
+++ /dev/null
@@ -1,10 +0,0 @@
-warning: unnecessary lifetime parameter `'a`
-  --> $DIR/equal-hidden-lifetimes.rs:7:25
-   |
-LL | fn equal_regions_static<'a: 'static>(x: &'a i32) -> impl Sized {
-   |                         ^^
-   |
-   = help: you can use the `'static` lifetime directly, in place of `'a`
-
-warning: 1 warning emitted
-
diff --git a/tests/ui/impl-trait/explicit-generic-args-with-impl-trait/explicit-generic-args-for-impl.stderr b/tests/ui/impl-trait/explicit-generic-args-with-impl-trait/explicit-generic-args-for-impl.stderr
index c8b82783ea8..9c101101870 100644
--- a/tests/ui/impl-trait/explicit-generic-args-with-impl-trait/explicit-generic-args-for-impl.stderr
+++ b/tests/ui/impl-trait/explicit-generic-args-with-impl-trait/explicit-generic-args-for-impl.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this function takes 1 generic argument but 2 generic arguments were supplied
+error[E0107]: function takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/explicit-generic-args-for-impl.rs:4:5
    |
 LL |     foo::<str, String>("".to_string());
diff --git a/tests/ui/impl-trait/explicit-generic-args-with-impl-trait/not-enough-args.stderr b/tests/ui/impl-trait/explicit-generic-args-with-impl-trait/not-enough-args.stderr
index 9d6db88d364..a26460c8ecc 100644
--- a/tests/ui/impl-trait/explicit-generic-args-with-impl-trait/not-enough-args.stderr
+++ b/tests/ui/impl-trait/explicit-generic-args-with-impl-trait/not-enough-args.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this function takes 2 generic arguments but 1 generic argument was supplied
+error[E0107]: function takes 2 generic arguments but 1 generic argument was supplied
   --> $DIR/not-enough-args.rs:4:5
    |
 LL |     f::<[u8]>("a", b"a");
diff --git a/tests/ui/impl-trait/in-trait/default-method-constraint.rs b/tests/ui/impl-trait/in-trait/default-method-constraint.rs
new file mode 100644
index 00000000000..8c50cc29586
--- /dev/null
+++ b/tests/ui/impl-trait/in-trait/default-method-constraint.rs
@@ -0,0 +1,17 @@
+// check-pass
+
+// This didn't work in the previous default RPITIT method hack attempt
+
+#![feature(return_position_impl_trait_in_trait)]
+//~^ WARN the feature `return_position_impl_trait_in_trait` is incomplete
+
+trait Foo {
+    fn bar(x: bool) -> impl Sized {
+        if x {
+            let _: u32 = Self::bar(!x);
+        }
+        Default::default()
+    }
+}
+
+fn main() {}
diff --git a/tests/ui/impl-trait/in-trait/default-method-constraint.stderr b/tests/ui/impl-trait/in-trait/default-method-constraint.stderr
new file mode 100644
index 00000000000..5e18605aa4c
--- /dev/null
+++ b/tests/ui/impl-trait/in-trait/default-method-constraint.stderr
@@ -0,0 +1,11 @@
+warning: the feature `return_position_impl_trait_in_trait` is incomplete and may not be safe to use and/or cause compiler crashes
+  --> $DIR/default-method-constraint.rs:5:12
+   |
+LL | #![feature(return_position_impl_trait_in_trait)]
+   |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |
+   = note: see issue #91611 <https://github.com/rust-lang/rust/issues/91611> for more information
+   = note: `#[warn(incomplete_features)]` on by default
+
+warning: 1 warning emitted
+
diff --git a/tests/ui/impl-trait/issues/issue-54600.stderr b/tests/ui/impl-trait/issues/issue-54600.stderr
index 316566a57a8..7ef063af952 100644
--- a/tests/ui/impl-trait/issues/issue-54600.stderr
+++ b/tests/ui/impl-trait/issues/issue-54600.stderr
@@ -1,4 +1,4 @@
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable binding
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable bindings
   --> $DIR/issue-54600.rs:4:19
    |
 LL |     let x: Option<impl Debug> = Some(44_u32);
diff --git a/tests/ui/impl-trait/issues/issue-54840.stderr b/tests/ui/impl-trait/issues/issue-54840.stderr
index 8d82133ac90..1d1316f0e11 100644
--- a/tests/ui/impl-trait/issues/issue-54840.stderr
+++ b/tests/ui/impl-trait/issues/issue-54840.stderr
@@ -1,4 +1,4 @@
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable binding
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable bindings
   --> $DIR/issue-54840.rs:5:13
    |
 LL |     let j: &impl Add = &i;
diff --git a/tests/ui/impl-trait/issues/issue-58504.stderr b/tests/ui/impl-trait/issues/issue-58504.stderr
index 6656e9fc3fb..26ec2a4f9cf 100644
--- a/tests/ui/impl-trait/issues/issue-58504.stderr
+++ b/tests/ui/impl-trait/issues/issue-58504.stderr
@@ -1,4 +1,4 @@
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable binding
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable bindings
   --> $DIR/issue-58504.rs:10:16
    |
 LL |     let gens: [impl Generator<Return=!, Yield=()>;2] = [ mk_gen(), mk_gen() ];
diff --git a/tests/ui/impl-trait/issues/issue-58956.stderr b/tests/ui/impl-trait/issues/issue-58956.stderr
index f591c07bcf5..2b4d0abdffc 100644
--- a/tests/ui/impl-trait/issues/issue-58956.stderr
+++ b/tests/ui/impl-trait/issues/issue-58956.stderr
@@ -1,10 +1,10 @@
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in const type
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in const types
   --> $DIR/issue-58956.rs:7:11
    |
 LL | const _A: impl Lam = {
    |           ^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable binding
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable bindings
   --> $DIR/issue-58956.rs:9:17
    |
 LL |     let x: Wrap<impl Lam> = Wrap(B);
diff --git a/tests/ui/impl-trait/issues/issue-70971.stderr b/tests/ui/impl-trait/issues/issue-70971.stderr
index 4dda4c22aa2..d066256bfb0 100644
--- a/tests/ui/impl-trait/issues/issue-70971.stderr
+++ b/tests/ui/impl-trait/issues/issue-70971.stderr
@@ -1,4 +1,4 @@
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable binding
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable bindings
   --> $DIR/issue-70971.rs:2:14
    |
 LL |     let x : (impl Copy,) = (true,);
diff --git a/tests/ui/impl-trait/issues/issue-79099.stderr b/tests/ui/impl-trait/issues/issue-79099.stderr
index 362c67dafd2..580250a62fe 100644
--- a/tests/ui/impl-trait/issues/issue-79099.stderr
+++ b/tests/ui/impl-trait/issues/issue-79099.stderr
@@ -9,7 +9,7 @@ LL |         let f: impl core::future::Future<Output = u8> = async { 1 };
    = help: pass `--edition 2021` to `rustc`
    = note: for more on editions, read https://doc.rust-lang.org/edition-guide
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable binding
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable bindings
   --> $DIR/issue-79099.rs:3:16
    |
 LL |         let f: impl core::future::Future<Output = u8> = async { 1 };
diff --git a/tests/ui/impl-trait/issues/issue-83929-impl-trait-in-generic-default.stderr b/tests/ui/impl-trait/issues/issue-83929-impl-trait-in-generic-default.stderr
index a227f0ba7d1..656bd047061 100644
--- a/tests/ui/impl-trait/issues/issue-83929-impl-trait-in-generic-default.stderr
+++ b/tests/ui/impl-trait/issues/issue-83929-impl-trait-in-generic-default.stderr
@@ -1,10 +1,10 @@
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic parameter default
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic parameter defaults
   --> $DIR/issue-83929-impl-trait-in-generic-default.rs:1:16
    |
 LL | struct Foo<T = impl Copy>(T);
    |                ^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic parameter default
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic parameter defaults
   --> $DIR/issue-83929-impl-trait-in-generic-default.rs:4:20
    |
 LL | type Result<T, E = impl std::error::Error> = std::result::Result<T, E>;
diff --git a/tests/ui/impl-trait/issues/issue-84919.stderr b/tests/ui/impl-trait/issues/issue-84919.stderr
index 5abe1bd8779..36010fdef36 100644
--- a/tests/ui/impl-trait/issues/issue-84919.stderr
+++ b/tests/ui/impl-trait/issues/issue-84919.stderr
@@ -1,4 +1,4 @@
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable binding
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable bindings
   --> $DIR/issue-84919.rs:5:13
    |
 LL |     let _x: impl Trait = ();
diff --git a/tests/ui/impl-trait/issues/issue-86642.stderr b/tests/ui/impl-trait/issues/issue-86642.stderr
index a137777840b..b6f8a54f35a 100644
--- a/tests/ui/impl-trait/issues/issue-86642.stderr
+++ b/tests/ui/impl-trait/issues/issue-86642.stderr
@@ -1,4 +1,4 @@
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in const type
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in const types
   --> $DIR/issue-86642.rs:1:11
    |
 LL | static x: impl Fn(&str) -> Result<&str, ()> = move |source| {
diff --git a/tests/ui/impl-trait/issues/issue-87295.stderr b/tests/ui/impl-trait/issues/issue-87295.stderr
index 0b043056b84..ec59b719c10 100644
--- a/tests/ui/impl-trait/issues/issue-87295.stderr
+++ b/tests/ui/impl-trait/issues/issue-87295.stderr
@@ -1,4 +1,4 @@
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable binding
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable bindings
   --> $DIR/issue-87295.rs:16:31
    |
 LL |     let _do_not_waste: Struct<impl Trait<Output = i32>> = Struct::new(());
diff --git a/tests/ui/impl-trait/nested_impl_trait.stderr b/tests/ui/impl-trait/nested_impl_trait.stderr
index 9a8f5a34068..ffe84b8e86f 100644
--- a/tests/ui/impl-trait/nested_impl_trait.stderr
+++ b/tests/ui/impl-trait/nested_impl_trait.stderr
@@ -34,7 +34,7 @@ LL |     fn bad(x: impl Into<u32>) -> impl Into<impl Debug> { x }
    |                                  |         nested `impl Trait` here
    |                                  outer `impl Trait`
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `fn` pointer return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `fn` pointer return types
   --> $DIR/nested_impl_trait.rs:10:32
    |
 LL | fn bad_in_fn_syntax(x: fn() -> impl Into<impl Debug>) {}
diff --git a/tests/ui/impl-trait/normalize-tait-in-const.rs b/tests/ui/impl-trait/normalize-tait-in-const.rs
index 020bcbb8396..d2e34c00b64 100644
--- a/tests/ui/impl-trait/normalize-tait-in-const.rs
+++ b/tests/ui/impl-trait/normalize-tait-in-const.rs
@@ -2,6 +2,7 @@
 // failure-status: 101
 // normalize-stderr-test "note: .*\n\n" -> ""
 // normalize-stderr-test "thread 'rustc' panicked.*\n" -> ""
+// normalize-stderr-test "(error: internal compiler error: [^:]+):\d+:\d+: " -> "$1:LL:CC: "
 // rustc-env:RUST_BACKTRACE=0
 
 #![feature(type_alias_impl_trait)]
diff --git a/tests/ui/impl-trait/normalize-tait-in-const.stderr b/tests/ui/impl-trait/normalize-tait-in-const.stderr
index 99eed29207b..84b00918724 100644
--- a/tests/ui/impl-trait/normalize-tait-in-const.stderr
+++ b/tests/ui/impl-trait/normalize-tait-in-const.stderr
@@ -1,4 +1,4 @@
-error: internal compiler error: compiler/rustc_middle/src/ty/normalize_erasing_regions.rs:201:90: Failed to normalize <for<'a, 'b> fn(&'a Alias<'b>) {foo} as std::ops::FnOnce<(&&S,)>>::Output, maybe try to call `try_normalize_erasing_regions` instead
+error: internal compiler error: compiler/rustc_middle/src/ty/normalize_erasing_regions.rs:LL:CC: Failed to normalize <for<'a, 'b> fn(&'a Alias<'b>) {foo} as std::ops::FnOnce<(&&S,)>>::Output, maybe try to call `try_normalize_erasing_regions` instead
 
 query stack during panic:
 #0 [eval_to_allocation_raw] const-evaluating + checking `BAR`
diff --git a/tests/ui/impl-trait/where-allowed.stderr b/tests/ui/impl-trait/where-allowed.stderr
index 201aba3adff..1cae3f77cc5 100644
--- a/tests/ui/impl-trait/where-allowed.stderr
+++ b/tests/ui/impl-trait/where-allowed.stderr
@@ -43,109 +43,109 @@ 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
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `fn` pointer param
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `fn` pointer params
   --> $DIR/where-allowed.rs:16:40
    |
 LL | fn in_fn_parameter_in_parameters(_: fn(impl Debug)) { panic!() }
    |                                        ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `fn` pointer return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `fn` pointer return types
   --> $DIR/where-allowed.rs:20:42
    |
 LL | fn in_fn_return_in_parameters(_: fn() -> impl Debug) { panic!() }
    |                                          ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `fn` pointer param
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `fn` pointer params
   --> $DIR/where-allowed.rs:24:38
    |
 LL | fn in_fn_parameter_in_return() -> fn(impl Debug) { panic!() }
    |                                      ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `fn` pointer return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `fn` pointer return types
   --> $DIR/where-allowed.rs:28:40
    |
 LL | fn in_fn_return_in_return() -> fn() -> impl Debug { panic!() }
    |                                        ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait param
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait params
   --> $DIR/where-allowed.rs:32:49
    |
 LL | fn in_dyn_Fn_parameter_in_parameters(_: &dyn Fn(impl Debug)) { panic!() }
    |                                                 ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait return types
   --> $DIR/where-allowed.rs:36:51
    |
 LL | fn in_dyn_Fn_return_in_parameters(_: &dyn Fn() -> impl Debug) { panic!() }
    |                                                   ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait param
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait params
   --> $DIR/where-allowed.rs:40:55
    |
 LL | fn in_dyn_Fn_parameter_in_return() -> &'static dyn Fn(impl Debug) { panic!() }
    |                                                       ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait param
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait params
   --> $DIR/where-allowed.rs:47:51
    |
 LL | fn in_impl_Fn_parameter_in_parameters(_: &impl Fn(impl Debug)) { panic!() }
    |                                                   ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait return types
   --> $DIR/where-allowed.rs:52:53
    |
 LL | fn in_impl_Fn_return_in_parameters(_: &impl Fn() -> impl Debug) { panic!() }
    |                                                     ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait param
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait params
   --> $DIR/where-allowed.rs:56:57
    |
 LL | fn in_impl_Fn_parameter_in_return() -> &'static impl Fn(impl Debug) { panic!() }
    |                                                         ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait param
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait params
   --> $DIR/where-allowed.rs:64:38
    |
 LL | fn in_Fn_parameter_in_generics<F: Fn(impl Debug)> (_: F) { panic!() }
    |                                      ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait return types
   --> $DIR/where-allowed.rs:68:40
    |
 LL | fn in_Fn_return_in_generics<F: Fn() -> impl Debug> (_: F) { panic!() }
    |                                        ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in field type
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in field types
   --> $DIR/where-allowed.rs:81:32
    |
 LL | struct InBraceStructField { x: impl Debug }
    |                                ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in field type
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in field types
   --> $DIR/where-allowed.rs:85:41
    |
 LL | struct InAdtInBraceStructField { x: Vec<impl Debug> }
    |                                         ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in field type
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in field types
   --> $DIR/where-allowed.rs:89:27
    |
 LL | struct InTupleStructField(impl Debug);
    |                           ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in field type
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in field types
   --> $DIR/where-allowed.rs:94:25
    |
 LL |     InBraceVariant { x: impl Debug },
    |                         ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in field type
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in field types
   --> $DIR/where-allowed.rs:96:20
    |
 LL |     InTupleVariant(impl Debug),
    |                    ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in trait method return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in trait method return types
   --> $DIR/where-allowed.rs:107:23
    |
 LL |     fn in_return() -> impl Debug;
@@ -154,7 +154,7 @@ LL |     fn in_return() -> impl Debug;
    = note: see issue #91611 <https://github.com/rust-lang/rust/issues/91611> for more information
    = help: add `#![feature(return_position_impl_trait_in_trait)]` to the crate attributes to enable
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `impl` method return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `impl` method return types
   --> $DIR/where-allowed.rs:124:34
    |
 LL |     fn in_trait_impl_return() -> impl Debug { () }
@@ -163,121 +163,121 @@ LL |     fn in_trait_impl_return() -> impl Debug { () }
    = note: see issue #91611 <https://github.com/rust-lang/rust/issues/91611> for more information
    = help: add `#![feature(return_position_impl_trait_in_trait)]` to the crate attributes to enable
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `extern fn` param
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `extern fn` params
   --> $DIR/where-allowed.rs:137:33
    |
 LL |     fn in_foreign_parameters(_: impl Debug);
    |                                 ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `extern fn` return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `extern fn` return types
   --> $DIR/where-allowed.rs:140:31
    |
 LL |     fn in_foreign_return() -> impl Debug;
    |                               ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `fn` pointer return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `fn` pointer return types
   --> $DIR/where-allowed.rs:156:39
    |
 LL | type InReturnInTypeAlias<R> = fn() -> impl Debug;
    |                                       ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in trait
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in traits
   --> $DIR/where-allowed.rs:161:16
    |
 LL | impl PartialEq<impl Debug> for () {
    |                ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in impl header
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in impl headers
   --> $DIR/where-allowed.rs:166:24
    |
 LL | impl PartialEq<()> for impl Debug {
    |                        ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in impl header
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in impl headers
   --> $DIR/where-allowed.rs:171:6
    |
 LL | impl impl Debug {
    |      ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in impl header
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in impl headers
   --> $DIR/where-allowed.rs:177:24
    |
 LL | impl InInherentImplAdt<impl Debug> {
    |                        ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in bound
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in bounds
   --> $DIR/where-allowed.rs:183:11
    |
 LL |     where impl Debug: Debug
    |           ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in bound
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in bounds
   --> $DIR/where-allowed.rs:190:15
    |
 LL |     where Vec<impl Debug>: Debug
    |               ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in bound
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in bounds
   --> $DIR/where-allowed.rs:197:24
    |
 LL |     where T: PartialEq<impl Debug>
    |                        ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait param
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait params
   --> $DIR/where-allowed.rs:204:17
    |
 LL |     where T: Fn(impl Debug)
    |                 ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `Fn` trait return types
   --> $DIR/where-allowed.rs:211:22
    |
 LL |     where T: Fn() -> impl Debug
    |                      ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic parameter default
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic parameter defaults
   --> $DIR/where-allowed.rs:217:40
    |
 LL | struct InStructGenericParamDefault<T = impl Debug>(T);
    |                                        ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic parameter default
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic parameter defaults
   --> $DIR/where-allowed.rs:221:36
    |
 LL | enum InEnumGenericParamDefault<T = impl Debug> { Variant(T) }
    |                                    ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic parameter default
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic parameter defaults
   --> $DIR/where-allowed.rs:225:38
    |
 LL | trait InTraitGenericParamDefault<T = impl Debug> {}
    |                                      ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic parameter default
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic parameter defaults
   --> $DIR/where-allowed.rs:229:41
    |
 LL | type InTypeAliasGenericParamDefault<T = impl Debug> = T;
    |                                         ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic parameter default
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic parameter defaults
   --> $DIR/where-allowed.rs:233:11
    |
 LL | impl <T = impl Debug> T {}
    |           ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic parameter default
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic parameter defaults
   --> $DIR/where-allowed.rs:240:40
    |
 LL | fn in_method_generic_param_default<T = impl Debug>(_: T) {}
    |                                        ^^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable binding
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable bindings
   --> $DIR/where-allowed.rs:246:29
    |
 LL |     let _in_local_variable: impl Fn() = || {};
    |                             ^^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in closure return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in closure return types
   --> $DIR/where-allowed.rs:248:46
    |
 LL |     let _in_return_in_local_variable = || -> impl Fn() { || {} };
diff --git a/tests/ui/implied-bounds/issue-100690.stderr b/tests/ui/implied-bounds/issue-100690.stderr
index 3f6af70d8ed..dba0353377f 100644
--- a/tests/ui/implied-bounds/issue-100690.stderr
+++ b/tests/ui/implied-bounds/issue-100690.stderr
@@ -12,7 +12,7 @@ note: required by a bound in `real_dispatch`
   --> $DIR/issue-100690.rs:9:8
    |
 LL | fn real_dispatch<T, F>(f: F) -> Result<(), io::Error>
-   |    ------------- required by a bound in this
+   |    ------------- required by a bound in this function
 ...
 LL |     F: FnOnce(&mut UIView<T>) -> Result<(), io::Error> + Send + 'static,
    |        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `real_dispatch`
diff --git a/tests/ui/inference/inference_unstable.rs b/tests/ui/inference/inference_unstable.rs
index daf0cf042c4..ad76499591c 100644
--- a/tests/ui/inference/inference_unstable.rs
+++ b/tests/ui/inference/inference_unstable.rs
@@ -14,16 +14,16 @@ use inference_unstable_itertools::IpuItertools;
 
 fn main() {
     assert_eq!('x'.ipu_flatten(), 1);
-//~^ WARN an associated function with this name may be added to the standard library in the future
+//~^ WARN a method with this name may be added to the standard library in the future
 //~| WARN once this associated item is added to the standard library, the ambiguity may cause an
     assert_eq!('x'.ipu_by_value_vs_by_ref(), 1);
-//~^ WARN an associated function with this name may be added to the standard library in the future
+//~^ WARN a method with this name may be added to the standard library in the future
 //~| WARN once this associated item is added to the standard library, the ambiguity may cause an
     assert_eq!('x'.ipu_by_ref_vs_by_ref_mut(), 1);
-//~^ WARN an associated function with this name may be added to the standard library in the future
+//~^ WARN a method with this name may be added to the standard library in the future
 //~| WARN once this associated item is added to the standard library, the ambiguity may cause an
     assert_eq!((&mut 'x' as *mut char).ipu_by_mut_ptr_vs_by_const_ptr(), 1);
-//~^ WARN an associated function with this name may be added to the standard library in the future
+//~^ WARN a method with this name may be added to the standard library in the future
 //~| WARN once this associated item is added to the standard library, the ambiguity may cause an
     assert_eq!(char::C, 1);
 //~^ WARN an associated constant with this name may be added to the standard library in the future
diff --git a/tests/ui/inference/inference_unstable.stderr b/tests/ui/inference/inference_unstable.stderr
index ecbf2641bec..c48aaf9f495 100644
--- a/tests/ui/inference/inference_unstable.stderr
+++ b/tests/ui/inference/inference_unstable.stderr
@@ -1,4 +1,4 @@
-warning: an associated function with this name may be added to the standard library in the future
+warning: a method with this name may be added to the standard library in the future
   --> $DIR/inference_unstable.rs:16:20
    |
 LL |     assert_eq!('x'.ipu_flatten(), 1);
@@ -10,7 +10,7 @@ LL |     assert_eq!('x'.ipu_flatten(), 1);
    = help: add `#![feature(ipu_flatten)]` to the crate attributes to enable `inference_unstable_iterator::IpuIterator::ipu_flatten`
    = note: `#[warn(unstable_name_collisions)]` on by default
 
-warning: an associated function with this name may be added to the standard library in the future
+warning: a method with this name may be added to the standard library in the future
   --> $DIR/inference_unstable.rs:19:20
    |
 LL |     assert_eq!('x'.ipu_by_value_vs_by_ref(), 1);
@@ -21,7 +21,7 @@ LL |     assert_eq!('x'.ipu_by_value_vs_by_ref(), 1);
    = help: call with fully qualified syntax `inference_unstable_itertools::IpuItertools::ipu_by_value_vs_by_ref(...)` to keep using the current method
    = help: add `#![feature(ipu_flatten)]` to the crate attributes to enable `inference_unstable_iterator::IpuIterator::ipu_by_value_vs_by_ref`
 
-warning: an associated function with this name may be added to the standard library in the future
+warning: a method with this name may be added to the standard library in the future
   --> $DIR/inference_unstable.rs:22:20
    |
 LL |     assert_eq!('x'.ipu_by_ref_vs_by_ref_mut(), 1);
@@ -32,7 +32,7 @@ LL |     assert_eq!('x'.ipu_by_ref_vs_by_ref_mut(), 1);
    = help: call with fully qualified syntax `inference_unstable_itertools::IpuItertools::ipu_by_ref_vs_by_ref_mut(...)` to keep using the current method
    = help: add `#![feature(ipu_flatten)]` to the crate attributes to enable `inference_unstable_iterator::IpuIterator::ipu_by_ref_vs_by_ref_mut`
 
-warning: an associated function with this name may be added to the standard library in the future
+warning: a method with this name may be added to the standard library in the future
   --> $DIR/inference_unstable.rs:25:40
    |
 LL |     assert_eq!((&mut 'x' as *mut char).ipu_by_mut_ptr_vs_by_const_ptr(), 1);
diff --git a/tests/ui/inference/inference_unstable_featured.stderr b/tests/ui/inference/inference_unstable_featured.stderr
index 4ddede29c85..dc43abf52c6 100644
--- a/tests/ui/inference/inference_unstable_featured.stderr
+++ b/tests/ui/inference/inference_unstable_featured.stderr
@@ -6,11 +6,11 @@ LL |     assert_eq!('x'.ipu_flatten(), 0);
    |
    = note: candidate #1 is defined in an impl of the trait `IpuIterator` for the type `char`
    = note: candidate #2 is defined in an impl of the trait `IpuItertools` for the type `char`
-help: disambiguate the associated function for candidate #1
+help: disambiguate the method for candidate #1
    |
 LL |     assert_eq!(IpuIterator::ipu_flatten(&'x'), 0);
    |                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-help: disambiguate the associated function for candidate #2
+help: disambiguate the method for candidate #2
    |
 LL |     assert_eq!(IpuItertools::ipu_flatten(&'x'), 0);
    |                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
diff --git a/tests/ui/inference/issue-71732.stderr b/tests/ui/inference/issue-71732.stderr
index 01b37f2acaa..e89e4dca619 100644
--- a/tests/ui/inference/issue-71732.stderr
+++ b/tests/ui/inference/issue-71732.stderr
@@ -4,7 +4,7 @@ error[E0283]: type annotations needed
 LL |         .get(&"key".into())
    |          ^^^ ------------- type must be known at this point
    |          |
-   |          cannot infer type of the type parameter `Q` declared on the associated function `get`
+   |          cannot infer type of the type parameter `Q` declared on the method `get`
    |
    = note: multiple `impl`s satisfying `String: Borrow<_>` found in the following crates: `alloc`, `core`:
            - impl Borrow<str> for String;
diff --git a/tests/ui/inference/question-mark-type-infer.stderr b/tests/ui/inference/question-mark-type-infer.stderr
index a9cb7e5257c..7a1e850d157 100644
--- a/tests/ui/inference/question-mark-type-infer.stderr
+++ b/tests/ui/inference/question-mark-type-infer.stderr
@@ -2,7 +2,7 @@ error[E0282]: type annotations needed
   --> $DIR/question-mark-type-infer.rs:10:21
    |
 LL |     l.iter().map(f).collect()?
-   |                     ^^^^^^^ cannot infer type of the type parameter `B` declared on the associated function `collect`
+   |                     ^^^^^^^ cannot infer type of the type parameter `B` declared on the method `collect`
    |
 help: consider specifying the generic argument
    |
diff --git a/tests/ui/infinite/auxiliary/alias.rs b/tests/ui/infinite/auxiliary/alias.rs
new file mode 100644
index 00000000000..59add7eb18b
--- /dev/null
+++ b/tests/ui/infinite/auxiliary/alias.rs
@@ -0,0 +1,2 @@
+pub struct W<T>(T);
+pub type Wrapper<T> = W<T>;
diff --git a/tests/ui/infinite/infinite-alias.rs b/tests/ui/infinite/infinite-alias.rs
new file mode 100644
index 00000000000..45356f359ce
--- /dev/null
+++ b/tests/ui/infinite/infinite-alias.rs
@@ -0,0 +1,9 @@
+// aux-build: alias.rs
+// regression test for 108160
+
+extern crate alias;
+
+use alias::Wrapper;
+struct Rec(Wrapper<Rec>); //~ ERROR recursive type `Rec` has infinite
+
+fn main() {}
diff --git a/tests/ui/infinite/infinite-alias.stderr b/tests/ui/infinite/infinite-alias.stderr
new file mode 100644
index 00000000000..9d9265f8c36
--- /dev/null
+++ b/tests/ui/infinite/infinite-alias.stderr
@@ -0,0 +1,14 @@
+error[E0072]: recursive type `Rec` has infinite size
+  --> $DIR/infinite-alias.rs:7:1
+   |
+LL | struct Rec(Wrapper<Rec>);
+   | ^^^^^^^^^^ ------------ recursive without indirection
+   |
+help: insert some indirection (e.g., a `Box`, `Rc`, or `&`) to break the cycle
+   |
+LL | struct Rec(Box<Wrapper<Rec>>);
+   |            ++++            +
+
+error: aborting due to previous error
+
+For more information about this error, try `rustc --explain E0072`.
diff --git a/tests/ui/issues/issue-106755.rs b/tests/ui/issues/issue-106755.rs
new file mode 100644
index 00000000000..46ece725fb7
--- /dev/null
+++ b/tests/ui/issues/issue-106755.rs
@@ -0,0 +1,19 @@
+// compile-flags:-Ztranslate-lang=en_US
+
+#![feature(negative_impls)]
+#![feature(marker_trait_attr)]
+
+#[marker]
+trait MyTrait {}
+
+struct TestType<T>(::std::marker::PhantomData<T>);
+
+unsafe impl<T: MyTrait + 'static> Send for TestType<T> {}
+
+impl<T: MyTrait> !Send for TestType<T> {} //~ ERROR found both positive and negative implementation
+
+unsafe impl<T: 'static> Send for TestType<T> {} //~ ERROR conflicting implementations
+
+impl !Send for TestType<i32> {}
+
+fn main() {}
diff --git a/tests/ui/issues/issue-106755.stderr b/tests/ui/issues/issue-106755.stderr
new file mode 100644
index 00000000000..54397034062
--- /dev/null
+++ b/tests/ui/issues/issue-106755.stderr
@@ -0,0 +1,22 @@
+error[E0751]: found both positive and negative implementation of trait `Send` for type `TestType<_>`:
+  --> $DIR/issue-106755.rs:13:1
+   |
+LL | unsafe impl<T: MyTrait + 'static> Send for TestType<T> {}
+   | ------------------------------------------------------ positive implementation here
+LL |
+LL | impl<T: MyTrait> !Send for TestType<T> {}
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ negative implementation here
+
+error[E0119]: conflicting implementations of trait `Send` for type `TestType<_>`
+  --> $DIR/issue-106755.rs:15:1
+   |
+LL | unsafe impl<T: MyTrait + 'static> Send for TestType<T> {}
+   | ------------------------------------------------------ first implementation here
+...
+LL | unsafe impl<T: 'static> Send for TestType<T> {}
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ conflicting implementation for `TestType<_>`
+
+error: aborting due to 2 previous errors
+
+Some errors have detailed explanations: E0119, E0751.
+For more information about an error, try `rustc --explain E0119`.
diff --git a/tests/ui/issues/issue-11374.stderr b/tests/ui/issues/issue-11374.stderr
index ef28c81d857..6e1fb1540bb 100644
--- a/tests/ui/issues/issue-11374.stderr
+++ b/tests/ui/issues/issue-11374.stderr
@@ -10,7 +10,7 @@ LL |     c.read_to(v);
    |
    = note: expected mutable reference `&mut [u8]`
                          found struct `Vec<_>`
-note: associated function defined here
+note: method defined here
   --> $DIR/issue-11374.rs:13:12
    |
 LL |     pub fn read_to(&mut self, vec: &mut [u8]) {
diff --git a/tests/ui/issues/issue-17337.stderr b/tests/ui/issues/issue-17337.stderr
index 34c2eb05fff..55e51e566d9 100644
--- a/tests/ui/issues/issue-17337.stderr
+++ b/tests/ui/issues/issue-17337.stderr
@@ -1,4 +1,4 @@
-error: use of deprecated associated function `Foo::foo`: text
+error: use of deprecated method `Foo::foo`: text
   --> $DIR/issue-17337.rs:16:6
    |
 LL |     .foo();
diff --git a/tests/ui/issues/issue-18423.rs b/tests/ui/issues/issue-18423.rs
index a81b32f050c..675fd041154 100644
--- a/tests/ui/issues/issue-18423.rs
+++ b/tests/ui/issues/issue-18423.rs
@@ -2,7 +2,7 @@
 
 struct Foo<'a> {
     x: Box<'a, isize>
-    //~^ ERROR this struct takes 0 lifetime arguments but 1 lifetime argument was supplied
+    //~^ ERROR struct takes 0 lifetime arguments but 1 lifetime argument was supplied
 }
 
 fn main() { }
diff --git a/tests/ui/issues/issue-18423.stderr b/tests/ui/issues/issue-18423.stderr
index bbf79366244..5d154dbbbdd 100644
--- a/tests/ui/issues/issue-18423.stderr
+++ b/tests/ui/issues/issue-18423.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this struct takes 0 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: struct takes 0 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/issue-18423.rs:4:8
    |
 LL |     x: Box<'a, isize>
diff --git a/tests/ui/issues/issue-18446.stderr b/tests/ui/issues/issue-18446.stderr
index 939cf029253..602b80c6824 100644
--- a/tests/ui/issues/issue-18446.stderr
+++ b/tests/ui/issues/issue-18446.stderr
@@ -14,7 +14,7 @@ note: candidate #2 is defined in the trait `T`
    |
 LL |     fn foo(&self);
    |     ^^^^^^^^^^^^^^
-help: disambiguate the associated function for candidate #2
+help: disambiguate the method for candidate #2
    |
 LL |     T::foo(&x);
    |     ~~~~~~~~~~
diff --git a/tests/ui/issues/issue-21202.rs b/tests/ui/issues/issue-21202.rs
index f62de7ce7db..2c5f1394449 100644
--- a/tests/ui/issues/issue-21202.rs
+++ b/tests/ui/issues/issue-21202.rs
@@ -8,7 +8,7 @@ mod B {
     use crate1::A::Foo;
     fn bar(f: Foo) {
         Foo::foo(&f);
-        //~^ ERROR: associated function `foo` is private
+        //~^ ERROR: method `foo` is private
     }
 }
 
diff --git a/tests/ui/issues/issue-21202.stderr b/tests/ui/issues/issue-21202.stderr
index 1d2816feda9..e7c3f2f9a07 100644
--- a/tests/ui/issues/issue-21202.stderr
+++ b/tests/ui/issues/issue-21202.stderr
@@ -1,13 +1,13 @@
-error[E0624]: associated function `foo` is private
+error[E0624]: method `foo` is private
   --> $DIR/issue-21202.rs:10:14
    |
 LL |         Foo::foo(&f);
-   |              ^^^ private associated function
+   |              ^^^ private method
    |
   ::: $DIR/auxiliary/issue-21202.rs:4:9
    |
 LL |         fn foo(&self) { }
-   |         ------------- private associated function defined here
+   |         ------------- private method defined here
 
 error: aborting due to previous error
 
diff --git a/tests/ui/issues/issue-23041.stderr b/tests/ui/issues/issue-23041.stderr
index 6592b76a39f..4271c67c3bc 100644
--- a/tests/ui/issues/issue-23041.stderr
+++ b/tests/ui/issues/issue-23041.stderr
@@ -2,7 +2,7 @@ error[E0282]: type annotations needed
   --> $DIR/issue-23041.rs:6:7
    |
 LL |     b.downcast_ref::<fn(_)->_>();
-   |       ^^^^^^^^^^^^ cannot infer type of the type parameter `T` declared on the associated function `downcast_ref`
+   |       ^^^^^^^^^^^^ cannot infer type of the type parameter `T` declared on the method `downcast_ref`
    |
 help: consider specifying the generic argument
    |
diff --git a/tests/ui/issues/issue-26094.rs b/tests/ui/issues/issue-26094.rs
index abf3543ddb9..2742529edd3 100644
--- a/tests/ui/issues/issue-26094.rs
+++ b/tests/ui/issues/issue-26094.rs
@@ -1,7 +1,7 @@
 macro_rules! some_macro {
-    ($other: expr) => ({
+    ($other: expr) => {{
         $other(None) //~ NOTE unexpected argument of type `Option<_>`
-    })
+    }};
 }
 
 fn some_function() {} //~ NOTE defined here
@@ -9,5 +9,4 @@ fn some_function() {} //~ NOTE defined here
 fn main() {
     some_macro!(some_function);
     //~^ ERROR function takes 0 arguments but 1 argument was supplied
-    //~| NOTE in this expansion of some_macro!
 }
diff --git a/tests/ui/issues/issue-26094.stderr b/tests/ui/issues/issue-26094.stderr
index 608d2c7aff9..ecdf48470f7 100644
--- a/tests/ui/issues/issue-26094.stderr
+++ b/tests/ui/issues/issue-26094.stderr
@@ -2,10 +2,7 @@ error[E0061]: this function takes 0 arguments but 1 argument was supplied
   --> $DIR/issue-26094.rs:10:17
    |
 LL |         $other(None)
-   |                ----
-   |                |
-   |                unexpected argument of type `Option<_>`
-   |                help: remove the extra argument
+   |                ---- unexpected argument of type `Option<_>`
 ...
 LL |     some_macro!(some_function);
    |                 ^^^^^^^^^^^^^
diff --git a/tests/ui/issues/issue-30438-c.rs b/tests/ui/issues/issue-30438-c.rs
index 4cf634245be..813c1d3e2cc 100644
--- a/tests/ui/issues/issue-30438-c.rs
+++ b/tests/ui/issues/issue-30438-c.rs
@@ -5,7 +5,6 @@ trait Trait { type Out; }
 struct Test<'a> { s: &'a str }
 
 fn silly<'y, 'z>(_s: &'y Test<'z>) -> &'y <Test<'z> as Trait>::Out where 'z: 'static {
-    //~^ WARN unnecessary lifetime parameter `'z`
     let x = Test { s: "this cannot last" };
     &x
     //~^ ERROR: cannot return reference to local variable `x`
diff --git a/tests/ui/issues/issue-30438-c.stderr b/tests/ui/issues/issue-30438-c.stderr
index a7a5c0500fd..7c001088097 100644
--- a/tests/ui/issues/issue-30438-c.stderr
+++ b/tests/ui/issues/issue-30438-c.stderr
@@ -1,17 +1,9 @@
-warning: unnecessary lifetime parameter `'z`
-  --> $DIR/issue-30438-c.rs:7:74
-   |
-LL | fn silly<'y, 'z>(_s: &'y Test<'z>) -> &'y <Test<'z> as Trait>::Out where 'z: 'static {
-   |                                                                          ^^
-   |
-   = help: you can use the `'static` lifetime directly, in place of `'z`
-
 error[E0515]: cannot return reference to local variable `x`
-  --> $DIR/issue-30438-c.rs:10:5
+  --> $DIR/issue-30438-c.rs:9:5
    |
 LL |     &x
    |     ^^ returns a reference to data owned by the current function
 
-error: aborting due to previous error; 1 warning emitted
+error: aborting due to previous error
 
 For more information about this error, try `rustc --explain E0515`.
diff --git a/tests/ui/issues/issue-3214.rs b/tests/ui/issues/issue-3214.rs
index 928a65938b7..e3c07bb3f72 100644
--- a/tests/ui/issues/issue-3214.rs
+++ b/tests/ui/issues/issue-3214.rs
@@ -4,7 +4,7 @@ fn foo<T>() {
     }
 
     impl<T> Drop for Foo<T> {
-        //~^ ERROR this struct takes 0 generic arguments but 1 generic argument
+        //~^ ERROR struct takes 0 generic arguments but 1 generic argument
         fn drop(&mut self) {}
     }
 }
diff --git a/tests/ui/issues/issue-3214.stderr b/tests/ui/issues/issue-3214.stderr
index aa0b5ce64b4..7a2d772f0a1 100644
--- a/tests/ui/issues/issue-3214.stderr
+++ b/tests/ui/issues/issue-3214.stderr
@@ -8,7 +8,7 @@ LL |     struct Foo {
 LL |         x: T,
    |            ^ use of generic parameter from outer function
 
-error[E0107]: this struct takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: struct takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/issue-3214.rs:6:22
    |
 LL |     impl<T> Drop for Foo<T> {
diff --git a/tests/ui/issues/issue-3702-2.stderr b/tests/ui/issues/issue-3702-2.stderr
index 1fd64ca90aa..0b94c3135a1 100644
--- a/tests/ui/issues/issue-3702-2.stderr
+++ b/tests/ui/issues/issue-3702-2.stderr
@@ -14,11 +14,11 @@ note: candidate #2 is defined in an impl of the trait `Add` for the type `isize`
    |
 LL |     fn to_int(&self) -> isize { *self }
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^
-help: disambiguate the associated function for candidate #1
+help: disambiguate the method for candidate #1
    |
 LL |         ToPrimitive::to_int(&self) + other.to_int()
    |         ~~~~~~~~~~~~~~~~~~~~~~~~~~
-help: disambiguate the associated function for candidate #2
+help: disambiguate the method for candidate #2
    |
 LL |         Add::to_int(&self) + other.to_int()
    |         ~~~~~~~~~~~~~~~~~~
diff --git a/tests/ui/issues/issue-3763.rs b/tests/ui/issues/issue-3763.rs
index 2e72d39cb32..893009a2cd9 100644
--- a/tests/ui/issues/issue-3763.rs
+++ b/tests/ui/issues/issue-3763.rs
@@ -20,9 +20,9 @@ fn main() {
     let _woohoo = (Box::new(my_struct)).priv_field;
     //~^ ERROR field `priv_field` of struct `MyStruct` is private
 
-    (&my_struct).happyfun();               //~ ERROR associated function `happyfun` is private
+    (&my_struct).happyfun();               //~ ERROR method `happyfun` is private
 
-    (Box::new(my_struct)).happyfun();          //~ ERROR associated function `happyfun` is private
+    (Box::new(my_struct)).happyfun();          //~ ERROR method `happyfun` is private
     let nope = my_struct.priv_field;
     //~^ ERROR field `priv_field` of struct `MyStruct` is private
 }
diff --git a/tests/ui/issues/issue-3763.stderr b/tests/ui/issues/issue-3763.stderr
index a09c8421bb7..d101e4c33ad 100644
--- a/tests/ui/issues/issue-3763.stderr
+++ b/tests/ui/issues/issue-3763.stderr
@@ -10,23 +10,23 @@ error[E0616]: field `priv_field` of struct `MyStruct` is private
 LL |     let _woohoo = (Box::new(my_struct)).priv_field;
    |                                         ^^^^^^^^^^ private field
 
-error[E0624]: associated function `happyfun` is private
+error[E0624]: method `happyfun` is private
   --> $DIR/issue-3763.rs:23:18
    |
 LL |         fn happyfun(&self) {}
-   |         ------------------ private associated function defined here
+   |         ------------------ private method defined here
 ...
 LL |     (&my_struct).happyfun();
-   |                  ^^^^^^^^ private associated function
+   |                  ^^^^^^^^ private method
 
-error[E0624]: associated function `happyfun` is private
+error[E0624]: method `happyfun` is private
   --> $DIR/issue-3763.rs:25:27
    |
 LL |         fn happyfun(&self) {}
-   |         ------------------ private associated function defined here
+   |         ------------------ private method defined here
 ...
 LL |     (Box::new(my_struct)).happyfun();
-   |                           ^^^^^^^^ private associated function
+   |                           ^^^^^^^^ private method
 
 error[E0616]: field `priv_field` of struct `MyStruct` is private
   --> $DIR/issue-3763.rs:26:26
diff --git a/tests/ui/issues/issue-47715.stderr b/tests/ui/issues/issue-47715.stderr
index 0ee9388bf2b..dadea34b688 100644
--- a/tests/ui/issues/issue-47715.stderr
+++ b/tests/ui/issues/issue-47715.stderr
@@ -1,22 +1,22 @@
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generics
   --> $DIR/issue-47715.rs:9:37
    |
 LL | struct Container<T: Iterable<Item = impl Foo>> {
    |                                     ^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generics
   --> $DIR/issue-47715.rs:14:30
    |
 LL | enum Enum<T: Iterable<Item = impl Foo>> {
    |                              ^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generics
   --> $DIR/issue-47715.rs:19:32
    |
 LL | union Union<T: Iterable<Item = impl Foo> + Copy> {
    |                                ^^^^^^^^
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generic
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in generics
   --> $DIR/issue-47715.rs:24:30
    |
 LL | type Type<T: Iterable<Item = impl Foo>> = T;
diff --git a/tests/ui/issues/issue-48364.stderr b/tests/ui/issues/issue-48364.stderr
index a4c88fd880a..cac4af6a7f3 100644
--- a/tests/ui/issues/issue-48364.stderr
+++ b/tests/ui/issues/issue-48364.stderr
@@ -8,7 +8,7 @@ LL |     b"".starts_with(stringify!(foo))
    |
    = note: expected reference `&[u8]`
               found reference `&'static str`
-note: associated function defined here
+note: method defined here
   --> $SRC_DIR/core/src/slice/mod.rs:LL:COL
    = note: this error originates in the macro `stringify` (in Nightly builds, run with -Z macro-backtrace for more info)
 
diff --git a/tests/ui/issues/issue-53251.rs b/tests/ui/issues/issue-53251.rs
index 240826a161d..da3ba63ef67 100644
--- a/tests/ui/issues/issue-53251.rs
+++ b/tests/ui/issues/issue-53251.rs
@@ -9,8 +9,8 @@ macro_rules! impl_add {
         $(
             fn $n() {
                 S::f::<i64>();
-                //~^ ERROR this associated function takes 0 generic
-                //~| ERROR this associated function takes 0 generic
+                //~^ ERROR associated function takes 0 generic
+                //~| ERROR associated function takes 0 generic
             }
         )*
     }
diff --git a/tests/ui/issues/issue-53251.stderr b/tests/ui/issues/issue-53251.stderr
index cee9a5deb05..d5f14e8deb9 100644
--- a/tests/ui/issues/issue-53251.stderr
+++ b/tests/ui/issues/issue-53251.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this associated function takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: associated function takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/issue-53251.rs:11:20
    |
 LL |                 S::f::<i64>();
@@ -16,7 +16,7 @@ LL |     fn f() {}
    |        ^
    = note: this error originates in the macro `impl_add` (in Nightly builds, run with -Z macro-backtrace for more info)
 
-error[E0107]: this associated function takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: associated function takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/issue-53251.rs:11:20
    |
 LL |                 S::f::<i64>();
diff --git a/tests/ui/issues/issue-60218.stderr b/tests/ui/issues/issue-60218.stderr
index dd72b6515dd..563690c9a5d 100644
--- a/tests/ui/issues/issue-60218.stderr
+++ b/tests/ui/issues/issue-60218.stderr
@@ -10,7 +10,7 @@ note: required by a bound in `trigger_error`
   --> $DIR/issue-60218.rs:13:72
    |
 LL | pub fn trigger_error<I, F>(iterable: I, functor: F)
-   |        ------------- required by a bound in this
+   |        ------------- required by a bound in this function
 ...
 LL | for<'t> <Map<<&'t I as IntoIterator>::IntoIter, F> as Iterator>::Item: Foo,
    |                                                                        ^^^ required by this bound in `trigger_error`
diff --git a/tests/ui/issues/issue-60622.rs b/tests/ui/issues/issue-60622.rs
index 8e230c615bc..7b9443eee50 100644
--- a/tests/ui/issues/issue-60622.rs
+++ b/tests/ui/issues/issue-60622.rs
@@ -9,7 +9,7 @@ impl Borked {
 fn run_wild<T>(b: &Borked) {
     b.a::<'_, T>();
     //~^ ERROR cannot specify lifetime arguments explicitly if late bound lifetime parameters are present
-    //~| ERROR this associated function takes 0 generic arguments but 1 generic argument
+    //~| ERROR method takes 0 generic arguments but 1 generic argument
     //~| WARN this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
 }
 
diff --git a/tests/ui/issues/issue-60622.stderr b/tests/ui/issues/issue-60622.stderr
index ecf1ae758dd..43da2773940 100644
--- a/tests/ui/issues/issue-60622.stderr
+++ b/tests/ui/issues/issue-60622.stderr
@@ -16,7 +16,7 @@ LL | #![deny(warnings)]
    |         ^^^^^^^^
    = note: `#[deny(late_bound_lifetime_arguments)]` implied by `#[deny(warnings)]`
 
-error[E0107]: this associated function takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: method takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/issue-60622.rs:10:7
    |
 LL |     b.a::<'_, T>();
@@ -24,7 +24,7 @@ LL |     b.a::<'_, T>();
    |       |
    |       expected 0 generic arguments
    |
-note: associated function defined here, with 0 generic parameters
+note: method defined here, with 0 generic parameters
   --> $DIR/issue-60622.rs:6:8
    |
 LL |     fn a(&self) {}
diff --git a/tests/ui/issues/issue-65634-raw-ident-suggestion.edition2015.stderr b/tests/ui/issues/issue-65634-raw-ident-suggestion.edition2015.stderr
index d0cb16995af..4af3672ef72 100644
--- a/tests/ui/issues/issue-65634-raw-ident-suggestion.edition2015.stderr
+++ b/tests/ui/issues/issue-65634-raw-ident-suggestion.edition2015.stderr
@@ -14,11 +14,11 @@ note: candidate #2 is defined in an impl of the trait `await` for the type `r#fn
    |
 LL |     fn r#struct(&self) {
    |     ^^^^^^^^^^^^^^^^^^
-help: disambiguate the associated function for candidate #1
+help: disambiguate the method for candidate #1
    |
 LL |     async::r#struct(&r#fn {});
    |     ~~~~~~~~~~~~~~~~~~~~~~~~~
-help: disambiguate the associated function for candidate #2
+help: disambiguate the method for candidate #2
    |
 LL |     await::r#struct(&r#fn {});
    |     ~~~~~~~~~~~~~~~~~~~~~~~~~
diff --git a/tests/ui/issues/issue-65634-raw-ident-suggestion.edition2018.stderr b/tests/ui/issues/issue-65634-raw-ident-suggestion.edition2018.stderr
index a75c1c41363..2b96a0fb5e5 100644
--- a/tests/ui/issues/issue-65634-raw-ident-suggestion.edition2018.stderr
+++ b/tests/ui/issues/issue-65634-raw-ident-suggestion.edition2018.stderr
@@ -14,11 +14,11 @@ note: candidate #2 is defined in an impl of the trait `r#await` for the type `r#
    |
 LL |     fn r#struct(&self) {
    |     ^^^^^^^^^^^^^^^^^^
-help: disambiguate the associated function for candidate #1
+help: disambiguate the method for candidate #1
    |
 LL |     r#async::r#struct(&r#fn {});
    |     ~~~~~~~~~~~~~~~~~~~~~~~~~~~
-help: disambiguate the associated function for candidate #2
+help: disambiguate the method for candidate #2
    |
 LL |     r#await::r#struct(&r#fn {});
    |     ~~~~~~~~~~~~~~~~~~~~~~~~~~~
diff --git a/tests/ui/issues/issue-69455.stderr b/tests/ui/issues/issue-69455.stderr
index fc343bb54aa..d3e307fba2c 100644
--- a/tests/ui/issues/issue-69455.stderr
+++ b/tests/ui/issues/issue-69455.stderr
@@ -2,7 +2,7 @@ error[E0284]: type annotations needed
   --> $DIR/issue-69455.rs:29:41
    |
 LL |     println!("{}", 23u64.test(xs.iter().sum()));
-   |                          ----           ^^^ cannot infer type of the type parameter `S` declared on the associated function `sum`
+   |                          ----           ^^^ cannot infer type of the type parameter `S` declared on the method `sum`
    |                          |
    |                          type must be known at this point
    |
@@ -16,7 +16,7 @@ error[E0283]: type annotations needed
   --> $DIR/issue-69455.rs:29:41
    |
 LL |     println!("{}", 23u64.test(xs.iter().sum()));
-   |                          ----           ^^^ cannot infer type of the type parameter `S` declared on the associated function `sum`
+   |                          ----           ^^^ cannot infer type of the type parameter `S` declared on the method `sum`
    |                          |
    |                          required by a bound introduced by this call
    |
diff --git a/tests/ui/issues/issue-69683.stderr b/tests/ui/issues/issue-69683.stderr
index 193de1a35cf..c428ea9ea2c 100644
--- a/tests/ui/issues/issue-69683.stderr
+++ b/tests/ui/issues/issue-69683.stderr
@@ -31,7 +31,7 @@ LL |     u8: Element<I>,
    |         ^^^^^^^^^^ required by this bound in `Foo::foo`
 LL | {
 LL |     fn foo(self, x: <u8 as Element<I>>::Array);
-   |        --- required by a bound in this
+   |        --- required by a bound in this associated function
 help: try using a fully qualified path to specify the expected types
    |
 LL |     <u16 as Foo<I>>::foo(0u16, b);
diff --git a/tests/ui/issues/issue-70093/issue-70093-link-directives.rs b/tests/ui/issues/issue-70093/issue-70093-link-directives.rs
new file mode 100644
index 00000000000..83f9b16c408
--- /dev/null
+++ b/tests/ui/issues/issue-70093/issue-70093-link-directives.rs
@@ -0,0 +1,10 @@
+// run-pass
+// compile-flags: -Zlink-directives=no
+// ignore-windows - this will probably only work on unixish systems
+// ignore-fuchsia - missing __libc_start_main for some reason (#84733)
+// ignore-cross-compile - default-linker-libraries=yes doesn't play well with cross compiling
+
+#[link(name = "some-random-non-existent-library", kind = "static")]
+extern "C" {}
+
+fn main() {}
diff --git a/tests/ui/issues/issue-70093.rs b/tests/ui/issues/issue-70093/issue-70093.rs
index 86459dc904a..86459dc904a 100644
--- a/tests/ui/issues/issue-70093.rs
+++ b/tests/ui/issues/issue-70093/issue-70093.rs
diff --git a/tests/ui/lang-items/bad-add-impl.rs b/tests/ui/lang-items/bad-add-impl.rs
new file mode 100644
index 00000000000..0c44edbe51a
--- /dev/null
+++ b/tests/ui/lang-items/bad-add-impl.rs
@@ -0,0 +1,18 @@
+#![feature(no_core)]
+#![feature(lang_items)]
+#![no_core]
+
+#[lang = "sized"]
+trait Sized {}
+
+#[lang = "add"]
+trait Add<T> {
+    const add: u32 = 1u32;
+}
+
+impl Add<u32> for u32 {}
+
+fn main() {
+    1u32 + 1u32;
+    //~^ ERROR cannot add `u32` to `u32`
+}
diff --git a/tests/ui/lang-items/bad-add-impl.stderr b/tests/ui/lang-items/bad-add-impl.stderr
new file mode 100644
index 00000000000..3143729f99b
--- /dev/null
+++ b/tests/ui/lang-items/bad-add-impl.stderr
@@ -0,0 +1,11 @@
+error[E0369]: cannot add `u32` to `u32`
+  --> $DIR/bad-add-impl.rs:16:10
+   |
+LL |     1u32 + 1u32;
+   |     ---- ^ ---- u32
+   |     |
+   |     u32
+
+error: aborting due to previous error
+
+For more information about this error, try `rustc --explain E0369`.
diff --git a/tests/ui/lang-items/fn-fn_mut-call-ill-formed.bad_item.stderr b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.bad_item.stderr
new file mode 100644
index 00000000000..ff603111e94
--- /dev/null
+++ b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.bad_item.stderr
@@ -0,0 +1,18 @@
+error: failed to find an overloaded call trait for closure call
+  --> $DIR/fn-fn_mut-call-ill-formed.rs:39:5
+   |
+LL |     a();
+   |     ^^^
+   |
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
+
+error: failed to find an overloaded call trait for closure call
+  --> $DIR/fn-fn_mut-call-ill-formed.rs:43:5
+   |
+LL |     b();
+   |     ^^^
+   |
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
+
+error: aborting due to 2 previous errors
+
diff --git a/tests/ui/lang-items/fn-fn_mut-call-ill-formed.bad_sig.stderr b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.bad_sig.stderr
new file mode 100644
index 00000000000..ff603111e94
--- /dev/null
+++ b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.bad_sig.stderr
@@ -0,0 +1,18 @@
+error: failed to find an overloaded call trait for closure call
+  --> $DIR/fn-fn_mut-call-ill-formed.rs:39:5
+   |
+LL |     a();
+   |     ^^^
+   |
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
+
+error: failed to find an overloaded call trait for closure call
+  --> $DIR/fn-fn_mut-call-ill-formed.rs:43:5
+   |
+LL |     b();
+   |     ^^^
+   |
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
+
+error: aborting due to 2 previous errors
+
diff --git a/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_bad_item.stderr b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_bad_item.stderr
new file mode 100644
index 00000000000..02e33c597fe
--- /dev/null
+++ b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_bad_item.stderr
@@ -0,0 +1,18 @@
+error: failed to find an overloaded call trait for closure call
+  --> $DIR/fn-fn_mut-call-ill-formed.rs:42:5
+   |
+LL |     a();
+   |     ^^^
+   |
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
+
+error: failed to find an overloaded call trait for closure call
+  --> $DIR/fn-fn_mut-call-ill-formed.rs:47:5
+   |
+LL |     b();
+   |     ^^^
+   |
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
+
+error: aborting due to 2 previous errors
+
diff --git a/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_bad_sig.stderr b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_bad_sig.stderr
new file mode 100644
index 00000000000..02e33c597fe
--- /dev/null
+++ b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_bad_sig.stderr
@@ -0,0 +1,18 @@
+error: failed to find an overloaded call trait for closure call
+  --> $DIR/fn-fn_mut-call-ill-formed.rs:42:5
+   |
+LL |     a();
+   |     ^^^
+   |
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
+
+error: failed to find an overloaded call trait for closure call
+  --> $DIR/fn-fn_mut-call-ill-formed.rs:47:5
+   |
+LL |     b();
+   |     ^^^
+   |
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
+
+error: aborting due to 2 previous errors
+
diff --git a/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_mut_bad_item.stderr b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_mut_bad_item.stderr
new file mode 100644
index 00000000000..02e33c597fe
--- /dev/null
+++ b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_mut_bad_item.stderr
@@ -0,0 +1,18 @@
+error: failed to find an overloaded call trait for closure call
+  --> $DIR/fn-fn_mut-call-ill-formed.rs:42:5
+   |
+LL |     a();
+   |     ^^^
+   |
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
+
+error: failed to find an overloaded call trait for closure call
+  --> $DIR/fn-fn_mut-call-ill-formed.rs:47:5
+   |
+LL |     b();
+   |     ^^^
+   |
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
+
+error: aborting due to 2 previous errors
+
diff --git a/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_mut_bad_sig.stderr b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_mut_bad_sig.stderr
new file mode 100644
index 00000000000..02e33c597fe
--- /dev/null
+++ b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_mut_bad_sig.stderr
@@ -0,0 +1,18 @@
+error: failed to find an overloaded call trait for closure call
+  --> $DIR/fn-fn_mut-call-ill-formed.rs:42:5
+   |
+LL |     a();
+   |     ^^^
+   |
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
+
+error: failed to find an overloaded call trait for closure call
+  --> $DIR/fn-fn_mut-call-ill-formed.rs:47:5
+   |
+LL |     b();
+   |     ^^^
+   |
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
+
+error: aborting due to 2 previous errors
+
diff --git a/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_once_bad_item.stderr b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_once_bad_item.stderr
new file mode 100644
index 00000000000..02e33c597fe
--- /dev/null
+++ b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_once_bad_item.stderr
@@ -0,0 +1,18 @@
+error: failed to find an overloaded call trait for closure call
+  --> $DIR/fn-fn_mut-call-ill-formed.rs:42:5
+   |
+LL |     a();
+   |     ^^^
+   |
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
+
+error: failed to find an overloaded call trait for closure call
+  --> $DIR/fn-fn_mut-call-ill-formed.rs:47:5
+   |
+LL |     b();
+   |     ^^^
+   |
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
+
+error: aborting due to 2 previous errors
+
diff --git a/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_once_bad_sig.stderr b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_once_bad_sig.stderr
new file mode 100644
index 00000000000..02e33c597fe
--- /dev/null
+++ b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.fn_once_bad_sig.stderr
@@ -0,0 +1,18 @@
+error: failed to find an overloaded call trait for closure call
+  --> $DIR/fn-fn_mut-call-ill-formed.rs:42:5
+   |
+LL |     a();
+   |     ^^^
+   |
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
+
+error: failed to find an overloaded call trait for closure call
+  --> $DIR/fn-fn_mut-call-ill-formed.rs:47:5
+   |
+LL |     b();
+   |     ^^^
+   |
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
+
+error: aborting due to 2 previous errors
+
diff --git a/tests/ui/lang-items/fn-fn_mut-call-ill-formed.rs b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.rs
index 52bd8136d9c..757c6538d05 100644
--- a/tests/ui/lang-items/fn-fn_mut-call-ill-formed.rs
+++ b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.rs
@@ -1,27 +1,49 @@
-// Make sure that an error is reported if the `call` function of the
-// `fn`/`fn_mut` lang item is grossly ill-formed.
+// revisions: fn_once_bad_item fn_once_bad_sig fn_mut_bad_item fn_mut_bad_sig fn_bad_item fn_bad_sig
 
 #![feature(lang_items)]
 #![feature(no_core)]
 #![no_core]
 
+#[lang = "sized"]
+trait Sized {}
+
+#[cfg(any(fn_bad_item, fn_bad_sig))]
 #[lang = "fn"]
 trait MyFn<T> {
+    #[cfg(fn_bad_sig)]
+    fn call(i: i32) -> i32 { 0 }
+
+    #[cfg(fn_bad_item)]
     const call: i32 = 42;
-    //~^ ERROR: `call` trait item in `fn` lang item must be a function
 }
 
+#[cfg(any(fn_mut_bad_item, fn_mut_bad_sig))]
 #[lang = "fn_mut"]
 trait MyFnMut<T> {
-    fn call(i: i32, j: i32) -> i32 { i + j }
-    //~^ ERROR: first argument of `call` in `fn_mut` lang item must be a reference
+    #[cfg(fn_mut_bad_sig)]
+    fn call_mut(i: i32) -> i32 { 0 }
+
+    #[cfg(fn_mut_bad_item)]
+    const call_mut: i32 = 42;
+}
+
+#[cfg(any(fn_once_bad_item, fn_once_bad_sig))]
+#[lang = "fn_once"]
+trait MyFnOnce<T> {
+    #[cfg(fn_once_bad_sig)]
+    fn call_once(i: i32) -> i32 { 0 }
+
+    #[cfg(fn_once_bad_item)]
+    const call_once: i32 = 42;
 }
 
 fn main() {
     let a = || 42;
     a();
+    //~^ ERROR failed to find an overloaded call trait for closure call
 
     let mut i = 0;
-    let mut b = || { i += 1; };
+    let mut b = || { };
     b();
+    //~^ ERROR failed to find an overloaded call trait for closure call
 }
diff --git a/tests/ui/lang-items/fn-fn_mut-call-ill-formed.stderr b/tests/ui/lang-items/fn-fn_mut-call-ill-formed.stderr
deleted file mode 100644
index 82bdae270c8..00000000000
--- a/tests/ui/lang-items/fn-fn_mut-call-ill-formed.stderr
+++ /dev/null
@@ -1,14 +0,0 @@
-error: `call` trait item in `fn` lang item must be a function
-  --> $DIR/fn-fn_mut-call-ill-formed.rs:10:5
-   |
-LL |     const call: i32 = 42;
-   |     ^^^^^^^^^^^^^^^^^^^^^
-
-error: first argument of `call` in `fn_mut` lang item must be a reference
-  --> $DIR/fn-fn_mut-call-ill-formed.rs:16:16
-   |
-LL |     fn call(i: i32, j: i32) -> i32 { i + j }
-   |                ^^^
-
-error: aborting due to 2 previous errors
-
diff --git a/tests/ui/lang-items/issue-86238.stderr b/tests/ui/lang-items/issue-86238.stderr
index 767e6de2263..c6e811a94fe 100644
--- a/tests/ui/lang-items/issue-86238.stderr
+++ b/tests/ui/lang-items/issue-86238.stderr
@@ -4,7 +4,7 @@ error: failed to find an overloaded call trait for closure call
 LL |     one()
    |     ^^^^^
    |
-   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have associated `call`/`call_mut`/`call_once` functions
+   = help: make sure the `fn`/`fn_mut`/`fn_once` lang items are defined and have correctly defined `call`/`call_mut`/`call_once` methods
 
 error: aborting due to previous error
 
diff --git a/tests/ui/late-bound-lifetimes/mismatched_arg_count.rs b/tests/ui/late-bound-lifetimes/mismatched_arg_count.rs
index 0b331e2039f..792563fd82b 100644
--- a/tests/ui/late-bound-lifetimes/mismatched_arg_count.rs
+++ b/tests/ui/late-bound-lifetimes/mismatched_arg_count.rs
@@ -7,6 +7,6 @@ trait Trait<'a> {
 type Alias<'a, T> = <T as Trait<'a>>::Assoc;
 
 fn bar<'a, T: Trait<'a>>(_: Alias<'a, 'a, T>) {}
-//~^ error: this type alias takes 1 lifetime argument but 2 lifetime arguments were supplied
+//~^ error: type alias takes 1 lifetime argument but 2 lifetime arguments were supplied
 
 fn main() {}
diff --git a/tests/ui/late-bound-lifetimes/mismatched_arg_count.stderr b/tests/ui/late-bound-lifetimes/mismatched_arg_count.stderr
index 3704d9bb957..de58a014ee8 100644
--- a/tests/ui/late-bound-lifetimes/mismatched_arg_count.stderr
+++ b/tests/ui/late-bound-lifetimes/mismatched_arg_count.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this type alias takes 1 lifetime argument but 2 lifetime arguments were supplied
+error[E0107]: type alias takes 1 lifetime argument but 2 lifetime arguments were supplied
   --> $DIR/mismatched_arg_count.rs:9:29
    |
 LL | fn bar<'a, T: Trait<'a>>(_: Alias<'a, 'a, T>) {}
diff --git a/tests/ui/lifetimes/lifetime-errors/ex1-return-one-existing-name-return-type-is-anon.stderr b/tests/ui/lifetimes/lifetime-errors/ex1-return-one-existing-name-return-type-is-anon.stderr
index 4bcd7cf9578..6fd7f67d15e 100644
--- a/tests/ui/lifetimes/lifetime-errors/ex1-return-one-existing-name-return-type-is-anon.stderr
+++ b/tests/ui/lifetimes/lifetime-errors/ex1-return-one-existing-name-return-type-is-anon.stderr
@@ -7,7 +7,7 @@ LL |   fn foo<'a>(&self, x: &'a i32) -> &i32 {
    |          lifetime `'a` defined here
 LL |
 LL |     x
-   |     ^ associated function was supposed to return data with lifetime `'1` but it is returning data with lifetime `'a`
+   |     ^ method was supposed to return data with lifetime `'1` but it is returning data with lifetime `'a`
 
 error: aborting due to previous error
 
diff --git a/tests/ui/lifetimes/lifetime-errors/ex1-return-one-existing-name-self-is-anon.stderr b/tests/ui/lifetimes/lifetime-errors/ex1-return-one-existing-name-self-is-anon.stderr
index 34a64f8a63e..2687266e098 100644
--- a/tests/ui/lifetimes/lifetime-errors/ex1-return-one-existing-name-self-is-anon.stderr
+++ b/tests/ui/lifetimes/lifetime-errors/ex1-return-one-existing-name-self-is-anon.stderr
@@ -7,7 +7,7 @@ LL |     fn foo<'a>(&self, x: &'a Foo) -> &'a Foo {
    |            lifetime `'a` defined here
 LL |
 LL |         if true { x } else { self }
-   |                              ^^^^ associated function was supposed to return data with lifetime `'a` but it is returning data with lifetime `'1`
+   |                              ^^^^ method was supposed to return data with lifetime `'a` but it is returning data with lifetime `'1`
 
 error: aborting due to previous error
 
diff --git a/tests/ui/lifetimes/lifetime-errors/ex3-both-anon-regions-return-type-is-anon.stderr b/tests/ui/lifetimes/lifetime-errors/ex3-both-anon-regions-return-type-is-anon.stderr
index 5601335d275..9ff5e42d732 100644
--- a/tests/ui/lifetimes/lifetime-errors/ex3-both-anon-regions-return-type-is-anon.stderr
+++ b/tests/ui/lifetimes/lifetime-errors/ex3-both-anon-regions-return-type-is-anon.stderr
@@ -6,7 +6,7 @@ LL |   fn foo<'a>(&self, x: &i32) -> &i32 {
    |              |
    |              let's call the lifetime of this reference `'2`
 LL |     x
-   |     ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |     ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
diff --git a/tests/ui/lifetimes/lifetime-errors/ex3-both-anon-regions-self-is-anon.stderr b/tests/ui/lifetimes/lifetime-errors/ex3-both-anon-regions-self-is-anon.stderr
index e221902c4a9..e4c855e11fe 100644
--- a/tests/ui/lifetimes/lifetime-errors/ex3-both-anon-regions-self-is-anon.stderr
+++ b/tests/ui/lifetimes/lifetime-errors/ex3-both-anon-regions-self-is-anon.stderr
@@ -6,7 +6,7 @@ LL |     fn foo<'a>(&self, x: &Foo) -> &Foo {
    |                |
    |                let's call the lifetime of this reference `'2`
 LL |         if true { x } else { self }
-   |                   ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |                   ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
diff --git a/tests/ui/lint/dead-code/in-closure.rs b/tests/ui/lint/dead-code/in-closure.rs
new file mode 100644
index 00000000000..c55634405ed
--- /dev/null
+++ b/tests/ui/lint/dead-code/in-closure.rs
@@ -0,0 +1,16 @@
+// edition: 2021
+
+#![deny(dead_code)]
+
+pub fn foo() {
+    let closure = || {
+        fn a() {}   //~ ERROR function `a` is never used
+    };
+    closure()
+}
+
+pub async fn async_foo() {
+    const A: usize = 1; //~ ERROR constant `A` is never used
+}
+
+fn main() {}
diff --git a/tests/ui/lint/dead-code/in-closure.stderr b/tests/ui/lint/dead-code/in-closure.stderr
new file mode 100644
index 00000000000..deb276be702
--- /dev/null
+++ b/tests/ui/lint/dead-code/in-closure.stderr
@@ -0,0 +1,20 @@
+error: function `a` is never used
+  --> $DIR/in-closure.rs:7:12
+   |
+LL |         fn a() {}
+   |            ^
+   |
+note: the lint level is defined here
+  --> $DIR/in-closure.rs:3:9
+   |
+LL | #![deny(dead_code)]
+   |         ^^^^^^^^^
+
+error: constant `A` is never used
+  --> $DIR/in-closure.rs:13:11
+   |
+LL |     const A: usize = 1;
+   |           ^
+
+error: aborting due to 2 previous errors
+
diff --git a/tests/ui/lint/dead-code/issue-85255.rs b/tests/ui/lint/dead-code/issue-85255.rs
index 043f68137b8..1978bd4e824 100644
--- a/tests/ui/lint/dead-code/issue-85255.rs
+++ b/tests/ui/lint/dead-code/issue-85255.rs
@@ -11,8 +11,8 @@ struct Foo {
 struct Bar;
 
 impl Bar {
-    fn a(&self) -> i32 { 5 } //~ WARNING: associated function `a` is never used
-    pub fn b(&self) -> i32 { 6 } //~ WARNING: associated function `b` is never used
+    fn a(&self) -> i32 { 5 } //~ WARNING: method `a` is never used
+    pub fn b(&self) -> i32 { 6 } //~ WARNING: method `b` is never used
 }
 
 pub(crate) struct Foo1 {
@@ -23,8 +23,8 @@ pub(crate) struct Foo1 {
 pub(crate) struct Bar1;
 
 impl Bar1 {
-    fn a(&self) -> i32 { 5 } //~ WARNING: associated function `a` is never used
-    pub fn b(&self) -> i32 { 6 } //~ WARNING: associated function `b` is never used
+    fn a(&self) -> i32 { 5 } //~ WARNING: method `a` is never used
+    pub fn b(&self) -> i32 { 6 } //~ WARNING: method `b` is never used
 }
 
 pub(crate) struct Foo2 {
@@ -35,8 +35,8 @@ pub(crate) struct Foo2 {
 pub(crate) struct Bar2;
 
 impl Bar2 {
-    fn a(&self) -> i32 { 5 } //~ WARNING: associated function `a` is never used
-    pub fn b(&self) -> i32 { 6 } //~ WARNING: associated function `b` is never used
+    fn a(&self) -> i32 { 5 } //~ WARNING: method `a` is never used
+    pub fn b(&self) -> i32 { 6 } //~ WARNING: method `b` is never used
 }
 
 
diff --git a/tests/ui/lint/dead-code/issue-85255.stderr b/tests/ui/lint/dead-code/issue-85255.stderr
index 3497b952fdd..58a19cf3c99 100644
--- a/tests/ui/lint/dead-code/issue-85255.stderr
+++ b/tests/ui/lint/dead-code/issue-85255.stderr
@@ -34,37 +34,37 @@ LL |     a: i32,
 LL |     pub b: i32,
    |         ^
 
-warning: associated function `a` is never used
+warning: method `a` is never used
   --> $DIR/issue-85255.rs:14:8
    |
 LL |     fn a(&self) -> i32 { 5 }
    |        ^
 
-warning: associated function `b` is never used
+warning: method `b` is never used
   --> $DIR/issue-85255.rs:15:12
    |
 LL |     pub fn b(&self) -> i32 { 6 }
    |            ^
 
-warning: associated function `a` is never used
+warning: method `a` is never used
   --> $DIR/issue-85255.rs:26:8
    |
 LL |     fn a(&self) -> i32 { 5 }
    |        ^
 
-warning: associated function `b` is never used
+warning: method `b` is never used
   --> $DIR/issue-85255.rs:27:12
    |
 LL |     pub fn b(&self) -> i32 { 6 }
    |            ^
 
-warning: associated function `a` is never used
+warning: method `a` is never used
   --> $DIR/issue-85255.rs:38:8
    |
 LL |     fn a(&self) -> i32 { 5 }
    |        ^
 
-warning: associated function `b` is never used
+warning: method `b` is never used
   --> $DIR/issue-85255.rs:39:12
    |
 LL |     pub fn b(&self) -> i32 { 6 }
diff --git a/tests/ui/lint/dead-code/lint-dead-code-3.rs b/tests/ui/lint/dead-code/lint-dead-code-3.rs
index 293fcdbc5ee..20b568054df 100644
--- a/tests/ui/lint/dead-code/lint-dead-code-3.rs
+++ b/tests/ui/lint/dead-code/lint-dead-code-3.rs
@@ -13,7 +13,7 @@ extern "C" {
 
 struct Foo; //~ ERROR: struct `Foo` is never constructed
 impl Foo {
-    fn foo(&self) { //~ ERROR: associated function `foo` is never used
+    fn foo(&self) { //~ ERROR: method `foo` is never used
         bar()
     }
 }
diff --git a/tests/ui/lint/dead-code/lint-dead-code-3.stderr b/tests/ui/lint/dead-code/lint-dead-code-3.stderr
index 26fc13bae08..797b7559c01 100644
--- a/tests/ui/lint/dead-code/lint-dead-code-3.stderr
+++ b/tests/ui/lint/dead-code/lint-dead-code-3.stderr
@@ -34,7 +34,7 @@ error: function `blah` is never used
 LL |         fn blah() {}
    |            ^^^^
 
-error: associated function `foo` is never used
+error: method `foo` is never used
   --> $DIR/lint-dead-code-3.rs:16:8
    |
 LL |     fn foo(&self) {
diff --git a/tests/ui/lint/invalid_value.stderr b/tests/ui/lint/invalid_value.stderr
index 48fd4169da7..57531b0968f 100644
--- a/tests/ui/lint/invalid_value.stderr
+++ b/tests/ui/lint/invalid_value.stderr
@@ -61,10 +61,7 @@ error: the type `!` does not permit zero-initialization
   --> $DIR/invalid_value.rs:65:23
    |
 LL |         let _val: ! = mem::zeroed();
-   |                       ^^^^^^^^^^^^^
-   |                       |
-   |                       this code causes undefined behavior when executed
-   |                       help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
+   |                       ^^^^^^^^^^^^^ this code causes undefined behavior when executed
    |
    = note: the `!` type has no valid value
 
@@ -72,10 +69,7 @@ error: the type `!` does not permit being left uninitialized
   --> $DIR/invalid_value.rs:66:23
    |
 LL |         let _val: ! = mem::uninitialized();
-   |                       ^^^^^^^^^^^^^^^^^^^^
-   |                       |
-   |                       this code causes undefined behavior when executed
-   |                       help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
+   |                       ^^^^^^^^^^^^^^^^^^^^ this code causes undefined behavior when executed
    |
    = note: the `!` type has no valid value
 
@@ -83,10 +77,7 @@ error: the type `(i32, !)` does not permit zero-initialization
   --> $DIR/invalid_value.rs:68:30
    |
 LL |         let _val: (i32, !) = mem::zeroed();
-   |                              ^^^^^^^^^^^^^
-   |                              |
-   |                              this code causes undefined behavior when executed
-   |                              help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
+   |                              ^^^^^^^^^^^^^ this code causes undefined behavior when executed
    |
    = note: the `!` type has no valid value
 
@@ -94,10 +85,7 @@ error: the type `(i32, !)` does not permit being left uninitialized
   --> $DIR/invalid_value.rs:69:30
    |
 LL |         let _val: (i32, !) = mem::uninitialized();
-   |                              ^^^^^^^^^^^^^^^^^^^^
-   |                              |
-   |                              this code causes undefined behavior when executed
-   |                              help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
+   |                              ^^^^^^^^^^^^^^^^^^^^ this code causes undefined behavior when executed
    |
    = note: integers must be initialized
 
@@ -105,10 +93,7 @@ error: the type `Void` does not permit zero-initialization
   --> $DIR/invalid_value.rs:71:26
    |
 LL |         let _val: Void = mem::zeroed();
-   |                          ^^^^^^^^^^^^^
-   |                          |
-   |                          this code causes undefined behavior when executed
-   |                          help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
+   |                          ^^^^^^^^^^^^^ this code causes undefined behavior when executed
    |
 note: enums with no inhabited variants have no valid value
   --> $DIR/invalid_value.rs:12:1
@@ -120,10 +105,7 @@ error: the type `Void` does not permit being left uninitialized
   --> $DIR/invalid_value.rs:72:26
    |
 LL |         let _val: Void = mem::uninitialized();
-   |                          ^^^^^^^^^^^^^^^^^^^^
-   |                          |
-   |                          this code causes undefined behavior when executed
-   |                          help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
+   |                          ^^^^^^^^^^^^^^^^^^^^ this code causes undefined behavior when executed
    |
 note: enums with no inhabited variants have no valid value
   --> $DIR/invalid_value.rs:12:1
@@ -405,10 +387,7 @@ error: the type `TwoUninhabited` does not permit zero-initialization
   --> $DIR/invalid_value.rs:104:36
    |
 LL |         let _val: TwoUninhabited = mem::zeroed();
-   |                                    ^^^^^^^^^^^^^
-   |                                    |
-   |                                    this code causes undefined behavior when executed
-   |                                    help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
+   |                                    ^^^^^^^^^^^^^ this code causes undefined behavior when executed
    |
 note: enums with no inhabited variants have no valid value
   --> $DIR/invalid_value.rs:42:1
@@ -420,10 +399,7 @@ error: the type `TwoUninhabited` does not permit being left uninitialized
   --> $DIR/invalid_value.rs:105:36
    |
 LL |         let _val: TwoUninhabited = mem::uninitialized();
-   |                                    ^^^^^^^^^^^^^^^^^^^^
-   |                                    |
-   |                                    this code causes undefined behavior when executed
-   |                                    help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
+   |                                    ^^^^^^^^^^^^^^^^^^^^ this code causes undefined behavior when executed
    |
 note: enums with no inhabited variants have no valid value
   --> $DIR/invalid_value.rs:42:1
diff --git a/tests/ui/lint/issue-106991.rs b/tests/ui/lint/issue-106991.rs
new file mode 100644
index 00000000000..e4d7f765b4a
--- /dev/null
+++ b/tests/ui/lint/issue-106991.rs
@@ -0,0 +1,13 @@
+fn foo(items: &mut Vec<u8>) {
+    items.sort();
+}
+
+fn bar() -> impl Iterator<Item = i32> {
+    //~^ ERROR expected `foo` to be a fn item that returns `i32`, but it returns `()` [E0271]
+    let mut x: Vec<Vec<u8>> = vec![vec![0, 2, 1], vec![5, 4, 3]];
+    x.iter_mut().map(foo)
+}
+
+fn main() {
+    bar();
+}
diff --git a/tests/ui/lint/issue-106991.stderr b/tests/ui/lint/issue-106991.stderr
new file mode 100644
index 00000000000..7b43f0b2ca8
--- /dev/null
+++ b/tests/ui/lint/issue-106991.stderr
@@ -0,0 +1,11 @@
+error[E0271]: expected `foo` to be a fn item that returns `i32`, but it returns `()`
+  --> $DIR/issue-106991.rs:5:13
+   |
+LL | fn bar() -> impl Iterator<Item = i32> {
+   |             ^^^^^^^^^^^^^^^^^^^^^^^^^ expected `()`, found `i32`
+   |
+   = note: required for `Map<std::slice::IterMut<'_, Vec<u8>>, for<'a> fn(&'a mut Vec<u8>) {foo}>` to implement `Iterator`
+
+error: aborting due to previous error
+
+For more information about this error, try `rustc --explain E0271`.
diff --git a/tests/ui/lint/lint-missing-doc.rs b/tests/ui/lint/lint-missing-doc.rs
index 2297257919e..4a234d2651a 100644
--- a/tests/ui/lint/lint-missing-doc.rs
+++ b/tests/ui/lint/lint-missing-doc.rs
@@ -50,8 +50,10 @@ trait B {
 }
 
 pub trait C { //~ ERROR: missing documentation for a trait
-    fn foo(&self); //~ ERROR: missing documentation for an associated function
-    fn foo_with_impl(&self) {} //~ ERROR: missing documentation for an associated function
+    fn foo(&self); //~ ERROR: missing documentation for a method
+    fn foo_with_impl(&self) {} //~ ERROR: missing documentation for a method
+    fn foo_no_self(); //~ ERROR: missing documentation for an associated function
+    fn foo_no_self_with_impl() {} //~ ERROR: missing documentation for an associated function
 }
 
 #[allow(missing_docs)]
diff --git a/tests/ui/lint/lint-missing-doc.stderr b/tests/ui/lint/lint-missing-doc.stderr
index d68472d4b66..733d062a08b 100644
--- a/tests/ui/lint/lint-missing-doc.stderr
+++ b/tests/ui/lint/lint-missing-doc.stderr
@@ -40,101 +40,113 @@ error: missing documentation for a trait
 LL | pub trait C {
    | ^^^^^^^^^^^
 
-error: missing documentation for an associated function
+error: missing documentation for a method
   --> $DIR/lint-missing-doc.rs:53:5
    |
 LL |     fn foo(&self);
    |     ^^^^^^^^^^^^^^
 
-error: missing documentation for an associated function
+error: missing documentation for a method
   --> $DIR/lint-missing-doc.rs:54:5
    |
 LL |     fn foo_with_impl(&self) {}
    |     ^^^^^^^^^^^^^^^^^^^^^^^
 
+error: missing documentation for an associated function
+  --> $DIR/lint-missing-doc.rs:55:5
+   |
+LL |     fn foo_no_self();
+   |     ^^^^^^^^^^^^^^^^^
+
+error: missing documentation for an associated function
+  --> $DIR/lint-missing-doc.rs:56:5
+   |
+LL |     fn foo_no_self_with_impl() {}
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^
+
 error: missing documentation for an associated type
-  --> $DIR/lint-missing-doc.rs:64:5
+  --> $DIR/lint-missing-doc.rs:66:5
    |
 LL |     type AssociatedType;
    |     ^^^^^^^^^^^^^^^^^^^
 
 error: missing documentation for an associated type
-  --> $DIR/lint-missing-doc.rs:65:5
+  --> $DIR/lint-missing-doc.rs:67:5
    |
 LL |     type AssociatedTypeDef = Self;
    |     ^^^^^^^^^^^^^^^^^^^^^^
 
 error: missing documentation for an associated function
-  --> $DIR/lint-missing-doc.rs:81:5
+  --> $DIR/lint-missing-doc.rs:83:5
    |
 LL |     pub fn foo() {}
    |     ^^^^^^^^^^^^
 
 error: missing documentation for an enum
-  --> $DIR/lint-missing-doc.rs:118:1
+  --> $DIR/lint-missing-doc.rs:120:1
    |
 LL | pub enum PubBaz {
    | ^^^^^^^^^^^^^^^
 
 error: missing documentation for a variant
-  --> $DIR/lint-missing-doc.rs:119:5
+  --> $DIR/lint-missing-doc.rs:121:5
    |
 LL |     PubBazA {
    |     ^^^^^^^
 
 error: missing documentation for a struct field
-  --> $DIR/lint-missing-doc.rs:120:9
+  --> $DIR/lint-missing-doc.rs:122:9
    |
 LL |         a: isize,
    |         ^^^^^^^^
 
 error: missing documentation for a constant
-  --> $DIR/lint-missing-doc.rs:151:1
+  --> $DIR/lint-missing-doc.rs:153:1
    |
 LL | pub const FOO4: u32 = 0;
    | ^^^^^^^^^^^^^^^^^^^
 
 error: missing documentation for a static
-  --> $DIR/lint-missing-doc.rs:161:1
+  --> $DIR/lint-missing-doc.rs:163:1
    |
 LL | pub static BAR4: u32 = 0;
    | ^^^^^^^^^^^^^^^^^^^^
 
 error: missing documentation for a function
-  --> $DIR/lint-missing-doc.rs:167:5
+  --> $DIR/lint-missing-doc.rs:169:5
    |
 LL |     pub fn undocumented1() {}
    |     ^^^^^^^^^^^^^^^^^^^^^^
 
 error: missing documentation for a function
-  --> $DIR/lint-missing-doc.rs:168:5
+  --> $DIR/lint-missing-doc.rs:170:5
    |
 LL |     pub fn undocumented2() {}
    |     ^^^^^^^^^^^^^^^^^^^^^^
 
 error: missing documentation for a function
-  --> $DIR/lint-missing-doc.rs:174:9
+  --> $DIR/lint-missing-doc.rs:176:9
    |
 LL |         pub fn also_undocumented1() {}
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: missing documentation for a function
-  --> $DIR/lint-missing-doc.rs:189:5
+  --> $DIR/lint-missing-doc.rs:191:5
    |
 LL |     pub fn extern_fn_undocumented(f: f32) -> f32;
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: missing documentation for a static
-  --> $DIR/lint-missing-doc.rs:194:5
+  --> $DIR/lint-missing-doc.rs:196:5
    |
 LL |     pub static EXTERN_STATIC_UNDOCUMENTED: u8;
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: missing documentation for a foreign type
-  --> $DIR/lint-missing-doc.rs:199:5
+  --> $DIR/lint-missing-doc.rs:201:5
    |
 LL |     pub type ExternTyUndocumented;
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
-error: aborting due to 22 previous errors
+error: aborting due to 24 previous errors
 
diff --git a/tests/ui/lint/lint-stability-deprecated.rs b/tests/ui/lint/lint-stability-deprecated.rs
index 74c35083e60..a56a37228e5 100644
--- a/tests/ui/lint/lint-stability-deprecated.rs
+++ b/tests/ui/lint/lint-stability-deprecated.rs
@@ -22,40 +22,40 @@ mod cross_crate {
         let foo = MethodTester;
 
         deprecated(); //~ WARN use of deprecated function `lint_stability::deprecated`
-        foo.method_deprecated(); //~ WARN use of deprecated associated function `lint_stability::MethodTester::method_deprecated`
-        Foo::method_deprecated(&foo); //~ WARN use of deprecated associated function `lint_stability::MethodTester::method_deprecated`
-        <Foo>::method_deprecated(&foo); //~ WARN use of deprecated associated function `lint_stability::MethodTester::method_deprecated`
-        foo.trait_deprecated(); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated`
-        Trait::trait_deprecated(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated`
-        <Foo>::trait_deprecated(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated`
-        <Foo as Trait>::trait_deprecated(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated`
+        foo.method_deprecated(); //~ WARN use of deprecated method `lint_stability::MethodTester::method_deprecated`
+        Foo::method_deprecated(&foo); //~ WARN use of deprecated method `lint_stability::MethodTester::method_deprecated`
+        <Foo>::method_deprecated(&foo); //~ WARN use of deprecated method `lint_stability::MethodTester::method_deprecated`
+        foo.trait_deprecated(); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated`
+        Trait::trait_deprecated(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated`
+        <Foo>::trait_deprecated(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated`
+        <Foo as Trait>::trait_deprecated(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated`
 
         deprecated_text(); //~ WARN use of deprecated function `lint_stability::deprecated_text`: text
-        foo.method_deprecated_text(); //~ WARN use of deprecated associated function `lint_stability::MethodTester::method_deprecated_text`: text
-        Foo::method_deprecated_text(&foo); //~ WARN use of deprecated associated function `lint_stability::MethodTester::method_deprecated_text`: text
-        <Foo>::method_deprecated_text(&foo); //~ WARN use of deprecated associated function `lint_stability::MethodTester::method_deprecated_text`: text
-        foo.trait_deprecated_text(); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
-        Trait::trait_deprecated_text(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
-        <Foo>::trait_deprecated_text(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
-        <Foo as Trait>::trait_deprecated_text(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
+        foo.method_deprecated_text(); //~ WARN use of deprecated method `lint_stability::MethodTester::method_deprecated_text`: text
+        Foo::method_deprecated_text(&foo); //~ WARN use of deprecated method `lint_stability::MethodTester::method_deprecated_text`: text
+        <Foo>::method_deprecated_text(&foo); //~ WARN use of deprecated method `lint_stability::MethodTester::method_deprecated_text`: text
+        foo.trait_deprecated_text(); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
+        Trait::trait_deprecated_text(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
+        <Foo>::trait_deprecated_text(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
+        <Foo as Trait>::trait_deprecated_text(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
 
         deprecated_unstable(); //~ WARN use of deprecated function `lint_stability::deprecated_unstable`
-        foo.method_deprecated_unstable(); //~ WARN use of deprecated associated function `lint_stability::MethodTester::method_deprecated_unstable`
-        Foo::method_deprecated_unstable(&foo); //~ WARN use of deprecated associated function `lint_stability::MethodTester::method_deprecated_unstable`
-        <Foo>::method_deprecated_unstable(&foo); //~ WARN use of deprecated associated function `lint_stability::MethodTester::method_deprecated_unstable`
-        foo.trait_deprecated_unstable(); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`
-        Trait::trait_deprecated_unstable(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`
-        <Foo>::trait_deprecated_unstable(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`
-        <Foo as Trait>::trait_deprecated_unstable(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`
+        foo.method_deprecated_unstable(); //~ WARN use of deprecated method `lint_stability::MethodTester::method_deprecated_unstable`
+        Foo::method_deprecated_unstable(&foo); //~ WARN use of deprecated method `lint_stability::MethodTester::method_deprecated_unstable`
+        <Foo>::method_deprecated_unstable(&foo); //~ WARN use of deprecated method `lint_stability::MethodTester::method_deprecated_unstable`
+        foo.trait_deprecated_unstable(); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`
+        Trait::trait_deprecated_unstable(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`
+        <Foo>::trait_deprecated_unstable(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`
+        <Foo as Trait>::trait_deprecated_unstable(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`
 
         deprecated_unstable_text(); //~ WARN use of deprecated function `lint_stability::deprecated_unstable_text`: text
-        foo.method_deprecated_unstable_text(); //~ WARN use of deprecated associated function `lint_stability::MethodTester::method_deprecated_unstable_text`: text
-        Foo::method_deprecated_unstable_text(&foo); //~ WARN use of deprecated associated function `lint_stability::MethodTester::method_deprecated_unstable_text`: text
-        <Foo>::method_deprecated_unstable_text(&foo); //~ WARN use of deprecated associated function `lint_stability::MethodTester::method_deprecated_unstable_text`: text
-        foo.trait_deprecated_unstable_text(); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
-        Trait::trait_deprecated_unstable_text(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
-        <Foo>::trait_deprecated_unstable_text(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
-        <Foo as Trait>::trait_deprecated_unstable_text(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
+        foo.method_deprecated_unstable_text(); //~ WARN use of deprecated method `lint_stability::MethodTester::method_deprecated_unstable_text`: text
+        Foo::method_deprecated_unstable_text(&foo); //~ WARN use of deprecated method `lint_stability::MethodTester::method_deprecated_unstable_text`: text
+        <Foo>::method_deprecated_unstable_text(&foo); //~ WARN use of deprecated method `lint_stability::MethodTester::method_deprecated_unstable_text`: text
+        foo.trait_deprecated_unstable_text(); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
+        Trait::trait_deprecated_unstable_text(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
+        <Foo>::trait_deprecated_unstable_text(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
+        <Foo as Trait>::trait_deprecated_unstable_text(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
 
         unstable();
         foo.method_unstable();
@@ -141,22 +141,22 @@ mod cross_crate {
     }
 
     fn test_method_param<Foo: Trait>(foo: Foo) {
-        foo.trait_deprecated(); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated`
-        Trait::trait_deprecated(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated`
-        <Foo>::trait_deprecated(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated`
-        <Foo as Trait>::trait_deprecated(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated`
-        foo.trait_deprecated_text(); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
-        Trait::trait_deprecated_text(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
-        <Foo>::trait_deprecated_text(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
-        <Foo as Trait>::trait_deprecated_text(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
-        foo.trait_deprecated_unstable(); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`
-        Trait::trait_deprecated_unstable(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`
-        <Foo>::trait_deprecated_unstable(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`
-        <Foo as Trait>::trait_deprecated_unstable(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`
-        foo.trait_deprecated_unstable_text(); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
-        Trait::trait_deprecated_unstable_text(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
-        <Foo>::trait_deprecated_unstable_text(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
-        <Foo as Trait>::trait_deprecated_unstable_text(&foo); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
+        foo.trait_deprecated(); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated`
+        Trait::trait_deprecated(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated`
+        <Foo>::trait_deprecated(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated`
+        <Foo as Trait>::trait_deprecated(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated`
+        foo.trait_deprecated_text(); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
+        Trait::trait_deprecated_text(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
+        <Foo>::trait_deprecated_text(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
+        <Foo as Trait>::trait_deprecated_text(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
+        foo.trait_deprecated_unstable(); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`
+        Trait::trait_deprecated_unstable(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`
+        <Foo>::trait_deprecated_unstable(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`
+        <Foo as Trait>::trait_deprecated_unstable(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`
+        foo.trait_deprecated_unstable_text(); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
+        Trait::trait_deprecated_unstable_text(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
+        <Foo>::trait_deprecated_unstable_text(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
+        <Foo as Trait>::trait_deprecated_unstable_text(&foo); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
         foo.trait_unstable();
         Trait::trait_unstable(&foo);
         <Foo>::trait_unstable(&foo);
@@ -172,10 +172,10 @@ mod cross_crate {
     }
 
     fn test_method_object(foo: &dyn Trait) {
-        foo.trait_deprecated(); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated`
-        foo.trait_deprecated_text(); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
-        foo.trait_deprecated_unstable(); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`
-        foo.trait_deprecated_unstable_text(); //~ WARN use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
+        foo.trait_deprecated(); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated`
+        foo.trait_deprecated_text(); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
+        foo.trait_deprecated_unstable(); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`
+        foo.trait_deprecated_unstable_text(); //~ WARN use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
         foo.trait_unstable();
         foo.trait_unstable_text();
         foo.trait_stable();
@@ -328,22 +328,22 @@ mod this_crate {
         let foo = MethodTester;
 
         deprecated(); //~ WARN use of deprecated function `this_crate::deprecated`
-        foo.method_deprecated(); //~ WARN use of deprecated associated function `this_crate::MethodTester::method_deprecated`
-        Foo::method_deprecated(&foo); //~ WARN use of deprecated associated function `this_crate::MethodTester::method_deprecated`
-        <Foo>::method_deprecated(&foo); //~ WARN use of deprecated associated function `this_crate::MethodTester::method_deprecated`
-        foo.trait_deprecated(); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated`
-        Trait::trait_deprecated(&foo); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated`
-        <Foo>::trait_deprecated(&foo); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated`
-        <Foo as Trait>::trait_deprecated(&foo); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated`
+        foo.method_deprecated(); //~ WARN use of deprecated method `this_crate::MethodTester::method_deprecated`
+        Foo::method_deprecated(&foo); //~ WARN use of deprecated method `this_crate::MethodTester::method_deprecated`
+        <Foo>::method_deprecated(&foo); //~ WARN use of deprecated method `this_crate::MethodTester::method_deprecated`
+        foo.trait_deprecated(); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated`
+        Trait::trait_deprecated(&foo); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated`
+        <Foo>::trait_deprecated(&foo); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated`
+        <Foo as Trait>::trait_deprecated(&foo); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated`
 
         deprecated_text(); //~ WARN use of deprecated function `this_crate::deprecated_text`: text
-        foo.method_deprecated_text(); //~ WARN use of deprecated associated function `this_crate::MethodTester::method_deprecated_text`: text
-        Foo::method_deprecated_text(&foo); //~ WARN use of deprecated associated function `this_crate::MethodTester::method_deprecated_text`: text
-        <Foo>::method_deprecated_text(&foo); //~ WARN use of deprecated associated function `this_crate::MethodTester::method_deprecated_text`: text
-        foo.trait_deprecated_text(); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
-        Trait::trait_deprecated_text(&foo); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
-        <Foo>::trait_deprecated_text(&foo); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
-        <Foo as Trait>::trait_deprecated_text(&foo); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+        foo.method_deprecated_text(); //~ WARN use of deprecated method `this_crate::MethodTester::method_deprecated_text`: text
+        Foo::method_deprecated_text(&foo); //~ WARN use of deprecated method `this_crate::MethodTester::method_deprecated_text`: text
+        <Foo>::method_deprecated_text(&foo); //~ WARN use of deprecated method `this_crate::MethodTester::method_deprecated_text`: text
+        foo.trait_deprecated_text(); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
+        Trait::trait_deprecated_text(&foo); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
+        <Foo>::trait_deprecated_text(&foo); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
+        <Foo as Trait>::trait_deprecated_text(&foo); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
 
         unstable();
         foo.method_unstable();
@@ -402,14 +402,14 @@ mod this_crate {
     }
 
     fn test_method_param<Foo: Trait>(foo: Foo) {
-        foo.trait_deprecated(); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated`
-        Trait::trait_deprecated(&foo); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated`
-        <Foo>::trait_deprecated(&foo); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated`
-        <Foo as Trait>::trait_deprecated(&foo); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated`
-        foo.trait_deprecated_text(); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
-        Trait::trait_deprecated_text(&foo); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
-        <Foo>::trait_deprecated_text(&foo); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
-        <Foo as Trait>::trait_deprecated_text(&foo); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+        foo.trait_deprecated(); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated`
+        Trait::trait_deprecated(&foo); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated`
+        <Foo>::trait_deprecated(&foo); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated`
+        <Foo as Trait>::trait_deprecated(&foo); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated`
+        foo.trait_deprecated_text(); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
+        Trait::trait_deprecated_text(&foo); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
+        <Foo>::trait_deprecated_text(&foo); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
+        <Foo as Trait>::trait_deprecated_text(&foo); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
         foo.trait_unstable();
         Trait::trait_unstable(&foo);
         <Foo>::trait_unstable(&foo);
@@ -425,8 +425,8 @@ mod this_crate {
     }
 
     fn test_method_object(foo: &dyn Trait) {
-        foo.trait_deprecated(); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated`
-        foo.trait_deprecated_text(); //~ WARN use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+        foo.trait_deprecated(); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated`
+        foo.trait_deprecated_text(); //~ WARN use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
         foo.trait_unstable();
         foo.trait_unstable_text();
         foo.trait_stable();
diff --git a/tests/ui/lint/lint-stability-deprecated.stderr b/tests/ui/lint/lint-stability-deprecated.stderr
index 9f1e7b281e9..19a4649e168 100644
--- a/tests/ui/lint/lint-stability-deprecated.stderr
+++ b/tests/ui/lint/lint-stability-deprecated.stderr
@@ -10,13 +10,13 @@ note: the lint level is defined here
 LL | #![warn(deprecated)]
    |         ^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:29:16
    |
 LL |         Trait::trait_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:31:25
    |
 LL |         <Foo as Trait>::trait_deprecated(&foo);
@@ -28,17 +28,17 @@ warning: use of deprecated function `lint_stability::deprecated_text`: text
 LL |         deprecated_text();
    |         ^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:38:16
    |
-LL | ...   Trait::trait_deprecated_text(&foo);
-   |              ^^^^^^^^^^^^^^^^^^^^^
+LL |         Trait::trait_deprecated_text(&foo);
+   |                ^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:40:25
    |
-LL | ...   <Foo as Trait>::trait_deprecated_text(&foo);
-   |                       ^^^^^^^^^^^^^^^^^^^^^
+LL |         <Foo as Trait>::trait_deprecated_text(&foo);
+   |                         ^^^^^^^^^^^^^^^^^^^^^
 
 warning: use of deprecated function `lint_stability::deprecated_unstable`: text
   --> $DIR/lint-stability-deprecated.rs:42:9
@@ -46,13 +46,13 @@ warning: use of deprecated function `lint_stability::deprecated_unstable`: text
 LL |         deprecated_unstable();
    |         ^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`: text
   --> $DIR/lint-stability-deprecated.rs:47:16
    |
-LL | ...   Trait::trait_deprecated_unstable(&foo);
-   |              ^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |         Trait::trait_deprecated_unstable(&foo);
+   |                ^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`: text
   --> $DIR/lint-stability-deprecated.rs:49:25
    |
 LL | ...   <Foo as Trait>::trait_deprecated_unstable(&foo);
@@ -64,13 +64,13 @@ warning: use of deprecated function `lint_stability::deprecated_unstable_text`:
 LL |         deprecated_unstable_text();
    |         ^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
   --> $DIR/lint-stability-deprecated.rs:56:16
    |
 LL | ...   Trait::trait_deprecated_unstable_text(&foo);
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
   --> $DIR/lint-stability-deprecated.rs:58:25
    |
 LL | ...   <Foo as Trait>::trait_deprecated_unstable_text(&foo);
@@ -142,49 +142,49 @@ warning: use of deprecated function `lint_stability::deprecated_text`: text
 LL |         macro_test_arg!(macro_test_arg!(deprecated_text()));
    |                                         ^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:145:16
    |
 LL |         Trait::trait_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:147:25
    |
 LL |         <Foo as Trait>::trait_deprecated(&foo);
    |                         ^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:149:16
    |
-LL | ...   Trait::trait_deprecated_text(&foo);
-   |              ^^^^^^^^^^^^^^^^^^^^^
+LL |         Trait::trait_deprecated_text(&foo);
+   |                ^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:151:25
    |
-LL | ...   <Foo as Trait>::trait_deprecated_text(&foo);
-   |                       ^^^^^^^^^^^^^^^^^^^^^
+LL |         <Foo as Trait>::trait_deprecated_text(&foo);
+   |                         ^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`: text
   --> $DIR/lint-stability-deprecated.rs:153:16
    |
-LL | ...   Trait::trait_deprecated_unstable(&foo);
-   |              ^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |         Trait::trait_deprecated_unstable(&foo);
+   |                ^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`: text
   --> $DIR/lint-stability-deprecated.rs:155:25
    |
 LL | ...   <Foo as Trait>::trait_deprecated_unstable(&foo);
    |                       ^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
   --> $DIR/lint-stability-deprecated.rs:157:16
    |
 LL | ...   Trait::trait_deprecated_unstable_text(&foo);
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
   --> $DIR/lint-stability-deprecated.rs:159:25
    |
 LL | ...   <Foo as Trait>::trait_deprecated_unstable_text(&foo);
@@ -214,13 +214,13 @@ warning: use of deprecated function `this_crate::deprecated`: text
 LL |         deprecated();
    |         ^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:335:16
    |
 LL |         Trait::trait_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:337:25
    |
 LL |         <Foo as Trait>::trait_deprecated(&foo);
@@ -232,17 +232,17 @@ warning: use of deprecated function `this_crate::deprecated_text`: text
 LL |         deprecated_text();
    |         ^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:344:16
    |
 LL |         Trait::trait_deprecated_text(&foo);
    |                ^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:346:25
    |
-LL | ...   <Foo as Trait>::trait_deprecated_text(&foo);
-   |                       ^^^^^^^^^^^^^^^^^^^^^
+LL |         <Foo as Trait>::trait_deprecated_text(&foo);
+   |                         ^^^^^^^^^^^^^^^^^^^^^
 
 warning: use of deprecated struct `this_crate::DeprecatedStruct`: text
   --> $DIR/lint-stability-deprecated.rs:384:17
@@ -268,29 +268,29 @@ warning: use of deprecated tuple struct `this_crate::DeprecatedTupleStruct`: tex
 LL |         let _ = DeprecatedTupleStruct (1);
    |                 ^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:406:16
    |
 LL |         Trait::trait_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:408:25
    |
 LL |         <Foo as Trait>::trait_deprecated(&foo);
    |                         ^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:410:16
    |
 LL |         Trait::trait_deprecated_text(&foo);
    |                ^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:412:25
    |
-LL | ...   <Foo as Trait>::trait_deprecated_text(&foo);
-   |                       ^^^^^^^^^^^^^^^^^^^^^
+LL |         <Foo as Trait>::trait_deprecated_text(&foo);
+   |                         ^^^^^^^^^^^^^^^^^^^^^
 
 warning: use of deprecated function `this_crate::test_fn_body::fn_in_body`: text
   --> $DIR/lint-stability-deprecated.rs:439:9
@@ -328,121 +328,121 @@ warning: use of deprecated associated type `lint_stability::TraitWithAssociatedT
 LL |             TypeDeprecated = u16,
    |             ^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::MethodTester::method_deprecated`: text
+warning: use of deprecated method `lint_stability::MethodTester::method_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:25:13
    |
 LL |         foo.method_deprecated();
    |             ^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::MethodTester::method_deprecated`: text
+warning: use of deprecated method `lint_stability::MethodTester::method_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:26:14
    |
 LL |         Foo::method_deprecated(&foo);
    |              ^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::MethodTester::method_deprecated`: text
+warning: use of deprecated method `lint_stability::MethodTester::method_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:27:16
    |
 LL |         <Foo>::method_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:28:13
    |
 LL |         foo.trait_deprecated();
    |             ^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:30:16
    |
 LL |         <Foo>::trait_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::MethodTester::method_deprecated_text`: text
+warning: use of deprecated method `lint_stability::MethodTester::method_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:34:13
    |
-LL | ...   foo.method_deprecated_text();
-   |           ^^^^^^^^^^^^^^^^^^^^^^
+LL |         foo.method_deprecated_text();
+   |             ^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::MethodTester::method_deprecated_text`: text
+warning: use of deprecated method `lint_stability::MethodTester::method_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:35:14
    |
-LL | ...   Foo::method_deprecated_text(&foo);
-   |            ^^^^^^^^^^^^^^^^^^^^^^
+LL |         Foo::method_deprecated_text(&foo);
+   |              ^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::MethodTester::method_deprecated_text`: text
+warning: use of deprecated method `lint_stability::MethodTester::method_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:36:16
    |
-LL | ...   <Foo>::method_deprecated_text(&foo);
-   |              ^^^^^^^^^^^^^^^^^^^^^^
+LL |         <Foo>::method_deprecated_text(&foo);
+   |                ^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:37:13
    |
 LL |         foo.trait_deprecated_text();
    |             ^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:39:16
    |
-LL | ...   <Foo>::trait_deprecated_text(&foo);
-   |              ^^^^^^^^^^^^^^^^^^^^^
+LL |         <Foo>::trait_deprecated_text(&foo);
+   |                ^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::MethodTester::method_deprecated_unstable`: text
+warning: use of deprecated method `lint_stability::MethodTester::method_deprecated_unstable`: text
   --> $DIR/lint-stability-deprecated.rs:43:13
    |
-LL | ...   foo.method_deprecated_unstable();
-   |           ^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |         foo.method_deprecated_unstable();
+   |             ^^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::MethodTester::method_deprecated_unstable`: text
+warning: use of deprecated method `lint_stability::MethodTester::method_deprecated_unstable`: text
   --> $DIR/lint-stability-deprecated.rs:44:14
    |
-LL | ...   Foo::method_deprecated_unstable(&foo);
-   |            ^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |         Foo::method_deprecated_unstable(&foo);
+   |              ^^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::MethodTester::method_deprecated_unstable`: text
+warning: use of deprecated method `lint_stability::MethodTester::method_deprecated_unstable`: text
   --> $DIR/lint-stability-deprecated.rs:45:16
    |
 LL | ...   <Foo>::method_deprecated_unstable(&foo);
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`: text
   --> $DIR/lint-stability-deprecated.rs:46:13
    |
 LL |         foo.trait_deprecated_unstable();
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`: text
   --> $DIR/lint-stability-deprecated.rs:48:16
    |
-LL | ...   <Foo>::trait_deprecated_unstable(&foo);
-   |              ^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |         <Foo>::trait_deprecated_unstable(&foo);
+   |                ^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::MethodTester::method_deprecated_unstable_text`: text
+warning: use of deprecated method `lint_stability::MethodTester::method_deprecated_unstable_text`: text
   --> $DIR/lint-stability-deprecated.rs:52:13
    |
 LL | ...   foo.method_deprecated_unstable_text();
    |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::MethodTester::method_deprecated_unstable_text`: text
+warning: use of deprecated method `lint_stability::MethodTester::method_deprecated_unstable_text`: text
   --> $DIR/lint-stability-deprecated.rs:53:14
    |
 LL | ...   Foo::method_deprecated_unstable_text(&foo);
    |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::MethodTester::method_deprecated_unstable_text`: text
+warning: use of deprecated method `lint_stability::MethodTester::method_deprecated_unstable_text`: text
   --> $DIR/lint-stability-deprecated.rs:54:16
    |
 LL | ...   <Foo>::method_deprecated_unstable_text(&foo);
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
   --> $DIR/lint-stability-deprecated.rs:55:13
    |
 LL | ...   foo.trait_deprecated_unstable_text();
    |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
   --> $DIR/lint-stability-deprecated.rs:57:16
    |
 LL | ...   <Foo>::trait_deprecated_unstable_text(&foo);
@@ -460,133 +460,133 @@ warning: use of deprecated field `lint_stability::DeprecatedUnstableStruct::i`:
 LL |             i: 0
    |             ^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:144:13
    |
 LL |         foo.trait_deprecated();
    |             ^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:146:16
    |
 LL |         <Foo>::trait_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:148:13
    |
 LL |         foo.trait_deprecated_text();
    |             ^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:150:16
    |
-LL | ...   <Foo>::trait_deprecated_text(&foo);
-   |              ^^^^^^^^^^^^^^^^^^^^^
+LL |         <Foo>::trait_deprecated_text(&foo);
+   |                ^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`: text
   --> $DIR/lint-stability-deprecated.rs:152:13
    |
 LL |         foo.trait_deprecated_unstable();
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`: text
   --> $DIR/lint-stability-deprecated.rs:154:16
    |
-LL | ...   <Foo>::trait_deprecated_unstable(&foo);
-   |              ^^^^^^^^^^^^^^^^^^^^^^^^^
+LL |         <Foo>::trait_deprecated_unstable(&foo);
+   |                ^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
   --> $DIR/lint-stability-deprecated.rs:156:13
    |
 LL | ...   foo.trait_deprecated_unstable_text();
    |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
   --> $DIR/lint-stability-deprecated.rs:158:16
    |
 LL | ...   <Foo>::trait_deprecated_unstable_text(&foo);
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:175:13
    |
 LL |         foo.trait_deprecated();
    |             ^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:176:13
    |
 LL |         foo.trait_deprecated_text();
    |             ^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable`: text
   --> $DIR/lint-stability-deprecated.rs:177:13
    |
 LL |         foo.trait_deprecated_unstable();
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `lint_stability::Trait::trait_deprecated_unstable_text`: text
+warning: use of deprecated method `lint_stability::Trait::trait_deprecated_unstable_text`: text
   --> $DIR/lint-stability-deprecated.rs:178:13
    |
 LL | ...   foo.trait_deprecated_unstable_text();
    |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::MethodTester::method_deprecated`: text
+warning: use of deprecated method `this_crate::MethodTester::method_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:331:13
    |
 LL |         foo.method_deprecated();
    |             ^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::MethodTester::method_deprecated`: text
+warning: use of deprecated method `this_crate::MethodTester::method_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:332:14
    |
 LL |         Foo::method_deprecated(&foo);
    |              ^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::MethodTester::method_deprecated`: text
+warning: use of deprecated method `this_crate::MethodTester::method_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:333:16
    |
 LL |         <Foo>::method_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:334:13
    |
 LL |         foo.trait_deprecated();
    |             ^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:336:16
    |
 LL |         <Foo>::trait_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::MethodTester::method_deprecated_text`: text
+warning: use of deprecated method `this_crate::MethodTester::method_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:340:13
    |
-LL | ...   foo.method_deprecated_text();
-   |           ^^^^^^^^^^^^^^^^^^^^^^
+LL |         foo.method_deprecated_text();
+   |             ^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::MethodTester::method_deprecated_text`: text
+warning: use of deprecated method `this_crate::MethodTester::method_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:341:14
    |
-LL | ...   Foo::method_deprecated_text(&foo);
-   |            ^^^^^^^^^^^^^^^^^^^^^^
+LL |         Foo::method_deprecated_text(&foo);
+   |              ^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::MethodTester::method_deprecated_text`: text
+warning: use of deprecated method `this_crate::MethodTester::method_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:342:16
    |
-LL | ...   <Foo>::method_deprecated_text(&foo);
-   |              ^^^^^^^^^^^^^^^^^^^^^^
+LL |         <Foo>::method_deprecated_text(&foo);
+   |                ^^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:343:13
    |
 LL |         foo.trait_deprecated_text();
    |             ^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:345:16
    |
 LL |         <Foo>::trait_deprecated_text(&foo);
@@ -598,37 +598,37 @@ warning: use of deprecated field `this_crate::DeprecatedStruct::i`: text
 LL |             i: 0
    |             ^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:405:13
    |
 LL |         foo.trait_deprecated();
    |             ^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:407:16
    |
 LL |         <Foo>::trait_deprecated(&foo);
    |                ^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:409:13
    |
 LL |         foo.trait_deprecated_text();
    |             ^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:411:16
    |
 LL |         <Foo>::trait_deprecated_text(&foo);
    |                ^^^^^^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated`: text
   --> $DIR/lint-stability-deprecated.rs:428:13
    |
 LL |         foo.trait_deprecated();
    |             ^^^^^^^^^^^^^^^^
 
-warning: use of deprecated associated function `this_crate::Trait::trait_deprecated_text`: text
+warning: use of deprecated method `this_crate::Trait::trait_deprecated_text`: text
   --> $DIR/lint-stability-deprecated.rs:429:13
    |
 LL |         foo.trait_deprecated_text();
diff --git a/tests/ui/lint/lint_map_unit_fn.rs b/tests/ui/lint/lint_map_unit_fn.rs
new file mode 100644
index 00000000000..dc1ecbf8424
--- /dev/null
+++ b/tests/ui/lint/lint_map_unit_fn.rs
@@ -0,0 +1,20 @@
+#![deny(map_unit_fn)]
+
+fn foo(items: &mut Vec<u8>) {
+    items.sort();
+}
+
+fn main() {
+    let mut x: Vec<Vec<u8>> = vec![vec![0, 2, 1], vec![5, 4, 3]];
+    x.iter_mut().map(foo);
+    //~^ ERROR `Iterator::map` call that discard the iterator's values
+    x.iter_mut().map(|items| {
+    //~^ ERROR `Iterator::map` call that discard the iterator's values
+        items.sort();
+    });
+    let f = |items: &mut Vec<u8>| {
+        items.sort();
+    };
+    x.iter_mut().map(f);
+    //~^ ERROR `Iterator::map` call that discard the iterator's values
+}
diff --git a/tests/ui/lint/lint_map_unit_fn.stderr b/tests/ui/lint/lint_map_unit_fn.stderr
new file mode 100644
index 00000000000..fbf689c5421
--- /dev/null
+++ b/tests/ui/lint/lint_map_unit_fn.stderr
@@ -0,0 +1,66 @@
+error: `Iterator::map` call that discard the iterator's values
+  --> $DIR/lint_map_unit_fn.rs:9:18
+   |
+LL | fn foo(items: &mut Vec<u8>) {
+   | --------------------------- this function returns `()`, which is likely not what you wanted
+...
+LL |     x.iter_mut().map(foo);
+   |                  ^^^^---^
+   |                  |   |
+   |                  |   called `Iterator::map` with callable that returns `()`
+   |                  after this call to map, the resulting iterator is `impl Iterator<Item = ()>`, which means the only information carried by the iterator is the number of items
+   |
+   = note: `Iterator::map`, like many of the methods on `Iterator`, gets executed lazily, meaning that its effects won't be visible until it is iterated
+note: the lint level is defined here
+  --> $DIR/lint_map_unit_fn.rs:1:9
+   |
+LL | #![deny(map_unit_fn)]
+   |         ^^^^^^^^^^^
+help: you might have meant to use `Iterator::for_each`
+   |
+LL |     x.iter_mut().for_each(foo);
+   |                  ~~~~~~~~
+
+error: `Iterator::map` call that discard the iterator's values
+  --> $DIR/lint_map_unit_fn.rs:11:18
+   |
+LL |         x.iter_mut().map(|items| {
+   |                      ^   -------
+   |                      |   |
+   |  ____________________|___this function returns `()`, which is likely not what you wanted
+   | |  __________________|
+   | | |
+LL | | |
+LL | | |         items.sort();
+LL | | |     });
+   | | |     -^ after this call to map, the resulting iterator is `impl Iterator<Item = ()>`, which means the only information carried by the iterator is the number of items
+   | | |_____||
+   | |_______|
+   |         called `Iterator::map` with callable that returns `()`
+   |
+   = note: `Iterator::map`, like many of the methods on `Iterator`, gets executed lazily, meaning that its effects won't be visible until it is iterated
+help: you might have meant to use `Iterator::for_each`
+   |
+LL |     x.iter_mut().for_each(|items| {
+   |                  ~~~~~~~~
+
+error: `Iterator::map` call that discard the iterator's values
+  --> $DIR/lint_map_unit_fn.rs:18:18
+   |
+LL |     let f = |items: &mut Vec<u8>| {
+   |             --------------------- this function returns `()`, which is likely not what you wanted
+...
+LL |     x.iter_mut().map(f);
+   |                  ^^^^-^
+   |                  |   |
+   |                  |   called `Iterator::map` with callable that returns `()`
+   |                  after this call to map, the resulting iterator is `impl Iterator<Item = ()>`, which means the only information carried by the iterator is the number of items
+   |
+   = note: `Iterator::map`, like many of the methods on `Iterator`, gets executed lazily, meaning that its effects won't be visible until it is iterated
+help: you might have meant to use `Iterator::for_each`
+   |
+LL |     x.iter_mut().for_each(f);
+   |                  ~~~~~~~~
+
+error: aborting due to 3 previous errors
+
diff --git a/tests/ui/match/match-ref-mut-invariance.stderr b/tests/ui/match/match-ref-mut-invariance.stderr
index 3b7e53cd527..b353d3514fe 100644
--- a/tests/ui/match/match-ref-mut-invariance.stderr
+++ b/tests/ui/match/match-ref-mut-invariance.stderr
@@ -6,7 +6,7 @@ LL | impl<'b> S<'b> {
 LL |     fn bar<'a>(&'a mut self) -> &'a mut &'a i32 {
    |            -- lifetime `'a` defined here
 LL |         match self.0 { ref mut x => x }
-   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ associated function was supposed to return data with lifetime `'b` but it is returning data with lifetime `'a`
+   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ method was supposed to return data with lifetime `'b` but it is returning data with lifetime `'a`
    |
    = help: consider adding the following bound: `'a: 'b`
    = note: requirement occurs because of a mutable reference to `&i32`
diff --git a/tests/ui/match/match-ref-mut-let-invariance.stderr b/tests/ui/match/match-ref-mut-let-invariance.stderr
index f4d1cea670b..bb0fcdb9990 100644
--- a/tests/ui/match/match-ref-mut-let-invariance.stderr
+++ b/tests/ui/match/match-ref-mut-let-invariance.stderr
@@ -7,7 +7,7 @@ LL |     fn bar<'a>(&'a mut self) -> &'a mut &'a i32 {
    |            -- lifetime `'a` defined here
 LL |         let ref mut x = self.0;
 LL |         x
-   |         ^ associated function was supposed to return data with lifetime `'b` but it is returning data with lifetime `'a`
+   |         ^ method was supposed to return data with lifetime `'b` but it is returning data with lifetime `'a`
    |
    = help: consider adding the following bound: `'a: 'b`
    = note: requirement occurs because of a mutable reference to `&i32`
diff --git a/tests/ui/methods/issues/issue-105732.stderr b/tests/ui/methods/issues/issue-105732.stderr
index 7696642548d..19ccd2de685 100644
--- a/tests/ui/methods/issues/issue-105732.stderr
+++ b/tests/ui/methods/issues/issue-105732.stderr
@@ -2,7 +2,7 @@ error[E0380]: auto traits cannot have associated items
   --> $DIR/issue-105732.rs:4:8
    |
 LL | auto trait Foo {
-   |            --- auto trait cannot have associated items
+   |            --- auto traits cannot have associated items
 LL |     fn g(&self);
    |     ---^-------- help: remove these associated items
 
diff --git a/tests/ui/methods/issues/issue-61525.stderr b/tests/ui/methods/issues/issue-61525.stderr
index 32e269b7ad8..a8afdeb8401 100644
--- a/tests/ui/methods/issues/issue-61525.stderr
+++ b/tests/ui/methods/issues/issue-61525.stderr
@@ -27,7 +27,7 @@ LL |         1.query::<dyn ToString>("")
    |
    = note: expected trait object `dyn ToString`
                  found reference `&'static str`
-note: associated function defined here
+note: method defined here
   --> $DIR/issue-61525.rs:2:8
    |
 LL |     fn query<Q>(self, q: Q);
diff --git a/tests/ui/methods/method-ambig-two-traits-cross-crate.stderr b/tests/ui/methods/method-ambig-two-traits-cross-crate.stderr
index 4b2597eed3c..5132d92777b 100644
--- a/tests/ui/methods/method-ambig-two-traits-cross-crate.stderr
+++ b/tests/ui/methods/method-ambig-two-traits-cross-crate.stderr
@@ -10,11 +10,11 @@ note: candidate #2 is defined in an impl of the trait `Me2` for the type `usize`
    |
 LL | impl Me2 for usize { fn me(&self) -> usize { *self } }
    |                      ^^^^^^^^^^^^^^^^^^^^^
-help: disambiguate the associated function for candidate #1
+help: disambiguate the method for candidate #1
    |
 LL | fn main() { Me::me(&1_usize); }
    |             ~~~~~~~~~~~~~~~~
-help: disambiguate the associated function for candidate #2
+help: disambiguate the method for candidate #2
    |
 LL | fn main() { Me2::me(&1_usize); }
    |             ~~~~~~~~~~~~~~~~~
diff --git a/tests/ui/methods/method-ambig-two-traits-from-bounds.stderr b/tests/ui/methods/method-ambig-two-traits-from-bounds.stderr
index 1feaa2c73e0..601e6bbb006 100644
--- a/tests/ui/methods/method-ambig-two-traits-from-bounds.stderr
+++ b/tests/ui/methods/method-ambig-two-traits-from-bounds.stderr
@@ -14,11 +14,11 @@ note: candidate #2 is defined in the trait `B`
    |
 LL | trait B { fn foo(&self); }
    |           ^^^^^^^^^^^^^^
-help: disambiguate the associated function for candidate #1
+help: disambiguate the method for candidate #1
    |
 LL |     A::foo(t);
    |     ~~~~~~~~~
-help: disambiguate the associated function for candidate #2
+help: disambiguate the method for candidate #2
    |
 LL |     B::foo(t);
    |     ~~~~~~~~~
diff --git a/tests/ui/methods/method-ambig-two-traits-from-impls.stderr b/tests/ui/methods/method-ambig-two-traits-from-impls.stderr
index f69b5689239..31359143391 100644
--- a/tests/ui/methods/method-ambig-two-traits-from-impls.stderr
+++ b/tests/ui/methods/method-ambig-two-traits-from-impls.stderr
@@ -14,11 +14,11 @@ note: candidate #2 is defined in an impl of the trait `B` for the type `AB`
    |
 LL |     fn foo(self) {}
    |     ^^^^^^^^^^^^
-help: disambiguate the associated function for candidate #1
+help: disambiguate the method for candidate #1
    |
 LL |     A::foo(AB {});
    |     ~~~~~~~~~~~~~
-help: disambiguate the associated function for candidate #2
+help: disambiguate the method for candidate #2
    |
 LL |     B::foo(AB {});
    |     ~~~~~~~~~~~~~
diff --git a/tests/ui/methods/method-ambig-two-traits-with-default-method.stderr b/tests/ui/methods/method-ambig-two-traits-with-default-method.stderr
index e84dff8bab7..df01966b3a2 100644
--- a/tests/ui/methods/method-ambig-two-traits-with-default-method.stderr
+++ b/tests/ui/methods/method-ambig-two-traits-with-default-method.stderr
@@ -14,11 +14,11 @@ note: candidate #2 is defined in an impl of the trait `Bar` for the type `usize`
    |
 LL | trait Bar { fn method(&self) {} }
    |             ^^^^^^^^^^^^^^^^
-help: disambiguate the associated function for candidate #1
+help: disambiguate the method for candidate #1
    |
 LL |     Foo::method(&1_usize);
    |     ~~~~~~~~~~~~~~~~~~~~~
-help: disambiguate the associated function for candidate #2
+help: disambiguate the method for candidate #2
    |
 LL |     Bar::method(&1_usize);
    |     ~~~~~~~~~~~~~~~~~~~~~
diff --git a/tests/ui/methods/method-call-err-msg.stderr b/tests/ui/methods/method-call-err-msg.stderr
index 0f37e8f09a9..c340c2d32b3 100644
--- a/tests/ui/methods/method-call-err-msg.stderr
+++ b/tests/ui/methods/method-call-err-msg.stderr
@@ -7,7 +7,7 @@ LL |     x.zero(0)
    |            unexpected argument of type `{integer}`
    |            help: remove the extra argument
    |
-note: associated function defined here
+note: method defined here
   --> $DIR/method-call-err-msg.rs:5:8
    |
 LL |     fn zero(self) -> Foo { self }
@@ -19,7 +19,7 @@ error[E0061]: this method takes 1 argument but 0 arguments were supplied
 LL |      .one()
    |       ^^^-- an argument of type `isize` is missing
    |
-note: associated function defined here
+note: method defined here
   --> $DIR/method-call-err-msg.rs:6:8
    |
 LL |     fn one(self, _: isize) -> Foo { self }
@@ -35,7 +35,7 @@ error[E0061]: this method takes 2 arguments but 1 argument was supplied
 LL |      .two(0);
    |       ^^^--- an argument of type `isize` is missing
    |
-note: associated function defined here
+note: method defined here
   --> $DIR/method-call-err-msg.rs:7:8
    |
 LL |     fn two(self, _: isize, _: isize) -> Foo { self }
@@ -72,7 +72,7 @@ error[E0061]: this method takes 3 arguments but 0 arguments were supplied
 LL |     y.three::<usize>();
    |       ^^^^^^^^^^^^^^-- three arguments of type `usize`, `usize`, and `usize` are missing
    |
-note: associated function defined here
+note: method defined here
   --> $DIR/method-call-err-msg.rs:8:8
    |
 LL |     fn three<T>(self, _: T, _: T, _: T) -> Foo { self }
diff --git a/tests/ui/methods/method-call-lifetime-args-fail.rs b/tests/ui/methods/method-call-lifetime-args-fail.rs
index 6bf55844da8..1f13de094bb 100644
--- a/tests/ui/methods/method-call-lifetime-args-fail.rs
+++ b/tests/ui/methods/method-call-lifetime-args-fail.rs
@@ -14,9 +14,9 @@ impl S {
 fn method_call() {
     S.early(); // OK
     S.early::<'static>();
-    //~^ ERROR this associated function takes 2 lifetime arguments but 1 lifetime argument
+    //~^ ERROR method takes 2 lifetime arguments but 1 lifetime argument
     S.early::<'static, 'static, 'static>();
-    //~^ ERROR this associated function takes 2 lifetime arguments but 3 lifetime arguments were supplied
+    //~^ ERROR method takes 2 lifetime arguments but 3 lifetime arguments were supplied
     let _: &u8 = S.life_and_type::<'static>();
     S.life_and_type::<u8>();
     S.life_and_type::<'static, u8>();
@@ -61,9 +61,9 @@ fn ufcs() {
 
     S::early(S); // OK
     S::early::<'static>(S);
-    //~^ ERROR this associated function takes 2 lifetime arguments but 1 lifetime argument
+    //~^ ERROR method takes 2 lifetime arguments but 1 lifetime argument
     S::early::<'static, 'static, 'static>(S);
-    //~^ ERROR this associated function takes 2 lifetime arguments but 3 lifetime arguments were supplied
+    //~^ ERROR method takes 2 lifetime arguments but 3 lifetime arguments were supplied
     let _: &u8 = S::life_and_type::<'static>(S);
     S::life_and_type::<u8>(S);
     S::life_and_type::<'static, u8>(S);
diff --git a/tests/ui/methods/method-call-lifetime-args-fail.stderr b/tests/ui/methods/method-call-lifetime-args-fail.stderr
index 249b48ab194..34526256f99 100644
--- a/tests/ui/methods/method-call-lifetime-args-fail.stderr
+++ b/tests/ui/methods/method-call-lifetime-args-fail.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this associated function takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: method takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/method-call-lifetime-args-fail.rs:16:7
    |
 LL |     S.early::<'static>();
@@ -6,7 +6,7 @@ LL |     S.early::<'static>();
    |       |
    |       expected 2 lifetime arguments
    |
-note: associated function defined here, with 2 lifetime parameters: `'a`, `'b`
+note: method defined here, with 2 lifetime parameters: `'a`, `'b`
   --> $DIR/method-call-lifetime-args-fail.rs:6:8
    |
 LL |     fn early<'a, 'b>(self) -> (&'a u8, &'b u8) { loop {} }
@@ -16,7 +16,7 @@ help: add missing lifetime argument
 LL |     S.early::<'static, 'static>();
    |                      +++++++++
 
-error[E0107]: this associated function takes 2 lifetime arguments but 3 lifetime arguments were supplied
+error[E0107]: method takes 2 lifetime arguments but 3 lifetime arguments were supplied
   --> $DIR/method-call-lifetime-args-fail.rs:18:7
    |
 LL |     S.early::<'static, 'static, 'static>();
@@ -24,7 +24,7 @@ LL |     S.early::<'static, 'static, 'static>();
    |       |
    |       expected 2 lifetime arguments
    |
-note: associated function defined here, with 2 lifetime parameters: `'a`, `'b`
+note: method defined here, with 2 lifetime parameters: `'a`, `'b`
   --> $DIR/method-call-lifetime-args-fail.rs:6:8
    |
 LL |     fn early<'a, 'b>(self) -> (&'a u8, &'b u8) { loop {} }
@@ -198,7 +198,7 @@ note: the late bound lifetime parameter is introduced here
 LL |     fn late_unused_early<'a, 'b>(self) -> &'b u8 { loop {} }
    |                          ^^
 
-error[E0107]: this associated function takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: method takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/method-call-lifetime-args-fail.rs:63:8
    |
 LL |     S::early::<'static>(S);
@@ -206,7 +206,7 @@ LL |     S::early::<'static>(S);
    |        |
    |        expected 2 lifetime arguments
    |
-note: associated function defined here, with 2 lifetime parameters: `'a`, `'b`
+note: method defined here, with 2 lifetime parameters: `'a`, `'b`
   --> $DIR/method-call-lifetime-args-fail.rs:6:8
    |
 LL |     fn early<'a, 'b>(self) -> (&'a u8, &'b u8) { loop {} }
@@ -216,7 +216,7 @@ help: add missing lifetime argument
 LL |     S::early::<'static, 'static>(S);
    |                       +++++++++
 
-error[E0107]: this associated function takes 2 lifetime arguments but 3 lifetime arguments were supplied
+error[E0107]: method takes 2 lifetime arguments but 3 lifetime arguments were supplied
   --> $DIR/method-call-lifetime-args-fail.rs:65:8
    |
 LL |     S::early::<'static, 'static, 'static>(S);
@@ -224,7 +224,7 @@ LL |     S::early::<'static, 'static, 'static>(S);
    |        |
    |        expected 2 lifetime arguments
    |
-note: associated function defined here, with 2 lifetime parameters: `'a`, `'b`
+note: method defined here, with 2 lifetime parameters: `'a`, `'b`
   --> $DIR/method-call-lifetime-args-fail.rs:6:8
    |
 LL |     fn early<'a, 'b>(self) -> (&'a u8, &'b u8) { loop {} }
diff --git a/tests/ui/methods/method-deref-to-same-trait-object-with-separate-params.stderr b/tests/ui/methods/method-deref-to-same-trait-object-with-separate-params.stderr
index 82addab9479..4e83e4b77f1 100644
--- a/tests/ui/methods/method-deref-to-same-trait-object-with-separate-params.stderr
+++ b/tests/ui/methods/method-deref-to-same-trait-object-with-separate-params.stderr
@@ -44,15 +44,15 @@ note: candidate #3 is defined in the trait `FinalFoo`
    |
 LL |     fn foo(&self) -> u8;
    |     ^^^^^^^^^^^^^^^^^^^^
-help: disambiguate the associated function for candidate #1
+help: disambiguate the method for candidate #1
    |
 LL |     let z = X::foo(x);
    |             ~~~~~~~~~
-help: disambiguate the associated function for candidate #2
+help: disambiguate the method for candidate #2
    |
 LL |     let z = NuisanceFoo::foo(x);
    |             ~~~~~~~~~~~~~~~~~~~
-help: disambiguate the associated function for candidate #3
+help: disambiguate the method for candidate #3
    |
 LL |     let z = FinalFoo::foo(x);
    |             ~~~~~~~~~~~~~~~~
diff --git a/tests/ui/methods/method-self-arg-1.stderr b/tests/ui/methods/method-self-arg-1.stderr
index 32ab8dced21..9241a8be58f 100644
--- a/tests/ui/methods/method-self-arg-1.stderr
+++ b/tests/ui/methods/method-self-arg-1.stderr
@@ -8,7 +8,7 @@ LL |     Foo::bar(x);
    |     |        help: consider borrowing here: `&x`
    |     arguments to this function are incorrect
    |
-note: associated function defined here
+note: method defined here
   --> $DIR/method-self-arg-1.rs:6:8
    |
 LL |     fn bar(&self) {}
@@ -24,7 +24,7 @@ LL |     Foo::bar(&42);
    |
    = note: expected reference `&Foo`
               found reference `&{integer}`
-note: associated function defined here
+note: method defined here
   --> $DIR/method-self-arg-1.rs:6:8
    |
 LL |     fn bar(&self) {}
diff --git a/tests/ui/mismatched_types/issue-47706.stderr b/tests/ui/mismatched_types/issue-47706.stderr
index d9d408844d0..69d6ee5cbd5 100644
--- a/tests/ui/mismatched_types/issue-47706.stderr
+++ b/tests/ui/mismatched_types/issue-47706.stderr
@@ -27,7 +27,7 @@ note: required by a bound in `foo`
   --> $DIR/issue-47706.rs:22:8
    |
 LL | fn foo<F>(f: F)
-   |    --- required by a bound in this
+   |    --- required by a bound in this function
 LL | where
 LL |     F: Fn(),
    |        ^^^^ required by this bound in `foo`
diff --git a/tests/ui/nll/outlives-suggestion-simple.stderr b/tests/ui/nll/outlives-suggestion-simple.stderr
index a8368c494ed..bcffd575aed 100644
--- a/tests/ui/nll/outlives-suggestion-simple.stderr
+++ b/tests/ui/nll/outlives-suggestion-simple.stderr
@@ -73,7 +73,7 @@ LL | impl<'a> Bar<'a> {
 LL |     pub fn get<'b>(&self) -> &'b usize {
    |                -- lifetime `'b` defined here
 LL |         self.x
-   |         ^^^^^^ associated function was supposed to return data with lifetime `'b` but it is returning data with lifetime `'a`
+   |         ^^^^^^ method was supposed to return data with lifetime `'b` but it is returning data with lifetime `'a`
    |
    = help: consider adding the following bound: `'a: 'b`
 
@@ -85,7 +85,7 @@ LL | impl<'a> Baz<'a> {
 LL |     fn get<'b>(&'b self) -> &'a i32 {
    |            -- lifetime `'b` defined here
 LL |         self.x
-   |         ^^^^^^ associated function was supposed to return data with lifetime `'a` but it is returning data with lifetime `'b`
+   |         ^^^^^^ method was supposed to return data with lifetime `'a` but it is returning data with lifetime `'b`
    |
    = help: consider adding the following bound: `'b: 'a`
 
diff --git a/tests/ui/object-safety/object-safety-supertrait-mentions-GAT.stderr b/tests/ui/object-safety/object-safety-supertrait-mentions-GAT.stderr
index f05b0cd6538..40429fe756f 100644
--- a/tests/ui/object-safety/object-safety-supertrait-mentions-GAT.stderr
+++ b/tests/ui/object-safety/object-safety-supertrait-mentions-GAT.stderr
@@ -1,5 +1,10 @@
 error[E0311]: the parameter type `Self` may not live long enough
    |
+note: the parameter type `Self` must be valid for the lifetime `'a` as defined here...
+  --> $DIR/object-safety-supertrait-mentions-GAT.rs:9:26
+   |
+LL | trait SuperTrait<T>: for<'a> GatTrait<Gat<'a> = T> {
+   |                          ^^
    = help: consider adding an explicit lifetime bound `Self: 'a`...
    = note: ...so that the type `Self` will meet its required lifetime bounds...
 note: ...that is required by this bound
diff --git a/tests/ui/privacy/privacy1.rs b/tests/ui/privacy/privacy1.rs
index 3c9fa983dfd..fcb2108ab5f 100644
--- a/tests/ui/privacy/privacy1.rs
+++ b/tests/ui/privacy/privacy1.rs
@@ -106,7 +106,7 @@ mod foo {
                                 //~^ ERROR: associated function `bar` is private
         ::bar::baz::A.foo2();   //~ ERROR: module `baz` is private
         ::bar::baz::A.bar2();   //~ ERROR: module `baz` is private
-                                //~^ ERROR: associated function `bar2` is private
+                                //~^ ERROR: method `bar2` is private
 
         let _: isize =
         ::bar::B::foo();        //~ ERROR: trait `B` is private
diff --git a/tests/ui/privacy/privacy1.stderr b/tests/ui/privacy/privacy1.stderr
index 70e6fcb7a07..6ebed8ee062 100644
--- a/tests/ui/privacy/privacy1.stderr
+++ b/tests/ui/privacy/privacy1.stderr
@@ -190,14 +190,14 @@ LL |             fn bar() {}
 LL |         ::bar::baz::A::bar();
    |                        ^^^ private associated function
 
-error[E0624]: associated function `bar2` is private
+error[E0624]: method `bar2` is private
   --> $DIR/privacy1.rs:108:23
    |
 LL |             fn bar2(&self) {}
-   |             -------------- private associated function defined here
+   |             -------------- private method defined here
 ...
 LL |         ::bar::baz::A.bar2();
-   |                       ^^^^ private associated function
+   |                       ^^^^ private method
 
 error: aborting due to 18 previous errors
 
diff --git a/tests/ui/privacy/private-impl-method.rs b/tests/ui/privacy/private-impl-method.rs
index f7be6726c5e..b5587920f1c 100644
--- a/tests/ui/privacy/private-impl-method.rs
+++ b/tests/ui/privacy/private-impl-method.rs
@@ -17,5 +17,5 @@ fn f() {
 fn main() {
     let s = a::Foo { x: 1 };
     s.bar();
-    s.foo();    //~ ERROR associated function `foo` is private
+    s.foo();    //~ ERROR method `foo` is private
 }
diff --git a/tests/ui/privacy/private-impl-method.stderr b/tests/ui/privacy/private-impl-method.stderr
index bb54dce7e7e..18e4531d112 100644
--- a/tests/ui/privacy/private-impl-method.stderr
+++ b/tests/ui/privacy/private-impl-method.stderr
@@ -1,11 +1,11 @@
-error[E0624]: associated function `foo` is private
+error[E0624]: method `foo` is private
   --> $DIR/private-impl-method.rs:20:7
    |
 LL |         fn foo(&self) {}
-   |         ------------- private associated function defined here
+   |         ------------- private method defined here
 ...
 LL |     s.foo();
-   |       ^^^ private associated function
+   |       ^^^ private method
 
 error: aborting due to previous error
 
diff --git a/tests/ui/privacy/private-method-cross-crate.rs b/tests/ui/privacy/private-method-cross-crate.rs
index ab3bbdfe496..4da44e0682b 100644
--- a/tests/ui/privacy/private-method-cross-crate.rs
+++ b/tests/ui/privacy/private-method-cross-crate.rs
@@ -4,5 +4,5 @@ use cci_class_5::kitties::cat;
 
 fn main() {
   let nyan : cat = cat(52, 99);
-  nyan.nap();   //~ ERROR associated function `nap` is private
+  nyan.nap();   //~ ERROR method `nap` is private
 }
diff --git a/tests/ui/privacy/private-method-cross-crate.stderr b/tests/ui/privacy/private-method-cross-crate.stderr
index 93f6a7f2f61..e644440c827 100644
--- a/tests/ui/privacy/private-method-cross-crate.stderr
+++ b/tests/ui/privacy/private-method-cross-crate.stderr
@@ -1,13 +1,13 @@
-error[E0624]: associated function `nap` is private
+error[E0624]: method `nap` is private
   --> $DIR/private-method-cross-crate.rs:7:8
    |
 LL |   nyan.nap();
-   |        ^^^ private associated function
+   |        ^^^ private method
    |
   ::: $DIR/auxiliary/cci_class_5.rs:8:9
    |
 LL |         fn nap(&self) {}
-   |         ------------- private associated function defined here
+   |         ------------- private method defined here
 
 error: aborting due to previous error
 
diff --git a/tests/ui/privacy/private-method-inherited.rs b/tests/ui/privacy/private-method-inherited.rs
index 2f6454288ae..bc27027e886 100644
--- a/tests/ui/privacy/private-method-inherited.rs
+++ b/tests/ui/privacy/private-method-inherited.rs
@@ -10,5 +10,5 @@ mod a {
 
 fn main() {
     let x = a::Foo;
-    x.f();  //~ ERROR associated function `f` is private
+    x.f();  //~ ERROR method `f` is private
 }
diff --git a/tests/ui/privacy/private-method-inherited.stderr b/tests/ui/privacy/private-method-inherited.stderr
index 011a7fee478..0104a1b27e4 100644
--- a/tests/ui/privacy/private-method-inherited.stderr
+++ b/tests/ui/privacy/private-method-inherited.stderr
@@ -1,11 +1,11 @@
-error[E0624]: associated function `f` is private
+error[E0624]: method `f` is private
   --> $DIR/private-method-inherited.rs:13:7
    |
 LL |         fn f(self) {}
-   |         ---------- private associated function defined here
+   |         ---------- private method defined here
 ...
 LL |     x.f();
-   |       ^ private associated function
+   |       ^ private method
 
 error: aborting due to previous error
 
diff --git a/tests/ui/privacy/private-method.rs b/tests/ui/privacy/private-method.rs
index 76a642cde1a..a9bea520e75 100644
--- a/tests/ui/privacy/private-method.rs
+++ b/tests/ui/privacy/private-method.rs
@@ -19,5 +19,5 @@ mod kitties {
 
 fn main() {
   let nyan : kitties::Cat = kitties::cat(52, 99);
-  nyan.nap(); //~ ERROR associated function `nap` is private
+  nyan.nap(); //~ ERROR method `nap` is private
 }
diff --git a/tests/ui/privacy/private-method.stderr b/tests/ui/privacy/private-method.stderr
index 17c7179dc36..42fec762265 100644
--- a/tests/ui/privacy/private-method.stderr
+++ b/tests/ui/privacy/private-method.stderr
@@ -1,11 +1,11 @@
-error[E0624]: associated function `nap` is private
+error[E0624]: method `nap` is private
   --> $DIR/private-method.rs:22:8
    |
 LL |         fn nap(&self) {}
-   |         ------------- private associated function defined here
+   |         ------------- private method defined here
 ...
 LL |   nyan.nap();
-   |        ^^^ private associated function
+   |        ^^^ private method
 
 error: aborting due to previous error
 
diff --git a/tests/ui/privacy/restricted/test.stderr b/tests/ui/privacy/restricted/test.stderr
index 1acd221b42c..76f19525df5 100644
--- a/tests/ui/privacy/restricted/test.stderr
+++ b/tests/ui/privacy/restricted/test.stderr
@@ -54,14 +54,14 @@ error[E0616]: field `x` of struct `S` is private
 LL |     S::default().x;
    |                  ^ private field
 
-error[E0624]: associated function `f` is private
+error[E0624]: method `f` is private
   --> $DIR/test.rs:32:18
    |
 LL |             pub(super) fn f(&self) {}
-   |             ---------------------- private associated function defined here
+   |             ---------------------- private method defined here
 ...
 LL |     S::default().f();
-   |                  ^ private associated function
+   |                  ^ private method
 
 error[E0624]: associated function `g` is private
   --> $DIR/test.rs:33:8
@@ -84,27 +84,27 @@ error[E0616]: field `z` of struct `Universe` is private
 LL |     let _ = u.z;
    |               ^ private field
 
-error[E0624]: associated function `g` is private
+error[E0624]: method `g` is private
   --> $DIR/test.rs:45:7
    |
 LL |     u.g();
-   |       ^ private associated function
+   |       ^ private method
    |
   ::: $DIR/auxiliary/pub_restricted.rs:12:5
    |
 LL |     pub(crate) fn g(&self) {}
-   |     ---------------------- private associated function defined here
+   |     ---------------------- private method defined here
 
-error[E0624]: associated function `h` is private
+error[E0624]: method `h` is private
   --> $DIR/test.rs:46:7
    |
 LL |     u.h();
-   |       ^ private associated function
+   |       ^ private method
    |
   ::: $DIR/auxiliary/pub_restricted.rs:13:5
    |
 LL |     pub(crate) fn h(&self) {}
-   |     ---------------------- private associated function defined here
+   |     ---------------------- private method defined here
 
 error: aborting due to 12 previous errors
 
diff --git a/tests/ui/recursion_limit/issue_21102.rs b/tests/ui/recursion_limit/issue-105700.rs
index e1fee46313d..e1fee46313d 100644
--- a/tests/ui/recursion_limit/issue_21102.rs
+++ b/tests/ui/recursion_limit/issue-105700.rs
diff --git a/tests/ui/recursion_limit/issue_21102.stderr b/tests/ui/recursion_limit/issue-105700.stderr
index 1bd722c492b..9b1114e9ce6 100644
--- a/tests/ui/recursion_limit/issue_21102.stderr
+++ b/tests/ui/recursion_limit/issue-105700.stderr
@@ -1,10 +1,10 @@
 error: recursion limit reached while expanding `#[invalid_attribute]`
-  --> $DIR/issue_21102.rs:6:1
+  --> $DIR/issue-105700.rs:6:1
    |
 LL | #![invalid_attribute]
    | ^^^^^^^^^^^^^^^^^^^^^
    |
-   = help: consider increasing the recursion limit by adding a `#![recursion_limit = "8"]` attribute to your crate (`issue_21102`)
+   = help: consider increasing the recursion limit by adding a `#![recursion_limit = "8"]` attribute to your crate (`issue_105700`)
 
 error: aborting due to previous error
 
diff --git a/tests/ui/regions/regions-early-bound-error-method.stderr b/tests/ui/regions/regions-early-bound-error-method.stderr
index 7f10c051f29..a7746d8981e 100644
--- a/tests/ui/regions/regions-early-bound-error-method.stderr
+++ b/tests/ui/regions/regions-early-bound-error-method.stderr
@@ -6,7 +6,7 @@ LL | impl<'a> Box<'a> {
 LL |     fn or<'b,G:GetRef<'b>>(&self, g2: G) -> &'a isize {
    |           -- lifetime `'b` defined here
 LL |         g2.get()
-   |         ^^^^^^^^ associated function was supposed to return data with lifetime `'a` but it is returning data with lifetime `'b`
+   |         ^^^^^^^^ method was supposed to return data with lifetime `'a` but it is returning data with lifetime `'b`
    |
    = help: consider adding the following bound: `'b: 'a`
 
diff --git a/tests/ui/regions/regions-free-region-ordering-incorrect.stderr b/tests/ui/regions/regions-free-region-ordering-incorrect.stderr
index f7c75033c04..d0ceaec3b67 100644
--- a/tests/ui/regions/regions-free-region-ordering-incorrect.stderr
+++ b/tests/ui/regions/regions-free-region-ordering-incorrect.stderr
@@ -9,7 +9,7 @@ LL | /         match self.next {
 LL | |             Some(ref next) => next.get(),
 LL | |             None => &self.val
 LL | |         }
-   | |_________^ associated function was supposed to return data with lifetime `'b` but it is returning data with lifetime `'a`
+   | |_________^ method was supposed to return data with lifetime `'b` but it is returning data with lifetime `'a`
    |
    = help: consider adding the following bound: `'a: 'b`
 
diff --git a/tests/ui/regions/regions-free-region-outlives-static-outlives-free-region.rs b/tests/ui/regions/regions-free-region-outlives-static-outlives-free-region.rs
index 7c2e1aeeea6..46462c432a8 100644
--- a/tests/ui/regions/regions-free-region-outlives-static-outlives-free-region.rs
+++ b/tests/ui/regions/regions-free-region-outlives-static-outlives-free-region.rs
@@ -8,6 +8,8 @@
 //
 //     'a : 'b
 
+#![warn(unused_lifetimes)]
+
 fn test<'a,'b>(x: &'a i32) -> &'b i32
     where 'a: 'static //~ WARN unnecessary lifetime parameter `'a`
 {
diff --git a/tests/ui/regions/regions-free-region-outlives-static-outlives-free-region.stderr b/tests/ui/regions/regions-free-region-outlives-static-outlives-free-region.stderr
index 70ed418d5cb..9f03a6553ba 100644
--- a/tests/ui/regions/regions-free-region-outlives-static-outlives-free-region.stderr
+++ b/tests/ui/regions/regions-free-region-outlives-static-outlives-free-region.stderr
@@ -1,10 +1,15 @@
 warning: unnecessary lifetime parameter `'a`
-  --> $DIR/regions-free-region-outlives-static-outlives-free-region.rs:12:11
+  --> $DIR/regions-free-region-outlives-static-outlives-free-region.rs:14:11
    |
 LL |     where 'a: 'static
    |           ^^
    |
    = help: you can use the `'static` lifetime directly, in place of `'a`
+note: the lint level is defined here
+  --> $DIR/regions-free-region-outlives-static-outlives-free-region.rs:11:9
+   |
+LL | #![warn(unused_lifetimes)]
+   |         ^^^^^^^^^^^^^^^^
 
 warning: 1 warning emitted
 
diff --git a/tests/ui/regions/regions-static-bound-rpass.rs b/tests/ui/regions/regions-static-bound-rpass.rs
index 25232b455b6..e2ebb394d0a 100644
--- a/tests/ui/regions/regions-static-bound-rpass.rs
+++ b/tests/ui/regions/regions-static-bound-rpass.rs
@@ -1,5 +1,7 @@
 // run-pass
 
+#![warn(unused_lifetimes)]
+
 fn invariant_id<'a,'b>(t: &'b mut &'static ()) -> &'b mut &'a ()
     where 'a: 'static { t }
 //~^ WARN unnecessary lifetime parameter `'a`
diff --git a/tests/ui/regions/regions-static-bound-rpass.stderr b/tests/ui/regions/regions-static-bound-rpass.stderr
index 9355a409d50..f0f3a4c5261 100644
--- a/tests/ui/regions/regions-static-bound-rpass.stderr
+++ b/tests/ui/regions/regions-static-bound-rpass.stderr
@@ -1,13 +1,18 @@
 warning: unnecessary lifetime parameter `'a`
-  --> $DIR/regions-static-bound-rpass.rs:4:11
+  --> $DIR/regions-static-bound-rpass.rs:6:11
    |
 LL |     where 'a: 'static { t }
    |           ^^
    |
    = help: you can use the `'static` lifetime directly, in place of `'a`
+note: the lint level is defined here
+  --> $DIR/regions-static-bound-rpass.rs:3:9
+   |
+LL | #![warn(unused_lifetimes)]
+   |         ^^^^^^^^^^^^^^^^
 
 warning: unnecessary lifetime parameter `'a`
-  --> $DIR/regions-static-bound-rpass.rs:8:11
+  --> $DIR/regions-static-bound-rpass.rs:10:11
    |
 LL |     where 'a: 'static { t }
    |           ^^
@@ -15,7 +20,7 @@ LL |     where 'a: 'static { t }
    = help: you can use the `'static` lifetime directly, in place of `'a`
 
 warning: unnecessary lifetime parameter `'b`
-  --> $DIR/regions-static-bound-rpass.rs:12:19
+  --> $DIR/regions-static-bound-rpass.rs:14:19
    |
 LL |     where 'a: 'b, 'b: 'static { t }
    |                   ^^
diff --git a/tests/ui/regions/regions-static-bound.rs b/tests/ui/regions/regions-static-bound.rs
index 4d2455470e2..e7aa8795f01 100644
--- a/tests/ui/regions/regions-static-bound.rs
+++ b/tests/ui/regions/regions-static-bound.rs
@@ -1,6 +1,8 @@
-fn static_id<'a,'b>(t: &'a ()) -> &'static ()
-    where 'a: 'static { t }
-//~^ WARN unnecessary lifetime parameter `'a`
+#![warn(unused_lifetimes)]
+
+fn static_id<'a,'b>(t: &'a ()) -> &'static () where 'a: 'static { t }
+//~^ WARN lifetime parameter `'b` never used
+//~| WARN unnecessary lifetime parameter `'a`
 
 fn static_id_indirect<'a,'b>(t: &'a ()) -> &'static ()
     where 'a: 'b, 'b: 'static { t }
diff --git a/tests/ui/regions/regions-static-bound.stderr b/tests/ui/regions/regions-static-bound.stderr
index 2886ec3ead5..b314e9fe85d 100644
--- a/tests/ui/regions/regions-static-bound.stderr
+++ b/tests/ui/regions/regions-static-bound.stderr
@@ -1,13 +1,27 @@
+warning: lifetime parameter `'b` never used
+  --> $DIR/regions-static-bound.rs:3:17
+   |
+LL | fn static_id<'a,'b>(t: &'a ()) -> &'static () where 'a: 'static { t }
+   |                -^^
+   |                |
+   |                help: elide the unused lifetime
+   |
+note: the lint level is defined here
+  --> $DIR/regions-static-bound.rs:1:9
+   |
+LL | #![warn(unused_lifetimes)]
+   |         ^^^^^^^^^^^^^^^^
+
 warning: unnecessary lifetime parameter `'a`
-  --> $DIR/regions-static-bound.rs:2:11
+  --> $DIR/regions-static-bound.rs:3:53
    |
-LL |     where 'a: 'static { t }
-   |           ^^
+LL | fn static_id<'a,'b>(t: &'a ()) -> &'static () where 'a: 'static { t }
+   |                                                     ^^
    |
    = help: you can use the `'static` lifetime directly, in place of `'a`
 
 warning: unnecessary lifetime parameter `'b`
-  --> $DIR/regions-static-bound.rs:6:19
+  --> $DIR/regions-static-bound.rs:8:19
    |
 LL |     where 'a: 'b, 'b: 'static { t }
    |                   ^^
@@ -15,7 +29,7 @@ LL |     where 'a: 'b, 'b: 'static { t }
    = help: you can use the `'static` lifetime directly, in place of `'b`
 
 error: lifetime may not live long enough
-  --> $DIR/regions-static-bound.rs:10:5
+  --> $DIR/regions-static-bound.rs:12:5
    |
 LL | fn static_id_wrong_way<'a>(t: &'a ()) -> &'static () where 'static: 'a {
    |                        -- lifetime `'a` defined here
@@ -23,7 +37,7 @@ LL |     t
    |     ^ returning this value requires that `'a` must outlive `'static`
 
 error[E0521]: borrowed data escapes outside of function
-  --> $DIR/regions-static-bound.rs:15:5
+  --> $DIR/regions-static-bound.rs:17:5
    |
 LL | fn error(u: &(), v: &()) {
    |          -  - let's call the lifetime of this reference `'1`
@@ -36,7 +50,7 @@ LL |     static_id(&u);
    |     argument requires that `'1` must outlive `'static`
 
 error[E0521]: borrowed data escapes outside of function
-  --> $DIR/regions-static-bound.rs:17:5
+  --> $DIR/regions-static-bound.rs:19:5
    |
 LL | fn error(u: &(), v: &()) {
    |                  -  - let's call the lifetime of this reference `'2`
@@ -49,6 +63,6 @@ LL |     static_id_indirect(&v);
    |     `v` escapes the function body here
    |     argument requires that `'2` must outlive `'static`
 
-error: aborting due to 3 previous errors; 2 warnings emitted
+error: aborting due to 3 previous errors; 3 warnings emitted
 
 For more information about this error, try `rustc --explain E0521`.
diff --git a/tests/ui/regions/resolve-re-error-ice.rs b/tests/ui/regions/resolve-re-error-ice.rs
new file mode 100644
index 00000000000..f37b27a82b3
--- /dev/null
+++ b/tests/ui/regions/resolve-re-error-ice.rs
@@ -0,0 +1,22 @@
+// check-pass
+
+// Allow this for now, can remove this UI test when this becomes a hard error.
+#![allow(implied_bounds_entailment)]
+
+use std::collections::hash_map::{Keys, HashMap};
+use std::marker::PhantomData;
+
+trait MapAssertion<'a, K, V, R> {
+    fn key_set(&self) -> Subject<Keys<K, V>, (), R>;
+}
+
+struct Subject<'a, T, V, R>(PhantomData<(&'a T, V, R)>);
+
+impl<'a, K, V, R> MapAssertion<'a, K, V, R> for Subject<'a, HashMap<K, V>, (), R>
+{
+    fn key_set(&self) -> Subject<'a, Keys<K, V>, (), R> {
+        todo!()
+    }
+}
+
+fn main() {}
diff --git a/tests/ui/regions/resolve-re-error-ice.stderr b/tests/ui/regions/resolve-re-error-ice.stderr
new file mode 100644
index 00000000000..e7003e1c32f
--- /dev/null
+++ b/tests/ui/regions/resolve-re-error-ice.stderr
@@ -0,0 +1,15 @@
+Future incompatibility report: Future breakage diagnostic:
+warning: impl method assumes more implied bounds than the corresponding trait method
+  --> $DIR/resolve-re-error-ice.rs:17:16
+   |
+LL |     fn key_set(&self) -> Subject<'a, Keys<K, V>, (), R> {
+   |                ^^^^^     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace this type to make the impl signature compatible: `Subject<'_, std::collections::hash_map::Keys<'_, K, V>, (), R>`
+   |
+   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+   = note: for more information, see issue #105572 <https://github.com/rust-lang/rust/issues/105572>
+note: the lint level is defined here
+  --> $DIR/resolve-re-error-ice.rs:4:10
+   |
+LL | #![allow(implied_bounds_entailment)]
+   |          ^^^^^^^^^^^^^^^^^^^^^^^^^
+
diff --git a/tests/ui/rfc-2091-track-caller/error-with-main.stderr b/tests/ui/rfc-2091-track-caller/error-with-main.stderr
index 7e2ec352414..6d6562dae3b 100644
--- a/tests/ui/rfc-2091-track-caller/error-with-main.stderr
+++ b/tests/ui/rfc-2091-track-caller/error-with-main.stderr
@@ -2,7 +2,7 @@ error: `main` function is not allowed to be `#[track_caller]`
   --> $DIR/error-with-main.rs:1:1
    |
 LL | #[track_caller]
-   | ^^^^^^^^^^^^^^^
+   | ^^^^^^^^^^^^^^^ help: remove this annotation
 LL | fn main() {
    | --------- `main` function is not allowed to be `#[track_caller]`
 
diff --git a/tests/ui/rfc-2457/mod_file_nonascii_forbidden.stderr b/tests/ui/rfc-2457/mod_file_nonascii_forbidden.stderr
index dd0dac95e36..7639ae9f6a4 100644
--- a/tests/ui/rfc-2457/mod_file_nonascii_forbidden.stderr
+++ b/tests/ui/rfc-2457/mod_file_nonascii_forbidden.stderr
@@ -12,7 +12,7 @@ error[E0754]: trying to load file for module `řųśť` with non-ascii identifie
 LL | mod řųśť;
    |     ^^^^
    |
-   = help: consider using `#[path]` attribute to specify filesystem path
+   = help: consider using the `#[path]` attribute to specify filesystem path
 
 error: aborting due to 2 previous errors
 
diff --git a/tests/ui/rfc-2632-const-trait-impl/do-not-const-check-override.rs b/tests/ui/rfc-2632-const-trait-impl/do-not-const-check-override.rs
new file mode 100644
index 00000000000..730e268c091
--- /dev/null
+++ b/tests/ui/rfc-2632-const-trait-impl/do-not-const-check-override.rs
@@ -0,0 +1,19 @@
+// check-pass
+#![feature(const_trait_impl, rustc_attrs)]
+
+#[const_trait]
+trait Foo {
+    #[rustc_do_not_const_check]
+    fn into_iter(&self) { println!("FEAR ME!") }
+}
+
+
+impl const Foo for () {
+    fn into_iter(&self) {
+        // ^_^
+    }
+}
+
+const _: () = Foo::into_iter(&());
+
+fn main() {}
diff --git a/tests/ui/rfc-2632-const-trait-impl/do-not-const-check.rs b/tests/ui/rfc-2632-const-trait-impl/do-not-const-check.rs
new file mode 100644
index 00000000000..3c39c53de5f
--- /dev/null
+++ b/tests/ui/rfc-2632-const-trait-impl/do-not-const-check.rs
@@ -0,0 +1,18 @@
+// check-pass
+#![feature(const_trait_impl, rustc_attrs)]
+
+#[const_trait]
+trait IntoIter {
+    fn into_iter(self);
+}
+
+#[const_trait]
+trait Hmm: Sized {
+    #[rustc_do_not_const_check]
+    fn chain<U>(self, other: U) where U: IntoIter,
+    {
+        other.into_iter()
+    }
+}
+
+fn main() {}
diff --git a/tests/ui/self/arbitrary_self_types_pin_lifetime_mismatch-async.stderr b/tests/ui/self/arbitrary_self_types_pin_lifetime_mismatch-async.stderr
index 6180e1e0f2d..0b4c0a7fece 100644
--- a/tests/ui/self/arbitrary_self_types_pin_lifetime_mismatch-async.stderr
+++ b/tests/ui/self/arbitrary_self_types_pin_lifetime_mismatch-async.stderr
@@ -2,7 +2,7 @@ error: lifetime may not live long enough
   --> $DIR/arbitrary_self_types_pin_lifetime_mismatch-async.rs:8:52
    |
 LL |     async fn a(self: Pin<&Foo>, f: &Foo) -> &Foo { f }
-   |                          -         -               ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |                          -         -               ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |                          |         |
    |                          |         let's call the lifetime of this reference `'1`
    |                          let's call the lifetime of this reference `'2`
@@ -16,7 +16,7 @@ error: lifetime may not live long enough
   --> $DIR/arbitrary_self_types_pin_lifetime_mismatch-async.rs:11:75
    |
 LL |     async fn c(self: Pin<&Self>, f: &Foo, g: &Foo) -> (Pin<&Foo>, &Foo) { (self, f) }
-   |                          -          -                                     ^^^^^^^^^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |                          -          -                                     ^^^^^^^^^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |                          |          |
    |                          |          let's call the lifetime of this reference `'1`
    |                          let's call the lifetime of this reference `'2`
@@ -30,7 +30,7 @@ error: lifetime may not live long enough
   --> $DIR/arbitrary_self_types_pin_lifetime_mismatch-async.rs:17:64
    |
 LL |     async fn bar<'a>(self: Alias<&Self>, arg: &'a ()) -> &() { arg }
-   |                  --              -                             ^^^ associated function was supposed to return data with lifetime `'1` but it is returning data with lifetime `'a`
+   |                  --              -                             ^^^ method was supposed to return data with lifetime `'1` but it is returning data with lifetime `'a`
    |                  |               |
    |                  |               let's call the lifetime of this reference `'1`
    |                  lifetime `'a` defined here
diff --git a/tests/ui/self/arbitrary_self_types_pin_lifetime_mismatch.stderr b/tests/ui/self/arbitrary_self_types_pin_lifetime_mismatch.stderr
index fccee5d4363..209dae9c1b3 100644
--- a/tests/ui/self/arbitrary_self_types_pin_lifetime_mismatch.stderr
+++ b/tests/ui/self/arbitrary_self_types_pin_lifetime_mismatch.stderr
@@ -2,7 +2,7 @@ error: lifetime may not live long enough
   --> $DIR/arbitrary_self_types_pin_lifetime_mismatch.rs:6:46
    |
 LL |     fn a(self: Pin<&Foo>, f: &Foo) -> &Foo { f }
-   |                    -         -               ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |                    -         -               ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |                    |         |
    |                    |         let's call the lifetime of this reference `'1`
    |                    let's call the lifetime of this reference `'2`
@@ -16,7 +16,7 @@ error: lifetime may not live long enough
   --> $DIR/arbitrary_self_types_pin_lifetime_mismatch.rs:9:69
    |
 LL |     fn c(self: Pin<&Self>, f: &Foo, g: &Foo) -> (Pin<&Foo>, &Foo) { (self, f) }
-   |                    -          -                                     ^^^^^^^^^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |                    -          -                                     ^^^^^^^^^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |                    |          |
    |                    |          let's call the lifetime of this reference `'1`
    |                    let's call the lifetime of this reference `'2`
@@ -30,7 +30,7 @@ error: lifetime may not live long enough
   --> $DIR/arbitrary_self_types_pin_lifetime_mismatch.rs:15:58
    |
 LL |     fn bar<'a>(self: Alias<&Self>, arg: &'a ()) -> &() { arg }
-   |            --  ---- has type `Pin<&'1 Foo>`              ^^^ associated function was supposed to return data with lifetime `'1` but it is returning data with lifetime `'a`
+   |            --  ---- has type `Pin<&'1 Foo>`              ^^^ method was supposed to return data with lifetime `'1` but it is returning data with lifetime `'a`
    |            |
    |            lifetime `'a` defined here
 
diff --git a/tests/ui/self/elision/lt-ref-self-async.stderr b/tests/ui/self/elision/lt-ref-self-async.stderr
index 787afd4dc9d..29d60ed6635 100644
--- a/tests/ui/self/elision/lt-ref-self-async.stderr
+++ b/tests/ui/self/elision/lt-ref-self-async.stderr
@@ -6,7 +6,7 @@ LL |     async fn ref_self(&self, f: &u32) -> &u32 {
    |                       |
    |                       let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -21,7 +21,7 @@ LL |     async fn ref_Self(self: &Self, f: &u32) -> &u32 {
    |                             |
    |                             let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -36,7 +36,7 @@ LL |     async fn box_ref_Self(self: Box<&Self>, f: &u32) -> &u32 {
    |                                     |
    |                                     let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -51,7 +51,7 @@ LL |     async fn pin_ref_Self(self: Pin<&Self>, f: &u32) -> &u32 {
    |                                     |
    |                                     let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -66,7 +66,7 @@ LL |     async fn box_box_ref_Self(self: Box<Box<&Self>>, f: &u32) -> &u32 {
    |                                             |
    |                                             let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -81,7 +81,7 @@ LL |     async fn box_pin_Self(self: Box<Pin<&Self>>, f: &u32) -> &u32 {
    |                                         |
    |                                         let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
diff --git a/tests/ui/self/elision/lt-ref-self.stderr b/tests/ui/self/elision/lt-ref-self.stderr
index 49af638e4c6..216737a2c73 100644
--- a/tests/ui/self/elision/lt-ref-self.stderr
+++ b/tests/ui/self/elision/lt-ref-self.stderr
@@ -6,7 +6,7 @@ LL |     fn ref_self(&self, f: &u32) -> &u32 {
    |                 |
    |                 let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -21,7 +21,7 @@ LL |     fn ref_Self(self: &Self, f: &u32) -> &u32 {
    |                       |
    |                       let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -36,7 +36,7 @@ LL |     fn box_ref_Self(self: Box<&Self>, f: &u32) -> &u32 {
    |                               |
    |                               let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -51,7 +51,7 @@ LL |     fn pin_ref_Self(self: Pin<&Self>, f: &u32) -> &u32 {
    |                               |
    |                               let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -66,7 +66,7 @@ LL |     fn box_box_ref_Self(self: Box<Box<&Self>>, f: &u32) -> &u32 {
    |                                       |
    |                                       let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -81,7 +81,7 @@ LL |     fn box_pin_Self(self: Box<Pin<&Self>>, f: &u32) -> &u32 {
    |                                   |
    |                                   let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
diff --git a/tests/ui/self/elision/ref-mut-self-async.stderr b/tests/ui/self/elision/ref-mut-self-async.stderr
index dff50aee918..62543ba5339 100644
--- a/tests/ui/self/elision/ref-mut-self-async.stderr
+++ b/tests/ui/self/elision/ref-mut-self-async.stderr
@@ -6,7 +6,7 @@ LL |     async fn ref_self(&mut self, f: &u32) -> &u32 {
    |                       |
    |                       let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -21,7 +21,7 @@ LL |     async fn ref_Self(self: &mut Self, f: &u32) -> &u32 {
    |                             |
    |                             let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -36,7 +36,7 @@ LL |     async fn box_ref_Self(self: Box<&mut Self>, f: &u32) -> &u32 {
    |                                     |
    |                                     let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -51,7 +51,7 @@ LL |     async fn pin_ref_Self(self: Pin<&mut Self>, f: &u32) -> &u32 {
    |                                     |
    |                                     let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -66,7 +66,7 @@ LL |     async fn box_box_ref_Self(self: Box<Box<&mut Self>>, f: &u32) -> &u32 {
    |                                             |
    |                                             let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -81,7 +81,7 @@ LL |     async fn box_pin_ref_Self(self: Box<Pin<&mut Self>>, f: &u32) -> &u32 {
    |                                             |
    |                                             let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
diff --git a/tests/ui/self/elision/ref-mut-self.stderr b/tests/ui/self/elision/ref-mut-self.stderr
index ccf1830167c..12b64a3f6dc 100644
--- a/tests/ui/self/elision/ref-mut-self.stderr
+++ b/tests/ui/self/elision/ref-mut-self.stderr
@@ -6,7 +6,7 @@ LL |     fn ref_self(&mut self, f: &u32) -> &u32 {
    |                 |
    |                 let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -21,7 +21,7 @@ LL |     fn ref_Self(self: &mut Self, f: &u32) -> &u32 {
    |                       |
    |                       let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -36,7 +36,7 @@ LL |     fn box_ref_Self(self: Box<&mut Self>, f: &u32) -> &u32 {
    |                               |
    |                               let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -51,7 +51,7 @@ LL |     fn pin_ref_Self(self: Pin<&mut Self>, f: &u32) -> &u32 {
    |                               |
    |                               let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -66,7 +66,7 @@ LL |     fn box_box_ref_Self(self: Box<Box<&mut Self>>, f: &u32) -> &u32 {
    |                                       |
    |                                       let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -81,7 +81,7 @@ LL |     fn box_pin_ref_Self(self: Box<Pin<&mut Self>>, f: &u32) -> &u32 {
    |                                       |
    |                                       let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
diff --git a/tests/ui/self/elision/ref-mut-struct-async.stderr b/tests/ui/self/elision/ref-mut-struct-async.stderr
index 5b7ad026f9d..f8fb2e4a138 100644
--- a/tests/ui/self/elision/ref-mut-struct-async.stderr
+++ b/tests/ui/self/elision/ref-mut-struct-async.stderr
@@ -6,7 +6,7 @@ LL |     async fn ref_Struct(self: &mut Struct, f: &u32) -> &u32 {
    |                               |
    |                               let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -21,7 +21,7 @@ LL |     async fn box_ref_Struct(self: Box<&mut Struct>, f: &u32) -> &u32 {
    |                                       |
    |                                       let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -36,7 +36,7 @@ LL |     async fn pin_ref_Struct(self: Pin<&mut Struct>, f: &u32) -> &u32 {
    |                                       |
    |                                       let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -51,7 +51,7 @@ LL |     async fn box_box_ref_Struct(self: Box<Box<&mut Struct>>, f: &u32) -> &u
    |                                               |
    |                                               let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -66,7 +66,7 @@ LL |     async fn box_pin_ref_Struct(self: Box<Pin<&mut Struct>>, f: &u32) -> &u
    |                                               |
    |                                               let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
diff --git a/tests/ui/self/elision/ref-mut-struct.stderr b/tests/ui/self/elision/ref-mut-struct.stderr
index b9c71e8433c..cde16ce8ba4 100644
--- a/tests/ui/self/elision/ref-mut-struct.stderr
+++ b/tests/ui/self/elision/ref-mut-struct.stderr
@@ -6,7 +6,7 @@ LL |     fn ref_Struct(self: &mut Struct, f: &u32) -> &u32 {
    |                         |
    |                         let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -21,7 +21,7 @@ LL |     fn box_ref_Struct(self: Box<&mut Struct>, f: &u32) -> &u32 {
    |                                 |
    |                                 let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -36,7 +36,7 @@ LL |     fn pin_ref_Struct(self: Pin<&mut Struct>, f: &u32) -> &u32 {
    |                                 |
    |                                 let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -51,7 +51,7 @@ LL |     fn box_box_ref_Struct(self: Box<Box<&mut Struct>>, f: &u32) -> &u32 {
    |                                         |
    |                                         let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -66,7 +66,7 @@ LL |     fn box_pin_ref_Struct(self: Box<Pin<&mut Struct>>, f: &u32) -> &u32 {
    |                                         |
    |                                         let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
diff --git a/tests/ui/self/elision/ref-self-async.stderr b/tests/ui/self/elision/ref-self-async.stderr
index 26ef9779be2..010d281b002 100644
--- a/tests/ui/self/elision/ref-self-async.stderr
+++ b/tests/ui/self/elision/ref-self-async.stderr
@@ -6,7 +6,7 @@ LL |     async fn ref_self(&self, f: &u32) -> &u32 {
    |                       |
    |                       let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -21,7 +21,7 @@ LL |     async fn ref_Self(self: &Self, f: &u32) -> &u32 {
    |                             |
    |                             let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -36,7 +36,7 @@ LL |     async fn box_ref_Self(self: Box<&Self>, f: &u32) -> &u32 {
    |                                     |
    |                                     let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -51,7 +51,7 @@ LL |     async fn pin_ref_Self(self: Pin<&Self>, f: &u32) -> &u32 {
    |                                     |
    |                                     let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -66,7 +66,7 @@ LL |     async fn box_box_ref_Self(self: Box<Box<&Self>>, f: &u32) -> &u32 {
    |                                             |
    |                                             let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -81,7 +81,7 @@ LL |     async fn box_pin_ref_Self(self: Box<Pin<&Self>>, f: &u32) -> &u32 {
    |                                             |
    |                                             let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -96,7 +96,7 @@ LL |     async fn wrap_ref_Self_Self(self: Wrap<&Self, Self>, f: &u8) -> &u8 {
    |                                            |
    |                                            let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
diff --git a/tests/ui/self/elision/ref-self.stderr b/tests/ui/self/elision/ref-self.stderr
index 32448f3a677..35693257c99 100644
--- a/tests/ui/self/elision/ref-self.stderr
+++ b/tests/ui/self/elision/ref-self.stderr
@@ -6,7 +6,7 @@ LL |     fn ref_self(&self, f: &u32) -> &u32 {
    |                 |
    |                 let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -21,7 +21,7 @@ LL |     fn ref_Self(self: &Self, f: &u32) -> &u32 {
    |                       |
    |                       let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -36,7 +36,7 @@ LL |     fn box_ref_Self(self: Box<&Self>, f: &u32) -> &u32 {
    |                               |
    |                               let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -51,7 +51,7 @@ LL |     fn pin_ref_Self(self: Pin<&Self>, f: &u32) -> &u32 {
    |                               |
    |                               let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -66,7 +66,7 @@ LL |     fn box_box_ref_Self(self: Box<Box<&Self>>, f: &u32) -> &u32 {
    |                                       |
    |                                       let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -81,7 +81,7 @@ LL |     fn box_pin_ref_Self(self: Box<Pin<&Self>>, f: &u32) -> &u32 {
    |                                       |
    |                                       let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -96,7 +96,7 @@ LL |     fn wrap_ref_Self_Self(self: Wrap<&Self, Self>, f: &u8) -> &u8 {
    |                                      |
    |                                      let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
diff --git a/tests/ui/self/elision/ref-struct-async.stderr b/tests/ui/self/elision/ref-struct-async.stderr
index edb5c54ab00..c9376d58f90 100644
--- a/tests/ui/self/elision/ref-struct-async.stderr
+++ b/tests/ui/self/elision/ref-struct-async.stderr
@@ -6,7 +6,7 @@ LL |     async fn ref_Struct(self: &Struct, f: &u32) -> &u32 {
    |                               |
    |                               let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -21,7 +21,7 @@ LL |     async fn box_ref_Struct(self: Box<&Struct>, f: &u32) -> &u32 {
    |                                       |
    |                                       let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -36,7 +36,7 @@ LL |     async fn pin_ref_Struct(self: Pin<&Struct>, f: &u32) -> &u32 {
    |                                       |
    |                                       let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -51,7 +51,7 @@ LL |     async fn box_box_ref_Struct(self: Box<Box<&Struct>>, f: &u32) -> &u32 {
    |                                               |
    |                                               let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -66,7 +66,7 @@ LL |     async fn box_pin_Struct(self: Box<Pin<&Struct>>, f: &u32) -> &u32 {
    |                                           |
    |                                           let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
diff --git a/tests/ui/self/elision/ref-struct.stderr b/tests/ui/self/elision/ref-struct.stderr
index 4492ed4aafc..a3d3cebeba9 100644
--- a/tests/ui/self/elision/ref-struct.stderr
+++ b/tests/ui/self/elision/ref-struct.stderr
@@ -6,7 +6,7 @@ LL |     fn ref_Struct(self: &Struct, f: &u32) -> &u32 {
    |                         |
    |                         let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -21,7 +21,7 @@ LL |     fn box_ref_Struct(self: Box<&Struct>, f: &u32) -> &u32 {
    |                                 |
    |                                 let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -36,7 +36,7 @@ LL |     fn pin_ref_Struct(self: Pin<&Struct>, f: &u32) -> &u32 {
    |                                 |
    |                                 let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -51,7 +51,7 @@ LL |     fn box_box_ref_Struct(self: Box<Box<&Struct>>, f: &u32) -> &u32 {
    |                                         |
    |                                         let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
@@ -66,7 +66,7 @@ LL |     fn box_pin_Struct(self: Box<Pin<&Struct>>, f: &u32) -> &u32 {
    |                                     |
    |                                     let's call the lifetime of this reference `'2`
 LL |         f
-   |         ^ associated function was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
+   |         ^ method was supposed to return data with lifetime `'2` but it is returning data with lifetime `'1`
    |
 help: consider introducing a named lifetime parameter and update trait if needed
    |
diff --git a/tests/ui/seq-args.rs b/tests/ui/seq-args.rs
index a5ebeecd311..627dfcc3198 100644
--- a/tests/ui/seq-args.rs
+++ b/tests/ui/seq-args.rs
@@ -2,12 +2,12 @@ fn main() {
     trait Seq { }
 
     impl<T> Seq<T> for Vec<T> {
-        //~^ ERROR this trait takes 0 generic arguments but 1 generic argument
+        //~^ ERROR trait takes 0 generic arguments but 1 generic argument
         /* ... */
     }
 
     impl Seq<bool> for u32 {
-        //~^ ERROR this trait takes 0 generic arguments but 1 generic argument
+        //~^ ERROR trait takes 0 generic arguments but 1 generic argument
         /* Treat the integer as a sequence of bits */
     }
 }
diff --git a/tests/ui/seq-args.stderr b/tests/ui/seq-args.stderr
index c404d95748b..a5b0f8e98dc 100644
--- a/tests/ui/seq-args.stderr
+++ b/tests/ui/seq-args.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this trait takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/seq-args.rs:4:13
    |
 LL |     impl<T> Seq<T> for Vec<T> {
@@ -12,7 +12,7 @@ note: trait defined here, with 0 generic parameters
 LL |     trait Seq { }
    |           ^^^
 
-error[E0107]: this trait takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/seq-args.rs:9:10
    |
 LL |     impl Seq<bool> for u32 {
diff --git a/tests/ui/span/issue-37767.stderr b/tests/ui/span/issue-37767.stderr
index f7732847a28..b612fdf16fc 100644
--- a/tests/ui/span/issue-37767.stderr
+++ b/tests/ui/span/issue-37767.stderr
@@ -14,11 +14,11 @@ note: candidate #2 is defined in the trait `B`
    |
 LL |     fn foo(&mut self) {}
    |     ^^^^^^^^^^^^^^^^^
-help: disambiguate the associated function for candidate #1
+help: disambiguate the method for candidate #1
    |
 LL |     A::foo(&a)
    |     ~~~~~~~~~~
-help: disambiguate the associated function for candidate #2
+help: disambiguate the method for candidate #2
    |
 LL |     B::foo(&a)
    |     ~~~~~~~~~~
@@ -39,11 +39,11 @@ note: candidate #2 is defined in the trait `D`
    |
 LL |     fn foo(&self) {}
    |     ^^^^^^^^^^^^^
-help: disambiguate the associated function for candidate #1
+help: disambiguate the method for candidate #1
    |
 LL |     C::foo(&a)
    |     ~~~~~~~~~~
-help: disambiguate the associated function for candidate #2
+help: disambiguate the method for candidate #2
    |
 LL |     D::foo(&a)
    |     ~~~~~~~~~~
@@ -64,11 +64,11 @@ note: candidate #2 is defined in the trait `F`
    |
 LL |     fn foo(self) {}
    |     ^^^^^^^^^^^^
-help: disambiguate the associated function for candidate #1
+help: disambiguate the method for candidate #1
    |
 LL |     E::foo(a)
    |     ~~~~~~~~~
-help: disambiguate the associated function for candidate #2
+help: disambiguate the method for candidate #2
    |
 LL |     F::foo(a)
    |     ~~~~~~~~~
diff --git a/tests/ui/span/issue-42234-unknown-receiver-type.full.stderr b/tests/ui/span/issue-42234-unknown-receiver-type.full.stderr
index 2b178990850..e01e1edab5a 100644
--- a/tests/ui/span/issue-42234-unknown-receiver-type.full.stderr
+++ b/tests/ui/span/issue-42234-unknown-receiver-type.full.stderr
@@ -15,7 +15,7 @@ error[E0282]: type annotations needed
   --> $DIR/issue-42234-unknown-receiver-type.rs:15:10
    |
 LL |         .sum::<_>()
-   |          ^^^ cannot infer type of the type parameter `S` declared on the associated function `sum`
+   |          ^^^ cannot infer type of the type parameter `S` declared on the method `sum`
    |
 help: consider specifying the generic argument
    |
diff --git a/tests/ui/span/issue-42234-unknown-receiver-type.generic_arg.stderr b/tests/ui/span/issue-42234-unknown-receiver-type.generic_arg.stderr
index d93d54e878b..a4b65256574 100644
--- a/tests/ui/span/issue-42234-unknown-receiver-type.generic_arg.stderr
+++ b/tests/ui/span/issue-42234-unknown-receiver-type.generic_arg.stderr
@@ -15,7 +15,7 @@ error[E0282]: type annotations needed
   --> $DIR/issue-42234-unknown-receiver-type.rs:15:10
    |
 LL |         .sum::<_>()
-   |          ^^^ cannot infer type of the type parameter `S` declared on the associated function `sum`
+   |          ^^^ cannot infer type of the type parameter `S` declared on the method `sum`
    |
 help: consider specifying the generic argument
    |
diff --git a/tests/ui/span/missing-unit-argument.stderr b/tests/ui/span/missing-unit-argument.stderr
index ef4d732b51d..ff89f775334 100644
--- a/tests/ui/span/missing-unit-argument.stderr
+++ b/tests/ui/span/missing-unit-argument.stderr
@@ -65,7 +65,7 @@ error[E0061]: this method takes 1 argument but 0 arguments were supplied
 LL |     S.baz();
    |       ^^^-- an argument of type `()` is missing
    |
-note: associated function defined here
+note: method defined here
   --> $DIR/missing-unit-argument.rs:6:8
    |
 LL |     fn baz(self, (): ()) { }
@@ -81,7 +81,7 @@ error[E0061]: this method takes 1 argument but 0 arguments were supplied
 LL |     S.generic::<()>();
    |       ^^^^^^^^^^^^^-- an argument of type `()` is missing
    |
-note: associated function defined here
+note: method defined here
   --> $DIR/missing-unit-argument.rs:7:8
    |
 LL |     fn generic<T>(self, _: T) { }
diff --git a/tests/ui/span/type-annotations-needed-expr.stderr b/tests/ui/span/type-annotations-needed-expr.stderr
index 9dff6c64db4..65a90318a3c 100644
--- a/tests/ui/span/type-annotations-needed-expr.stderr
+++ b/tests/ui/span/type-annotations-needed-expr.stderr
@@ -2,7 +2,7 @@ error[E0282]: type annotations needed
   --> $DIR/type-annotations-needed-expr.rs:2:39
    |
 LL |     let _ = (vec![1,2,3]).into_iter().sum() as f64;
-   |                                       ^^^ cannot infer type of the type parameter `S` declared on the associated function `sum`
+   |                                       ^^^ cannot infer type of the type parameter `S` declared on the method `sum`
    |
 help: consider specifying the generic argument
    |
diff --git a/tests/ui/stability-attribute/unresolved_stability_lint.rs b/tests/ui/stability-attribute/unresolved_stability_lint.rs
new file mode 100644
index 00000000000..818d228bc91
--- /dev/null
+++ b/tests/ui/stability-attribute/unresolved_stability_lint.rs
@@ -0,0 +1,8 @@
+#![feature(staged_api)]
+#![stable(feature = "uwu", since = "1.0.0")]
+
+#[unstable(feature = "foo", issue = "none")]
+impl Foo for () {}
+//~^ ERROR cannot find trait `Foo` in this scope
+
+fn main() {}
diff --git a/tests/ui/stability-attribute/unresolved_stability_lint.stderr b/tests/ui/stability-attribute/unresolved_stability_lint.stderr
new file mode 100644
index 00000000000..11d6abcaf36
--- /dev/null
+++ b/tests/ui/stability-attribute/unresolved_stability_lint.stderr
@@ -0,0 +1,9 @@
+error[E0405]: cannot find trait `Foo` in this scope
+  --> $DIR/unresolved_stability_lint.rs:5:6
+   |
+LL | impl Foo for () {}
+   |      ^^^ not found in this scope
+
+error: aborting due to previous error
+
+For more information about this error, try `rustc --explain E0405`.
diff --git a/tests/ui/static/static-lifetime-bound.rs b/tests/ui/static/static-lifetime-bound.rs
index b5da91ec3b6..847fe87b2ea 100644
--- a/tests/ui/static/static-lifetime-bound.rs
+++ b/tests/ui/static/static-lifetime-bound.rs
@@ -1,4 +1,4 @@
-fn f<'a: 'static>(_: &'a i32) {} //~WARN unnecessary lifetime parameter `'a`
+fn f<'a: 'static>(_: &'a i32) {}
 
 fn main() {
     let x = 0;
diff --git a/tests/ui/static/static-lifetime-bound.stderr b/tests/ui/static/static-lifetime-bound.stderr
index e22411b13b7..19e55a6582e 100644
--- a/tests/ui/static/static-lifetime-bound.stderr
+++ b/tests/ui/static/static-lifetime-bound.stderr
@@ -1,11 +1,3 @@
-warning: unnecessary lifetime parameter `'a`
-  --> $DIR/static-lifetime-bound.rs:1:6
-   |
-LL | fn f<'a: 'static>(_: &'a i32) {}
-   |      ^^
-   |
-   = help: you can use the `'static` lifetime directly, in place of `'a`
-
 error[E0597]: `x` does not live long enough
   --> $DIR/static-lifetime-bound.rs:5:7
    |
@@ -19,6 +11,6 @@ LL |     f(&x);
 LL | }
    | - `x` dropped here while still borrowed
 
-error: aborting due to previous error; 1 warning emitted
+error: aborting due to previous error
 
 For more information about this error, try `rustc --explain E0597`.
diff --git a/tests/ui/statics/uninhabited-static.stderr b/tests/ui/statics/uninhabited-static.stderr
index ef794bb36ac..437053a4476 100644
--- a/tests/ui/statics/uninhabited-static.stderr
+++ b/tests/ui/statics/uninhabited-static.stderr
@@ -53,10 +53,7 @@ warning: the type `Void` does not permit zero-initialization
   --> $DIR/uninhabited-static.rs:12:31
    |
 LL | static VOID2: Void = unsafe { std::mem::transmute(()) };
-   |                               ^^^^^^^^^^^^^^^^^^^^^^^
-   |                               |
-   |                               this code causes undefined behavior when executed
-   |                               help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
+   |                               ^^^^^^^^^^^^^^^^^^^^^^^ this code causes undefined behavior when executed
    |
 note: enums with no inhabited variants have no valid value
   --> $DIR/uninhabited-static.rs:4:1
@@ -75,10 +72,7 @@ warning: the type `Void` does not permit zero-initialization
   --> $DIR/uninhabited-static.rs:16:32
    |
 LL | static NEVER2: Void = unsafe { std::mem::transmute(()) };
-   |                                ^^^^^^^^^^^^^^^^^^^^^^^
-   |                                |
-   |                                this code causes undefined behavior when executed
-   |                                help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
+   |                                ^^^^^^^^^^^^^^^^^^^^^^^ this code causes undefined behavior when executed
    |
 note: enums with no inhabited variants have no valid value
   --> $DIR/uninhabited-static.rs:4:1
diff --git a/tests/ui/stats/hir-stats.stderr b/tests/ui/stats/hir-stats.stderr
index 7d9ff2dfb4d..ee62d8f2d25 100644
--- a/tests/ui/stats/hir-stats.stderr
+++ b/tests/ui/stats/hir-stats.stderr
@@ -1,119 +1,119 @@
 ast-stats-1 PRE EXPANSION AST STATS
 ast-stats-1 Name                Accumulated Size         Count     Item Size
 ast-stats-1 ----------------------------------------------------------------
-ast-stats-1 ExprField                 48 ( 0.6%)             1            48
-ast-stats-1 GenericArgs               56 ( 0.8%)             1            56
-ast-stats-1 - AngleBracketed            56 ( 0.8%)             1
-ast-stats-1 Crate                     56 ( 0.8%)             1            56
-ast-stats-1 Attribute                 64 ( 0.9%)             2            32
-ast-stats-1 - Normal                    32 ( 0.4%)             1
-ast-stats-1 - DocComment                32 ( 0.4%)             1
-ast-stats-1 Local                     72 ( 1.0%)             1            72
-ast-stats-1 WherePredicate            72 ( 1.0%)             1            72
-ast-stats-1 - BoundPredicate            72 ( 1.0%)             1
-ast-stats-1 Arm                       96 ( 1.3%)             2            48
-ast-stats-1 ForeignItem               96 ( 1.3%)             1            96
-ast-stats-1 - Fn                        96 ( 1.3%)             1
-ast-stats-1 FieldDef                 160 ( 2.2%)             2            80
-ast-stats-1 Stmt                     160 ( 2.2%)             5            32
-ast-stats-1 - Local                     32 ( 0.4%)             1
-ast-stats-1 - MacCall                   32 ( 0.4%)             1
-ast-stats-1 - Expr                      96 ( 1.3%)             3
-ast-stats-1 Param                    160 ( 2.2%)             4            40
-ast-stats-1 FnDecl                   200 ( 2.7%)             5            40
-ast-stats-1 Variant                  240 ( 3.2%)             2           120
-ast-stats-1 GenericBound             288 ( 3.9%)             4            72
-ast-stats-1 - Trait                    288 ( 3.9%)             4
-ast-stats-1 Block                    288 ( 3.9%)             6            48
-ast-stats-1 AssocItem                416 ( 5.6%)             4           104
-ast-stats-1 - Type                     208 ( 2.8%)             2
-ast-stats-1 - Fn                       208 ( 2.8%)             2
-ast-stats-1 GenericParam             480 ( 6.5%)             5            96
-ast-stats-1 Expr                     576 ( 7.8%)             8            72
-ast-stats-1 - Path                      72 ( 1.0%)             1
-ast-stats-1 - Match                     72 ( 1.0%)             1
-ast-stats-1 - Struct                    72 ( 1.0%)             1
-ast-stats-1 - Lit                      144 ( 1.9%)             2
-ast-stats-1 - Block                    216 ( 2.9%)             3
-ast-stats-1 Pat                      616 ( 8.3%)             7            88
-ast-stats-1 - Struct                    88 ( 1.2%)             1
-ast-stats-1 - Wild                      88 ( 1.2%)             1
-ast-stats-1 - Ident                    440 ( 5.9%)             5
-ast-stats-1 PathSegment              720 ( 9.7%)            30            24
-ast-stats-1 Ty                       896 (12.1%)            14            64
-ast-stats-1 - Ptr                       64 ( 0.9%)             1
-ast-stats-1 - Ref                       64 ( 0.9%)             1
-ast-stats-1 - ImplicitSelf             128 ( 1.7%)             2
-ast-stats-1 - Path                     640 ( 8.6%)            10
-ast-stats-1 Item                   1_656 (22.3%)             9           184
-ast-stats-1 - Trait                    184 ( 2.5%)             1
-ast-stats-1 - Enum                     184 ( 2.5%)             1
-ast-stats-1 - ForeignMod               184 ( 2.5%)             1
-ast-stats-1 - Impl                     184 ( 2.5%)             1
-ast-stats-1 - Fn                       368 ( 5.0%)             2
-ast-stats-1 - Use                      552 ( 7.4%)             3
+ast-stats-1 GenericArgs               40 ( 0.6%)             1            40
+ast-stats-1 - AngleBracketed            40 ( 0.6%)             1
+ast-stats-1 Crate                     40 ( 0.6%)             1            40
+ast-stats-1 ExprField                 48 ( 0.7%)             1            48
+ast-stats-1 WherePredicate            56 ( 0.9%)             1            56
+ast-stats-1 - BoundPredicate            56 ( 0.9%)             1
+ast-stats-1 Attribute                 64 ( 1.0%)             2            32
+ast-stats-1 - Normal                    32 ( 0.5%)             1
+ast-stats-1 - DocComment                32 ( 0.5%)             1
+ast-stats-1 Local                     72 ( 1.1%)             1            72
+ast-stats-1 Arm                       96 ( 1.5%)             2            48
+ast-stats-1 ForeignItem               96 ( 1.5%)             1            96
+ast-stats-1 - Fn                        96 ( 1.5%)             1
+ast-stats-1 FnDecl                   120 ( 1.8%)             5            24
+ast-stats-1 FieldDef                 160 ( 2.4%)             2            80
+ast-stats-1 Stmt                     160 ( 2.4%)             5            32
+ast-stats-1 - Local                     32 ( 0.5%)             1
+ast-stats-1 - MacCall                   32 ( 0.5%)             1
+ast-stats-1 - Expr                      96 ( 1.5%)             3
+ast-stats-1 Param                    160 ( 2.4%)             4            40
+ast-stats-1 Block                    192 ( 2.9%)             6            32
+ast-stats-1 Variant                  208 ( 3.2%)             2           104
+ast-stats-1 GenericBound             224 ( 3.4%)             4            56
+ast-stats-1 - Trait                    224 ( 3.4%)             4
+ast-stats-1 AssocItem                416 ( 6.3%)             4           104
+ast-stats-1 - Type                     208 ( 3.2%)             2
+ast-stats-1 - Fn                       208 ( 3.2%)             2
+ast-stats-1 GenericParam             480 ( 7.3%)             5            96
+ast-stats-1 Pat                      504 ( 7.7%)             7            72
+ast-stats-1 - Struct                    72 ( 1.1%)             1
+ast-stats-1 - Wild                      72 ( 1.1%)             1
+ast-stats-1 - Ident                    360 ( 5.5%)             5
+ast-stats-1 Expr                     576 ( 8.8%)             8            72
+ast-stats-1 - Path                      72 ( 1.1%)             1
+ast-stats-1 - Match                     72 ( 1.1%)             1
+ast-stats-1 - Struct                    72 ( 1.1%)             1
+ast-stats-1 - Lit                      144 ( 2.2%)             2
+ast-stats-1 - Block                    216 ( 3.3%)             3
+ast-stats-1 PathSegment              720 (11.0%)            30            24
+ast-stats-1 Ty                       896 (13.7%)            14            64
+ast-stats-1 - Ptr                       64 ( 1.0%)             1
+ast-stats-1 - Ref                       64 ( 1.0%)             1
+ast-stats-1 - ImplicitSelf             128 ( 2.0%)             2
+ast-stats-1 - Path                     640 ( 9.8%)            10
+ast-stats-1 Item                   1_224 (18.7%)             9           136
+ast-stats-1 - Trait                    136 ( 2.1%)             1
+ast-stats-1 - Enum                     136 ( 2.1%)             1
+ast-stats-1 - ForeignMod               136 ( 2.1%)             1
+ast-stats-1 - Impl                     136 ( 2.1%)             1
+ast-stats-1 - Fn                       272 ( 4.2%)             2
+ast-stats-1 - Use                      408 ( 6.2%)             3
 ast-stats-1 ----------------------------------------------------------------
-ast-stats-1 Total                  7_416
+ast-stats-1 Total                  6_552
 ast-stats-1
 ast-stats-2 POST EXPANSION AST STATS
 ast-stats-2 Name                Accumulated Size         Count     Item Size
 ast-stats-2 ----------------------------------------------------------------
-ast-stats-2 ExprField                 48 ( 0.6%)             1            48
-ast-stats-2 GenericArgs               56 ( 0.7%)             1            56
-ast-stats-2 - AngleBracketed            56 ( 0.7%)             1
-ast-stats-2 Crate                     56 ( 0.7%)             1            56
-ast-stats-2 Local                     72 ( 0.9%)             1            72
-ast-stats-2 WherePredicate            72 ( 0.9%)             1            72
-ast-stats-2 - BoundPredicate            72 ( 0.9%)             1
-ast-stats-2 Arm                       96 ( 1.2%)             2            48
-ast-stats-2 ForeignItem               96 ( 1.2%)             1            96
-ast-stats-2 - Fn                        96 ( 1.2%)             1
-ast-stats-2 InlineAsm                120 ( 1.5%)             1           120
-ast-stats-2 Attribute                128 ( 1.6%)             4            32
+ast-stats-2 GenericArgs               40 ( 0.6%)             1            40
+ast-stats-2 - AngleBracketed            40 ( 0.6%)             1
+ast-stats-2 Crate                     40 ( 0.6%)             1            40
+ast-stats-2 ExprField                 48 ( 0.7%)             1            48
+ast-stats-2 WherePredicate            56 ( 0.8%)             1            56
+ast-stats-2 - BoundPredicate            56 ( 0.8%)             1
+ast-stats-2 Local                     72 ( 1.0%)             1            72
+ast-stats-2 Arm                       96 ( 1.3%)             2            48
+ast-stats-2 ForeignItem               96 ( 1.3%)             1            96
+ast-stats-2 - Fn                        96 ( 1.3%)             1
+ast-stats-2 InlineAsm                120 ( 1.7%)             1           120
+ast-stats-2 FnDecl                   120 ( 1.7%)             5            24
+ast-stats-2 Attribute                128 ( 1.8%)             4            32
 ast-stats-2 - DocComment                32 ( 0.4%)             1
-ast-stats-2 - Normal                    96 ( 1.2%)             3
-ast-stats-2 FieldDef                 160 ( 2.0%)             2            80
-ast-stats-2 Stmt                     160 ( 2.0%)             5            32
+ast-stats-2 - Normal                    96 ( 1.3%)             3
+ast-stats-2 FieldDef                 160 ( 2.2%)             2            80
+ast-stats-2 Stmt                     160 ( 2.2%)             5            32
 ast-stats-2 - Local                     32 ( 0.4%)             1
 ast-stats-2 - Semi                      32 ( 0.4%)             1
-ast-stats-2 - Expr                      96 ( 1.2%)             3
-ast-stats-2 Param                    160 ( 2.0%)             4            40
-ast-stats-2 FnDecl                   200 ( 2.5%)             5            40
-ast-stats-2 Variant                  240 ( 3.0%)             2           120
-ast-stats-2 GenericBound             288 ( 3.6%)             4            72
-ast-stats-2 - Trait                    288 ( 3.6%)             4
-ast-stats-2 Block                    288 ( 3.6%)             6            48
-ast-stats-2 AssocItem                416 ( 5.1%)             4           104
-ast-stats-2 - Type                     208 ( 2.6%)             2
-ast-stats-2 - Fn                       208 ( 2.6%)             2
-ast-stats-2 GenericParam             480 ( 5.9%)             5            96
-ast-stats-2 Pat                      616 ( 7.6%)             7            88
-ast-stats-2 - Struct                    88 ( 1.1%)             1
-ast-stats-2 - Wild                      88 ( 1.1%)             1
-ast-stats-2 - Ident                    440 ( 5.4%)             5
-ast-stats-2 Expr                     648 ( 8.0%)             9            72
-ast-stats-2 - Path                      72 ( 0.9%)             1
-ast-stats-2 - Match                     72 ( 0.9%)             1
-ast-stats-2 - Struct                    72 ( 0.9%)             1
-ast-stats-2 - InlineAsm                 72 ( 0.9%)             1
-ast-stats-2 - Lit                      144 ( 1.8%)             2
-ast-stats-2 - Block                    216 ( 2.7%)             3
-ast-stats-2 PathSegment              792 ( 9.8%)            33            24
-ast-stats-2 Ty                       896 (11.0%)            14            64
-ast-stats-2 - Ptr                       64 ( 0.8%)             1
-ast-stats-2 - Ref                       64 ( 0.8%)             1
-ast-stats-2 - ImplicitSelf             128 ( 1.6%)             2
-ast-stats-2 - Path                     640 ( 7.9%)            10
-ast-stats-2 Item                   2_024 (25.0%)            11           184
-ast-stats-2 - Trait                    184 ( 2.3%)             1
-ast-stats-2 - Enum                     184 ( 2.3%)             1
-ast-stats-2 - ExternCrate              184 ( 2.3%)             1
-ast-stats-2 - ForeignMod               184 ( 2.3%)             1
-ast-stats-2 - Impl                     184 ( 2.3%)             1
-ast-stats-2 - Fn                       368 ( 4.5%)             2
-ast-stats-2 - Use                      736 ( 9.1%)             4
+ast-stats-2 - Expr                      96 ( 1.3%)             3
+ast-stats-2 Param                    160 ( 2.2%)             4            40
+ast-stats-2 Block                    192 ( 2.7%)             6            32
+ast-stats-2 Variant                  208 ( 2.9%)             2           104
+ast-stats-2 GenericBound             224 ( 3.1%)             4            56
+ast-stats-2 - Trait                    224 ( 3.1%)             4
+ast-stats-2 AssocItem                416 ( 5.8%)             4           104
+ast-stats-2 - Type                     208 ( 2.9%)             2
+ast-stats-2 - Fn                       208 ( 2.9%)             2
+ast-stats-2 GenericParam             480 ( 6.7%)             5            96
+ast-stats-2 Pat                      504 ( 7.0%)             7            72
+ast-stats-2 - Struct                    72 ( 1.0%)             1
+ast-stats-2 - Wild                      72 ( 1.0%)             1
+ast-stats-2 - Ident                    360 ( 5.0%)             5
+ast-stats-2 Expr                     648 ( 9.1%)             9            72
+ast-stats-2 - Path                      72 ( 1.0%)             1
+ast-stats-2 - Match                     72 ( 1.0%)             1
+ast-stats-2 - Struct                    72 ( 1.0%)             1
+ast-stats-2 - InlineAsm                 72 ( 1.0%)             1
+ast-stats-2 - Lit                      144 ( 2.0%)             2
+ast-stats-2 - Block                    216 ( 3.0%)             3
+ast-stats-2 PathSegment              792 (11.1%)            33            24
+ast-stats-2 Ty                       896 (12.5%)            14            64
+ast-stats-2 - Ptr                       64 ( 0.9%)             1
+ast-stats-2 - Ref                       64 ( 0.9%)             1
+ast-stats-2 - ImplicitSelf             128 ( 1.8%)             2
+ast-stats-2 - Path                     640 ( 8.9%)            10
+ast-stats-2 Item                   1_496 (20.9%)            11           136
+ast-stats-2 - Trait                    136 ( 1.9%)             1
+ast-stats-2 - Enum                     136 ( 1.9%)             1
+ast-stats-2 - ExternCrate              136 ( 1.9%)             1
+ast-stats-2 - ForeignMod               136 ( 1.9%)             1
+ast-stats-2 - Impl                     136 ( 1.9%)             1
+ast-stats-2 - Fn                       272 ( 3.8%)             2
+ast-stats-2 - Use                      544 ( 7.6%)             4
 ast-stats-2 ----------------------------------------------------------------
-ast-stats-2 Total                  8_112
+ast-stats-2 Total                  7_152
 ast-stats-2
 hir-stats HIR STATS
 hir-stats Name                Accumulated Size         Count     Item Size
diff --git a/tests/ui/structs/struct-path-associated-type.rs b/tests/ui/structs/struct-path-associated-type.rs
index 2dd7174a9be..74d9705d4b8 100644
--- a/tests/ui/structs/struct-path-associated-type.rs
+++ b/tests/ui/structs/struct-path-associated-type.rs
@@ -13,7 +13,7 @@ fn f<T: Tr>() {
     //~^ ERROR expected struct, variant or union type, found associated type
     let z = T::A::<u8> {};
     //~^ ERROR expected struct, variant or union type, found associated type
-    //~| ERROR this associated type takes 0 generic arguments but 1 generic argument was supplied
+    //~| ERROR associated type takes 0 generic arguments but 1 generic argument was supplied
     match S {
         T::A {} => {}
         //~^ ERROR expected struct, variant or union type, found associated type
@@ -22,7 +22,7 @@ fn f<T: Tr>() {
 
 fn g<T: Tr<A = S>>() {
     let s = T::A {}; // OK
-    let z = T::A::<u8> {}; //~ ERROR this associated type takes 0 generic arguments but 1 generic argument was supplied
+    let z = T::A::<u8> {}; //~ ERROR associated type takes 0 generic arguments but 1 generic argument was supplied
     match S {
         T::A {} => {} // OK
     }
diff --git a/tests/ui/structs/struct-path-associated-type.stderr b/tests/ui/structs/struct-path-associated-type.stderr
index ca5f0b7e21e..acfddaf3760 100644
--- a/tests/ui/structs/struct-path-associated-type.stderr
+++ b/tests/ui/structs/struct-path-associated-type.stderr
@@ -4,7 +4,7 @@ error[E0071]: expected struct, variant or union type, found associated type
 LL |     let s = T::A {};
    |             ^^^^ not a struct
 
-error[E0107]: this associated type takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: associated type takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/struct-path-associated-type.rs:14:16
    |
 LL |     let z = T::A::<u8> {};
@@ -30,7 +30,7 @@ error[E0071]: expected struct, variant or union type, found associated type
 LL |         T::A {} => {}
    |         ^^^^ not a struct
 
-error[E0107]: this associated type takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: associated type takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/struct-path-associated-type.rs:25:16
    |
 LL |     let z = T::A::<u8> {};
diff --git a/tests/ui/structs/structure-constructor-type-mismatch.rs b/tests/ui/structs/structure-constructor-type-mismatch.rs
index a03ef590cb3..21cd9d08b21 100644
--- a/tests/ui/structs/structure-constructor-type-mismatch.rs
+++ b/tests/ui/structs/structure-constructor-type-mismatch.rs
@@ -45,13 +45,13 @@ fn main() {
         y: 8,
     };
 
-    let pt3 = PointF::<i32> { //~ ERROR this type alias takes 0 generic arguments but 1 generic argument
+    let pt3 = PointF::<i32> { //~ ERROR type alias takes 0 generic arguments but 1 generic argument
         x: 9,  //~ ERROR mismatched types
         y: 10, //~ ERROR mismatched types
     };
 
     match (Point { x: 1, y: 2 }) {
-        PointF::<u32> { .. } => {} //~ ERROR this type alias takes 0 generic arguments but 1 generic argument
+        PointF::<u32> { .. } => {} //~ ERROR type alias takes 0 generic arguments but 1 generic argument
         //~^ ERROR mismatched types
     }
 
diff --git a/tests/ui/structs/structure-constructor-type-mismatch.stderr b/tests/ui/structs/structure-constructor-type-mismatch.stderr
index 3e3f9ea06ef..63dda459396 100644
--- a/tests/ui/structs/structure-constructor-type-mismatch.stderr
+++ b/tests/ui/structs/structure-constructor-type-mismatch.stderr
@@ -52,7 +52,7 @@ LL |         x: 7,
    |            expected `f32`, found integer
    |            help: use a float literal: `7.0`
 
-error[E0107]: this type alias takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: type alias takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/structure-constructor-type-mismatch.rs:48:15
    |
 LL |     let pt3 = PointF::<i32> {
@@ -84,7 +84,7 @@ LL |         y: 10,
    |            expected `f32`, found integer
    |            help: use a float literal: `10.0`
 
-error[E0107]: this type alias takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: type alias takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/structure-constructor-type-mismatch.rs:54:9
    |
 LL |         PointF::<u32> { .. } => {}
diff --git a/tests/ui/suggestions/assoc-ct-for-assoc-method.stderr b/tests/ui/suggestions/assoc-ct-for-assoc-method.stderr
index afef38f1296..211cb1584ad 100644
--- a/tests/ui/suggestions/assoc-ct-for-assoc-method.stderr
+++ b/tests/ui/suggestions/assoc-ct-for-assoc-method.stderr
@@ -36,7 +36,7 @@ LL |     let y: i32 = i32::max - 42;
    |                  |
    |                  fn(i32, i32) -> i32 {<i32 as Ord>::max}
    |
-help: use parentheses to call this associated function
+help: use parentheses to call this method
    |
 LL |     let y: i32 = i32::max(/* i32 */, /* i32 */) - 42;
    |                          ++++++++++++++++++++++
diff --git a/tests/ui/suggestions/fn-or-tuple-struct-without-args.stderr b/tests/ui/suggestions/fn-or-tuple-struct-without-args.stderr
index 4f981a16374..a137db8cdee 100644
--- a/tests/ui/suggestions/fn-or-tuple-struct-without-args.stderr
+++ b/tests/ui/suggestions/fn-or-tuple-struct-without-args.stderr
@@ -206,7 +206,7 @@ error[E0308]: mismatched types
   --> $DIR/fn-or-tuple-struct-without-args.rs:41:20
    |
 LL |     fn ban(&self) -> usize { 42 }
-   |     ---------------------- associated function `ban` defined here
+   |     ---------------------- method `ban` defined here
 ...
 LL |     let _: usize = X::ban;
    |            -----   ^^^^^^ expected `usize`, found fn item
@@ -215,7 +215,7 @@ LL |     let _: usize = X::ban;
    |
    = note: expected type `usize`
            found fn item `for<'a> fn(&'a X) -> usize {<X as T>::ban}`
-help: use parentheses to call this associated function
+help: use parentheses to call this method
    |
 LL |     let _: usize = X::ban(/* &X */);
    |                          ++++++++++
@@ -224,7 +224,7 @@ error[E0308]: mismatched types
   --> $DIR/fn-or-tuple-struct-without-args.rs:42:20
    |
 LL |     fn bal(&self) -> usize;
-   |     ----------------------- associated function `bal` defined here
+   |     ----------------------- method `bal` defined here
 ...
 LL |     let _: usize = X::bal;
    |            -----   ^^^^^^ expected `usize`, found fn item
@@ -233,7 +233,7 @@ LL |     let _: usize = X::bal;
    |
    = note: expected type `usize`
            found fn item `for<'a> fn(&'a X) -> usize {<X as T>::bal}`
-help: use parentheses to call this associated function
+help: use parentheses to call this method
    |
 LL |     let _: usize = X::bal(/* &X */);
    |                          ++++++++++
diff --git a/tests/ui/suggestions/imm-ref-trait-object-literal-bound-regions.stderr b/tests/ui/suggestions/imm-ref-trait-object-literal-bound-regions.stderr
index 864ab053520..fc5a521746a 100644
--- a/tests/ui/suggestions/imm-ref-trait-object-literal-bound-regions.stderr
+++ b/tests/ui/suggestions/imm-ref-trait-object-literal-bound-regions.stderr
@@ -12,7 +12,7 @@ note: required by a bound in `foo`
   --> $DIR/imm-ref-trait-object-literal-bound-regions.rs:11:20
    |
 LL | fn foo<X>(_: X)
-   |    --- required by a bound in this
+   |    --- required by a bound in this function
 LL | where
 LL |     for<'b> &'b X: Trait,
    |                    ^^^^^ required by this bound in `foo`
diff --git a/tests/ui/suggestions/issue-101421.rs b/tests/ui/suggestions/issue-101421.rs
index b615997d1a9..1407ebd277c 100644
--- a/tests/ui/suggestions/issue-101421.rs
+++ b/tests/ui/suggestions/issue-101421.rs
@@ -8,5 +8,5 @@ impl Ice for () {
 
 fn main() {
     ().f::<()>(());
-    //~^ ERROR this associated function takes 0 generic arguments but 1 generic argument was supplied
+    //~^ ERROR method takes 0 generic arguments but 1 generic argument was supplied
 }
diff --git a/tests/ui/suggestions/issue-101421.stderr b/tests/ui/suggestions/issue-101421.stderr
index f8e1efb8820..2656ab3db0b 100644
--- a/tests/ui/suggestions/issue-101421.stderr
+++ b/tests/ui/suggestions/issue-101421.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this associated function takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: method takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/issue-101421.rs:10:8
    |
 LL |     ().f::<()>(());
@@ -6,7 +6,7 @@ LL |     ().f::<()>(());
    |        |
    |        expected 0 generic arguments
    |
-note: associated function defined here, with 0 generic parameters
+note: method defined here, with 0 generic parameters
   --> $DIR/issue-101421.rs:2:8
    |
 LL |     fn f(&self, _: ());
diff --git a/tests/ui/suggestions/issue-104287.rs b/tests/ui/suggestions/issue-104287.rs
index e3fa22a8f66..37b3339fa92 100644
--- a/tests/ui/suggestions/issue-104287.rs
+++ b/tests/ui/suggestions/issue-104287.rs
@@ -8,6 +8,6 @@ impl S {
 fn main() {
     let x = S;
     foo::<()>(x);
-    //~^ ERROR this associated function takes 0 generic arguments but 1 generic argument was supplied
+    //~^ ERROR method takes 0 generic arguments but 1 generic argument was supplied
     //~| ERROR cannot find function `foo` in this scope
 }
diff --git a/tests/ui/suggestions/issue-104287.stderr b/tests/ui/suggestions/issue-104287.stderr
index 602a01828b2..ed59b2e7a2d 100644
--- a/tests/ui/suggestions/issue-104287.stderr
+++ b/tests/ui/suggestions/issue-104287.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this associated function takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: method takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/issue-104287.rs:10:5
    |
 LL |     foo::<()>(x);
@@ -6,7 +6,7 @@ LL |     foo::<()>(x);
    |     |
    |     expected 0 generic arguments
    |
-note: associated function defined here, with 0 generic parameters
+note: method defined here, with 0 generic parameters
   --> $DIR/issue-104287.rs:6:8
    |
 LL |     fn foo(&self) {}
diff --git a/tests/ui/suggestions/issue-84973.stderr b/tests/ui/suggestions/issue-84973.stderr
index ae2bf5aac40..55c89884a5f 100644
--- a/tests/ui/suggestions/issue-84973.stderr
+++ b/tests/ui/suggestions/issue-84973.stderr
@@ -13,7 +13,7 @@ LL |     G: SomeTrait,
    |        ^^^^^^^^^ required by this bound in `Other::<'a, G>::new`
 LL | {
 LL |     pub fn new(g: G) -> Self {
-   |            --- required by a bound in this
+   |            --- required by a bound in this associated function
 help: consider borrowing here
    |
 LL |     let o = Other::new(&f);
diff --git a/tests/ui/suggestions/issue-85347.rs b/tests/ui/suggestions/issue-85347.rs
index 02b5fb61894..04d4c47d8e5 100644
--- a/tests/ui/suggestions/issue-85347.rs
+++ b/tests/ui/suggestions/issue-85347.rs
@@ -1,7 +1,7 @@
 use std::ops::Deref;
 trait Foo {
     type Bar<'a>: Deref<Target = <Self>::Bar<Target = Self>>;
-    //~^ ERROR this associated type takes 1 lifetime argument but 0 lifetime arguments were supplied
+    //~^ ERROR associated type takes 1 lifetime argument but 0 lifetime arguments were supplied
     //~| ERROR associated type bindings are not allowed here
     //~| HELP add missing
 }
diff --git a/tests/ui/suggestions/issue-85347.stderr b/tests/ui/suggestions/issue-85347.stderr
index 17c1b7dc4cc..f330b3c1fad 100644
--- a/tests/ui/suggestions/issue-85347.stderr
+++ b/tests/ui/suggestions/issue-85347.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this associated type takes 1 lifetime argument but 0 lifetime arguments were supplied
+error[E0107]: associated type takes 1 lifetime argument but 0 lifetime arguments were supplied
   --> $DIR/issue-85347.rs:3:42
    |
 LL |     type Bar<'a>: Deref<Target = <Self>::Bar<Target = Self>>;
diff --git a/tests/ui/suggestions/issue-89064.stderr b/tests/ui/suggestions/issue-89064.stderr
index 93d8da226c8..be09dd89512 100644
--- a/tests/ui/suggestions/issue-89064.stderr
+++ b/tests/ui/suggestions/issue-89064.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this associated function takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: associated function takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/issue-89064.rs:17:16
    |
 LL |     let _ = A::foo::<S>();
@@ -20,7 +20,7 @@ LL -     let _ = A::foo::<S>();
 LL +     let _ = A::foo();
    |
 
-error[E0107]: this associated function takes 0 generic arguments but 2 generic arguments were supplied
+error[E0107]: associated function takes 0 generic arguments but 2 generic arguments were supplied
   --> $DIR/issue-89064.rs:22:16
    |
 LL |     let _ = B::bar::<S, S>();
@@ -42,7 +42,7 @@ LL -     let _ = B::bar::<S, S>();
 LL +     let _ = B::bar();
    |
 
-error[E0107]: this associated function takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: associated function takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/issue-89064.rs:27:21
    |
 LL |     let _ = A::<S>::foo::<S>();
@@ -56,7 +56,7 @@ note: associated function defined here, with 0 generic parameters
 LL |     fn foo() {}
    |        ^^^
 
-error[E0107]: this associated function takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: method takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/issue-89064.rs:31:16
    |
 LL |     let _ = 42.into::<Option<_>>();
diff --git a/tests/ui/suggestions/missing-lifetime-specifier.rs b/tests/ui/suggestions/missing-lifetime-specifier.rs
index 24f5f782f35..cb734e8ba85 100644
--- a/tests/ui/suggestions/missing-lifetime-specifier.rs
+++ b/tests/ui/suggestions/missing-lifetime-specifier.rs
@@ -37,19 +37,19 @@ thread_local! {
 
 thread_local! {
     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, i32>>>>> = RefCell::new(HashMap::new());
-    //~^ ERROR this union takes 2 lifetime arguments but 1 lifetime argument
-    //~| ERROR this union takes 2 lifetime arguments but 1 lifetime argument was supplied
-    //~| ERROR this union takes 2 lifetime arguments but 1 lifetime argument was supplied
-    //~| ERROR this union takes 2 lifetime arguments but 1 lifetime argument was supplied
-    //~| ERROR this union takes 2 lifetime arguments but 1 lifetime argument was supplied
+    //~^ ERROR union takes 2 lifetime arguments but 1 lifetime argument
+    //~| ERROR union takes 2 lifetime arguments but 1 lifetime argument was supplied
+    //~| ERROR union takes 2 lifetime arguments but 1 lifetime argument was supplied
+    //~| ERROR union takes 2 lifetime arguments but 1 lifetime argument was supplied
+    //~| ERROR union takes 2 lifetime arguments but 1 lifetime argument was supplied
 }
 thread_local! {
     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, i32>>>>> = RefCell::new(HashMap::new());
-    //~^ ERROR this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
-    //~| ERROR this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
-    //~| ERROR this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
-    //~| ERROR this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
-    //~| ERROR this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
+    //~^ ERROR trait takes 2 lifetime arguments but 1 lifetime argument was supplied
+    //~| ERROR trait takes 2 lifetime arguments but 1 lifetime argument was supplied
+    //~| ERROR trait takes 2 lifetime arguments but 1 lifetime argument was supplied
+    //~| ERROR trait takes 2 lifetime arguments but 1 lifetime argument was supplied
+    //~| ERROR trait takes 2 lifetime arguments but 1 lifetime argument was supplied
     //~| ERROR missing lifetime
     //~| ERROR missing lifetime
 }
diff --git a/tests/ui/suggestions/missing-lifetime-specifier.stderr b/tests/ui/suggestions/missing-lifetime-specifier.stderr
index 997bbb5e9b5..21d2378382c 100644
--- a/tests/ui/suggestions/missing-lifetime-specifier.stderr
+++ b/tests/ui/suggestions/missing-lifetime-specifier.stderr
@@ -133,7 +133,7 @@ LL | | }
    |
    = help: this function's return type contains a borrowed value, but the signature does not say which one of `init`'s 3 lifetimes it is borrowed from
 
-error[E0107]: this union takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: union takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/missing-lifetime-specifier.rs:39:44
    |
 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, i32>>>>> = RefCell::new(HashMap::new());
@@ -151,7 +151,7 @@ help: add missing lifetime argument
 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
    |                                                       +++++++++
 
-error[E0107]: this union takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: union takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/missing-lifetime-specifier.rs:39:44
    |
 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, i32>>>>> = RefCell::new(HashMap::new());
@@ -169,7 +169,7 @@ help: add missing lifetime argument
 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
    |                                                       +++++++++
 
-error[E0107]: this union takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: union takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/missing-lifetime-specifier.rs:39:44
    |
 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, i32>>>>> = RefCell::new(HashMap::new());
@@ -187,7 +187,7 @@ help: add missing lifetime argument
 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
    |                                                       +++++++++
 
-error[E0107]: this union takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: union takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/missing-lifetime-specifier.rs:39:44
    |
 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, i32>>>>> = RefCell::new(HashMap::new());
@@ -205,7 +205,7 @@ help: add missing lifetime argument
 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
    |                                                       +++++++++
 
-error[E0107]: this union takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: union takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/missing-lifetime-specifier.rs:39:44
    |
 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, i32>>>>> = RefCell::new(HashMap::new());
@@ -223,7 +223,7 @@ help: add missing lifetime argument
 LL |     static e: RefCell<HashMap<i32, Vec<Vec<Qux<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
    |                                                       +++++++++
 
-error[E0107]: this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: trait takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/missing-lifetime-specifier.rs:47:45
    |
 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, i32>>>>> = RefCell::new(HashMap::new());
@@ -241,7 +241,7 @@ help: add missing lifetime argument
 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
    |                                                        +++++++++
 
-error[E0107]: this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: trait takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/missing-lifetime-specifier.rs:47:45
    |
 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, i32>>>>> = RefCell::new(HashMap::new());
@@ -259,7 +259,7 @@ help: add missing lifetime argument
 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
    |                                                        +++++++++
 
-error[E0107]: this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: trait takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/missing-lifetime-specifier.rs:47:45
    |
 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, i32>>>>> = RefCell::new(HashMap::new());
@@ -277,7 +277,7 @@ help: add missing lifetime argument
 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
    |                                                        +++++++++
 
-error[E0107]: this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: trait takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/missing-lifetime-specifier.rs:47:45
    |
 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, i32>>>>> = RefCell::new(HashMap::new());
@@ -295,7 +295,7 @@ help: add missing lifetime argument
 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, 'static, i32>>>>> = RefCell::new(HashMap::new());
    |                                                        +++++++++
 
-error[E0107]: this trait takes 2 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: trait takes 2 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/missing-lifetime-specifier.rs:47:45
    |
 LL |     static f: RefCell<HashMap<i32, Vec<Vec<&Tar<'static, i32>>>>> = RefCell::new(HashMap::new());
diff --git a/tests/ui/suggestions/missing-type-param-used-in-param.stderr b/tests/ui/suggestions/missing-type-param-used-in-param.stderr
index 4f7058a6492..3116c5a0a1c 100644
--- a/tests/ui/suggestions/missing-type-param-used-in-param.stderr
+++ b/tests/ui/suggestions/missing-type-param-used-in-param.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this function takes 2 generic arguments but 1 generic argument was supplied
+error[E0107]: function takes 2 generic arguments but 1 generic argument was supplied
   --> $DIR/missing-type-param-used-in-param.rs:6:5
    |
 LL |     two_type_params::<String>(100);
diff --git a/tests/ui/suggestions/move-generic-to-trait-in-method-with-params.rs b/tests/ui/suggestions/move-generic-to-trait-in-method-with-params.rs
index 2f540060a34..4066cd3b11a 100644
--- a/tests/ui/suggestions/move-generic-to-trait-in-method-with-params.rs
+++ b/tests/ui/suggestions/move-generic-to-trait-in-method-with-params.rs
@@ -12,7 +12,7 @@ impl Foo<i32> for i32 {
 
 fn main() {
     1.bar::<i32>(0);
-    //~^ ERROR this associated function takes 0 generic arguments but 1 generic argument was supplied
+    //~^ ERROR method takes 0 generic arguments but 1 generic argument was supplied
     //~| HELP consider moving this generic argument to the `Foo` trait, which takes up to 1 argument
     //~| HELP remove these generics
 }
diff --git a/tests/ui/suggestions/move-generic-to-trait-in-method-with-params.stderr b/tests/ui/suggestions/move-generic-to-trait-in-method-with-params.stderr
index 9557220f6bb..bfdb35947ef 100644
--- a/tests/ui/suggestions/move-generic-to-trait-in-method-with-params.stderr
+++ b/tests/ui/suggestions/move-generic-to-trait-in-method-with-params.stderr
@@ -1,10 +1,10 @@
-error[E0107]: this associated function takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: method takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/move-generic-to-trait-in-method-with-params.rs:14:7
    |
 LL |     1.bar::<i32>(0);
    |       ^^^ expected 0 generic arguments
    |
-note: associated function defined here, with 0 generic parameters
+note: method defined here, with 0 generic parameters
   --> $DIR/move-generic-to-trait-in-method-with-params.rs:4:8
    |
 LL |     fn bar(&self, _: T);
diff --git a/tests/ui/suggestions/sugg-else-for-closure.stderr b/tests/ui/suggestions/sugg-else-for-closure.stderr
index 7f05832bcd7..09553b93c45 100644
--- a/tests/ui/suggestions/sugg-else-for-closure.stderr
+++ b/tests/ui/suggestions/sugg-else-for-closure.stderr
@@ -15,7 +15,7 @@ LL |     let _s = y.unwrap_or(|| x.split('.').nth(1).unwrap());
    |              ^^^^^^^^^^^^-------------------------------^
    |                          |
    |                          this argument influences the return type of `unwrap_or`
-note: associated function defined here
+note: method defined here
   --> $SRC_DIR/core/src/option.rs:LL:COL
 help: try calling `unwrap_or_else` instead
    |
diff --git a/tests/ui/suggestions/trait-with-missing-associated-type-restriction.stderr b/tests/ui/suggestions/trait-with-missing-associated-type-restriction.stderr
index f520d88c6ba..7deb9a4342d 100644
--- a/tests/ui/suggestions/trait-with-missing-associated-type-restriction.stderr
+++ b/tests/ui/suggestions/trait-with-missing-associated-type-restriction.stderr
@@ -90,7 +90,7 @@ LL |     fn func(&self) -> Self::A;
 LL |     fn funk(&self, _: Self::A);
 LL |     fn funq(&self) -> Self::A {}
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^ consider calling `Trait::funq`
-note: associated function defined here
+note: method defined here
   --> $DIR/trait-with-missing-associated-type-restriction.rs:9:8
    |
 LL |     fn funk(&self, _: Self::A);
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 fcff02e09db..4e3180e84d2 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
@@ -18,7 +18,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
 
-error[E0107]: this struct takes at least 1 generic argument but 0 generic arguments were supplied
+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
    |
 LL |     let _: Vec<A:B> = A::B;
diff --git a/tests/ui/suggestions/use-type-argument-instead-of-assoc-type.rs b/tests/ui/suggestions/use-type-argument-instead-of-assoc-type.rs
index 8b6e8cfd720..ed262fd39a5 100644
--- a/tests/ui/suggestions/use-type-argument-instead-of-assoc-type.rs
+++ b/tests/ui/suggestions/use-type-argument-instead-of-assoc-type.rs
@@ -6,7 +6,7 @@ pub trait T<X, Y> {
 pub struct Foo {
     i: Box<dyn T<usize, usize, usize, usize, B=usize>>,
     //~^ ERROR must be specified
-    //~| ERROR this trait takes 2 generic arguments but 4 generic arguments were supplied
+    //~| ERROR trait takes 2 generic arguments but 4 generic arguments were supplied
 }
 
 
diff --git a/tests/ui/suggestions/use-type-argument-instead-of-assoc-type.stderr b/tests/ui/suggestions/use-type-argument-instead-of-assoc-type.stderr
index 75b91923284..175a5fbba61 100644
--- a/tests/ui/suggestions/use-type-argument-instead-of-assoc-type.stderr
+++ b/tests/ui/suggestions/use-type-argument-instead-of-assoc-type.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this trait takes 2 generic arguments but 4 generic arguments were supplied
+error[E0107]: trait takes 2 generic arguments but 4 generic arguments were supplied
   --> $DIR/use-type-argument-instead-of-assoc-type.rs:7:16
    |
 LL |     i: Box<dyn T<usize, usize, usize, usize, B=usize>>,
diff --git a/tests/ui/tool-attributes/auxiliary/p1.rs b/tests/ui/tool-attributes/auxiliary/p1.rs
new file mode 100644
index 00000000000..47195c7e9d6
--- /dev/null
+++ b/tests/ui/tool-attributes/auxiliary/p1.rs
@@ -0,0 +1,3 @@
+#![feature(rustc_attrs)]
+#[rustc_diagnostic_item = "Foo"]
+pub struct Foo {}
diff --git a/tests/ui/tool-attributes/auxiliary/p2.rs b/tests/ui/tool-attributes/auxiliary/p2.rs
new file mode 100644
index 00000000000..47195c7e9d6
--- /dev/null
+++ b/tests/ui/tool-attributes/auxiliary/p2.rs
@@ -0,0 +1,3 @@
+#![feature(rustc_attrs)]
+#[rustc_diagnostic_item = "Foo"]
+pub struct Foo {}
diff --git a/tests/ui/tool-attributes/duplicate-diagnostic.rs b/tests/ui/tool-attributes/duplicate-diagnostic.rs
new file mode 100644
index 00000000000..39c2ca1cb86
--- /dev/null
+++ b/tests/ui/tool-attributes/duplicate-diagnostic.rs
@@ -0,0 +1,13 @@
+// aux-build: p1.rs
+// aux-build: p2.rs
+
+// error-pattern: duplicate diagnostic item in crate `p2`
+// error-pattern: note: the diagnostic item is first defined in crate `p1`
+
+#![feature(rustc_attrs)]
+extern crate p1;
+extern crate p2;
+
+#[rustc_diagnostic_item = "Foo"]
+pub struct Foo {} //~ ERROR duplicate diagnostic item found
+fn main() {}
diff --git a/tests/ui/tool-attributes/duplicate-diagnostic.stderr b/tests/ui/tool-attributes/duplicate-diagnostic.stderr
new file mode 100644
index 00000000000..e315fdc7d84
--- /dev/null
+++ b/tests/ui/tool-attributes/duplicate-diagnostic.stderr
@@ -0,0 +1,12 @@
+error: duplicate diagnostic item in crate `p2`: `Foo`.
+   |
+   = note: the diagnostic item is first defined in crate `p1`.
+
+error: duplicate diagnostic item found: `Foo`.
+  --> $DIR/duplicate-diagnostic.rs:12:1
+   |
+LL | pub struct Foo {}
+   | ^^^^^^^^^^^^^^
+
+error: aborting due to 2 previous errors
+
diff --git a/tests/ui/traits/alias/ambiguous.stderr b/tests/ui/traits/alias/ambiguous.stderr
index 0fe1a79678d..203bdc526f6 100644
--- a/tests/ui/traits/alias/ambiguous.stderr
+++ b/tests/ui/traits/alias/ambiguous.stderr
@@ -14,11 +14,11 @@ note: candidate #2 is defined in an impl of the trait `B` for the type `u8`
    |
 LL |         fn foo(&self) {}
    |         ^^^^^^^^^^^^^
-help: disambiguate the associated function for candidate #1
+help: disambiguate the method for candidate #1
    |
 LL |     A::foo(&t);
    |     ~~~~~~~~~~
-help: disambiguate the associated function for candidate #2
+help: disambiguate the method for candidate #2
    |
 LL |     B::foo(&t);
    |     ~~~~~~~~~~
diff --git a/tests/ui/traits/inductive-overflow/supertrait-auto-trait.stderr b/tests/ui/traits/inductive-overflow/supertrait-auto-trait.stderr
index 3ec288d1382..dc967d51298 100644
--- a/tests/ui/traits/inductive-overflow/supertrait-auto-trait.stderr
+++ b/tests/ui/traits/inductive-overflow/supertrait-auto-trait.stderr
@@ -4,7 +4,7 @@ error[E0568]: auto traits cannot have super traits or lifetime bounds
 LL | auto trait Magic: Copy {}
    |            -----^^^^^^ help: remove the super traits or lifetime bounds
    |            |
-   |            auto trait cannot have super traits or lifetime bounds
+   |            auto traits cannot have super traits or lifetime bounds
 
 error[E0277]: the trait bound `NoClone: Copy` is not satisfied
   --> $DIR/supertrait-auto-trait.rs:16:23
diff --git a/tests/ui/traits/issue-52893.stderr b/tests/ui/traits/issue-52893.stderr
index 006cb3a7b72..db807a38830 100644
--- a/tests/ui/traits/issue-52893.stderr
+++ b/tests/ui/traits/issue-52893.stderr
@@ -18,7 +18,7 @@ LL |         builder.push(output);
    |         ^^^^^^^^^^^^^------^
    |                      |
    |                      this argument influences the return type of `push`
-note: associated function defined here
+note: method defined here
   --> $DIR/issue-52893.rs:11:8
    |
 LL |     fn push(self, other: T) -> Self::PushRes;
diff --git a/tests/ui/traits/issue-77982.stderr b/tests/ui/traits/issue-77982.stderr
index 0b57a8212bd..a397b0accc8 100644
--- a/tests/ui/traits/issue-77982.stderr
+++ b/tests/ui/traits/issue-77982.stderr
@@ -4,7 +4,7 @@ error[E0283]: type annotations needed
 LL |     opts.get(opt.as_ref());
    |          ^^^ ------------ type must be known at this point
    |          |
-   |          cannot infer type of the type parameter `Q` declared on the associated function `get`
+   |          cannot infer type of the type parameter `Q` declared on the method `get`
    |
    = note: multiple `impl`s satisfying `String: Borrow<_>` found in the following crates: `alloc`, `core`:
            - impl Borrow<str> for String;
@@ -23,7 +23,7 @@ error[E0283]: type annotations needed
 LL |     opts.get(opt.as_ref());
    |          ^^^     ------ type must be known at this point
    |          |
-   |          cannot infer type of the type parameter `Q` declared on the associated function `get`
+   |          cannot infer type of the type parameter `Q` declared on the method `get`
    |
    = note: multiple `impl`s satisfying `String: AsRef<_>` found in the following crates: `alloc`, `std`:
            - impl AsRef<OsStr> for String;
diff --git a/tests/ui/traits/item-privacy.rs b/tests/ui/traits/item-privacy.rs
index 38d06b967bc..a3e1a22e7a8 100644
--- a/tests/ui/traits/item-privacy.rs
+++ b/tests/ui/traits/item-privacy.rs
@@ -69,7 +69,7 @@ fn check_method() {
     S.c(); // OK
     // a, b, c are resolved as inherent items, their traits don't need to be in scope
     let c = &S as &dyn C;
-    c.a(); //~ ERROR associated function `a` is private
+    c.a(); //~ ERROR method `a` is private
     c.b(); // OK
     c.c(); // OK
 
@@ -81,7 +81,7 @@ fn check_method() {
     //~^ ERROR no function or associated item named `b` found
     S::c(&S); // OK
     // a, b, c are resolved as inherent items, their traits don't need to be in scope
-    <dyn C>::a(&S); //~ ERROR associated function `a` is private
+    <dyn C>::a(&S); //~ ERROR method `a` is private
     <dyn C>::b(&S); // OK
     C::c(&S); // OK
 }
diff --git a/tests/ui/traits/item-privacy.stderr b/tests/ui/traits/item-privacy.stderr
index 293cfbda86c..04995b3a17b 100644
--- a/tests/ui/traits/item-privacy.stderr
+++ b/tests/ui/traits/item-privacy.stderr
@@ -32,14 +32,14 @@ help: the following trait is implemented but not in scope; perhaps add a `use` f
 LL | use method::B;
    |
 
-error[E0624]: associated function `a` is private
+error[E0624]: method `a` is private
   --> $DIR/item-privacy.rs:72:7
    |
 LL |         fn a(&self) { }
-   |         ----------- private associated function defined here
+   |         ----------- private method defined here
 ...
 LL |     c.a();
-   |       ^ private associated function
+   |       ^ private method
 
 error[E0599]: no function or associated item named `a` found for struct `S` in the current scope
   --> $DIR/item-privacy.rs:78:8
@@ -72,14 +72,14 @@ help: the following trait is implemented but not in scope; perhaps add a `use` f
 LL | use method::B;
    |
 
-error[E0624]: associated function `a` is private
+error[E0624]: method `a` is private
   --> $DIR/item-privacy.rs:84:14
    |
 LL |         fn a(&self) { }
-   |         ----------- private associated function defined here
+   |         ----------- private method defined here
 ...
 LL |     <dyn C>::a(&S);
-   |              ^ private associated function
+   |              ^ private method
 
 error[E0599]: no associated item named `A` found for struct `S` in the current scope
   --> $DIR/item-privacy.rs:97:8
diff --git a/tests/ui/traits/method-private.stderr b/tests/ui/traits/method-private.stderr
index 8e991ec018c..55656f21e00 100644
--- a/tests/ui/traits/method-private.stderr
+++ b/tests/ui/traits/method-private.stderr
@@ -1,11 +1,11 @@
-error[E0624]: associated function `method` is private
+error[E0624]: method `method` is private
   --> $DIR/method-private.rs:19:9
    |
 LL |         fn method(&self) {}
-   |         ---------------- private associated function defined here
+   |         ---------------- private method defined here
 ...
 LL |     foo.method();
-   |         ^^^^^^ private associated function
+   |         ^^^^^^ private method
    |
    = help: items from traits can only be used if the trait is in scope
 help: the following trait is implemented but not in scope; perhaps add a `use` for it:
diff --git a/tests/ui/traits/multidispatch-convert-ambig-dest.stderr b/tests/ui/traits/multidispatch-convert-ambig-dest.stderr
index 6e6172eea47..e927f26e96d 100644
--- a/tests/ui/traits/multidispatch-convert-ambig-dest.stderr
+++ b/tests/ui/traits/multidispatch-convert-ambig-dest.stderr
@@ -29,7 +29,7 @@ note: required by a bound in `test`
   --> $DIR/multidispatch-convert-ambig-dest.rs:21:11
    |
 LL | fn test<T,U>(_: T, _: U)
-   |    ---- required by a bound in this
+   |    ---- required by a bound in this function
 LL | where T : Convert<U>
    |           ^^^^^^^^^^ required by this bound in `test`
 help: consider specifying the generic arguments
diff --git a/tests/ui/traits/new-solver/higher-ranked-dyn-bounds.rs b/tests/ui/traits/new-solver/higher-ranked-dyn-bounds.rs
new file mode 100644
index 00000000000..c886aeeda3e
--- /dev/null
+++ b/tests/ui/traits/new-solver/higher-ranked-dyn-bounds.rs
@@ -0,0 +1,17 @@
+// compile-flags: -Ztrait-solver=next
+// check-pass
+
+trait Trait<'a> {
+    type Item: for<'b> Trait2<'b>;
+}
+
+trait Trait2<'a> {}
+impl Trait2<'_> for () {}
+
+fn needs_trait(_: Box<impl for<'a> Trait<'a> + ?Sized>) {}
+
+fn foo(x: Box<dyn for<'a> Trait<'a, Item = ()>>) {
+    needs_trait(x);
+}
+
+fn main() {}
diff --git a/tests/ui/traits/new-solver/more-object-bound.rs b/tests/ui/traits/new-solver/more-object-bound.rs
new file mode 100644
index 00000000000..712759ef0e6
--- /dev/null
+++ b/tests/ui/traits/new-solver/more-object-bound.rs
@@ -0,0 +1,27 @@
+// compile-flags: -Ztrait-solver=next
+// From #80800
+
+trait SuperTrait {
+    type A;
+    type B;
+}
+
+trait Trait: SuperTrait<A = <Self as SuperTrait>::B> {}
+
+fn transmute<A, B>(x: A) -> B {
+    foo::<A, B, dyn Trait<A = A, B = B>>(x)
+    //~^ ERROR type annotations needed: cannot satisfy `dyn Trait<A = A, B = B>: Trait`
+}
+
+fn foo<A, B, T: ?Sized>(x: T::A) -> B
+where
+    T: Trait<B = B>,
+{
+    x
+}
+
+static X: u8 = 0;
+fn main() {
+    let x = transmute::<&u8, &[u8; 1_000_000]>(&X);
+    println!("{:?}", x[100_000]);
+}
diff --git a/tests/ui/traits/new-solver/more-object-bound.stderr b/tests/ui/traits/new-solver/more-object-bound.stderr
new file mode 100644
index 00000000000..208fdecb08f
--- /dev/null
+++ b/tests/ui/traits/new-solver/more-object-bound.stderr
@@ -0,0 +1,19 @@
+error[E0283]: type annotations needed: cannot satisfy `dyn Trait<A = A, B = B>: Trait`
+  --> $DIR/more-object-bound.rs:12:5
+   |
+LL |     foo::<A, B, dyn Trait<A = A, B = B>>(x)
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |
+   = note: cannot satisfy `dyn Trait<A = A, B = B>: Trait`
+note: required by a bound in `foo`
+  --> $DIR/more-object-bound.rs:18:8
+   |
+LL | fn foo<A, B, T: ?Sized>(x: T::A) -> B
+   |    --- required by a bound in this function
+LL | where
+LL |     T: Trait<B = B>,
+   |        ^^^^^^^^^^^^ required by this bound in `foo`
+
+error: aborting due to previous error
+
+For more information about this error, try `rustc --explain E0283`.
diff --git a/tests/ui/traits/new-solver/object-unsafety.rs b/tests/ui/traits/new-solver/object-unsafety.rs
new file mode 100644
index 00000000000..7bdd863a762
--- /dev/null
+++ b/tests/ui/traits/new-solver/object-unsafety.rs
@@ -0,0 +1,20 @@
+// compile-flags: -Ztrait-solver=next
+
+trait Setup {
+    type From: Copy;
+}
+
+fn copy<U: Setup + ?Sized>(from: &U::From) -> U::From {
+    *from
+}
+
+pub fn copy_any<T>(t: &T) -> T {
+    copy::<dyn Setup<From=T>>(t)
+    //~^ ERROR the trait bound `dyn Setup<From = T>: Setup` is not satisfied
+}
+
+fn main() {
+    let x = String::from("Hello, world");
+    let y = copy_any(&x);
+    println!("{y}");
+}
diff --git a/tests/ui/traits/new-solver/object-unsafety.stderr b/tests/ui/traits/new-solver/object-unsafety.stderr
new file mode 100644
index 00000000000..198ac623df8
--- /dev/null
+++ b/tests/ui/traits/new-solver/object-unsafety.stderr
@@ -0,0 +1,19 @@
+error[E0277]: the trait bound `dyn Setup<From = T>: Setup` is not satisfied
+  --> $DIR/object-unsafety.rs:12:12
+   |
+LL |     copy::<dyn Setup<From=T>>(t)
+   |            ^^^^^^^^^^^^^^^^^ the trait `Setup` is not implemented for `dyn Setup<From = T>`
+   |
+note: required by a bound in `copy`
+  --> $DIR/object-unsafety.rs:7:12
+   |
+LL | fn copy<U: Setup + ?Sized>(from: &U::From) -> U::From {
+   |            ^^^^^ required by this bound in `copy`
+help: consider introducing a `where` clause, but there might be an alternative better way to express this requirement
+   |
+LL | pub fn copy_any<T>(t: &T) -> T where dyn Setup<From = T>: Setup {
+   |                                ++++++++++++++++++++++++++++++++
+
+error: aborting due to previous error
+
+For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/traits/non_lifetime_binders/bad-sized-cond.stderr b/tests/ui/traits/non_lifetime_binders/bad-sized-cond.stderr
index 6480e490e8b..ed9b57cb1bd 100644
--- a/tests/ui/traits/non_lifetime_binders/bad-sized-cond.stderr
+++ b/tests/ui/traits/non_lifetime_binders/bad-sized-cond.stderr
@@ -18,7 +18,7 @@ note: required by a bound in `foo`
   --> $DIR/bad-sized-cond.rs:6:15
    |
 LL | pub fn foo()
-   |        --- required by a bound in this
+   |        --- required by a bound in this function
 LL | where
 LL |     for<V> V: Sized,
    |               ^^^^^ required by this bound in `foo`
@@ -35,7 +35,7 @@ note: required by a bound in `bar`
   --> $DIR/bad-sized-cond.rs:12:15
    |
 LL | pub fn bar()
-   |        --- required by a bound in this
+   |        --- required by a bound in this function
 LL | where
 LL |     for<V> V: IntoIterator,
    |               ^^^^^^^^^^^^ required by this bound in `bar`
@@ -52,7 +52,7 @@ note: required by a bound in `bar`
   --> $DIR/bad-sized-cond.rs:12:15
    |
 LL | pub fn bar()
-   |        --- required by a bound in this
+   |        --- required by a bound in this function
 LL | where
 LL |     for<V> V: IntoIterator,
    |               ^^^^^^^^^^^^ required by this bound in `bar`
diff --git a/tests/ui/traits/non_lifetime_binders/fail.stderr b/tests/ui/traits/non_lifetime_binders/fail.stderr
index c3f4fd6a88e..7bd02550fb3 100644
--- a/tests/ui/traits/non_lifetime_binders/fail.stderr
+++ b/tests/ui/traits/non_lifetime_binders/fail.stderr
@@ -17,7 +17,7 @@ note: required by a bound in `fail`
   --> $DIR/fail.rs:10:15
    |
 LL | fn fail()
-   |    ---- required by a bound in this
+   |    ---- required by a bound in this function
 LL | where
 LL |     for<T> T: Trait,
    |               ^^^^^ required by this bound in `fail`
@@ -33,7 +33,7 @@ note: required by a bound in `auto_trait`
   --> $DIR/fail.rs:15:15
    |
 LL | fn auto_trait()
-   |    ---------- required by a bound in this
+   |    ---------- required by a bound in this function
 LL | where
 LL |     for<T> T: Send,
    |               ^^^^ required by this bound in `auto_trait`
diff --git a/tests/ui/traits/non_lifetime_binders/type-match-with-late-bound.rs b/tests/ui/traits/non_lifetime_binders/type-match-with-late-bound.rs
new file mode 100644
index 00000000000..5ff7089b993
--- /dev/null
+++ b/tests/ui/traits/non_lifetime_binders/type-match-with-late-bound.rs
@@ -0,0 +1,14 @@
+// edition:2021
+// check-pass
+
+// Checks that test_type_match code doesn't ICE when predicates have late-bound types
+
+#![feature(non_lifetime_binders)]
+//~^ WARN is incomplete and may not be safe to use
+
+async fn walk2<'a, T: 'a>(_: T)
+where
+    for<F> F: 'a,
+{}
+
+fn main() {}
diff --git a/tests/ui/traits/non_lifetime_binders/type-match-with-late-bound.stderr b/tests/ui/traits/non_lifetime_binders/type-match-with-late-bound.stderr
new file mode 100644
index 00000000000..3609bed28df
--- /dev/null
+++ b/tests/ui/traits/non_lifetime_binders/type-match-with-late-bound.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/type-match-with-late-bound.rs:6: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/object/enforce-supertrait-projection.stderr b/tests/ui/traits/object/enforce-supertrait-projection.stderr
index cbf09386654..848b4e69a4b 100644
--- a/tests/ui/traits/object/enforce-supertrait-projection.stderr
+++ b/tests/ui/traits/object/enforce-supertrait-projection.stderr
@@ -16,7 +16,7 @@ note: required by a bound in `foo`
   --> $DIR/enforce-supertrait-projection.rs:15:8
    |
 LL | fn foo<A, B, T: ?Sized>(x: T::A) -> B
-   |    --- required by a bound in this
+   |    --- required by a bound in this function
 LL | where
 LL |     T: Trait<B = B>,
    |        ^^^^^^^^^^^^ required by this bound in `foo`
diff --git a/tests/ui/traits/object/vs-lifetime.rs b/tests/ui/traits/object/vs-lifetime.rs
index 14ae67cffd7..d3e6c0b217c 100644
--- a/tests/ui/traits/object/vs-lifetime.rs
+++ b/tests/ui/traits/object/vs-lifetime.rs
@@ -9,8 +9,8 @@ fn main() {
     let _: S<'static, dyn 'static +>;
     //~^ at least one trait is required for an object type
     let _: S<'static, 'static>;
-    //~^ ERROR this struct takes 1 lifetime argument but 2 lifetime arguments were supplied
-    //~| ERROR this struct takes 1 generic argument but 0 generic arguments were supplied
+    //~^ ERROR struct takes 1 lifetime argument but 2 lifetime arguments were supplied
+    //~| ERROR struct takes 1 generic argument but 0 generic arguments were supplied
     let _: S<dyn 'static +, 'static>;
     //~^ ERROR type provided when a lifetime was expected
     //~| ERROR at least one trait is required for an object type
diff --git a/tests/ui/traits/object/vs-lifetime.stderr b/tests/ui/traits/object/vs-lifetime.stderr
index 22446522852..a69cd140807 100644
--- a/tests/ui/traits/object/vs-lifetime.stderr
+++ b/tests/ui/traits/object/vs-lifetime.stderr
@@ -4,7 +4,7 @@ error[E0224]: at least one trait is required for an object type
 LL |     let _: S<'static, dyn 'static +>;
    |                       ^^^^^^^^^^^^^
 
-error[E0107]: this struct takes 1 lifetime argument but 2 lifetime arguments were supplied
+error[E0107]: struct takes 1 lifetime argument but 2 lifetime arguments were supplied
   --> $DIR/vs-lifetime.rs:11:12
    |
 LL |     let _: S<'static, 'static>;
@@ -18,7 +18,7 @@ note: struct defined here, with 1 lifetime parameter: `'a`
 LL | struct S<'a, T>(&'a u8, T);
    |        ^ --
 
-error[E0107]: this struct takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: struct takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/vs-lifetime.rs:11:12
    |
 LL |     let _: S<'static, 'static>;
diff --git a/tests/ui/traits/test-2.rs b/tests/ui/traits/test-2.rs
index 342928e882a..ffb778a0141 100644
--- a/tests/ui/traits/test-2.rs
+++ b/tests/ui/traits/test-2.rs
@@ -7,9 +7,9 @@ impl bar for u32 { fn dup(&self) -> u32 { *self } fn blah<X>(&self) {} }
 
 fn main() {
     10.dup::<i32>();
-    //~^ ERROR this associated function takes 0 generic arguments but 1
+    //~^ ERROR method takes 0 generic arguments but 1
     10.blah::<i32, i32>();
-    //~^ ERROR this associated function takes 1 generic argument but 2
+    //~^ ERROR method takes 1 generic argument but 2
     (Box::new(10) as Box<dyn bar>).dup();
     //~^ ERROR E0038
     //~| ERROR E0038
diff --git a/tests/ui/traits/test-2.stderr b/tests/ui/traits/test-2.stderr
index eaa20b0b4f4..6c0e8b8af4b 100644
--- a/tests/ui/traits/test-2.stderr
+++ b/tests/ui/traits/test-2.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this associated function takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: method takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/test-2.rs:9:8
    |
 LL |     10.dup::<i32>();
@@ -6,13 +6,13 @@ LL |     10.dup::<i32>();
    |        |
    |        expected 0 generic arguments
    |
-note: associated function defined here, with 0 generic parameters
+note: method defined here, with 0 generic parameters
   --> $DIR/test-2.rs:4:16
    |
 LL | trait bar { fn dup(&self) -> Self; fn blah<X>(&self); }
    |                ^^^
 
-error[E0107]: this associated function takes 1 generic argument but 2 generic arguments were supplied
+error[E0107]: method takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/test-2.rs:11:8
    |
 LL |     10.blah::<i32, i32>();
@@ -20,7 +20,7 @@ LL |     10.blah::<i32, i32>();
    |        |
    |        expected 1 generic argument
    |
-note: associated function defined here, with 1 generic parameter: `X`
+note: method defined here, with 1 generic parameter: `X`
   --> $DIR/test-2.rs:4:39
    |
 LL | trait bar { fn dup(&self) -> Self; fn blah<X>(&self); }
diff --git a/tests/ui/transmutability/arrays/should_require_well_defined_layout.stderr b/tests/ui/transmutability/arrays/should_require_well_defined_layout.stderr
index 96a2fdc54db..164e88ede20 100644
--- a/tests/ui/transmutability/arrays/should_require_well_defined_layout.stderr
+++ b/tests/ui/transmutability/arrays/should_require_well_defined_layout.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -31,7 +31,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -53,7 +53,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -75,7 +75,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -97,7 +97,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -119,7 +119,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
diff --git a/tests/ui/transmutability/enums/repr/primitive_reprs_should_have_correct_length.stderr b/tests/ui/transmutability/enums/repr/primitive_reprs_should_have_correct_length.stderr
index 4da5fcea337..0f0f77f1683 100644
--- a/tests/ui/transmutability/enums/repr/primitive_reprs_should_have_correct_length.stderr
+++ b/tests/ui/transmutability/enums/repr/primitive_reprs_should_have_correct_length.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -32,7 +32,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -55,7 +55,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -78,7 +78,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -101,7 +101,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -124,7 +124,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -147,7 +147,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -170,7 +170,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -193,7 +193,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -216,7 +216,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -239,7 +239,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -262,7 +262,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -285,7 +285,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -308,7 +308,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -331,7 +331,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -354,7 +354,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -377,7 +377,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -400,7 +400,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -423,7 +423,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -446,7 +446,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
diff --git a/tests/ui/transmutability/enums/repr/should_require_well_defined_layout.stderr b/tests/ui/transmutability/enums/repr/should_require_well_defined_layout.stderr
index 510b8c56e5a..d456a746f5e 100644
--- a/tests/ui/transmutability/enums/repr/should_require_well_defined_layout.stderr
+++ b/tests/ui/transmutability/enums/repr/should_require_well_defined_layout.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:14:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -32,7 +32,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:14:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -55,7 +55,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:14:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -78,7 +78,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:14:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -101,7 +101,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:14:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -124,7 +124,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:14:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
diff --git a/tests/ui/transmutability/enums/should_pad_variants.stderr b/tests/ui/transmutability/enums/should_pad_variants.stderr
index a823503d594..f4988239df9 100644
--- a/tests/ui/transmutability/enums/should_pad_variants.stderr
+++ b/tests/ui/transmutability/enums/should_pad_variants.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/should_pad_variants.rs:13:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
diff --git a/tests/ui/transmutability/enums/should_respect_endianness.stderr b/tests/ui/transmutability/enums/should_respect_endianness.stderr
index 0845a5edf32..350583b0b85 100644
--- a/tests/ui/transmutability/enums/should_respect_endianness.stderr
+++ b/tests/ui/transmutability/enums/should_respect_endianness.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/should_respect_endianness.rs:14:14
    |
 LL |       pub fn is_transmutable<Src, Dst>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
diff --git a/tests/ui/transmutability/issue-101739-2.rs b/tests/ui/transmutability/issue-101739-2.rs
index 964a7e49ee6..e5a56ccc9e0 100644
--- a/tests/ui/transmutability/issue-101739-2.rs
+++ b/tests/ui/transmutability/issue-101739-2.rs
@@ -15,7 +15,7 @@ mod assert {
         const ASSUME_VISIBILITY: bool,
     >()
     where
-        Dst: BikeshedIntrinsicFrom< //~ ERROR this trait takes at most 3 generic arguments but 6 generic arguments were supplied
+        Dst: BikeshedIntrinsicFrom< //~ ERROR trait takes at most 3 generic arguments but 6 generic arguments were supplied
             Src,
             Context,
             ASSUME_ALIGNMENT,
diff --git a/tests/ui/transmutability/issue-101739-2.stderr b/tests/ui/transmutability/issue-101739-2.stderr
index 1b3d202590d..420a9f33008 100644
--- a/tests/ui/transmutability/issue-101739-2.stderr
+++ b/tests/ui/transmutability/issue-101739-2.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this trait takes at most 3 generic arguments but 6 generic arguments were supplied
+error[E0107]: trait takes at most 3 generic arguments but 6 generic arguments were supplied
   --> $DIR/issue-101739-2.rs:18:14
    |
 LL |           Dst: BikeshedIntrinsicFrom<
diff --git a/tests/ui/transmutability/primitives/bool.stderr b/tests/ui/transmutability/primitives/bool.stderr
index 214b5e150ed..22decf15e54 100644
--- a/tests/ui/transmutability/primitives/bool.stderr
+++ b/tests/ui/transmutability/primitives/bool.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/bool.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
diff --git a/tests/ui/transmutability/primitives/numbers.stderr b/tests/ui/transmutability/primitives/numbers.stderr
index 7cb7ca8e6db..c04a0e82aa2 100644
--- a/tests/ui/transmutability/primitives/numbers.stderr
+++ b/tests/ui/transmutability/primitives/numbers.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -25,7 +25,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -41,7 +41,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -57,7 +57,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -73,7 +73,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -89,7 +89,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -105,7 +105,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -121,7 +121,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -137,7 +137,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -153,7 +153,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -169,7 +169,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -185,7 +185,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -201,7 +201,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -217,7 +217,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -233,7 +233,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -249,7 +249,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -265,7 +265,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -281,7 +281,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -297,7 +297,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -313,7 +313,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -329,7 +329,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -345,7 +345,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -361,7 +361,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -377,7 +377,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -393,7 +393,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -409,7 +409,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -425,7 +425,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -441,7 +441,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -457,7 +457,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -473,7 +473,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -489,7 +489,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -505,7 +505,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -521,7 +521,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -537,7 +537,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -553,7 +553,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -569,7 +569,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -585,7 +585,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -601,7 +601,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -617,7 +617,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -633,7 +633,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -649,7 +649,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -665,7 +665,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -681,7 +681,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -697,7 +697,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -713,7 +713,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -729,7 +729,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -745,7 +745,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -761,7 +761,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -777,7 +777,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -793,7 +793,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -809,7 +809,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -825,7 +825,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -841,7 +841,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -857,7 +857,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -873,7 +873,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -889,7 +889,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -905,7 +905,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/numbers.rs:12:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
diff --git a/tests/ui/transmutability/primitives/unit.stderr b/tests/ui/transmutability/primitives/unit.stderr
index 8cabe44a053..988cd33b3bf 100644
--- a/tests/ui/transmutability/primitives/unit.stderr
+++ b/tests/ui/transmutability/primitives/unit.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/unit.rs:12:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
diff --git a/tests/ui/transmutability/references.stderr b/tests/ui/transmutability/references.stderr
index e9c7b144a82..eb3bd03fd31 100644
--- a/tests/ui/transmutability/references.stderr
+++ b/tests/ui/transmutability/references.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/references.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
diff --git a/tests/ui/transmutability/structs/repr/should_require_well_defined_layout.stderr b/tests/ui/transmutability/structs/repr/should_require_well_defined_layout.stderr
index 621dbee849f..d9aebac6417 100644
--- a/tests/ui/transmutability/structs/repr/should_require_well_defined_layout.stderr
+++ b/tests/ui/transmutability/structs/repr/should_require_well_defined_layout.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -32,7 +32,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -55,7 +55,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -78,7 +78,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -101,7 +101,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -124,7 +124,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -147,7 +147,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -170,7 +170,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -193,7 +193,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -216,7 +216,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -239,7 +239,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -262,7 +262,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
diff --git a/tests/ui/transmutability/unions/repr/should_require_well_defined_layout.stderr b/tests/ui/transmutability/unions/repr/should_require_well_defined_layout.stderr
index 523bde85adf..aa0cbc51b1b 100644
--- a/tests/ui/transmutability/unions/repr/should_require_well_defined_layout.stderr
+++ b/tests/ui/transmutability/unions/repr/should_require_well_defined_layout.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
@@ -32,7 +32,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_require_well_defined_layout.rs:13:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
diff --git a/tests/ui/transmutability/unions/should_pad_variants.stderr b/tests/ui/transmutability/unions/should_pad_variants.stderr
index a823503d594..f4988239df9 100644
--- a/tests/ui/transmutability/unions/should_pad_variants.stderr
+++ b/tests/ui/transmutability/unions/should_pad_variants.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/should_pad_variants.rs:13:14
    |
 LL |       pub fn is_transmutable<Src, Dst, Context>()
-   |              --------------- required by a bound in this
+   |              --------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<Src, Context, {
    |  ______________^
diff --git a/tests/ui/transmutability/unions/should_reject_contraction.stderr b/tests/ui/transmutability/unions/should_reject_contraction.stderr
index 41f0cedc3a3..fa7dcc3d22a 100644
--- a/tests/ui/transmutability/unions/should_reject_contraction.stderr
+++ b/tests/ui/transmutability/unions/should_reject_contraction.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/should_reject_contraction.rs:13:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
diff --git a/tests/ui/transmutability/unions/should_reject_disjoint.stderr b/tests/ui/transmutability/unions/should_reject_disjoint.stderr
index 4323f974066..880e4cd8940 100644
--- a/tests/ui/transmutability/unions/should_reject_disjoint.stderr
+++ b/tests/ui/transmutability/unions/should_reject_disjoint.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_reject_disjoint.rs:13:14
    |
 LL |     pub fn is_maybe_transmutable<Src, Dst>()
-   |            --------------------- required by a bound in this
+   |            --------------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY.and(Assume::VALIDITY) }>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
@@ -25,7 +25,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/should_reject_disjoint.rs:13:14
    |
 LL |     pub fn is_maybe_transmutable<Src, Dst>()
-   |            --------------------- required by a bound in this
+   |            --------------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY.and(Assume::VALIDITY) }>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
diff --git a/tests/ui/transmutability/unions/should_reject_intersecting.stderr b/tests/ui/transmutability/unions/should_reject_intersecting.stderr
index e009888ae8d..501760b0809 100644
--- a/tests/ui/transmutability/unions/should_reject_intersecting.stderr
+++ b/tests/ui/transmutability/unions/should_reject_intersecting.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/should_reject_intersecting.rs:14:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
@@ -25,7 +25,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/should_reject_intersecting.rs:14:14
    |
 LL |     pub fn is_transmutable<Src, Dst>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
diff --git a/tests/ui/transmutability/visibility/should_reject_if_dst_has_private_field.stderr b/tests/ui/transmutability/visibility/should_reject_if_dst_has_private_field.stderr
index d5d6d431b6f..afbba653b83 100644
--- a/tests/ui/transmutability/visibility/should_reject_if_dst_has_private_field.stderr
+++ b/tests/ui/transmutability/visibility/should_reject_if_dst_has_private_field.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/should_reject_if_dst_has_private_field.rs:13:14
    |
 LL |     pub fn is_transmutable<Src, Dst, Context>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
diff --git a/tests/ui/transmutability/visibility/should_reject_if_dst_has_private_variant.stderr b/tests/ui/transmutability/visibility/should_reject_if_dst_has_private_variant.stderr
index a1ca2ced53f..f14b5d8b2cb 100644
--- a/tests/ui/transmutability/visibility/should_reject_if_dst_has_private_variant.stderr
+++ b/tests/ui/transmutability/visibility/should_reject_if_dst_has_private_variant.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/should_reject_if_dst_has_private_variant.rs:13:14
    |
 LL |     pub fn is_transmutable<Src, Dst, Context>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
diff --git a/tests/ui/transmutability/visibility/should_reject_if_dst_has_unreachable_field.stderr b/tests/ui/transmutability/visibility/should_reject_if_dst_has_unreachable_field.stderr
index 4e648664d5a..01ae8bea256 100644
--- a/tests/ui/transmutability/visibility/should_reject_if_dst_has_unreachable_field.stderr
+++ b/tests/ui/transmutability/visibility/should_reject_if_dst_has_unreachable_field.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/should_reject_if_dst_has_unreachable_field.rs:15:14
    |
 LL |     pub fn is_transmutable<Src, Dst, Context>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
diff --git a/tests/ui/transmutability/visibility/should_reject_if_dst_has_unreachable_ty.stderr b/tests/ui/transmutability/visibility/should_reject_if_dst_has_unreachable_ty.stderr
index bd72d64ccd7..20a680a7484 100644
--- a/tests/ui/transmutability/visibility/should_reject_if_dst_has_unreachable_ty.stderr
+++ b/tests/ui/transmutability/visibility/should_reject_if_dst_has_unreachable_ty.stderr
@@ -21,7 +21,7 @@ note: required by a bound in `is_transmutable`
   --> $DIR/should_reject_if_dst_has_unreachable_ty.rs:15:14
    |
 LL |     pub fn is_transmutable<Src, Dst, Context>()
-   |            --------------- required by a bound in this
+   |            --------------- required by a bound in this function
 LL |     where
 LL |         Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
diff --git a/tests/ui/transmute/transmute-padding-ice.stderr b/tests/ui/transmute/transmute-padding-ice.stderr
index c9233890f7a..87fd4fb6630 100644
--- a/tests/ui/transmute/transmute-padding-ice.stderr
+++ b/tests/ui/transmute/transmute-padding-ice.stderr
@@ -9,7 +9,7 @@ note: required by a bound in `is_maybe_transmutable`
   --> $DIR/transmute-padding-ice.rs:11:14
    |
 LL |       pub fn is_maybe_transmutable<Src, Dst>()
-   |              --------------------- required by a bound in this
+   |              --------------------- required by a bound in this function
 LL |       where
 LL |           Dst: BikeshedIntrinsicFrom<
    |  ______________^
diff --git a/tests/ui/tuple/wrong_argument_ice-3.stderr b/tests/ui/tuple/wrong_argument_ice-3.stderr
index 7143c959478..8b9dac6e291 100644
--- a/tests/ui/tuple/wrong_argument_ice-3.stderr
+++ b/tests/ui/tuple/wrong_argument_ice-3.stderr
@@ -11,7 +11,7 @@ LL |         groups.push(new_group, vec![process]);
    |                     ^^^^^^^^^
    = note: expected tuple `(Vec<String>, Vec<Process>)`
              found struct `Vec<String>`
-note: associated function defined here
+note: method defined here
   --> $SRC_DIR/alloc/src/vec/mod.rs:LL:COL
 help: remove the extra argument
    |
diff --git a/tests/ui/tuple/wrong_argument_ice.stderr b/tests/ui/tuple/wrong_argument_ice.stderr
index f1b00ae0b92..213ca8f885c 100644
--- a/tests/ui/tuple/wrong_argument_ice.stderr
+++ b/tests/ui/tuple/wrong_argument_ice.stderr
@@ -4,7 +4,7 @@ error[E0061]: method takes 1 argument but 2 arguments were supplied
 LL |         self.acc.push_back(self.current_provides, self.current_requires);
    |                  ^^^^^^^^^
    |
-note: associated function defined here
+note: method defined here
   --> $SRC_DIR/alloc/src/collections/vec_deque/mod.rs:LL:COL
 help: wrap these arguments in parentheses to construct a tuple
    |
diff --git a/tests/ui/type-alias-enum-variants/enum-variant-generic-args.rs b/tests/ui/type-alias-enum-variants/enum-variant-generic-args.rs
index 0031a4665c8..759a7fd7e05 100644
--- a/tests/ui/type-alias-enum-variants/enum-variant-generic-args.rs
+++ b/tests/ui/type-alias-enum-variants/enum-variant-generic-args.rs
@@ -62,10 +62,10 @@ fn main() {
     AliasFixed::TSVariant::<()>(());
     //~^ ERROR type arguments are not allowed on this type [E0109]
     AliasFixed::<()>::TSVariant(());
-    //~^ ERROR this type alias takes 0 generic arguments but 1 generic argument was supplied [E0107]
+    //~^ ERROR type alias takes 0 generic arguments but 1 generic argument was supplied [E0107]
     AliasFixed::<()>::TSVariant::<()>(());
     //~^ ERROR type arguments are not allowed on this type [E0109]
-    //~| ERROR this type alias takes 0 generic arguments but 1 generic argument was supplied [E0107]
+    //~| ERROR type alias takes 0 generic arguments but 1 generic argument was supplied [E0107]
 
     // Struct variant
 
@@ -80,10 +80,10 @@ fn main() {
     AliasFixed::SVariant::<()> { v: () };
     //~^ ERROR type arguments are not allowed on this type [E0109]
     AliasFixed::<()>::SVariant { v: () };
-    //~^ ERROR this type alias takes 0 generic arguments but 1 generic argument was supplied [E0107]
+    //~^ ERROR type alias takes 0 generic arguments but 1 generic argument was supplied [E0107]
     AliasFixed::<()>::SVariant::<()> { v: () };
     //~^ ERROR type arguments are not allowed on this type [E0109]
-    //~| ERROR this type alias takes 0 generic arguments but 1 generic argument was supplied [E0107]
+    //~| ERROR type alias takes 0 generic arguments but 1 generic argument was supplied [E0107]
 
     // Unit variant
 
@@ -98,8 +98,8 @@ fn main() {
     AliasFixed::UVariant::<()>;
     //~^ ERROR type arguments are not allowed on this type [E0109]
     AliasFixed::<()>::UVariant;
-    //~^ ERROR this type alias takes 0 generic arguments but 1 generic argument was supplied [E0107]
+    //~^ ERROR type alias takes 0 generic arguments but 1 generic argument was supplied [E0107]
     AliasFixed::<()>::UVariant::<()>;
     //~^ ERROR type arguments are not allowed on this type [E0109]
-    //~| ERROR this type alias takes 0 generic arguments but 1 generic argument was supplied [E0107]
+    //~| ERROR type alias takes 0 generic arguments but 1 generic argument was supplied [E0107]
 }
diff --git a/tests/ui/type-alias-enum-variants/enum-variant-generic-args.stderr b/tests/ui/type-alias-enum-variants/enum-variant-generic-args.stderr
index a922d7a5e41..758ff31ff70 100644
--- a/tests/ui/type-alias-enum-variants/enum-variant-generic-args.stderr
+++ b/tests/ui/type-alias-enum-variants/enum-variant-generic-args.stderr
@@ -304,7 +304,7 @@ LL |     AliasFixed::TSVariant::<()>(());
    |                 |
    |                 not allowed on this type
 
-error[E0107]: this type alias takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: type alias takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/enum-variant-generic-args.rs:64:5
    |
 LL |     AliasFixed::<()>::TSVariant(());
@@ -318,7 +318,7 @@ note: type alias defined here, with 0 generic parameters
 LL | type AliasFixed = Enum<()>;
    |      ^^^^^^^^^^
 
-error[E0107]: this type alias takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: type alias takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/enum-variant-generic-args.rs:66:5
    |
 LL |     AliasFixed::<()>::TSVariant::<()>(());
@@ -395,7 +395,7 @@ LL -     AliasFixed::SVariant::<()> { v: () };
 LL +     AliasFixed::<()>::SVariant { v: () };
    |
 
-error[E0107]: this type alias takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: type alias takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/enum-variant-generic-args.rs:82:5
    |
 LL |     AliasFixed::<()>::SVariant { v: () };
@@ -409,7 +409,7 @@ note: type alias defined here, with 0 generic parameters
 LL | type AliasFixed = Enum<()>;
    |      ^^^^^^^^^^
 
-error[E0107]: this type alias takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: type alias takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/enum-variant-generic-args.rs:84:5
    |
 LL |     AliasFixed::<()>::SVariant::<()> { v: () };
@@ -470,7 +470,7 @@ LL |     AliasFixed::UVariant::<()>;
    |                 |
    |                 not allowed on this type
 
-error[E0107]: this type alias takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: type alias takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/enum-variant-generic-args.rs:100:5
    |
 LL |     AliasFixed::<()>::UVariant;
@@ -484,7 +484,7 @@ note: type alias defined here, with 0 generic parameters
 LL | type AliasFixed = Enum<()>;
    |      ^^^^^^^^^^
 
-error[E0107]: this type alias takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: type alias takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/enum-variant-generic-args.rs:102:5
    |
 LL |     AliasFixed::<()>::UVariant::<()>;
diff --git a/tests/ui/type-alias-impl-trait/bounds-are-checked.rs b/tests/ui/type-alias-impl-trait/bounds-are-checked.rs
index eeb5dca07f0..7c3a3a84406 100644
--- a/tests/ui/type-alias-impl-trait/bounds-are-checked.rs
+++ b/tests/ui/type-alias-impl-trait/bounds-are-checked.rs
@@ -6,7 +6,6 @@
 type X<'a> = impl Into<&'static str> + From<&'a str>;
 
 fn f<'a: 'static>(t: &'a str) -> X<'a> {
-    //~^ WARNING unnecessary lifetime parameter
     t
     //~^ ERROR expected generic lifetime parameter, found `'static`
 }
diff --git a/tests/ui/type-alias-impl-trait/bounds-are-checked.stderr b/tests/ui/type-alias-impl-trait/bounds-are-checked.stderr
index 94882597a62..962dedde09a 100644
--- a/tests/ui/type-alias-impl-trait/bounds-are-checked.stderr
+++ b/tests/ui/type-alias-impl-trait/bounds-are-checked.stderr
@@ -1,13 +1,5 @@
-warning: unnecessary lifetime parameter `'a`
-  --> $DIR/bounds-are-checked.rs:8:6
-   |
-LL | fn f<'a: 'static>(t: &'a str) -> X<'a> {
-   |      ^^
-   |
-   = help: you can use the `'static` lifetime directly, in place of `'a`
-
 error[E0792]: expected generic lifetime parameter, found `'static`
-  --> $DIR/bounds-are-checked.rs:10:5
+  --> $DIR/bounds-are-checked.rs:9:5
    |
 LL | type X<'a> = impl Into<&'static str> + From<&'a str>;
    |        -- cannot use static lifetime; use a bound lifetime instead or remove the lifetime parameter from the opaque type
@@ -15,6 +7,6 @@ LL | type X<'a> = impl Into<&'static str> + From<&'a str>;
 LL |     t
    |     ^
 
-error: aborting due to previous error; 1 warning emitted
+error: aborting due to previous error
 
 For more information about this error, try `rustc --explain E0792`.
diff --git a/tests/ui/type-alias-impl-trait/implied_lifetime_wf_check3.rs b/tests/ui/type-alias-impl-trait/implied_lifetime_wf_check3.rs
index 07f825aea50..6f9434255a8 100644
--- a/tests/ui/type-alias-impl-trait/implied_lifetime_wf_check3.rs
+++ b/tests/ui/type-alias-impl-trait/implied_lifetime_wf_check3.rs
@@ -4,7 +4,6 @@ mod test_lifetime_param {
     type Ty<'a> = impl Sized + 'a;
     fn defining(a: &str) -> Ty<'_> { a }
     fn assert_static<'a: 'static>() {}
-    //~^ WARN: unnecessary lifetime parameter `'a`
     fn test<'a>() where Ty<'a>: 'static { assert_static::<'a>() }
     //~^ ERROR: lifetime may not live long enough
 }
@@ -13,14 +12,12 @@ mod test_higher_kinded_lifetime_param {
     type Ty<'a> = impl Sized + 'a;
     fn defining(a: &str) -> Ty<'_> { a }
     fn assert_static<'a: 'static>() {}
-    //~^ WARN: unnecessary lifetime parameter `'a`
     fn test<'a>() where for<'b> Ty<'b>: 'a { assert_static::<'a>() }
     //~^ ERROR: lifetime may not live long enough
 }
 
 mod test_higher_kinded_lifetime_param2 {
     fn assert_static<'a: 'static>() {}
-    //~^ WARN: unnecessary lifetime parameter `'a`
     fn test<'a>() { assert_static::<'a>() }
     //~^ ERROR: lifetime may not live long enough
 }
diff --git a/tests/ui/type-alias-impl-trait/implied_lifetime_wf_check3.stderr b/tests/ui/type-alias-impl-trait/implied_lifetime_wf_check3.stderr
index 887620a4d50..399775641f8 100644
--- a/tests/ui/type-alias-impl-trait/implied_lifetime_wf_check3.stderr
+++ b/tests/ui/type-alias-impl-trait/implied_lifetime_wf_check3.stderr
@@ -1,41 +1,17 @@
-warning: unnecessary lifetime parameter `'a`
-  --> $DIR/implied_lifetime_wf_check3.rs:6:22
-   |
-LL |     fn assert_static<'a: 'static>() {}
-   |                      ^^
-   |
-   = help: you can use the `'static` lifetime directly, in place of `'a`
-
-warning: unnecessary lifetime parameter `'a`
-  --> $DIR/implied_lifetime_wf_check3.rs:15:22
-   |
-LL |     fn assert_static<'a: 'static>() {}
-   |                      ^^
-   |
-   = help: you can use the `'static` lifetime directly, in place of `'a`
-
-warning: unnecessary lifetime parameter `'a`
-  --> $DIR/implied_lifetime_wf_check3.rs:22:22
-   |
-LL |     fn assert_static<'a: 'static>() {}
-   |                      ^^
-   |
-   = help: you can use the `'static` lifetime directly, in place of `'a`
-
 error: lifetime may not live long enough
-  --> $DIR/implied_lifetime_wf_check3.rs:8:43
+  --> $DIR/implied_lifetime_wf_check3.rs:7:43
    |
 LL |     fn test<'a>() where Ty<'a>: 'static { assert_static::<'a>() }
    |             -- lifetime `'a` defined here ^^^^^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`
 
 error: lifetime may not live long enough
-  --> $DIR/implied_lifetime_wf_check3.rs:17:46
+  --> $DIR/implied_lifetime_wf_check3.rs:15:46
    |
 LL |     fn test<'a>() where for<'b> Ty<'b>: 'a { assert_static::<'a>() }
    |             -- lifetime `'a` defined here    ^^^^^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`
 
 error: lifetime may not live long enough
-  --> $DIR/implied_lifetime_wf_check3.rs:24:21
+  --> $DIR/implied_lifetime_wf_check3.rs:21:21
    |
 LL |     fn test<'a>() { assert_static::<'a>() }
    |             --      ^^^^^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`
@@ -43,7 +19,7 @@ LL |     fn test<'a>() { assert_static::<'a>() }
    |             lifetime `'a` defined here
 
 error[E0310]: the parameter type `A` may not live long enough
-  --> $DIR/implied_lifetime_wf_check3.rs:32:41
+  --> $DIR/implied_lifetime_wf_check3.rs:29:41
    |
 LL |     fn test<A>() where Ty<A>: 'static { assert_static::<A>() }
    |                                         ^^^^^^^^^^^^^^^^^^ ...so that the type `A` will meet its required lifetime bounds
@@ -53,6 +29,6 @@ help: consider adding an explicit lifetime bound...
 LL |     fn test<A: 'static>() where Ty<A>: 'static { assert_static::<A>() }
    |              +++++++++
 
-error: aborting due to 4 previous errors; 3 warnings emitted
+error: aborting due to 4 previous errors
 
 For more information about this error, try `rustc --explain E0310`.
diff --git a/tests/ui/type-alias-impl-trait/match-unification.rs b/tests/ui/type-alias-impl-trait/match-unification.rs
new file mode 100644
index 00000000000..f5c2abc0efa
--- /dev/null
+++ b/tests/ui/type-alias-impl-trait/match-unification.rs
@@ -0,0 +1,14 @@
+use std::fmt::Debug;
+
+// check-pass
+
+fn bar() -> impl Debug {}
+
+fn baz(b: bool) -> Option<impl Debug> {
+    match b {
+        true => baz(false),
+        false => Some(bar()),
+    }
+}
+
+fn main() {}
diff --git a/tests/ui/type-alias-impl-trait/type-alias-impl-trait-fn-type.stderr b/tests/ui/type-alias-impl-trait/type-alias-impl-trait-fn-type.stderr
index a31cf1a51cc..ff375b2ff86 100644
--- a/tests/ui/type-alias-impl-trait/type-alias-impl-trait-fn-type.stderr
+++ b/tests/ui/type-alias-impl-trait/type-alias-impl-trait-fn-type.stderr
@@ -1,4 +1,4 @@
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `fn` pointer return
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in `fn` pointer return types
   --> $DIR/type-alias-impl-trait-fn-type.rs:6:20
    |
 LL | type Foo = fn() -> impl Send;
diff --git a/tests/ui/type-inference/sort_by_key.stderr b/tests/ui/type-inference/sort_by_key.stderr
index 0a48d5756eb..de7b4b24899 100644
--- a/tests/ui/type-inference/sort_by_key.stderr
+++ b/tests/ui/type-inference/sort_by_key.stderr
@@ -2,7 +2,7 @@ error[E0282]: type annotations needed
   --> $DIR/sort_by_key.rs:3:40
    |
 LL |     lst.sort_by_key(|&(v, _)| v.iter().sum());
-   |                                        ^^^ cannot infer type of the type parameter `S` declared on the associated function `sum`
+   |                                        ^^^ cannot infer type of the type parameter `S` declared on the method `sum`
    |
 help: consider specifying the generic argument
    |
diff --git a/tests/ui/type/type-check/point-at-inference-3.fixed b/tests/ui/type/type-check/point-at-inference-3.fixed
index 1a960133ceb..edd4adf8bd2 100644
--- a/tests/ui/type/type-check/point-at-inference-3.fixed
+++ b/tests/ui/type/type-check/point-at-inference-3.fixed
@@ -7,6 +7,6 @@ fn main() {
     v.push(1i32); //~ ERROR mismatched types
     //~^ NOTE expected `i32`, found `u32`
     //~| NOTE arguments to this method are incorrect
-    //~| NOTE associated function defined here
+    //~| NOTE method defined here
     //~| HELP change the type of the numeric literal from `u32` to `i32`
 }
diff --git a/tests/ui/type/type-check/point-at-inference-3.rs b/tests/ui/type/type-check/point-at-inference-3.rs
index 92910ae1a31..49d7b50075b 100644
--- a/tests/ui/type/type-check/point-at-inference-3.rs
+++ b/tests/ui/type/type-check/point-at-inference-3.rs
@@ -7,6 +7,6 @@ fn main() {
     v.push(1u32); //~ ERROR mismatched types
     //~^ NOTE expected `i32`, found `u32`
     //~| NOTE arguments to this method are incorrect
-    //~| NOTE associated function defined here
+    //~| NOTE method defined here
     //~| HELP change the type of the numeric literal from `u32` to `i32`
 }
diff --git a/tests/ui/type/type-check/point-at-inference-3.stderr b/tests/ui/type/type-check/point-at-inference-3.stderr
index 999c3148362..2c4907ed263 100644
--- a/tests/ui/type/type-check/point-at-inference-3.stderr
+++ b/tests/ui/type/type-check/point-at-inference-3.stderr
@@ -9,7 +9,7 @@ LL |     v.push(1u32);
    |       |
    |       arguments to this method are incorrect
    |
-note: associated function defined here
+note: method defined here
   --> $SRC_DIR/alloc/src/vec/mod.rs:LL:COL
 help: change the type of the numeric literal from `u32` to `i32`
    |
diff --git a/tests/ui/type/type-check/point-at-inference-4.rs b/tests/ui/type/type-check/point-at-inference-4.rs
index 7903e9e83cf..aea9b2c6c14 100644
--- a/tests/ui/type/type-check/point-at-inference-4.rs
+++ b/tests/ui/type/type-check/point-at-inference-4.rs
@@ -2,7 +2,7 @@ struct S<A, B>(Option<(A, B)>);
 
 impl<A, B> S<A, B> {
     fn infer(&self, a: A, b: B) {}
-    //~^ NOTE associated function defined here
+    //~^ NOTE method defined here
     //~| NOTE
     //~| NOTE
 }
diff --git a/tests/ui/type/type-check/point-at-inference-4.stderr b/tests/ui/type/type-check/point-at-inference-4.stderr
index fac9701e4a1..28833d2ed1c 100644
--- a/tests/ui/type/type-check/point-at-inference-4.stderr
+++ b/tests/ui/type/type-check/point-at-inference-4.stderr
@@ -4,7 +4,7 @@ error[E0061]: this method takes 2 arguments but 1 argument was supplied
 LL |     s.infer(0i32);
    |       ^^^^^------ an argument is missing
    |
-note: associated function defined here
+note: method defined here
   --> $DIR/point-at-inference-4.rs:4:8
    |
 LL |     fn infer(&self, a: A, b: B) {}
diff --git a/tests/ui/type/wrong-call-return-type-due-to-generic-arg.stderr b/tests/ui/type/wrong-call-return-type-due-to-generic-arg.stderr
index 4d012cb156b..fbe6bfeebb1 100644
--- a/tests/ui/type/wrong-call-return-type-due-to-generic-arg.stderr
+++ b/tests/ui/type/wrong-call-return-type-due-to-generic-arg.stderr
@@ -95,7 +95,7 @@ LL |     let x: u16 = (S {}).method(0u32);
    |                  ^^^^^^^^^^^^^^----^
    |                                |
    |                                this argument influences the return type of `method`
-note: associated function defined here
+note: method defined here
   --> $DIR/wrong-call-return-type-due-to-generic-arg.rs:7:8
    |
 LL |     fn method<T>(&self, x: T) -> T {
diff --git a/tests/ui/typeck/bad-type-in-vec-push.stderr b/tests/ui/typeck/bad-type-in-vec-push.stderr
index 882854acb1d..ae46050c91b 100644
--- a/tests/ui/typeck/bad-type-in-vec-push.stderr
+++ b/tests/ui/typeck/bad-type-in-vec-push.stderr
@@ -10,7 +10,7 @@ LL |     result.push(vector);
    |
    = note: expected type `{integer}`
             found struct `Vec<_>`
-note: associated function defined here
+note: method defined here
   --> $SRC_DIR/alloc/src/vec/mod.rs:LL:COL
 
 error[E0308]: mismatched types
@@ -21,7 +21,7 @@ LL |     x.push("");
    |       |
    |       arguments to this method are incorrect
    |
-note: associated function defined here
+note: method defined here
   --> $SRC_DIR/alloc/src/vec/mod.rs:LL:COL
 
 error: aborting due to 2 previous errors
diff --git a/tests/ui/typeck/issue-104513-ice.stderr b/tests/ui/typeck/issue-104513-ice.stderr
index 42cfe38aed8..09187d7863a 100644
--- a/tests/ui/typeck/issue-104513-ice.stderr
+++ b/tests/ui/typeck/issue-104513-ice.stderr
@@ -4,7 +4,7 @@ error[E0405]: cannot find trait `Oops` in this scope
 LL |     let _: S<impl Oops> = S;
    |                   ^^^^ not found in this scope
 
-error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable binding
+error[E0562]: `impl Trait` only allowed in function and inherent method return types, not in variable bindings
   --> $DIR/issue-104513-ice.rs:3:14
    |
 LL |     let _: S<impl Oops> = S;
diff --git a/tests/ui/typeck/issue-75883.rs b/tests/ui/typeck/issue-75883.rs
index 885acc48231..c50ea0a086b 100644
--- a/tests/ui/typeck/issue-75883.rs
+++ b/tests/ui/typeck/issue-75883.rs
@@ -4,7 +4,7 @@ pub struct UI {}
 
 impl UI {
     pub fn run() -> Result<_> {
-        //~^ ERROR: this enum takes 2 generic arguments but 1 generic argument was supplied
+        //~^ ERROR: enum takes 2 generic arguments but 1 generic argument was supplied
         //~| ERROR: the placeholder `_` is not allowed within types on item signatures for return types
         let mut ui = UI {};
         ui.interact();
@@ -13,7 +13,7 @@ impl UI {
     }
 
     pub fn interact(&mut self) -> Result<_> {
-        //~^ ERROR: this enum takes 2 generic arguments but 1 generic argument was supplied
+        //~^ ERROR: enum takes 2 generic arguments but 1 generic argument was supplied
         //~| ERROR: the placeholder `_` is not allowed within types on item signatures for return types
         unimplemented!();
     }
diff --git a/tests/ui/typeck/issue-75883.stderr b/tests/ui/typeck/issue-75883.stderr
index f5adcabe3e9..a1ed0840675 100644
--- a/tests/ui/typeck/issue-75883.stderr
+++ b/tests/ui/typeck/issue-75883.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this enum takes 2 generic arguments but 1 generic argument was supplied
+error[E0107]: enum takes 2 generic arguments but 1 generic argument was supplied
   --> $DIR/issue-75883.rs:6:21
    |
 LL |     pub fn run() -> Result<_> {
@@ -11,7 +11,7 @@ help: add missing generic argument
 LL |     pub fn run() -> Result<_, E> {
    |                             +++
 
-error[E0107]: this enum takes 2 generic arguments but 1 generic argument was supplied
+error[E0107]: enum takes 2 generic arguments but 1 generic argument was supplied
   --> $DIR/issue-75883.rs:15:35
    |
 LL |     pub fn interact(&mut self) -> Result<_> {
diff --git a/tests/ui/typeck/issue-84768.stderr b/tests/ui/typeck/issue-84768.stderr
index 63936f9979f..3d2d53f5c76 100644
--- a/tests/ui/typeck/issue-84768.stderr
+++ b/tests/ui/typeck/issue-84768.stderr
@@ -21,7 +21,7 @@ LL |     <F as FnOnce(&mut u8)>::call_once(f, 1)
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-^
    |                                          |
    |                                          this argument influences the return type of `FnOnce`
-note: associated function defined here
+note: method defined here
   --> $SRC_DIR/core/src/ops/function.rs:LL:COL
 
 error: aborting due to 2 previous errors
diff --git a/tests/ui/typeck/lazy-norm/cast-checks-handling-projections.rs b/tests/ui/typeck/lazy-norm/cast-checks-handling-projections.rs
new file mode 100644
index 00000000000..5ff567cd07c
--- /dev/null
+++ b/tests/ui/typeck/lazy-norm/cast-checks-handling-projections.rs
@@ -0,0 +1,6 @@
+// compile-flags: -Ztrait-solver=next
+// known-bug: unknown
+
+fn main() {
+    (0u8 + 0u8) as char;
+}
diff --git a/tests/ui/typeck/lazy-norm/cast-checks-handling-projections.stderr b/tests/ui/typeck/lazy-norm/cast-checks-handling-projections.stderr
new file mode 100644
index 00000000000..6b09ccd5214
--- /dev/null
+++ b/tests/ui/typeck/lazy-norm/cast-checks-handling-projections.stderr
@@ -0,0 +1,9 @@
+error[E0271]: type mismatch resolving `char == <u8 as Add>::Output`
+  --> $DIR/cast-checks-handling-projections.rs:5:5
+   |
+LL |     (0u8 + 0u8) as char;
+   |     ^^^^^^^^^^^ types differ
+
+error: aborting due to previous error
+
+For more information about this error, try `rustc --explain E0271`.
diff --git a/tests/ui/typeck/typeck-builtin-bound-type-parameters.rs b/tests/ui/typeck/typeck-builtin-bound-type-parameters.rs
index c463a8ad0c7..7ff9199f63c 100644
--- a/tests/ui/typeck/typeck-builtin-bound-type-parameters.rs
+++ b/tests/ui/typeck/typeck-builtin-bound-type-parameters.rs
@@ -1,17 +1,17 @@
 fn foo1<T:Copy<U>, U>(x: T) {}
-//~^ ERROR this trait takes 0 generic arguments but 1 generic argument was supplied
+//~^ ERROR trait takes 0 generic arguments but 1 generic argument was supplied
 
 trait Trait: Copy<dyn Send> {}
-//~^ ERROR this trait takes 0 generic arguments but 1 generic argument was supplied
+//~^ ERROR trait takes 0 generic arguments but 1 generic argument was supplied
 
 struct MyStruct1<T: Copy<T>>;
-//~^ ERROR this trait takes 0 generic arguments but 1 generic argument was supplied
+//~^ ERROR trait takes 0 generic arguments but 1 generic argument was supplied
 
 struct MyStruct2<'a, T: Copy<'a>>;
-//~^ ERROR this trait takes 0 lifetime arguments but 1 lifetime argument was supplied
+//~^ ERROR trait takes 0 lifetime arguments but 1 lifetime argument was supplied
 
 fn foo2<'a, T:Copy<'a, U>, U>(x: T) {}
-//~^ ERROR this trait takes 0 lifetime arguments but 1 lifetime argument was supplied
-//~| ERROR this trait takes 0 generic arguments but 1 generic argument was supplied
+//~^ ERROR trait takes 0 lifetime arguments but 1 lifetime argument was supplied
+//~| ERROR trait takes 0 generic arguments but 1 generic argument was supplied
 
 fn main() { }
diff --git a/tests/ui/typeck/typeck-builtin-bound-type-parameters.stderr b/tests/ui/typeck/typeck-builtin-bound-type-parameters.stderr
index 331540d1e42..a71fd953658 100644
--- a/tests/ui/typeck/typeck-builtin-bound-type-parameters.stderr
+++ b/tests/ui/typeck/typeck-builtin-bound-type-parameters.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this trait takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/typeck-builtin-bound-type-parameters.rs:1:11
    |
 LL | fn foo1<T:Copy<U>, U>(x: T) {}
@@ -6,7 +6,7 @@ LL | fn foo1<T:Copy<U>, U>(x: T) {}
    |           |
    |           expected 0 generic arguments
 
-error[E0107]: this trait takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/typeck-builtin-bound-type-parameters.rs:4:14
    |
 LL | trait Trait: Copy<dyn Send> {}
@@ -14,7 +14,7 @@ LL | trait Trait: Copy<dyn Send> {}
    |              |
    |              expected 0 generic arguments
 
-error[E0107]: this trait takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/typeck-builtin-bound-type-parameters.rs:7:21
    |
 LL | struct MyStruct1<T: Copy<T>>;
@@ -22,7 +22,7 @@ LL | struct MyStruct1<T: Copy<T>>;
    |                     |
    |                     expected 0 generic arguments
 
-error[E0107]: this trait takes 0 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: trait takes 0 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/typeck-builtin-bound-type-parameters.rs:10:25
    |
 LL | struct MyStruct2<'a, T: Copy<'a>>;
@@ -30,7 +30,7 @@ LL | struct MyStruct2<'a, T: Copy<'a>>;
    |                         |
    |                         expected 0 lifetime arguments
 
-error[E0107]: this trait takes 0 lifetime arguments but 1 lifetime argument was supplied
+error[E0107]: trait takes 0 lifetime arguments but 1 lifetime argument was supplied
   --> $DIR/typeck-builtin-bound-type-parameters.rs:13:15
    |
 LL | fn foo2<'a, T:Copy<'a, U>, U>(x: T) {}
@@ -38,7 +38,7 @@ LL | fn foo2<'a, T:Copy<'a, U>, U>(x: T) {}
    |               |
    |               expected 0 lifetime arguments
 
-error[E0107]: this trait takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/typeck-builtin-bound-type-parameters.rs:13:15
    |
 LL | fn foo2<'a, T:Copy<'a, U>, U>(x: T) {}
diff --git a/tests/ui/typeck/typeck_type_placeholder_item.rs b/tests/ui/typeck/typeck_type_placeholder_item.rs
index b96c5271339..a450dbb82d1 100644
--- a/tests/ui/typeck/typeck_type_placeholder_item.rs
+++ b/tests/ui/typeck/typeck_type_placeholder_item.rs
@@ -227,4 +227,6 @@ fn evens_squared(n: usize) -> _ {
 }
 
 const _: _ = (1..10).filter(|x| x % 2 == 0).map(|x| x * x);
-//~^ ERROR the placeholder `_` is not allowed within types on item signatures for constants
+//~^ ERROR the trait bound
+//~| ERROR the trait bound
+//~| ERROR the placeholder
diff --git a/tests/ui/typeck/typeck_type_placeholder_item.stderr b/tests/ui/typeck/typeck_type_placeholder_item.stderr
index bc02547c65e..bc6c9fd0779 100644
--- a/tests/ui/typeck/typeck_type_placeholder_item.stderr
+++ b/tests/ui/typeck/typeck_type_placeholder_item.stderr
@@ -437,17 +437,37 @@ LL | fn evens_squared(n: usize) -> _ {
    |                               not allowed in type signatures
    |                               help: replace with an appropriate return type: `impl Iterator<Item = usize>`
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for constants
-  --> $DIR/typeck_type_placeholder_item.rs:229:10
+error[E0277]: the trait bound `std::ops::Range<{integer}>: Iterator` is not satisfied
+  --> $DIR/typeck_type_placeholder_item.rs:229:22
    |
 LL | const _: _ = (1..10).filter(|x| x % 2 == 0).map(|x| x * x);
-   |          ^ not allowed in type signatures
+   |                      ^^^^^^ `std::ops::Range<{integer}>` is not an iterator
+   |
+   = help: the trait `~const Iterator` is not implemented for `std::ops::Range<{integer}>`
+note: the trait `Iterator` is implemented for `std::ops::Range<{integer}>`, but that implementation is not `const`
+  --> $DIR/typeck_type_placeholder_item.rs:229:14
+   |
+LL | const _: _ = (1..10).filter(|x| x % 2 == 0).map(|x| x * x);
+   |              ^^^^^^^
+
+error[E0277]: the trait bound `Filter<std::ops::Range<{integer}>, [closure@$DIR/typeck_type_placeholder_item.rs:229:29: 229:32]>: Iterator` is not satisfied
+  --> $DIR/typeck_type_placeholder_item.rs:229:45
    |
-note: however, the inferred type `Map<Filter<Range<i32>, [closure@typeck_type_placeholder_item.rs:229:29]>, [closure@typeck_type_placeholder_item.rs:229:49]>` cannot be named
+LL | const _: _ = (1..10).filter(|x| x % 2 == 0).map(|x| x * x);
+   |                                             ^^^ `Filter<std::ops::Range<{integer}>, [closure@$DIR/typeck_type_placeholder_item.rs:229:29: 229:32]>` is not an iterator
+   |
+   = help: the trait `~const Iterator` is not implemented for `Filter<std::ops::Range<{integer}>, [closure@$DIR/typeck_type_placeholder_item.rs:229:29: 229:32]>`
+note: the trait `Iterator` is implemented for `Filter<std::ops::Range<{integer}>, [closure@$DIR/typeck_type_placeholder_item.rs:229:29: 229:32]>`, but that implementation is not `const`
   --> $DIR/typeck_type_placeholder_item.rs:229:14
    |
 LL | const _: _ = (1..10).filter(|x| x % 2 == 0).map(|x| x * x);
-   |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for constants
+  --> $DIR/typeck_type_placeholder_item.rs:229:10
+   |
+LL | const _: _ = (1..10).filter(|x| x % 2 == 0).map(|x| x * x);
+   |          ^ not allowed in type signatures
 
 error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
   --> $DIR/typeck_type_placeholder_item.rs:140:31
@@ -657,7 +677,7 @@ LL |     const D: _ = 42;
    |              not allowed in type signatures
    |              help: replace with the correct type: `i32`
 
-error: aborting due to 71 previous errors
+error: aborting due to 73 previous errors
 
-Some errors have detailed explanations: E0121, E0282, E0403.
+Some errors have detailed explanations: E0121, E0277, E0282, E0403.
 For more information about an error, try `rustc --explain E0121`.
diff --git a/tests/ui/typeck/typeck_type_placeholder_lifetime_1.rs b/tests/ui/typeck/typeck_type_placeholder_lifetime_1.rs
index 43e46c5b6c3..90b12ffdf77 100644
--- a/tests/ui/typeck/typeck_type_placeholder_lifetime_1.rs
+++ b/tests/ui/typeck/typeck_type_placeholder_lifetime_1.rs
@@ -7,5 +7,5 @@ struct Foo<'a, T:'a> {
 
 pub fn main() {
     let c: Foo<_, _> = Foo { r: &5 };
-    //~^ ERROR this struct takes 1 generic argument but 2 generic arguments were supplied
+    //~^ ERROR struct takes 1 generic argument but 2 generic arguments were supplied
 }
diff --git a/tests/ui/typeck/typeck_type_placeholder_lifetime_1.stderr b/tests/ui/typeck/typeck_type_placeholder_lifetime_1.stderr
index a89c6b85c78..c4e4aed2067 100644
--- a/tests/ui/typeck/typeck_type_placeholder_lifetime_1.stderr
+++ b/tests/ui/typeck/typeck_type_placeholder_lifetime_1.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this struct takes 1 generic argument but 2 generic arguments were supplied
+error[E0107]: struct takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/typeck_type_placeholder_lifetime_1.rs:9:12
    |
 LL |     let c: Foo<_, _> = Foo { r: &5 };
diff --git a/tests/ui/typeck/typeck_type_placeholder_lifetime_2.rs b/tests/ui/typeck/typeck_type_placeholder_lifetime_2.rs
index 178b8b1229a..e361312ddba 100644
--- a/tests/ui/typeck/typeck_type_placeholder_lifetime_2.rs
+++ b/tests/ui/typeck/typeck_type_placeholder_lifetime_2.rs
@@ -7,5 +7,5 @@ struct Foo<'a, T:'a> {
 
 pub fn main() {
     let c: Foo<_, usize> = Foo { r: &5 };
-    //~^ ERROR this struct takes 1 generic argument but 2 generic arguments were supplied
+    //~^ ERROR struct takes 1 generic argument but 2 generic arguments were supplied
 }
diff --git a/tests/ui/typeck/typeck_type_placeholder_lifetime_2.stderr b/tests/ui/typeck/typeck_type_placeholder_lifetime_2.stderr
index f30766bdf01..302231777bd 100644
--- a/tests/ui/typeck/typeck_type_placeholder_lifetime_2.stderr
+++ b/tests/ui/typeck/typeck_type_placeholder_lifetime_2.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this struct takes 1 generic argument but 2 generic arguments were supplied
+error[E0107]: struct takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/typeck_type_placeholder_lifetime_2.rs:9:12
    |
 LL |     let c: Foo<_, usize> = Foo { r: &5 };
diff --git a/tests/ui/ufcs/ufcs-qpath-missing-params.rs b/tests/ui/ufcs/ufcs-qpath-missing-params.rs
index 766351634bb..6ab6580c0e6 100644
--- a/tests/ui/ufcs/ufcs-qpath-missing-params.rs
+++ b/tests/ui/ufcs/ufcs-qpath-missing-params.rs
@@ -15,6 +15,6 @@ fn main() {
       //~^ ERROR missing generics for
 
     <String as IntoCow>::into_cow::<str>("foo".to_string());
-    //~^ ERROR this associated function takes 0 generic arguments but 1
+    //~^ ERROR method takes 0 generic arguments but 1
     //~| ERROR missing generics for
 }
diff --git a/tests/ui/ufcs/ufcs-qpath-missing-params.stderr b/tests/ui/ufcs/ufcs-qpath-missing-params.stderr
index d0ec47d6132..2338871218b 100644
--- a/tests/ui/ufcs/ufcs-qpath-missing-params.stderr
+++ b/tests/ui/ufcs/ufcs-qpath-missing-params.stderr
@@ -30,7 +30,7 @@ help: add missing generic argument
 LL |     <String as IntoCow<B>>::into_cow::<str>("foo".to_string());
    |                       +++
 
-error[E0107]: this associated function takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: method takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/ufcs-qpath-missing-params.rs:17:26
    |
 LL |     <String as IntoCow>::into_cow::<str>("foo".to_string());
@@ -38,7 +38,7 @@ LL |     <String as IntoCow>::into_cow::<str>("foo".to_string());
    |                          |
    |                          expected 0 generic arguments
    |
-note: associated function defined here, with 0 generic parameters
+note: method defined here, with 0 generic parameters
   --> $DIR/ufcs-qpath-missing-params.rs:4:8
    |
 LL |     fn into_cow(self) -> Cow<'a, B>;
diff --git a/tests/ui/ufcs/ufcs-qpath-self-mismatch.stderr b/tests/ui/ufcs/ufcs-qpath-self-mismatch.stderr
index e85144a31ca..96ac4321689 100644
--- a/tests/ui/ufcs/ufcs-qpath-self-mismatch.stderr
+++ b/tests/ui/ufcs/ufcs-qpath-self-mismatch.stderr
@@ -28,7 +28,7 @@ LL |     <i32 as Add<i32>>::add(1u32, 2);
    |     ^^^^^^^^^^^^^^^^^^^^^^^----^^^^
    |                            |
    |                            this argument influences the return type of `Add`
-note: associated function defined here
+note: method defined here
   --> $SRC_DIR/core/src/ops/arith.rs:LL:COL
 help: change the type of the numeric literal from `u32` to `i32`
    |
@@ -50,7 +50,7 @@ LL |     <i32 as Add<i32>>::add(1, 2u32);
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^----^
    |                               |
    |                               this argument influences the return type of `Add`
-note: associated function defined here
+note: method defined here
   --> $SRC_DIR/core/src/ops/arith.rs:LL:COL
 help: change the type of the numeric literal from `u32` to `i32`
    |
diff --git a/tests/ui/unboxed-closures/unboxed-closure-sugar-region.rs b/tests/ui/unboxed-closures/unboxed-closure-sugar-region.rs
index 65f40075bd8..c575f507704 100644
--- a/tests/ui/unboxed-closures/unboxed-closure-sugar-region.rs
+++ b/tests/ui/unboxed-closures/unboxed-closure-sugar-region.rs
@@ -28,7 +28,7 @@ fn test<'a,'b>() {
 }
 
 fn test2(x: &dyn Foo<(isize,),Output=()>, y: &dyn Foo(isize)) {
-    //~^ ERROR this trait takes 1 lifetime argument but 0 lifetime arguments were supplied
+    //~^ ERROR trait takes 1 lifetime argument but 0 lifetime arguments were supplied
     // Here, the omitted lifetimes are expanded to distinct things.
     same_type(x, y)
 }
diff --git a/tests/ui/unboxed-closures/unboxed-closure-sugar-region.stderr b/tests/ui/unboxed-closures/unboxed-closure-sugar-region.stderr
index 016fc4dfb24..8814617814c 100644
--- a/tests/ui/unboxed-closures/unboxed-closure-sugar-region.stderr
+++ b/tests/ui/unboxed-closures/unboxed-closure-sugar-region.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this trait takes 1 lifetime argument but 0 lifetime arguments were supplied
+error[E0107]: trait takes 1 lifetime argument but 0 lifetime arguments were supplied
   --> $DIR/unboxed-closure-sugar-region.rs:30:51
    |
 LL | fn test2(x: &dyn Foo<(isize,),Output=()>, y: &dyn Foo(isize)) {
diff --git a/tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct-1.rs b/tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct-1.rs
index 462f6fb7b87..14d5646b508 100644
--- a/tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct-1.rs
+++ b/tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct-1.rs
@@ -7,7 +7,7 @@ struct Bar<A> {
 fn bar() {
     let x: Box<Bar()> = panic!();
     //~^ ERROR parenthesized type parameters may only be used with a `Fn` trait
-    //~| ERROR this struct takes 1 generic argument but 0 generic arguments
+    //~| ERROR struct takes 1 generic argument but 0 generic arguments
 }
 
 fn main() { }
diff --git a/tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct-1.stderr b/tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct-1.stderr
index 29ea5735cad..27b22c2127b 100644
--- a/tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct-1.stderr
+++ b/tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct-1.stderr
@@ -4,7 +4,7 @@ error[E0214]: parenthesized type parameters may only be used with a `Fn` trait
 LL |     let x: Box<Bar()> = panic!();
    |                ^^^^^ only `Fn` traits may use parentheses
 
-error[E0107]: this struct takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: struct takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/unboxed-closure-sugar-used-on-struct-1.rs:8:16
    |
 LL |     let x: Box<Bar()> = panic!();
diff --git a/tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct.rs b/tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct.rs
index bd61cbd8022..657b29204cd 100644
--- a/tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct.rs
+++ b/tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct.rs
@@ -6,7 +6,7 @@ struct Bar<A> {
 
 fn foo(b: Box<Bar()>) {
     //~^ ERROR parenthesized type parameters may only be used with a `Fn` trait
-    //~| ERROR this struct takes 1 generic argument but 0 generic arguments
+    //~| ERROR struct takes 1 generic argument but 0 generic arguments
 }
 
 fn main() { }
diff --git a/tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct.stderr b/tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct.stderr
index 427ba3414f8..94e42a66c9e 100644
--- a/tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct.stderr
+++ b/tests/ui/unboxed-closures/unboxed-closure-sugar-used-on-struct.stderr
@@ -4,7 +4,7 @@ error[E0214]: parenthesized type parameters may only be used with a `Fn` trait
 LL | fn foo(b: Box<Bar()>) {
    |               ^^^^^ only `Fn` traits may use parentheses
 
-error[E0107]: this struct takes 1 generic argument but 0 generic arguments were supplied
+error[E0107]: struct takes 1 generic argument but 0 generic arguments were supplied
   --> $DIR/unboxed-closure-sugar-used-on-struct.rs:7:15
    |
 LL | fn foo(b: Box<Bar()>) {
diff --git a/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters-3.rs b/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters-3.rs
index f26ad8e93a1..dd47ae73a38 100644
--- a/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters-3.rs
+++ b/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters-3.rs
@@ -3,7 +3,7 @@
 trait Three<A,B,C> { fn dummy(&self) -> (A,B,C); }
 
 fn foo(_: &dyn Three())
-//~^ ERROR this trait takes 3 generic arguments but 1 generic argument
+//~^ ERROR trait takes 3 generic arguments but 1 generic argument
 //~| ERROR associated type `Output` not found
 {}
 
diff --git a/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters-3.stderr b/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters-3.stderr
index ebaacf0a698..5d7fe3fa533 100644
--- a/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters-3.stderr
+++ b/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters-3.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this trait takes 3 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 3 generic arguments but 1 generic argument was supplied
   --> $DIR/unboxed-closure-sugar-wrong-number-number-type-parameters-3.rs:5:16
    |
 LL | fn foo(_: &dyn Three())
diff --git a/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters.rs b/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters.rs
index 4465b43a757..2c7e12f3257 100644
--- a/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters.rs
+++ b/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters.rs
@@ -3,25 +3,25 @@
 trait Zero { fn dummy(&self); }
 
 fn foo1(_: dyn Zero()) {
-    //~^ ERROR this trait takes 0 generic arguments but 1 generic argument
+    //~^ ERROR trait takes 0 generic arguments but 1 generic argument
     //~| ERROR associated type `Output` not found for `Zero`
 }
 
 fn foo2(_: dyn Zero<usize>) {
-    //~^ ERROR this trait takes 0 generic arguments but 1 generic argument
+    //~^ ERROR trait takes 0 generic arguments but 1 generic argument
 }
 
 fn foo3(_: dyn Zero <   usize   >) {
-    //~^ ERROR this trait takes 0 generic arguments but 1 generic argument
+    //~^ ERROR trait takes 0 generic arguments but 1 generic argument
 }
 
 fn foo4(_: dyn Zero(usize)) {
-    //~^ ERROR this trait takes 0 generic arguments but 1 generic argument
+    //~^ ERROR trait takes 0 generic arguments but 1 generic argument
     //~| ERROR associated type `Output` not found for `Zero`
 }
 
 fn foo5(_: dyn Zero (   usize   )) {
-    //~^ ERROR this trait takes 0 generic arguments but 1 generic argument
+    //~^ ERROR trait takes 0 generic arguments but 1 generic argument
     //~| ERROR associated type `Output` not found for `Zero`
 }
 
diff --git a/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters.stderr b/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters.stderr
index 9601e64c189..50b90553aa7 100644
--- a/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters.stderr
+++ b/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-number-number-type-parameters.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this trait takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/unboxed-closure-sugar-wrong-number-number-type-parameters.rs:5:16
    |
 LL | fn foo1(_: dyn Zero()) {
@@ -18,7 +18,7 @@ error[E0220]: associated type `Output` not found for `Zero`
 LL | fn foo1(_: dyn Zero()) {
    |                ^^^^^^ associated type `Output` not found
 
-error[E0107]: this trait takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/unboxed-closure-sugar-wrong-number-number-type-parameters.rs:10:16
    |
 LL | fn foo2(_: dyn Zero<usize>) {
@@ -32,7 +32,7 @@ note: trait defined here, with 0 generic parameters
 LL | trait Zero { fn dummy(&self); }
    |       ^^^^
 
-error[E0107]: this trait takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/unboxed-closure-sugar-wrong-number-number-type-parameters.rs:14:16
    |
 LL | fn foo3(_: dyn Zero <   usize   >) {
@@ -46,7 +46,7 @@ note: trait defined here, with 0 generic parameters
 LL | trait Zero { fn dummy(&self); }
    |       ^^^^
 
-error[E0107]: this trait takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/unboxed-closure-sugar-wrong-number-number-type-parameters.rs:18:16
    |
 LL | fn foo4(_: dyn Zero(usize)) {
@@ -66,7 +66,7 @@ error[E0220]: associated type `Output` not found for `Zero`
 LL | fn foo4(_: dyn Zero(usize)) {
    |                ^^^^^^^^^^^ associated type `Output` not found
 
-error[E0107]: this trait takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/unboxed-closure-sugar-wrong-number-number-type-parameters.rs:23:16
    |
 LL | fn foo5(_: dyn Zero (   usize   )) {
diff --git a/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-trait.rs b/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-trait.rs
index 4bcf90552f9..ad60b0a0c77 100644
--- a/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-trait.rs
+++ b/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-trait.rs
@@ -3,7 +3,7 @@
 trait Trait {}
 
 fn f<F:Trait(isize) -> isize>(x: F) {}
-//~^ ERROR this trait takes 0 generic arguments but 1 generic argument
+//~^ ERROR trait takes 0 generic arguments but 1 generic argument
 //~| ERROR associated type `Output` not found for `Trait`
 
 fn main() {}
diff --git a/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-trait.stderr b/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-trait.stderr
index 3ff05fb2331..130b193d69c 100644
--- a/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-trait.stderr
+++ b/tests/ui/unboxed-closures/unboxed-closure-sugar-wrong-trait.stderr
@@ -1,4 +1,4 @@
-error[E0107]: this trait takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: trait takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/unboxed-closure-sugar-wrong-trait.rs:5:8
    |
 LL | fn f<F:Trait(isize) -> isize>(x: F) {}
diff --git a/tests/ui/unboxed-closures/unboxed-closures-infer-fn-once-move-from-projection.stderr b/tests/ui/unboxed-closures/unboxed-closures-infer-fn-once-move-from-projection.stderr
index 635ebbb71d0..846a44ce4d7 100644
--- a/tests/ui/unboxed-closures/unboxed-closures-infer-fn-once-move-from-projection.stderr
+++ b/tests/ui/unboxed-closures/unboxed-closures-infer-fn-once-move-from-projection.stderr
@@ -14,7 +14,7 @@ note: required by a bound in `foo`
   --> $DIR/unboxed-closures-infer-fn-once-move-from-projection.rs:4:14
    |
 LL | fn foo<F>(f: F)
-   |    --- required by a bound in this
+   |    --- required by a bound in this function
 LL |     where F: Fn()
    |              ^^^^ required by this bound in `foo`
 
diff --git a/tests/ui/unsized/issue-71659.stderr b/tests/ui/unsized/issue-71659.stderr
index d7b95f55769..b57b3015e47 100644
--- a/tests/ui/unsized/issue-71659.stderr
+++ b/tests/ui/unsized/issue-71659.stderr
@@ -8,7 +8,7 @@ note: required by a bound in `Cast::cast`
   --> $DIR/issue-71659.rs:19:15
    |
 LL |     fn cast<T: ?Sized>(&self) -> &T
-   |        ---- required by a bound in this
+   |        ---- required by a bound in this associated function
 LL |     where
 LL |         Self: CastTo<T>,
    |               ^^^^^^^^^ required by this bound in `Cast::cast`
diff --git a/tests/ui/where-clauses/higher-ranked-fn-type.quiet.stderr b/tests/ui/where-clauses/higher-ranked-fn-type.quiet.stderr
index 30248a7a397..191a8ca8ebc 100644
--- a/tests/ui/where-clauses/higher-ranked-fn-type.quiet.stderr
+++ b/tests/ui/where-clauses/higher-ranked-fn-type.quiet.stderr
@@ -8,7 +8,7 @@ note: required by a bound in `called`
   --> $DIR/higher-ranked-fn-type.rs:12:25
    |
 LL | fn called()
-   |    ------ required by a bound in this
+   |    ------ required by a bound in this function
 LL | where
 LL |     for<'b> fn(&'b ()): Foo,
    |                         ^^^ required by this bound in `called`
diff --git a/tests/ui/where-clauses/higher-ranked-fn-type.verbose.stderr b/tests/ui/where-clauses/higher-ranked-fn-type.verbose.stderr
index 268cef6e275..f4c7acd5c58 100644
--- a/tests/ui/where-clauses/higher-ranked-fn-type.verbose.stderr
+++ b/tests/ui/where-clauses/higher-ranked-fn-type.verbose.stderr
@@ -8,7 +8,7 @@ note: required by a bound in `called`
   --> $DIR/higher-ranked-fn-type.rs:12:25
    |
 LL | fn called()
-   |    ------ required by a bound in this
+   |    ------ required by a bound in this function
 LL | where
 LL |     for<'b> fn(&'b ()): Foo,
    |                         ^^^ required by this bound in `called`
diff --git a/tests/ui/xc-private-method2.rs b/tests/ui/xc-private-method2.rs
index 92946923f6e..f11b251082b 100644
--- a/tests/ui/xc-private-method2.rs
+++ b/tests/ui/xc-private-method2.rs
@@ -4,8 +4,8 @@ extern crate xc_private_method_lib;
 
 fn main() {
     let _ = xc_private_method_lib::Struct{ x: 10 }.meth_struct();
-    //~^ ERROR associated function `meth_struct` is private
+    //~^ ERROR method `meth_struct` is private
 
     let _ = xc_private_method_lib::Enum::Variant1(20).meth_enum();
-    //~^ ERROR associated function `meth_enum` is private
+    //~^ ERROR method `meth_enum` is private
 }
diff --git a/tests/ui/xc-private-method2.stderr b/tests/ui/xc-private-method2.stderr
index b569882f8c1..af0c3cfcb2c 100644
--- a/tests/ui/xc-private-method2.stderr
+++ b/tests/ui/xc-private-method2.stderr
@@ -1,24 +1,24 @@
-error[E0624]: associated function `meth_struct` is private
+error[E0624]: method `meth_struct` is private
   --> $DIR/xc-private-method2.rs:6:52
    |
 LL |     let _ = xc_private_method_lib::Struct{ x: 10 }.meth_struct();
-   |                                                    ^^^^^^^^^^^ private associated function
+   |                                                    ^^^^^^^^^^^ private method
    |
   ::: $DIR/auxiliary/xc-private-method-lib.rs:12:5
    |
 LL |     fn meth_struct(&self) -> isize {
-   |     ------------------------------ private associated function defined here
+   |     ------------------------------ private method defined here
 
-error[E0624]: associated function `meth_enum` is private
+error[E0624]: method `meth_enum` is private
   --> $DIR/xc-private-method2.rs:9:55
    |
 LL |     let _ = xc_private_method_lib::Enum::Variant1(20).meth_enum();
-   |                                                       ^^^^^^^^^ private associated function
+   |                                                       ^^^^^^^^^ private method
    |
   ::: $DIR/auxiliary/xc-private-method-lib.rs:27:5
    |
 LL |     fn meth_enum(&self) -> isize {
-   |     ---------------------------- private associated function defined here
+   |     ---------------------------- private method defined here
 
 error: aborting due to 2 previous errors