rust/tests/ui/did_you_mean/dont-suggest-hygienic-fields.stderr

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

55 lines
1.7 KiB
Plaintext
Raw Normal View History

2023-10-04 12:10:35 -05:00
error[E0560]: struct `Crate` has no field named `fiel`
--> $DIR/dont-suggest-hygienic-fields.rs:44:34
|
LL | environment!();
| -------------- in this macro invocation
...
LL | const CRATE: Crate = Crate { fiel: () };
2023-11-17 18:40:11 -06:00
| ^^^^ unknown field
2023-10-04 12:10:35 -05:00
|
= note: this error originates in the macro `environment` (in Nightly builds, run with -Z macro-backtrace for more info)
2023-11-17 18:40:11 -06:00
help: a field with a similar name exists
|
LL | const CRATE: Crate = Crate { field: () };
| ~~~~~
2023-10-04 12:10:35 -05:00
error[E0609]: no field `field` on type `Compound`
--> $DIR/dont-suggest-hygienic-fields.rs:24:16
|
LL | let _ = ty.field;
2023-11-09 00:01:10 -06:00
| ^^^^^ unknown field
2023-10-04 12:10:35 -05:00
error[E0609]: no field `fieeld` on type `Compound`
--> $DIR/dont-suggest-hygienic-fields.rs:25:16
|
LL | let _ = ty.fieeld;
2023-11-09 00:01:10 -06:00
| ^^^^^^ unknown field
2023-10-04 12:10:35 -05:00
error[E0026]: struct `Compound` does not have a field named `field`
--> $DIR/dont-suggest-hygienic-fields.rs:27:20
|
LL | let Compound { field } = ty;
| ^^^^^ struct `Compound` does not have this field
error: pattern requires `..` due to inaccessible fields
--> $DIR/dont-suggest-hygienic-fields.rs:27:9
|
LL | let Compound { field } = ty;
| ^^^^^^^^^^^^^^^^^^
|
help: ignore the inaccessible and unused fields
|
LL | let Compound { field, .. } = ty;
| ++++
error[E0609]: no field `0` on type `Component`
--> $DIR/dont-suggest-hygienic-fields.rs:34:16
|
LL | let _ = ty.0;
2023-11-09 00:01:10 -06:00
| ^ unknown field
2023-10-04 12:10:35 -05:00
error: aborting due to 6 previous errors
Some errors have detailed explanations: E0026, E0560, E0609.
For more information about an error, try `rustc --explain E0026`.