[][src]Enum next_gen::GeneratorState

pub enum GeneratorState<Yield, Return = ()> {

Value obtained when polling a GeneratorFn.

This corresponds to:



The Generator suspended with a value.

This state indicates that a Generator has been suspended, and corresponds to a yield_! statement. The value provided in this variant corresponds to the expression passed to yield_! and allows generators to provide a value each time they yield_!.


The Generator completed with a Return value.

This state indicates that a Generator has finished execution with the provided value. Once a generator has returned Return, it is considered a programmer error to call .resume() again.

Trait Implementations

impl<Yield: Clone, Return: Clone> Clone for GeneratorState<Yield, Return>[src]

impl<Yield: Copy, Return: Copy> Copy for GeneratorState<Yield, Return>[src]

impl<Yield: Eq, Return: Eq> Eq for GeneratorState<Yield, Return>[src]

impl<Yield: Ord, Return: Ord> Ord for GeneratorState<Yield, Return>[src]

impl<Yield: PartialEq, Return: PartialEq> PartialEq<GeneratorState<Yield, Return>> for GeneratorState<Yield, Return>[src]

impl<Yield: PartialOrd, Return: PartialOrd> PartialOrd<GeneratorState<Yield, Return>> for GeneratorState<Yield, Return>[src]

impl<Yield: Debug, Return: Debug> Debug for GeneratorState<Yield, Return>[src]

impl<Yield: Hash, Return: Hash> Hash for GeneratorState<Yield, Return>[src]

impl<Yield, Return> StructuralPartialEq for GeneratorState<Yield, Return>[src]

impl<Yield, Return> StructuralEq for GeneratorState<Yield, Return>[src]

Auto Trait Implementations

impl<Yield, Return> Send for GeneratorState<Yield, Return> where
    Return: Send,
    Yield: Send

impl<Yield, Return> Sync for GeneratorState<Yield, Return> where
    Return: Sync,
    Yield: Sync

impl<Yield, Return> Unpin for GeneratorState<Yield, Return> where
    Return: Unpin,
    Yield: Unpin

impl<Yield, Return> UnwindSafe for GeneratorState<Yield, Return> where
    Return: UnwindSafe,
    Yield: UnwindSafe

impl<Yield, Return> RefUnwindSafe for GeneratorState<Yield, Return> where
    Return: RefUnwindSafe,
    Yield: RefUnwindSafe

Blanket Implementations

impl<T, U> Into<U> for T where
    U: From<T>, 

impl<T> From<T> for T[src]

impl<T> ToOwned for T where
    T: Clone

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized

impl<T> BorrowMut<T> for T where
    T: ?Sized

impl<T> Any for T where
    T: 'static + ?Sized