pub struct ContAdj<R>(/* private fields */);Expand description
Witness for the self-adjunction ContF<R> ⊣ ContF<R>.
This is the canonical contravariant adjunction. The composed functor
ContF<R> . ContF<R> gives Of<A> = (A -> R) -> R, the continuation monad.
unit(a) = |k| k(a)(embed a value into CPS)counit(b) = |k| k(b)(same operation — self-adjoint!)
Trait Implementations§
Auto Trait Implementations§
impl<R> Freeze for ContAdj<R>
impl<R> RefUnwindSafe for ContAdj<R>where
R: RefUnwindSafe,
impl<R> Send for ContAdj<R>where
R: Send,
impl<R> Sync for ContAdj<R>where
R: Sync,
impl<R> Unpin for ContAdj<R>where
R: Unpin,
impl<R> UnsafeUnpin for ContAdj<R>
impl<R> UnwindSafe for ContAdj<R>where
R: 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