summaryrefslogtreecommitdiffstats
path: root/src/test/ui/pattern/usefulness/issue-50900.rs
blob: 27135af9575819f2eec093641c58a7f7bd5cc8e3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#[derive(PartialEq, Eq)]
pub struct Tag(pub Context, pub u16);

#[derive(PartialEq, Eq)]
pub enum Context {
    Tiff,
    Exif,
}

impl Tag {
    const ExifIFDPointer: Tag = Tag(Context::Tiff, 34665);
}

fn main() {
    match Tag::ExifIFDPointer {
    //~^ ERROR: non-exhaustive patterns: `Tag(Exif, _)` not covered
        Tag::ExifIFDPointer => {}
    }
}