fork/rust

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

borsAuto merge of #103046 - JanBeh:PR_clarify_cmp_terminology, r=workingjubilee3bcad65fbf6

master
475 B21 linesraw
1// check-pass
2// run-rustfix
3
4#![warn(ellipsis_inclusive_range_patterns)]
5
6fn main() {
7    let despondency = 2;
8    match despondency {
9        1..=2 => {}
10        //~^ WARN `...` range patterns are deprecated
11        //~| WARN this is accepted in the current edition
12        _ => {}
13    }
14
15    match &despondency {
16        &(1..=2) => {}
17        //~^ WARN `...` range patterns are deprecated
18        //~| WARN this is accepted in the current edition
19        _ => {}
20    }
21}