Functor => Pointed => Applicative => Monad

Felipe Almeida Lessa felipe.lessa at
Mon Nov 29 19:19:28 CET 2010

On Mon, Nov 29, 2010 at 3:50 PM, Michael Snoyman <michael at> wrote:
> It would be useful for the Failure typeclass[1]. As-is, we made Monad
> the superclass just for ease of use, but there could definitely be
> some non-Monads for which a Failure instance makes sense. I think the
> one that occurred to me most recently is forms in Yesod, which have an
> Applicative but not Monad instance.

OP's proposal is to have

  class Applicative m => Monad m where ...

so you could just say

  class Applicative f => Failure e f where ...

The question is if there is something that is Pointed but not
Applicative that we would like to be Failure.

Cheers! =)


More information about the Libraries mailing list