[][src]Trait funlib::Monad

pub trait Monad<B>: Applicative<B> {
    fn bind<F>(&self, f: F) -> Self::M
    where
        F: Fn(&Self::A) -> Self::M
; fn return_(v: B) -> Self::M
    where
        Self: HKT<B, A = B>
, { ... }
fn fmap<F>(&self, f: F) -> Self::M
    where
        F: Fn(&Self::A) -> B,
        Self: HKT<B, A = B>
, { ... } }

Required methods

fn bind<F>(&self, f: F) -> Self::M where
    F: Fn(&Self::A) -> Self::M

Loading content...

Provided methods

fn return_(v: B) -> Self::M where
    Self: HKT<B, A = B>, 

fn fmap<F>(&self, f: F) -> Self::M where
    F: Fn(&Self::A) -> B,
    Self: HKT<B, A = B>, 

Loading content...

Implementations on Foreign Types

impl<A, B> Monad<B> for Option<A>[src]

impl<A, B> Monad<B> for Box<A>[src]

impl<A, B> Monad<B> for Rc<A>[src]

impl<A, B> Monad<B> for Vec<A>[src]

Loading content...

Implementors

Loading content...