enum_const

enum const trait

usage

```rust use enum_const::EnumConst;

[derive(EnumConst, PartialEq, Debug)]

enum Foo { X = 1, Y = 2, Z, }

[test]

fn itworks() { asserteq!(Some(Foo::X), Foo::fromconstisize(1)); asserteq!(Some(1isize), Foo::X.getconst_isize()); } ```