summaryrefslogtreecommitdiffstats
path: root/tests/ui/issues/issue-46964.rs
blob: 28fa92f2091e78d99d453648718063e28be6ba4c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// check-pass
mod my_mod {
    #[derive(Clone, Copy, Eq, PartialEq, PartialOrd, Ord, Hash)]
    pub struct Name<'a> {
        source: &'a str,
    }

    pub const JSON: Name = Name { source: "JSON" };
}

pub fn crash() -> bool {
  match (my_mod::JSON, None) {
    (_, Some(my_mod::JSON)) => true,
    (my_mod::JSON, None) => true,
    _ => false,
  }
}

fn main() {}