Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Glasgow Haskell Compiler
GHC
Commits
8564b7f3
Commit
8564b7f3
authored
Jan 12, 2013
by
Ian Lynagh
Browse files
Fix warnings on Windows
parent
753e3e38
Changes
1
Hide whitespace changes
Inline
Side-by-side
libraries/base/Control/Concurrent.hs
View file @
8564b7f3
...
...
@@ -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
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment