From 7069b9af8594c6f4f199e71224547d39077acb38 Mon Sep 17 00:00:00 2001 From: Ian Lynagh Date: Sun, 3 Aug 2008 18:03:45 +0000 Subject: [PATCH] Windows fixes --- Control/Concurrent.hs | 2 +- GHC/TopHandler.lhs | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Control/Concurrent.hs b/Control/Concurrent.hs index 6268311..38a08d2 100644 --- a/Control/Concurrent.hs +++ b/Control/Concurrent.hs @@ -470,7 +470,7 @@ withThread io = do x <- takeMVar m case x of Right a -> return a - Left e -> throwIO e + Left e -> throwIO (e :: IOException) waitFd :: Fd -> CInt -> IO () waitFd fd write = do diff --git a/GHC/TopHandler.lhs b/GHC/TopHandler.lhs index 98ce59b..422b8b0 100644 --- a/GHC/TopHandler.lhs +++ b/GHC/TopHandler.lhs @@ -38,6 +38,9 @@ import GHC.Handle import GHC.IOBase import GHC.Weak import Data.Typeable +#if defined(mingw32_HOST_OS) +import GHC.ConsoleHandler +#endif -- | 'runMainIO' is wrapped around 'Main.main' (or whatever main is -- called in the program). It catches otherwise uncaught exceptions, -- 1.7.10.4