rust/tests/ui/diagnostic-width
Esteban Küber 26c12c7462 Account for bare tuples in field searching logic
When looking for the field names and types of a given type, account for tuples. This allows suggestions for incorrectly nested field accesses and field name typos to trigger as intended. Previously these suggestions only worked on `ty::Adt`, including tuple structs which are no different to tuples, so they should behave the same in suggestions.

```
error[E0599]: no method named `get_ref` found for tuple `(BufReader<File>,)` in the current scope
  --> $DIR/missing-field-access.rs:11:15
   |
LL |     let x = f.get_ref();
   |               ^^^^^^^ method not found in `(BufReader<File>,)`
   |
help: one of the expressions' fields has a method of the same name
   |
LL |     let x = f.0.get_ref();
   |               ++
```
2025-08-07 21:39:00 +00:00
..
auxiliary Create AnnotationColumn struct to fix hard tab column numbers in errors 2023-03-28 09:18:55 -04:00
binop.rs tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
binop.stderr tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
command-line-error-format-human.rs cleaned up some tests 2025-06-05 20:03:29 +05:00
command-line-error-format-human.stderr cleaned up some tests 2025-06-05 20:03:29 +05:00
E0271.ascii.stderr tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
E0271.rs tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
E0271.unicode.stderr tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
flag-human.ascii.stderr Add Unicode block-drawing compiler output support 2024-11-10 23:57:18 +01:00
flag-human.rs Don't allow -Zunstable-options to take a value 2024-11-18 18:04:59 +11:00
flag-human.unicode.stderr Add Unicode block-drawing compiler output support 2024-11-10 23:57:18 +01:00
flag-json.rs compiletest: Support matching on non-json lines in compiler output 2025-05-04 18:27:45 +03:00
flag-json.stderr compiletest: Support matching on non-json lines in compiler output 2025-05-04 18:27:45 +03:00
impl-trait-invalid-iterator-error.rs cleaned up some tests 2025-06-08 01:14:05 +05:00
impl-trait-invalid-iterator-error.stderr cleaned up some tests 2025-06-08 01:14:05 +05:00
long-e0277.rs tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
long-e0277.stderr tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
long-E0308.ascii.stderr tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
long-E0308.rs tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
long-E0308.unicode.stderr tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
long-E0529.rs compiletest: Make diagnostic kind mandatory on line annotations 2025-04-30 10:44:24 +03:00
long-E0529.stderr compiletest: Make diagnostic kind mandatory on line annotations 2025-04-30 10:44:24 +03:00
long-E0609.rs tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
long-E0609.stderr Account for bare tuples in field searching logic 2025-08-07 21:39:00 +00:00
long-E0614.rs tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
long-E0614.stderr tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
long-E0618.rs compiletest: Make diagnostic kind mandatory on line annotations 2025-04-30 10:44:24 +03:00
long-E0618.stderr compiletest: Make diagnostic kind mandatory on line annotations 2025-04-30 10:44:24 +03:00
long-span.long.stderr Make trimming logic work on more than one span at a time 2025-03-07 17:55:08 +00:00
long-span.longest.stderr Make trimming logic work on more than one span at a time 2025-03-07 17:55:08 +00:00
long-span.rs Make trimming logic work on more than one span at a time 2025-03-07 17:55:08 +00:00
long-span.short.stderr Make trimming logic work on more than one span at a time 2025-03-07 17:55:08 +00:00
long-span.shortest.stderr Make trimming logic work on more than one span at a time 2025-03-07 17:55:08 +00:00
non-1-width-unicode-multiline-label.ascii.stderr Refactor emitter to better account for unicode chars when trimming 2025-03-07 17:55:08 +00:00
non-1-width-unicode-multiline-label.rs Refactor emitter to better account for unicode chars when trimming 2025-03-07 17:55:08 +00:00
non-1-width-unicode-multiline-label.unicode.stderr Refactor emitter to better account for unicode chars when trimming 2025-03-07 17:55:08 +00:00
non-copy-type-moved.rs tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
non-copy-type-moved.stderr tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
non-whitespace-trimming-2.ascii.stderr Add Unicode block-drawing compiler output support 2024-11-10 23:57:18 +01:00
non-whitespace-trimming-2.rs Don't allow -Zunstable-options to take a value 2024-11-18 18:04:59 +11:00
non-whitespace-trimming-2.unicode.stderr Add Unicode block-drawing compiler output support 2024-11-10 23:57:18 +01:00
non-whitespace-trimming-unicode.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
non-whitespace-trimming-unicode.stderr Bless unicode test 2025-06-16 07:30:09 -04:00
non-whitespace-trimming.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
non-whitespace-trimming.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
secondary-label-with-long-type.rs tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
secondary-label-with-long-type.stderr tests: remove explicit long type filename hash normalization from some ui tests 2025-03-04 00:21:02 +08:00
tab-column-numbers.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
tab-column-numbers.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
tabs-trimming.rs Continue to borrowck even if there were previous errors 2024-02-08 08:10:43 +00:00
tabs-trimming.stderr Do not suggest using -Zmacro-backtrace for builtin macros 2025-03-14 19:50:03 +00:00
whitespace-trimming-2.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
whitespace-trimming-2.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
whitespace-trimming.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
whitespace-trimming.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00