summaryrefslogtreecommitdiffstats
path: root/tests/ui/issues/issue-18352.rs
blob: 5d93ed0646caa45e47ddd71af9ae2911d6e6a114 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// run-pass

const X: &'static str = "12345";

fn test(s: String) -> bool {
    match &*s {
        X => true,
        _ => false
    }
}

fn main() {
    assert!(test("12345".to_string()));
}