]> git.proxmox.com Git - rustc.git/blame - src/tools/clippy/tests/ui/large_enum_variant.stderr
New upstream version 1.57.0+dfsg1
[rustc.git] / src / tools / clippy / tests / ui / large_enum_variant.stderr
CommitLineData
f20569fa
XL
1error: large size difference between variants
2 --> $DIR/large_enum_variant.rs:12:5
3 |
4LL | B([i32; 8000]),
5 | ^^^^^^^^^^^^^^ this variant is 32000 bytes
6 |
7 = note: `-D clippy::large-enum-variant` implied by `-D warnings`
8note: and the second-largest variant is 4 bytes:
9 --> $DIR/large_enum_variant.rs:11:5
10 |
11LL | A(i32),
12 | ^^^^^^
13help: consider boxing the large fields to reduce the total size of the enum
14 |
15LL | B(Box<[i32; 8000]>),
94222f64 16 | ~~~~~~~~~~~~~~~~
f20569fa
XL
17
18error: large size difference between variants
19 --> $DIR/large_enum_variant.rs:36:5
20 |
21LL | ContainingLargeEnum(LargeEnum),
22 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ this variant is 32004 bytes
23 |
24note: and the second-largest variant is 8 bytes:
25 --> $DIR/large_enum_variant.rs:35:5
26 |
27LL | VariantOk(i32, u32),
28 | ^^^^^^^^^^^^^^^^^^^
29help: consider boxing the large fields to reduce the total size of the enum
30 |
31LL | ContainingLargeEnum(Box<LargeEnum>),
94222f64 32 | ~~~~~~~~~~~~~~
f20569fa
XL
33
34error: large size difference between variants
c295e0f8
XL
35 --> $DIR/large_enum_variant.rs:40:5
36 |
37LL | ContainingMoreThanOneField(i32, [i32; 8000], [i32; 9500]),
38 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ this variant is 70004 bytes
39 |
40note: and the second-largest variant is 8 bytes:
41 --> $DIR/large_enum_variant.rs:42:5
42 |
43LL | StructLikeLittle { x: i32, y: i32 },
44 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
45help: consider boxing the large fields to reduce the total size of the enum
46 |
47LL | ContainingMoreThanOneField(i32, Box<[i32; 8000]>, Box<[i32; 9500]>),
48 | ~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~
49
50error: large size difference between variants
51 --> $DIR/large_enum_variant.rs:47:5
f20569fa
XL
52 |
53LL | StructLikeLarge { x: [i32; 8000], y: i32 },
54 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ this variant is 32004 bytes
55 |
56note: and the second-largest variant is 8 bytes:
c295e0f8 57 --> $DIR/large_enum_variant.rs:46:5
f20569fa
XL
58 |
59LL | VariantOk(i32, u32),
60 | ^^^^^^^^^^^^^^^^^^^
61help: consider boxing the large fields to reduce the total size of the enum
f20569fa 62 |
c295e0f8
XL
63LL | StructLikeLarge { x: Box<[i32; 8000]>, y: i32 },
64 | ~~~~~~~~~~~~~~~~
f20569fa
XL
65
66error: large size difference between variants
c295e0f8 67 --> $DIR/large_enum_variant.rs:52:5
f20569fa
XL
68 |
69LL | StructLikeLarge2 { x: [i32; 8000] },
70 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ this variant is 32000 bytes
71 |
72note: and the second-largest variant is 8 bytes:
c295e0f8 73 --> $DIR/large_enum_variant.rs:51:5
f20569fa
XL
74 |
75LL | VariantOk(i32, u32),
76 | ^^^^^^^^^^^^^^^^^^^
77help: consider boxing the large fields to reduce the total size of the enum
78 |
79LL | StructLikeLarge2 { x: Box<[i32; 8000]> },
94222f64 80 | ~~~~~~~~~~~~~~~~
f20569fa 81
c295e0f8
XL
82error: large size difference between variants
83 --> $DIR/large_enum_variant.rs:68:5
84 |
85LL | B([u8; 1255]),
86 | ^^^^^^^^^^^^^ this variant is 1255 bytes
87 |
88note: and the second-largest variant is 200 bytes:
89 --> $DIR/large_enum_variant.rs:69:5
90 |
91LL | C([u8; 200]),
92 | ^^^^^^^^^^^^
93help: consider boxing the large fields to reduce the total size of the enum
94 |
95LL | B(Box<[u8; 1255]>),
96 | ~~~~~~~~~~~~~~~
97
98error: large size difference between variants
99 --> $DIR/large_enum_variant.rs:74:5
100 |
101LL | ContainingMoreThanOneField([i32; 8000], [i32; 2], [i32; 9500], [i32; 30]),
102 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ this variant is 70128 bytes
103 |
104note: and the second-largest variant is 8 bytes:
105 --> $DIR/large_enum_variant.rs:73:5
106 |
107LL | VariantOk(i32, u32),
108 | ^^^^^^^^^^^^^^^^^^^
109help: consider boxing the large fields to reduce the total size of the enum
110 |
111LL | ContainingMoreThanOneField(Box<[i32; 8000]>, [i32; 2], Box<[i32; 9500]>, [i32; 30]),
112 | ~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~
113
114error: aborting due to 7 previous errors
f20569fa 115