Housekeeping for GHC 8
- Remove some CPP needed only because of GHC 7.4 (which is not supported now, yey) - Move CPP for GHC 8 to Gap module
This commit is contained in:
@@ -23,16 +23,18 @@ spec = do
|
||||
|
||||
mv_ex :: MVar (Either SomeException ())
|
||||
<- newEmptyMVar
|
||||
mv_startup_barrier :: MVar () <- newEmptyMVar
|
||||
mv_startup_barrier :: MVar ()
|
||||
<- newEmptyMVar
|
||||
|
||||
_t1 <- forkOS $ do
|
||||
putMVar mv_startup_barrier ()
|
||||
-- wait (inside GhcModT) for t2 to receive the exception
|
||||
_ <- runD $ liftIO $ readMVar mv_ex
|
||||
_ <- runD $ liftIO $ do
|
||||
putMVar mv_startup_barrier ()
|
||||
readMVar mv_ex
|
||||
return ()
|
||||
|
||||
_t2 <- forkOS $ do
|
||||
readMVar mv_startup_barrier -- wait for t1 to start up
|
||||
readMVar mv_startup_barrier -- wait for t1 to be in GhcModT
|
||||
res <- try $ runD $ return ()
|
||||
res' <- evaluate res
|
||||
putMVar mv_ex res'
|
||||
|
||||
Reference in New Issue
Block a user