pub enum Value<T> {
Unset,
Set(T),
Bad {
why: String,
},
}Expand description
What a key said. Three answers, because “unset” is a state this project
makes decisions with — amont.commit.gitmoji has four meanings and one
of them is absence.
Variants§
Unset
Set(T)
Bad
Set to something that could not be read. why is git’s own diagnostic
where git produced one, and ours where the constraint is ours (a value
outside an allowed set, or outside a range).
Implementations§
Trait Implementations§
impl<T: Eq> Eq for Value<T>
impl<T: PartialEq> StructuralPartialEq for Value<T>
Auto Trait Implementations§
impl<T> Freeze for Value<T>where
T: Freeze,
impl<T> RefUnwindSafe for Value<T>where
T: RefUnwindSafe,
impl<T> Send for Value<T>where
T: Send,
impl<T> Sync for Value<T>where
T: Sync,
impl<T> Unpin for Value<T>where
T: Unpin,
impl<T> UnsafeUnpin for Value<T>where
T: UnsafeUnpin,
impl<T> UnwindSafe for Value<T>where
T: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more