1 2 3 4 5
/// A trait that is automatically implemented for any enum type with the attribute `#[derive(Tag)]`. pub trait TaggedEnum { type Tag; fn tag(&self) -> Self::Tag; }