rust/tests/ui/consts/const-enum-ptr.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

13 lines
174 B
Rust
Raw Normal View History

//@ run-pass
#![allow(dead_code)]
enum E { V0, V1(isize) }
static C: &'static E = &E::V0;
2013-01-31 00:42:46 +00:00
pub fn main() {
2013-01-31 00:42:46 +00:00
match *C {
E::V0 => (),
_ => panic!()
2013-01-31 00:42:46 +00:00
}
}