Debian Codegraph @

debian/rust-vendor/zerocopy-derive/tests/ui/enum.msrv.stderr

raw
1 error: unrecognized representation hint
2 --> $DIR/enum.rs:20:8
3 |
4 20 | #[repr("foo")]
5 | ^^^^^
6
7 error: unrecognized representation hint
8 --> $DIR/enum.rs:29:8
9 |
10 29 | #[repr(foo)]
11 | ^^^
12
13 error: must have #[repr(C)] or #[repr(Int)] attribute in order to guarantee this type's memory layout
14 --> $DIR/enum.rs:36:10
15 |
16 36 | #[derive(FromBytes)]
17 | ^^^^^^^^^
18 |
19 = note: this error originates in the derive macro `FromBytes` (in Nightly builds, run with -Z macro-backtrace for more info)
20
21 error: this conflicts with another representation hint
22 --> $DIR/enum.rs:46:12
23 |
24 46 | #[repr(u8, u16)]
25 | ^^^
26
27 error: must have #[repr(C)] or #[repr(Int)] attribute in order to guarantee this type's memory layout
28 --> $DIR/enum.rs:53:10
29 |
30 53 | #[derive(FromBytes)]
31 | ^^^^^^^^^
32 |
33 = note: this error originates in the derive macro `FromBytes` (in Nightly builds, run with -Z macro-backtrace for more info)
34
35 error: must have #[repr(C)] or #[repr(Int)] attribute in order to guarantee this type's memory layout
36 --> $DIR/enum.rs:88:1
37 |
38 88 | #[zerocopy(crate = "zerocopy_renamed")]
39 | ^
40
41 error: must have #[repr(C)] or #[repr(Int)] attribute in order to guarantee this type's memory layout
42 --> $DIR/enum.rs:95:1
43 |
44 95 | #[zerocopy(crate = "zerocopy_renamed")]
45 | ^
46
47 error: must have #[repr(C)] or #[repr(Int)] attribute in order to guarantee this type's memory layout
48 --> $DIR/enum.rs:117:1
49 |
50 117 | #[zerocopy(crate = "zerocopy_renamed")]
51 | ^
52
53 error: must have #[repr(C)] or #[repr(Int)] attribute in order to guarantee this type's memory layout
54 --> $DIR/enum.rs:124:1
55 |
56 124 | #[zerocopy(crate = "zerocopy_renamed")]
57 | ^
58
59 error: must have #[repr(C)] or #[repr(Int)] attribute in order to guarantee this type's memory layout
60 --> $DIR/enum.rs:132:1
61 |
62 132 | #[zerocopy(crate = "zerocopy_renamed")]
63 | ^
64
65 error: FromZeros only supported on enums with a variant that has a discriminant of `0`
66 --> $DIR/enum.rs:140:1
67 |
68 140 | / #[zerocopy(crate = "zerocopy_renamed")]
69 141 | |
70 142 | | #[repr(u8)]
71 143 | | enum FromZeros4 {
72 144 | | A = 1,
73 145 | | B = 2,
74 146 | | }
75 | |_^
76
77 error: FromZeros only supported on enums with a variant that has a discriminant of `0`
78 help: This enum has discriminants which are not literal integers. One of those may define or imply which variant has a discriminant of zero. Use a literal integer to define or imply the variant with a discriminant of zero.
79 --> $DIR/enum.rs:151:1
80 |
81 151 | / #[zerocopy(crate = "zerocopy_renamed")]
82 152 | |
83 153 | | #[repr(i8)]
84 154 | | enum FromZeros5 {
85 155 | | A = NEGATIVE_ONE,
86 156 | | B,
87 157 | | }
88 | |_^
89
90 error: FromZeros only supported on enums with a variant that has a discriminant of `0`
91 --> $DIR/enum.rs:171:1
92 |
93 171 | / #[zerocopy(crate = "zerocopy_renamed")]
94 172 | |
95 173 | | #[repr(u8)]
96 174 | | enum FromZeros7 {
97 ... |
98 177 | | B(NotFromZeros),
99 178 | | }
100 | |_^
101
102 error: must have #[repr(C)] or #[repr(Int)] attribute in order to guarantee this type's memory layout
103 --> $DIR/enum.rs:184:10
104 |
105 184 | #[derive(FromBytes)]
106 | ^^^^^^^^^
107 |
108 = note: this error originates in the derive macro `FromBytes` (in Nightly builds, run with -Z macro-backtrace for more info)
109
110 error: `FromBytes` only supported on enums with `#[repr(...)]` attributes `u8`, `i8`, `u16`, or `i16`
111 --> $DIR/enum.rs:193:8
112 |
113 193 | #[repr(C)]
114 | ^
115
116 error: `FromBytes` only supported on enums with `#[repr(...)]` attributes `u8`, `i8`, `u16`, or `i16`
117 --> $DIR/enum.rs:201:8
118 |
119 201 | #[repr(usize)]
120 | ^^^^^
121
122 error: `FromBytes` only supported on enums with `#[repr(...)]` attributes `u8`, `i8`, `u16`, or `i16`
123 --> $DIR/enum.rs:209:8
124 |
125 209 | #[repr(isize)]
126 | ^^^^^
127
128 error: `FromBytes` only supported on enums with `#[repr(...)]` attributes `u8`, `i8`, `u16`, or `i16`
129 --> $DIR/enum.rs:217:8
130 |
131 217 | #[repr(u32)]
132 | ^^^
133
134 error: `FromBytes` only supported on enums with `#[repr(...)]` attributes `u8`, `i8`, `u16`, or `i16`
135 --> $DIR/enum.rs:225:8
136 |
137 225 | #[repr(i32)]
138 | ^^^
139
140 error: `FromBytes` only supported on enums with `#[repr(...)]` attributes `u8`, `i8`, `u16`, or `i16`
141 --> $DIR/enum.rs:233:8
142 |
143 233 | #[repr(u64)]
144 | ^^^
145
146 error: `FromBytes` only supported on enums with `#[repr(...)]` attributes `u8`, `i8`, `u16`, or `i16`
147 --> $DIR/enum.rs:241:8
148 |
149 241 | #[repr(i64)]
150 | ^^^
151
152 error: must have #[repr(u8)] or #[repr(i8)] attribute in order to guarantee this type's alignment
153 --> $DIR/enum.rs:515:10
154 |
155 515 | #[derive(Unaligned)]
156 | ^^^^^^^^^
157 |
158 = note: this error originates in the derive macro `Unaligned` (in Nightly builds, run with -Z macro-backtrace for more info)
159
160 error: must have #[repr(u8)] or #[repr(i8)] attribute in order to guarantee this type's alignment
161 --> $DIR/enum.rs:523:10
162 |
163 523 | #[derive(Unaligned)]
164 | ^^^^^^^^^
165 |
166 = note: this error originates in the derive macro `Unaligned` (in Nightly builds, run with -Z macro-backtrace for more info)
167
168 error: must have #[repr(u8)] or #[repr(i8)] attribute in order to guarantee this type's alignment
169 --> $DIR/enum.rs:531:10
170 |
171 531 | #[derive(Unaligned)]
172 | ^^^^^^^^^
173 |
174 = note: this error originates in the derive macro `Unaligned` (in Nightly builds, run with -Z macro-backtrace for more info)
175
176 error: must have #[repr(u8)] or #[repr(i8)] attribute in order to guarantee this type's alignment
177 --> $DIR/enum.rs:539:10
178 |
179 539 | #[derive(Unaligned)]
180 | ^^^^^^^^^
181 |
182 = note: this error originates in the derive macro `Unaligned` (in Nightly builds, run with -Z macro-backtrace for more info)
183
184 error: must have #[repr(u8)] or #[repr(i8)] attribute in order to guarantee this type's alignment
185 --> $DIR/enum.rs:547:10
186 |
187 547 | #[derive(Unaligned)]
188 | ^^^^^^^^^
189 |
190 = note: this error originates in the derive macro `Unaligned` (in Nightly builds, run with -Z macro-backtrace for more info)
191
192 error: must have #[repr(u8)] or #[repr(i8)] attribute in order to guarantee this type's alignment
193 --> $DIR/enum.rs:555:10
194 |
195 555 | #[derive(Unaligned)]
196 | ^^^^^^^^^
197 |
198 = note: this error originates in the derive macro `Unaligned` (in Nightly builds, run with -Z macro-backtrace for more info)
199
200 error: must have #[repr(u8)] or #[repr(i8)] attribute in order to guarantee this type's alignment
201 --> $DIR/enum.rs:563:10
202 |
203 563 | #[derive(Unaligned)]
204 | ^^^^^^^^^
205 |
206 = note: this error originates in the derive macro `Unaligned` (in Nightly builds, run with -Z macro-backtrace for more info)
207
208 error: must have #[repr(u8)] or #[repr(i8)] attribute in order to guarantee this type's alignment
209 --> $DIR/enum.rs:571:10
210 |
211 571 | #[derive(Unaligned)]
212 | ^^^^^^^^^
213 |
214 = note: this error originates in the derive macro `Unaligned` (in Nightly builds, run with -Z macro-backtrace for more info)
215
216 error: must have #[repr(u8)] or #[repr(i8)] attribute in order to guarantee this type's alignment
217 --> $DIR/enum.rs:579:10
218 |
219 579 | #[derive(Unaligned)]
220 | ^^^^^^^^^
221 |
222 = note: this error originates in the derive macro `Unaligned` (in Nightly builds, run with -Z macro-backtrace for more info)
223
224 error: cannot derive `Unaligned` on type with alignment greater than 1
225 --> $DIR/enum.rs:589:12
226 |
227 589 | #[repr(u8, align(2))]
228 | ^^^^^
229
230 error: cannot derive `Unaligned` on type with alignment greater than 1
231 --> $DIR/enum.rs:597:12
232 |
233 597 | #[repr(i8, align(2))]
234 | ^^^^^
235
236 error: this conflicts with another representation hint
237 --> $DIR/enum.rs:605:18
238 |
239 605 | #[repr(align(1), align(2))]
240 | ^^^^^
241
242 error: this conflicts with another representation hint
243 --> $DIR/enum.rs:613:18
244 |
245 613 | #[repr(align(2), align(4))]
246 | ^^^^^
247
248 error: must have #[repr(C)] or #[repr(Int)] attribute in order to guarantee this type's memory layout
249 --> $DIR/enum.rs:657:10
250 |
251 657 | #[derive(IntoBytes)]
252 | ^^^^^^^^^
253 |
254 = note: this error originates in the derive macro `IntoBytes` (in Nightly builds, run with -Z macro-backtrace for more info)
255
256 error: must have #[repr(C)] or #[repr(Int)] attribute in order to guarantee this type's memory layout
257 --> $DIR/enum.rs:665:10
258 |
259 665 | #[derive(IntoBytes)]
260 | ^^^^^^^^^
261 |
262 = note: this error originates in the derive macro `IntoBytes` (in Nightly builds, run with -Z macro-backtrace for more info)
263
264 error: generic parameters may not be used in const operations
265 --> $DIR/enum.rs:677:7
266 |
267 677 | A(T),
268 | ^ cannot perform const operation using `T`
269 |
270 = note: type parameters may not be used in const expressions
271
272 error[E0658]: custom discriminant values are not allowed in enums with tuple or struct variants
273 --> $DIR/enum.rs:175:9
274 |
275 175 | A = 1,
276 | ^ disallowed custom discriminant
277 176 |
278 177 | B(NotFromZeros),
279 | --------------- tuple variant defined here
280 |
281 = note: see issue #60553 <https://github.com/rust-lang/rust/issues/60553> for more information
282
283 error[E0565]: meta item in `repr` must be an identifier
284 --> $DIR/enum.rs:20:8
285 |
286 20 | #[repr("foo")]
287 | ^^^^^
288
289 error[E0552]: unrecognized representation hint
290 --> $DIR/enum.rs:29:8
291 |
292 29 | #[repr(foo)]
293 | ^^^
294
295 error[E0566]: conflicting representation hints
296 --> $DIR/enum.rs:46:8
297 |
298 46 | #[repr(u8, u16)]
299 | ^^ ^^^
300 |
301 = note: `#[deny(conflicting_repr_hints)]` on by default
302 = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
303 = note: for more information, see issue #68585 <https://github.com/rust-lang/rust/issues/68585>
304
305 error[E0277]: the trait bound `UnsafeCell<()>: Immutable` is not satisfied
306 --> $DIR/enum.rs:64:10
307 |
308 64 | #[derive(Immutable)]
309 | ^^^^^^^^^ the trait `Immutable` is not implemented for `UnsafeCell<()>`
310 |
311 = help: see issue #48214
312 = note: this error originates in the derive macro `Immutable` (in Nightly builds, run with -Z macro-backtrace for more info)
313
314 error[E0277]: the trait bound `UnsafeCell<u8>: Immutable` is not satisfied
315 --> $DIR/enum.rs:75:10
316 |
317 75 | #[derive(Immutable)]
318 | ^^^^^^^^^ the trait `Immutable` is not implemented for `UnsafeCell<u8>`
319 |
320 = help: see issue #48214
321 = note: this error originates in the derive macro `Immutable` (in Nightly builds, run with -Z macro-backtrace for more info)
322
323 error[E0277]: the trait bound `NotTryFromBytes: TryFromBytes` is not satisfied
324 --> $DIR/enum.rs:104:10
325 |
326 104 | #[derive(TryFromBytes)]
327 | ^^^^^^^^^^^^ the trait `TryFromBytes` is not implemented for `NotTryFromBytes`
328 |
329 = help: see issue #48214
330 = note: this error originates in the derive macro `TryFromBytes` (in Nightly builds, run with -Z macro-backtrace for more info)
331
332 error[E0277]: the trait bound `NotFromZeros: TryFromBytes` is not satisfied
333 --> $DIR/enum.rs:161:10
334 |
335 161 | #[derive(FromZeros)]
336 | ^^^^^^^^^ the trait `TryFromBytes` is not implemented for `NotFromZeros`
337 |
338 = help: see issue #48214
339 = note: this error originates in the derive macro `FromZeros` (in Nightly builds, run with -Z macro-backtrace for more info)
340
341 error[E0277]: the trait bound `NotFromZeros: FromZeros` is not satisfied
342 --> $DIR/enum.rs:161:10
343 |
344 161 | #[derive(FromZeros)]
345 | ^^^^^^^^^ the trait `FromZeros` is not implemented for `NotFromZeros`
346 |
347 = help: see issue #48214
348 = note: this error originates in the derive macro `FromZeros` (in Nightly builds, run with -Z macro-backtrace for more info)
349
350 error[E0277]: the trait bound `bool: FromBytes` is not satisfied
351 --> $DIR/enum.rs:247:10
352 |
353 247 | #[derive(FromBytes)]
354 | ^^^^^^^^^ the trait `FromBytes` is not implemented for `bool`
355 |
356 = help: see issue #48214
357 = note: this error originates in the derive macro `FromBytes` (in Nightly builds, run with -Z macro-backtrace for more info)
358
359 error[E0277]: the trait bound `(): PaddingFree<IntoBytes1, 1_usize>` is not satisfied
360 --> $DIR/enum.rs:623:10
361 |
362 623 | #[derive(IntoBytes)]
363 | ^^^^^^^^^ the trait `PaddingFree<IntoBytes1, 1_usize>` is not implemented for `()`
364 |
365 = help: the following implementations were found:
366 <() as PaddingFree<T, 0_usize>>
367 = help: see issue #48214
368 = note: this error originates in the derive macro `IntoBytes` (in Nightly builds, run with -Z macro-backtrace for more info)
369
370 error[E0277]: the trait bound `(): PaddingFree<IntoBytes2, 3_usize>` is not satisfied
371 --> $DIR/enum.rs:638:10
372 |
373 638 | #[derive(IntoBytes)]
374 | ^^^^^^^^^ the trait `PaddingFree<IntoBytes2, 3_usize>` is not implemented for `()`
375 |
376 = help: the following implementations were found:
377 <() as PaddingFree<T, 0_usize>>
378 = help: see issue #48214
379 = note: this error originates in the derive macro `IntoBytes` (in Nightly builds, run with -Z macro-backtrace for more info)
380
381 error[E0277]: the trait bound `(): PaddingFree<IntoBytes3, 2_usize>` is not satisfied
382 --> $DIR/enum.rs:647:10
383 |
384 647 | #[derive(IntoBytes)]
385 | ^^^^^^^^^ the trait `PaddingFree<IntoBytes3, 2_usize>` is not implemented for `()`
386 |
387 = help: the following implementations were found:
388 <() as PaddingFree<T, 0_usize>>
389 = help: see issue #48214
390 = note: this error originates in the derive macro `IntoBytes` (in Nightly builds, run with -Z macro-backtrace for more info)
391
392 error: generic `Self` types are currently not permitted in anonymous constants
393 --> $DIR/enum.rs:672:10
394 |
395 672 | #[derive(IntoBytes)]
396 | ^^^^^^^^^
397 |
398 note: not a concrete type
399 --> $DIR/enum.rs:672:10
400 |
401 672 | #[derive(IntoBytes)]
402 | ^^^^^^^^^
403 = note: this error originates in the derive macro `IntoBytes` (in Nightly builds, run with -Z macro-backtrace for more info)
404
405 error[E0277]: the trait bound `(): PaddingFree<IntoBytes7, 1_usize>` is not satisfied
406 --> $DIR/enum.rs:681:10
407 |
408 681 | #[derive(IntoBytes)]
409 | ^^^^^^^^^ the trait `PaddingFree<IntoBytes7, 1_usize>` is not implemented for `()`
410 |
411 = help: the following implementations were found:
412 <() as PaddingFree<T, 0_usize>>
413 = help: see issue #48214
414 = note: this error originates in the derive macro `IntoBytes` (in Nightly builds, run with -Z macro-backtrace for more info)
415
416 error: aborting due to 52 previous errors
417
418 Some errors have detailed explanations: E0277, E0552, E0565, E0566, E0658.
419 For more information about an error, try `rustc --explain E0277`.