pub trait FallibleCtxExt<'a>: FallibleCtx<'a> {
    // Provided methods
    fn unstuff<A: 'a + Send, E: 'a + Send>(
        wa: FallibleWrapped<'a, Self, A, E>
    ) -> WrapC<'a, Result<A, E>, Self> { ... }
    fn stuff<A: 'a + Send, E: 'a + Send>(
        fa: WrapC<'a, Result<A, E>, Self>
    ) -> FallibleWrapped<'a, Self, A, E> { ... }
}
Expand description

Extention trait for simpler conversion between FunctorContext::T and FallibleCtx::Fallible.

this is the preferred way to switch between WrapC and FallibleWrapped.

Provided Methods§

source

fn unstuff<A: 'a + Send, E: 'a + Send>( wa: FallibleWrapped<'a, Self, A, E> ) -> WrapC<'a, Result<A, E>, Self>

Convert a fallible wrapped into a wrapped result.

source

fn stuff<A: 'a + Send, E: 'a + Send>( fa: WrapC<'a, Result<A, E>, Self> ) -> FallibleWrapped<'a, Self, A, E>

Convert a wrapped result into a fallible wrapped.

Implementors§

source§

impl<'a, Ctx: FallibleCtx<'a>> FallibleCtxExt<'a> for Ctx