[Haskell-cafe] do

Brandon S. Allbery KF8NH allbery at ece.cmu.edu
Mon Oct 15 10:00:50 EDT 2007

On Oct 15, 2007, at 9:48 , Brandon S. Allbery KF8NH wrote:

> On Oct 15, 2007, at 7:02 , jerzy.karczmarczuk at info.unicaen.fr wrote:
>> IO is different, you *cannot* make it non-monadic.
> Not really true; it's just much more painful.

Expanding on this slightly:  the neat thing about Haskell's monads is  
not that they are somehow not "pure".  It is that they a completely  
pure and referentially transparent way to capture and safely  
encapsulate concepts that themselves may *not* be pure or  
referentially transparent, such as IO --- while simultaneously being  
useful for concepts that *are* pure and referentially transparent,  
such as State or Maybe/Either/[].

brandon s. allbery [solaris,freebsd,perl,pugs,haskell] allbery at kf8nh.com
system administrator [openafs,heimdal,too many hats] allbery at ece.cmu.edu
electrical and computer engineering, carnegie mellon university    KF8NH

More information about the Haskell-Cafe mailing list