Yves Parès <[email protected]> wrote:

> But still, I maintain my previous view. I could clarify that by saying
> that (e.g. for Maybe) we could separate it in two types, Maybe itself
> and its monad:
>
> -- The plain Maybe type
> data Maybe a = Just a | Nothing
>
> -- The MaybeMonad
> newtype MaybeMonad a = MM ( () -> Maybe a )
>
> That's what using Maybe as a monad semantically means, doesn't it?

That's a statement like "the sky is blue".  You can represent any value
as a function of ().  You are saying that every integer is a function.

    newtype MyInt = MyInt (() -> Int)
    newtype My a = My (() -> a)

Think of it this way:  There is something like a canonical
representation of every monad.  If you let that one be the one with the
least order (which is reasonable), then no, not every monad's canonical
representation is a function, because the base library definition of
Maybe is the canonical one (order zero).

In that sense every value in maths is a function.  In other words: Your
extension of everything (!) to functions is redundant.

You get the idea.


Greets,
Ertugrul

-- 
nightmare = unsafePerformIO (getWrongWife >>= sex)
http://ertes.de/

Attachment: signature.asc
Description: PGP signature

_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to