fork/rust

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

borsAuto merge of #71868 - Mark-Simulacrum:stable-1.43.1, r=pietroalbini8d69840ab92

1.43.1
2.7 KiB82 linesraw
1error[E0603]: tuple variant `Tuple` is private
2  --> $DIR/variant.rs:11:48
3   |
4LL |     let variant_tuple = NonExhaustiveVariants::Tuple(640);
5   |                                                ^^^^^ this tuple variant is private
6   |
7note: the tuple variant `Tuple` is defined here
8  --> $DIR/auxiliary/variants.rs:5:23
9   |
10LL |     #[non_exhaustive] Tuple(u32),
11   |                       ^^^^^^^^^^
12
13error[E0603]: unit variant `Unit` is private
14  --> $DIR/variant.rs:14:47
15   |
16LL |     let variant_unit = NonExhaustiveVariants::Unit;
17   |                                               ^^^^ this unit variant is private
18   |
19note: the unit variant `Unit` is defined here
20  --> $DIR/auxiliary/variants.rs:4:23
21   |
22LL |     #[non_exhaustive] Unit,
23   |                       ^^^^
24
25error[E0603]: unit variant `Unit` is private
26  --> $DIR/variant.rs:18:32
27   |
28LL |         NonExhaustiveVariants::Unit => "",
29   |                                ^^^^ this unit variant is private
30   |
31note: the unit variant `Unit` is defined here
32  --> $DIR/auxiliary/variants.rs:4:23
33   |
34LL |     #[non_exhaustive] Unit,
35   |                       ^^^^
36
37error[E0603]: tuple variant `Tuple` is private
38  --> $DIR/variant.rs:20:32
39   |
40LL |         NonExhaustiveVariants::Tuple(fe_tpl) => "",
41   |                                ^^^^^ this tuple variant is private
42   |
43note: the tuple variant `Tuple` is defined here
44  --> $DIR/auxiliary/variants.rs:5:23
45   |
46LL |     #[non_exhaustive] Tuple(u32),
47   |                       ^^^^^^^^^^
48
49error[E0603]: tuple variant `Tuple` is private
50  --> $DIR/variant.rs:26:35
51   |
52LL |     if let NonExhaustiveVariants::Tuple(fe_tpl) = variant_struct {
53   |                                   ^^^^^ this tuple variant is private
54   |
55note: the tuple variant `Tuple` is defined here
56  --> $DIR/auxiliary/variants.rs:5:23
57   |
58LL |     #[non_exhaustive] Tuple(u32),
59   |                       ^^^^^^^^^^
60
61error[E0639]: cannot create non-exhaustive variant using struct expression
62  --> $DIR/variant.rs:8:26
63   |
64LL |     let variant_struct = NonExhaustiveVariants::Struct { field: 640 };
65   |                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
66
67error[E0638]: `..` required with variant marked as non-exhaustive
68  --> $DIR/variant.rs:22:9
69   |
70LL |         NonExhaustiveVariants::Struct { field } => ""
71   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
72
73error[E0638]: `..` required with variant marked as non-exhaustive
74  --> $DIR/variant.rs:30:12
75   |
76LL |     if let NonExhaustiveVariants::Struct { field } = variant_struct {
77   |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
78
79error: aborting due to 8 previous errors
80
81Some errors have detailed explanations: E0603, E0638, E0639.
82For more information about an error, try `rustc --explain E0603`.