1 2 3 4 5 6 7 8 9 10
// `impl_into_static_str(disable)` must not generate `From<Foo> for &'static str`. #[derive(enum_helper::EnumStr, PartialEq, Eq)] #[enum_str(impl_into_static_str(disable))] enum Foo { Bar, } fn main() { let _: &'static str = Foo::Bar.into(); }