[commit: base] master: Fix warnings on Windows (e747d14)
Ian Lynagh
igloo at earth.li
Sat Jan 12 21:50:02 CET 2013
Repository : ssh://darcs.haskell.org//srv/darcs/packages/base
On branch : master
http://hackage.haskell.org/trac/ghc/changeset/e747d14ef05c7e28a9c84d720e91670549d8f5d9
>---------------------------------------------------------------
commit e747d14ef05c7e28a9c84d720e91670549d8f5d9
Author: Ian Lynagh <igloo at earth.li>
Date: Sat Jan 12 19:51:39 2013 +0000
Fix warnings on Windows
>---------------------------------------------------------------
Control/Concurrent.hs | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/Control/Concurrent.hs b/Control/Concurrent.hs
index ae015a8..a53b1a8 100644
--- a/Control/Concurrent.hs
+++ b/Control/Concurrent.hs
@@ -128,7 +128,7 @@ import GHC.Base
import System.Posix.Types ( Fd )
import Foreign.StablePtr
import Foreign.C.Types
-import Control.Monad ( when )
+import Control.Monad
#ifdef mingw32_HOST_OS
import Foreign.C
@@ -460,8 +460,8 @@ threadWaitReadSTM :: Fd -> IO (STM (), IO ())
threadWaitReadSTM fd
#ifdef mingw32_HOST_OS
| threaded = do v <- newTVarIO Nothing
- mask_ $ forkIO $ do result <- try (waitFd fd 0)
- atomically (writeTVar v $ Just result)
+ mask_ $ void $ forkIO $ do result <- try (waitFd fd 0)
+ atomically (writeTVar v $ Just result)
let waitAction = do result <- readTVar v
case result of
Nothing -> retry
@@ -482,8 +482,8 @@ threadWaitWriteSTM :: Fd -> IO (STM (), IO ())
threadWaitWriteSTM fd
#ifdef mingw32_HOST_OS
| threaded = do v <- newTVarIO Nothing
- mask_ $ forkIO $ do result <- try (waitFd fd 1)
- atomically (writeTVar v $ Just result)
+ mask_ $ void $ forkIO $ do result <- try (waitFd fd 1)
+ atomically (writeTVar v $ Just result)
let waitAction = do result <- readTVar v
case result of
Nothing -> retry
More information about the ghc-commits
mailing list