patch applied (packages/directory): make more use of System.Win32 or System.Posix

Ian Lynagh igloo at earth.li
Sat Aug 23 12:55:56 EDT 2008


On Thu, Aug 21, 2008 at 08:40:45AM -0700, Simon Marlow wrote:
> Thu Aug 21 07:35:50 PDT 2008  Simon Marlow <marlowsd at gmail.com>
>   * make more use of System.Win32 or System.Posix

directory functions on Windows now ultimately raise errors with
System.Win32.Types.failWith, which just calls fail, so we get user
errors.

This is what's breaking the GHC directory creation: When we are trying
to "mkdir $tmp/ghc$pid_$x" we only catch IOExceptions, and only keep
trying if we get an AlreadyExists IOException:
    `IO.catch` \e ->
            if isAlreadyExistsError e
            then mkTempDir (x+1)
            else ioError e

We'll need to fix the Win32 library before 6.10 (or roll back these
changes).


Thanks
Ian



More information about the Cvs-libraries mailing list