summaryrefslogtreecommitdiffstats
path: root/src/test/ui/lint/dead-code/tuple-struct-field.stderr
blob: ca0989f5b987f145864975465db9f0935fd0b603 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
error: field `1` is never read
  --> $DIR/tuple-struct-field.rs:8:26
   |
LL | struct SingleUnused(i32, [u8; LEN], String);
   |        ------------      ^^^^^^^^^
   |        |
   |        field in this struct
   |
note: the lint level is defined here
  --> $DIR/tuple-struct-field.rs:1:9
   |
LL | #![deny(unused_tuple_struct_fields)]
   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^
help: consider changing the field to be of unit type to suppress this warning while preserving the field numbering, or remove the field
   |
LL | struct SingleUnused(i32, (), String);
   |                          ~~

error: fields `0`, `1`, `2` and `3` are never read
  --> $DIR/tuple-struct-field.rs:13:23
   |
LL | struct MultipleUnused(i32, f32, String, u8);
   |        -------------- ^^^  ^^^  ^^^^^^  ^^
   |        |
   |        fields in this struct
   |
help: consider changing the fields to be of unit type to suppress this warning while preserving the field numbering, or remove the fields
   |
LL | struct MultipleUnused((), (), (), ());
   |                       ~~  ~~  ~~  ~~

error: aborting due to 2 previous errors