pub enum Either<T, U> {
Left(T),
Right(U),
}Expand description
Sum type of left and right case.
Variants
Left(T)
Left case.
Right(U)
Right case.
Trait Implementations
impl<T: Copy, U: Copy> Copy for Either<T, U>
Auto Trait Implementations
impl<T, U> RefUnwindSafe for Either<T, U> where
T: RefUnwindSafe,
U: RefUnwindSafe,
impl<T, U> Send for Either<T, U> where
T: Send,
U: Send,
impl<T, U> Sync for Either<T, U> where
T: Sync,
U: Sync,
impl<T, U> Unpin for Either<T, U> where
T: Unpin,
U: Unpin,
impl<T, U> UnwindSafe for Either<T, U> where
T: UnwindSafe,
U: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Existential for T where
T: Decidable,
impl<T> Existential for T where
T: Decidable,
sourceimpl<N, T> HomotopyLevel<N> for T where
N: Nat,
T: DecidableHomotopyLevel<N>,
impl<N, T> HomotopyLevel<N> for T where
N: Nat,
T: DecidableHomotopyLevel<N>,
type H0 = <T as DecidableHomotopyLevel<N>>::H0
type H0 = <T as DecidableHomotopyLevel<N>>::H0
A type such that it proves homotopy level 0.
type H = <T as DecidableHomotopyLevel<N>>::H
type H = <T as DecidableHomotopyLevel<N>>::H
A type such that it proves a lower homotopy level.
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into)Uses borrowed data to replace owned data, usually by cloning. Read more