[Haskell-cafe] Re: Applicative but not Monad

Daniel Fischer daniel.is.fischer at web.de
Sat Oct 31 07:51:04 EDT 2009


Am Samstag 31 Oktober 2009 12:25:17 schrieb Tom Davie:
> On 10/31/09, Heinrich Apfelmus <apfelmus at quantentunnel.de> wrote:
> > The only possible monad instance would be
> >
> >    return x = Const mempty
> >    fmap f (Const b) = Const b
> >    join (Const b)   = Const b
>
> Your join doesn't seem to have the right type... Unless I'm missing
> something.
>
> Bob

join (Const b :: Const b (Const b a)) = (Const b :: Const b a)


More information about the Haskell-Cafe mailing list