diff options
Diffstat (limited to 'src/bt.rs')
-rw-r--r-- | src/bt.rs | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -86,6 +86,18 @@ impl FromStr for TraitChoice { } } +impl fmt::Display for TraitChoice { + fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { + let result = match *self { + TraitChoice::None => "none", + TraitChoice::Top => "top", + TraitChoice::Middle => "mid", + TraitChoice::Bottom => "bot", + }; + write!(f, "{}", result) + } +} + /// Represents a revenenant legend. #[repr(u8)] #[derive(Debug, PartialEq, Eq, Hash, Copy, Clone, IntoPrimitive, TryFromPrimitive)] |