
20 May
2014
20 May
'14
1:10 p.m.
I think this translation is wrong. The left-hand side executes the side-effects of the ioFunction exactly once. The right-hand side looks like it would execute the side-effects of ioFunction everytime res is used.
I knew I should have left the let thing alone. It looks a bit strange to me too. But think if it this way, it's the {} that does the IO not the let. I'm not en expert in formality but it should work something like this stmtpart1 { exp } stmtpart2 should desugar to x <- exp stmtpart1 x stmtpart2 but as I said I don't insist on this working in the let case. It's not the main point.