about summary refs log tree commit diff
path: root/tests/ui/issues/issue-18352.rs
blob: 8b6aa82ea8c0c4c00735c3d2477184ef5840ec0c (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()));
}