pub enum Maybe<T, R: Deref<Target = T>> {
Ref(R),
Val(T),
}Variants§
Implementations§
Auto Trait Implementations§
impl<T, R> RefUnwindSafe for Maybe<T, R>where R: RefUnwindSafe, T: RefUnwindSafe,
impl<T, R> Send for Maybe<T, R>where R: Send, T: Send,
impl<T, R> Sync for Maybe<T, R>where R: Sync, T: Sync,
impl<T, R> Unpin for Maybe<T, R>where R: Unpin, T: Unpin,
impl<T, R> UnwindSafe for Maybe<T, R>where R: UnwindSafe, 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