[Haskell-cafe] evaluation semantics of bind

Bulat Ziganshin bulat.ziganshin at gmail.com
Thu Feb 5 10:27:59 EST 2009


Hello Gregg,

Thursday, February 5, 2009, 6:20:06 PM, you wrote:

> An optimizer can see that the result of the first getChar is
> discarded and replace the entire expression with one getChar without
> changing the formal semantics. 

this is prohibited by using pseudo-value of type RealWorld which is
passed through entire action stream. actually, order of execution is
controlled by dependencies on this values

http://haskell.org/haskellwiki/IO_inside


-- 
Best regards,
 Bulat                            mailto:Bulat.Ziganshin at gmail.com



More information about the Haskell-Cafe mailing list