]> git.lizzy.rs Git - rust.git/blob - src/test/ui/suggestions/const-pat-non-exaustive-let-new-var.rs
Rollup merge of #65261 - nnethercote:rm-Option-from-TokenStream, r=petrochenkov
[rust.git] / src / test / ui / suggestions / const-pat-non-exaustive-let-new-var.rs
1 fn main() {
2     let A = 3;
3     //~^ ERROR refutable pattern in local binding: `std::i32::MIN..=1i32` and
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 }