1 2 3 4 5 6 7 8
use super::{Applicative, Functor, GenType}; pub trait Monad<'a, A>: GenType + Functor<'a, A> + Applicative<'a, A> { #[must_use] fn bind<F, B: 'a>(self, f: F) -> Self::Type<B> where F: Fn(A) -> Self::Type<B> + 'a; }