DDC compiler and effects; better than Haskell? (was Re: [Haskell-cafe] unsafeDestructiveAssign?)

Jules Bean jules at jellybean.co.uk
Wed Aug 12 06:37:31 EDT 2009

Peter Verswyvelen wrote:
> I kind of agree with the DDC authors here; in Haskell as soon as a
> function has a side effect, and you want to pass that function to a
> pure higher order function, you're stuck, you need to pick the monadic
> version of the higher order function, if it exists. 

I just want to point out that you could *always* use the monadic version.

That is, mapM subsumes map. Just use the Identity monad if you don't 
have anything really monadic going on.

The reason we don't is that that looks + feels ugly.


More information about the Haskell-Cafe mailing list