@@ -12,7 +12,7 @@ LL | | }
12
12
|
13
13
= note: `-D clippy::large-enum-variant` implied by `-D warnings`
14
14
= help: to override `-D warnings` add `#[allow(clippy::large_enum_variant)]`
15
- help: consider boxing the large fields to reduce the total size of the enum
15
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
16
16
|
17
17
LL - B([i32; 8000]),
18
18
LL + B(Box<[i32; 8000]>),
@@ -30,7 +30,7 @@ LL | | ContainingLargeEnum(LargeEnum),
30
30
LL | | }
31
31
| |_^ the entire enum is at least 32004 bytes
32
32
|
33
- help: consider boxing the large fields to reduce the total size of the enum
33
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
34
34
|
35
35
LL - ContainingLargeEnum(LargeEnum),
36
36
LL + ContainingLargeEnum(Box<LargeEnum>),
@@ -49,7 +49,7 @@ LL | | StructLikeLittle { x: i32, y: i32 },
49
49
LL | | }
50
50
| |_^ the entire enum is at least 70008 bytes
51
51
|
52
- help: consider boxing the large fields to reduce the total size of the enum
52
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
53
53
|
54
54
LL - ContainingMoreThanOneField(i32, [i32; 8000], [i32; 9500]),
55
55
LL + ContainingMoreThanOneField(i32, Box<[i32; 8000]>, Box<[i32; 9500]>),
@@ -67,7 +67,7 @@ LL | | StructLikeLarge { x: [i32; 8000], y: i32 },
67
67
LL | | }
68
68
| |_^ the entire enum is at least 32008 bytes
69
69
|
70
- help: consider boxing the large fields to reduce the total size of the enum
70
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
71
71
|
72
72
LL - StructLikeLarge { x: [i32; 8000], y: i32 },
73
73
LL + StructLikeLarge { x: Box<[i32; 8000]>, y: i32 },
@@ -85,7 +85,7 @@ LL | | StructLikeLarge2 { x: [i32; 8000] },
85
85
LL | | }
86
86
| |_^ the entire enum is at least 32004 bytes
87
87
|
88
- help: consider boxing the large fields to reduce the total size of the enum
88
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
89
89
|
90
90
LL - StructLikeLarge2 { x: [i32; 8000] },
91
91
LL + StructLikeLarge2 { x: Box<[i32; 8000]> },
@@ -104,7 +104,7 @@ LL | | C([u8; 200]),
104
104
LL | | }
105
105
| |_^ the entire enum is at least 1256 bytes
106
106
|
107
- help: consider boxing the large fields to reduce the total size of the enum
107
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
108
108
|
109
109
LL - B([u8; 1255]),
110
110
LL + B(Box<[u8; 1255]>),
@@ -122,7 +122,7 @@ LL | | ContainingMoreThanOneField([i32; 8000], [i32; 2], [i32; 9500], [i32;
122
122
LL | | }
123
123
| |_^ the entire enum is at least 70132 bytes
124
124
|
125
- help: consider boxing the large fields to reduce the total size of the enum
125
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
126
126
|
127
127
LL - ContainingMoreThanOneField([i32; 8000], [i32; 2], [i32; 9500], [i32; 30]),
128
128
LL + ContainingMoreThanOneField(Box<[i32; 8000]>, [i32; 2], Box<[i32; 9500]>, [i32; 30]),
@@ -140,7 +140,7 @@ LL | | B(Struct2),
140
140
LL | | }
141
141
| |_^ the entire enum is at least 32004 bytes
142
142
|
143
- help: consider boxing the large fields to reduce the total size of the enum
143
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
144
144
|
145
145
LL - B(Struct2),
146
146
LL + B(Box<Struct2>),
@@ -158,7 +158,7 @@ LL | | B(Struct2),
158
158
LL | | }
159
159
| |_^ the entire enum is at least 32000 bytes
160
160
|
161
- help: consider boxing the large fields to reduce the total size of the enum
161
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
162
162
|
163
163
LL - B(Struct2),
164
164
LL + B(Box<Struct2>),
@@ -176,7 +176,7 @@ LL | | B(Struct2),
176
176
LL | | }
177
177
| |_^ the entire enum is at least 32000 bytes
178
178
|
179
- help: consider boxing the large fields to reduce the total size of the enum
179
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
180
180
|
181
181
LL - B(Struct2),
182
182
LL + B(Box<Struct2>),
@@ -199,7 +199,7 @@ note: boxing a variant would require the type no longer be `Copy`
199
199
|
200
200
LL | enum CopyableLargeEnum {
201
201
| ^^^^^^^^^^^^^^^^^
202
- help: consider boxing the large fields to reduce the total size of the enum
202
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
203
203
--> tests/ui/large_enum_variant.rs:118:5
204
204
|
205
205
LL | B([u64; 8000]),
@@ -222,7 +222,7 @@ note: boxing a variant would require the type no longer be `Copy`
222
222
|
223
223
LL | enum ManuallyCopyLargeEnum {
224
224
| ^^^^^^^^^^^^^^^^^^^^^
225
- help: consider boxing the large fields to reduce the total size of the enum
225
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
226
226
--> tests/ui/large_enum_variant.rs:124:5
227
227
|
228
228
LL | B([u64; 8000]),
@@ -245,7 +245,7 @@ note: boxing a variant would require the type no longer be `Copy`
245
245
|
246
246
LL | enum SomeGenericPossiblyCopyEnum<T> {
247
247
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
248
- help: consider boxing the large fields to reduce the total size of the enum
248
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
249
249
--> tests/ui/large_enum_variant.rs:138:5
250
250
|
251
251
LL | B([u64; 4000]),
@@ -263,7 +263,7 @@ LL | | Large((T, [u8; 512])),
263
263
LL | | }
264
264
| |_^ the entire enum is at least 512 bytes
265
265
|
266
- help: consider boxing the large fields to reduce the total size of the enum
266
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
267
267
|
268
268
LL - Large((T, [u8; 512])),
269
269
LL + Large(Box<(T, [u8; 512])>),
@@ -281,7 +281,7 @@ LL | | Small(u8),
281
281
LL | | }
282
282
| |_^ the entire enum is at least 520 bytes
283
283
|
284
- help: consider boxing the large fields to reduce the total size of the enum
284
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
285
285
|
286
286
LL - Large([Foo<u64>; 64]),
287
287
LL + Large(Box<[Foo<u64>; 64]>),
@@ -299,7 +299,7 @@ LL | | Error(PossiblyLargeEnumWithConst<256>),
299
299
LL | | }
300
300
| |_^ the entire enum is at least 514 bytes
301
301
|
302
- help: consider boxing the large fields to reduce the total size of the enum
302
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
303
303
|
304
304
LL - Error(PossiblyLargeEnumWithConst<256>),
305
305
LL + Error(Box<PossiblyLargeEnumWithConst<256>>),
@@ -317,7 +317,7 @@ LL | | Recursive(Box<WithRecursion>),
317
317
LL | | }
318
318
| |_^ the entire enum is at least 520 bytes
319
319
|
320
- help: consider boxing the large fields to reduce the total size of the enum
320
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
321
321
|
322
322
LL - Large([u64; 64]),
323
323
LL + Large(Box<[u64; 64]>),
@@ -335,7 +335,7 @@ LL | | Error(WithRecursionAndGenerics<u64>),
335
335
LL | | }
336
336
| |_^ the entire enum is at least 520 bytes
337
337
|
338
- help: consider boxing the large fields to reduce the total size of the enum
338
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
339
339
|
340
340
LL - Error(WithRecursionAndGenerics<u64>),
341
341
LL + Error(Box<WithRecursionAndGenerics<u64>>),
@@ -353,7 +353,7 @@ LL | | _SmallBoi(u8),
353
353
LL | | }
354
354
| |_____^ the entire enum is at least 296 bytes
355
355
|
356
- help: consider boxing the large fields to reduce the total size of the enum
356
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
357
357
|
358
358
LL - BigBoi(PublishWithBytes),
359
359
LL + BigBoi(Box<PublishWithBytes>),
@@ -371,7 +371,7 @@ LL | | _SmallBoi(u8),
371
371
LL | | }
372
372
| |_____^ the entire enum is at least 224 bytes
373
373
|
374
- help: consider boxing the large fields to reduce the total size of the enum
374
+ help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
375
375
|
376
376
LL - BigBoi(PublishWithVec),
377
377
LL + BigBoi(Box<PublishWithVec>),
0 commit comments