fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #68568 - pietroalbini:stable-next, r=pietroalbini5e1a799842b

1.41.0
1.3 KiB36 linesraw
1error[E0658]: discriminants on non-unit variants are experimental
2  --> $DIR/feature-gate-arbitrary_enum_discriminant.rs:6:13
3   |
4LL |   Tuple() = 2,
5   |             ^
6   |
7   = note: for more information, see https://github.com/rust-lang/rust/issues/60553
8   = help: add `#![feature(arbitrary_enum_discriminant)]` to the crate attributes to enable
9
10error[E0658]: discriminants on non-unit variants are experimental
11  --> $DIR/feature-gate-arbitrary_enum_discriminant.rs:8:14
12   |
13LL |   Struct{} = 3,
14   |              ^
15   |
16   = note: for more information, see https://github.com/rust-lang/rust/issues/60553
17   = help: add `#![feature(arbitrary_enum_discriminant)]` to the crate attributes to enable
18
19error[E0658]: custom discriminant values are not allowed in enums with tuple or struct variants
20  --> $DIR/feature-gate-arbitrary_enum_discriminant.rs:4:10
21   |
22LL |   Unit = 1,
23   |          ^ disallowed custom discriminant
24LL |
25LL |   Tuple() = 2,
26   |   ----------- tuple variant defined here
27LL |
28LL |   Struct{} = 3,
29   |   ------------ struct variant defined here
30   |
31   = note: for more information, see https://github.com/rust-lang/rust/issues/60553
32   = help: add `#![feature(arbitrary_enum_discriminant)]` to the crate attributes to enable
33
34error: aborting due to 3 previous errors
35
36For more information about this error, try `rustc --explain E0658`.