
1 Nov
2007
1 Nov
'07
10:46 a.m.
Stefan Holdermans wrote:
Exposing uniqueness types is, in that sense, just an alternative to monadic encapsulation of side effects.
While *World -> (a, *World) seems to work in practice, I wonder what its (denotational) semantics are. I mean, the two programs loop, loop' :: *World -> ((),*World) loop w = loop w loop' w = let (_,w') = print "x" w in loop' w' both have denotation _|_ but are clearly different in terms of side effects. (The example is from SPJs awkward-squad tutorial.) Any pointers? Regards, apfelmus