diff options
Diffstat (limited to 'tests/ui/issues/issue-36401.rs')
-rw-r--r-- | tests/ui/issues/issue-36401.rs | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/ui/issues/issue-36401.rs b/tests/ui/issues/issue-36401.rs new file mode 100644 index 000000000..f51197b01 --- /dev/null +++ b/tests/ui/issues/issue-36401.rs @@ -0,0 +1,16 @@ +// run-pass +#[derive(Debug)] +pub enum Event { + Key(u8), + Resize, + Unknown(u16), +} + +static XTERM_SINGLE_BYTES : [(u8, Event); 1] = [(1, Event::Resize)]; + +fn main() { + match XTERM_SINGLE_BYTES[0] { + (1, Event::Resize) => {}, + ref bad => panic!("unexpected {:?}", bad) + } +} |