xml in fptools?

Bulat Ziganshin bulat.ziganshin at gmail.com
Fri May 26 07:36:39 EDT 2006


Hello Simon,

Friday, May 26, 2006, 2:52:34 PM, you wrote:

>> Assuming we do have imprecise exceptions what is wrong with lazy IO?

> I'm not even certain that lazy I/O doesn't upset referential 
> transparency.  It seems hard to construct a concrete counter example 
> though.  My intuition is something like this: if evaluating a thunk can
> cause IO to take place, then the act of evaluating that thunk might 
> affect the value of another lazy I/O computation, and hence it should be
> possible to get different results by evaluating the thunks in a 
> different order.  I'm concerned that in the presence of dependencies 
> between lazy I/O computations, the order of evaluation might be visible.

of course it can if, or example, we evaluate two hGetContents on the
same Handle; or read the file that is written by other computation

i think that lazy I/O is like the ST threads - it's imperative code
that works with it's own part of World, and it is safe as far as we
don't touch this part of world in any other way. the only difference
is that for ST we can be sure that this part of world cannot be used
outside, while for lazy I/O we should himself give guaranties

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



More information about the Libraries mailing list