rust/src/test/run-pass/binding/match-enum-struct-0.rs
2018-12-25 21:08:33 -07:00

17 lines
220 B
Rust

// run-pass
#![allow(dead_code)]
// regression test for issue #5625
enum E {
Foo{f : isize},
Bar
}
pub fn main() {
let e = E::Bar;
match e {
E::Foo{f: _f} => panic!(),
_ => (),
}
}