about summary refs log tree commit diff
path: root/tests/ui/parser/issues/issue-63115-range-pat-interpolated.rs
blob: 9a6bd4442e5636460a45d0029406c5ec175845fc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
//@ check-pass

#![allow(ellipsis_inclusive_range_patterns)]

fn main() {
    macro_rules! mac_expr {
        ($e:expr) => {
            if let 2...$e = 3 {}
            if let 2..=$e = 3 {}
            if let 2..$e = 3 {}
            if let ..$e = 3 {}
            if let ..=$e = 3 {}
            if let $e.. = 5 {}
            if let $e..5 = 4 {}
            if let $e..=5 = 4 {}
        }
    }
    mac_expr!(4);
}