rust/tests/ui/hygiene
Esteban Küber 5de8e6edfc Tweak output of import suggestions
When both `std::` and `core::` items are available, only suggest the
`std::` ones. We ensure that in `no_std` crates we suggest `core::`
items.

Ensure that the list of items suggested to be imported are always in the
order of local crate items, `std`/`core` items and finally foreign crate
items.

Tweak wording of import suggestion: if there are multiple items but they
are all of the same kind, we use the kind name and not the generic "items".

Fix #83564.
2024-06-13 20:22:21 +00:00
..
auxiliary [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
arguments.rs
arguments.stderr
assoc_item_ctxt.rs
assoc_item_ctxt.stderr
assoc_ty_bindings.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
cross-crate-codegen-attrs.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
cross-crate-define-and-use.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
cross-crate-fields.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
cross-crate-glob-hygiene.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
cross-crate-glob-hygiene.stderr
cross-crate-methods.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
cross-crate-name-collision.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
cross-crate-name-hiding-2.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
cross-crate-name-hiding-2.stderr
cross-crate-name-hiding.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
cross-crate-name-hiding.stderr
cross-crate-redefine.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
cross-crate-redefine.stderr
cross-crate-variants.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
dollar-crate-modern.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
duplicate_lifetimes.rs
duplicate_lifetimes.stderr
eager-from-opaque-2.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
eager-from-opaque.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
expansion-info-reset.rs
expansion-info-reset.stderr
extern-prelude-from-opaque-fail-2018.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
extern-prelude-from-opaque-fail-2018.stderr Tweak output of import suggestions 2024-06-13 20:22:21 +00:00
extern-prelude-from-opaque-fail.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
extern-prelude-from-opaque-fail.stderr
fields-definition.rs
fields-definition.stderr
fields-move.rs
fields-move.stderr
fields-numeric-borrowck.rs
fields-numeric-borrowck.stderr
fields.rs
fields.stderr
for-loop.rs
for-loop.stderr
format-args.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
generate-mod.rs
generate-mod.stderr
generic_params.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
globs.rs
globs.stderr
hir-res-hygiene.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
hygiene-dodging-1.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
hygiene.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
hygienic-label-1.rs
hygienic-label-1.stderr
hygienic-label-2.rs
hygienic-label-2.stderr
hygienic-label-3.rs
hygienic-label-3.stderr
hygienic-label-4.rs
hygienic-label-4.stderr
hygienic-labels-in-let.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
hygienic-labels.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
impl_items-2.rs
impl_items-2.stderr
impl_items.rs
impl_items.stderr
intercrate.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
intercrate.stderr
issue-15221.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-29746.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-32922.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-40847.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-44128.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-47311.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-47312.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-61574-const-parameters.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-77523-def-site-async-await.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
items.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
lambda-var-hygiene.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
legacy_interaction.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
lexical.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
local_inner_macros.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
macro-metavars-legacy.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
macro-metavars-transparent.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
missing-self-diag.rs
missing-self-diag.stderr
nested_macro_privacy.rs
nested_macro_privacy.stderr
nested-dollar-crate.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
no_implicit_prelude-2018.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
no_implicit_prelude-2018.stderr
no_implicit_prelude-2021.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
no_implicit_prelude.rs
no_implicit_prelude.stderr Tweak wording of "implemented trait isn't imported" suggestion 2024-02-22 18:05:27 +00:00
panic-location.rs RawVec::into_box: avoid unnecessary intermediate reference 2024-03-10 18:07:34 +01:00
panic-location.run.stderr RawVec::into_box: avoid unnecessary intermediate reference 2024-03-10 18:07:34 +01:00
pattern-macro.rs
pattern-macro.stderr
prelude-import-hygiene.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
privacy-early.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
privacy-early.stderr
privacy.rs
privacy.stderr
rustc-macro-transparency.rs
rustc-macro-transparency.stderr
specialization.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
stdlib-prelude-from-opaque-early.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
stdlib-prelude-from-opaque-late.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
thread-local-not-in-prelude.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
trait_items-2.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
trait_items.rs
trait_items.stderr Tweak wording of "implemented trait isn't imported" suggestion 2024-02-22 18:05:27 +00:00
traits-in-scope.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
transparent-basic.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
unpretty-debug.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
unpretty-debug.stdout [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
wrap_unhygienic_example.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
xcrate.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00