rust/tests/ui/lint/dead-code/lint-dead-code-4.stderr

67 lines
1.2 KiB
Plaintext
Raw Normal View History

error: field `b` is never read
2018-12-25 09:56:47 -06:00
--> $DIR/lint-dead-code-4.rs:7:5
2018-08-08 07:28:26 -05:00
|
LL | struct Foo {
| --- field in this struct
LL | x: usize,
2019-03-09 06:03:44 -06:00
LL | b: bool,
2022-06-22 13:33:59 -05:00
| ^
2018-08-08 07:28:26 -05:00
|
2020-01-22 17:57:38 -06:00
note: the lint level is defined here
2018-12-25 09:56:47 -06:00
--> $DIR/lint-dead-code-4.rs:3:9
2018-08-08 07:28:26 -05:00
|
LL | #![deny(dead_code)]
| ^^^^^^^^^
error: variants `X` and `Y` are never constructed
2018-12-25 09:56:47 -06:00
--> $DIR/lint-dead-code-4.rs:15:5
2018-08-08 07:28:26 -05:00
|
2022-06-22 13:33:59 -05:00
LL | enum XYZ {
| --- variants in this enum
LL | X,
| ^
LL | Y {
| ^
2018-08-08 07:28:26 -05:00
error: enum `ABC` is never used
--> $DIR/lint-dead-code-4.rs:24:6
2018-08-08 07:28:26 -05:00
|
2019-03-09 06:03:44 -06:00
LL | enum ABC {
| ^^^
2018-08-08 07:28:26 -05:00
error: fields `b` and `c` are never read
2018-12-25 09:56:47 -06:00
--> $DIR/lint-dead-code-4.rs:39:9
2018-08-08 07:28:26 -05:00
|
LL | J {
| - fields in this variant
LL | a: String,
2019-03-09 06:03:44 -06:00
LL | b: i32,
2022-06-22 13:33:59 -05:00
| ^
2019-03-09 06:03:44 -06:00
LL | c: i32,
2022-06-22 13:33:59 -05:00
| ^
2018-08-08 07:28:26 -05:00
error: variants `I` and `K` are never constructed
--> $DIR/lint-dead-code-4.rs:36:5
2018-08-08 07:28:26 -05:00
|
LL | enum IJK {
| --- variants in this enum
LL | I,
| ^
...
2019-03-09 06:03:44 -06:00
LL | K
2018-08-08 07:28:26 -05:00
| ^
error: fields `x` and `c` are never read
2018-12-25 09:56:47 -06:00
--> $DIR/lint-dead-code-4.rs:61:5
2018-08-08 07:28:26 -05:00
|
LL | struct Bar {
| --- fields in this struct
2019-03-09 06:03:44 -06:00
LL | x: usize,
2022-06-22 13:33:59 -05:00
| ^
LL | b: bool,
2019-03-09 06:03:44 -06:00
LL | c: bool,
2022-06-22 13:33:59 -05:00
| ^
2018-08-08 07:28:26 -05:00
error: aborting due to 6 previous errors
2018-08-08 07:28:26 -05:00