Re: fixIO
Malcolm Wallace <[email protected]> Tue, 2 Sep 2003 16:32:25 +0100
| Newsgroups | gmane.comp.lang.haskell.nhc.bugs |
|---|---|
| Organization | Dept of Computer Science, University of York |
| Message-ID | <[email protected]> |
Ross Paterson <[email protected]> writes: > The definition of fixIO used by Nhc (in System.IO), namely > fixIO f = let x = unsafePerformIO (f x) in return x > produces the wrong results. I suggest: > fixIO f = IO (\w -> let { IO f' = f a; r = f' w; Right a = r } in r) Thanks for the bug report and the fix, now committed. Regards, Malcolm