]> git.proxmox.com Git - rustc.git/blame - src/test/ui/suggestions/const-pat-non-exaustive-let-new-var.rs
New upstream version 1.46.0~beta.2+dfsg1
[rustc.git] / src / test / ui / suggestions / const-pat-non-exaustive-let-new-var.rs
CommitLineData
e74abb32
XL
1fn main() {
2 let A = 3;
f035d41b 3 //~^ ERROR refutable pattern in local binding: `i32::MIN..=1_i32` and
e74abb32
XL
4 //~| interpreted as a constant pattern, not a new variable
5 //~| HELP introduce a variable instead
6 //~| SUGGESTION a_var
7
8 const A: i32 = 2;
9 //~^ constant defined here
10}