On Thu, 2008-05-15 at 21:04 -0400, Olivier Boudry wrote:

> I tried to place a "length text `seq`" before the mapM_ writeExport to
> force the process output to be read but the result was even worst
> (only one line printed). Apparently withtout the `evaluate` function
> it causes more troubles than it solves.

Yes, you should prefer evaluate over seq (or return $!) in the IO monad
because you sometimes have to distinguish between the evaluation that
happens when you construct your IO actions, and the evaluation that
happens when you run your IO actions. The evaluate action does the
latter and its ordered with respect to the other IO actions.

Duncan

_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to