use macro_attr_2018::macro_attr; use enum_derive_2018::{EnumDisplay, EnumFromStr, IterVariants}; macro_attr! { #[derive(Eq, PartialEq, Debug, Hash, Clone, Copy, Ord, PartialOrd)] #[derive(EnumDisplay!, EnumFromStr!, IterVariants!(ColorVariants))] pub enum Color { Black, Red, Green, Yellow, Blue, Magenta, Cyan, White } }