[GHC] #10759: don't throw BlockedIndefinitelyOn... in main thread
GHC
ghc-devs at haskell.org
Sat Aug 8 15:07:24 UTC 2015
#10759: don't throw BlockedIndefinitelyOn... in main thread
-------------------------------------+-------------------------------------
Reporter: yokto | Owner:
Type: bug | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 7.10.2
Keywords: | Operating System: Unknown/Multiple
Architecture: | Type of failure: None/Unknown
Unknown/Multiple |
Test Case: | Blocked By:
Blocking: | Related Tickets:
Differential Revisions: |
-------------------------------------+-------------------------------------
In the main thread UserInterrupt can be thrown to unblock a thread.
So the following program should wait for such an interrupt instead of
throwing a BlockedIndefinitelyOnMVar exception
{{{
main = do
var <- newEmptyMVar
takeMVar var `catch`
(const $ putStrLn "UserInterrupt caught" :: AsyncException -> IO
())
}}}
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/10759>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list