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
762 B23 linesraw
1error[E0530]: match bindings cannot shadow unit variants
2  --> $DIR/issue-27033.rs:7:9
3   |
4LL |         None @ _ => {}
5   |         ^^^^ cannot be named the same as a unit variant
6   | 
7  ::: $SRC_DIR/libstd/prelude/v1.rs:LL:COL
8   |
9LL | pub use crate::option::Option::{self, None, Some};
10   |                                       ---- the unit variant `None` is defined here
11
12error[E0530]: match bindings cannot shadow constants
13  --> $DIR/issue-27033.rs:11:9
14   |
15LL |     const C: u8 = 1;
16   |     ---------------- the constant `C` is defined here
17LL |     match 1 {
18LL |         C @ 2 => {
19   |         ^ cannot be named the same as a constant
20
21error: aborting due to 2 previous errors
22
23For more information about this error, try `rustc --explain E0530`.