On Thu, Feb 5, 2009 at 12:24 AM, Petr Rockai <[email protected]> wrote: > Judah Jacobson <[email protected]> writes: >> I think the below code might be slightly cleaner: >> >> x <- unsafeMMapFile `catch` $ \e -> do >> size <- fileSize `fmap` getSymbolicLinkStatus f >> if size == 0 >> then return B.empty >> else throwIO e >> >> That is, explicitly re-throw the caught exception, rather than calling >> unsafeMMapFile again to get it implicitly re-thrown. > The idea is that after performGC, there is a reasonable chance that the second > call will actually succeed.
Ah, neat, I get it. Thanks for the explanation. -Judah _______________________________________________ darcs-users mailing list [email protected] http://lists.osuosl.org/mailman/listinfo/darcs-users
