/playground.rs
Last active Feb 20, 2017
Shared via Rust Playground
| const BASE: u32 = 5; | |
| #[repr(u32)] | |
| enum Foo { | |
| Base = BASE, | |
| Blob, | |
| Canvas, | |
| } | |
| fn main() { | |
| println!("{} {} {}", Foo::Base as u32, Foo::Blob as u32, Foo::Canvas as u32) | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment