summaryrefslogtreecommitdiffstats
path: root/src/test/ui/suggestions/const-pat-non-exaustive-let-new-var.rs
blob: ac819dce6db2b5cf2fc838cc1cf84361b71876f1 (plain)
1
2
3
4
5
6
7
8
9
10
fn main() {
    let A = 3;
    //~^ ERROR refutable pattern in local binding: `i32::MIN..=1_i32` and
    //~| interpreted as a constant pattern, not a new variable
    //~| HELP introduce a variable instead
    //~| SUGGESTION a_var

    const A: i32 = 2;
    //~^ constant defined here
}