Tests for BlockedOnDeadMVar and ThreadKilled exceptions (they generate
no output by default in forked threads).
--- /dev/null
+module Main where
+
+import Exception
+import Concurrent
+import Prelude hiding (catch)
+
+-- the BlockOnDeadMVar exception doesn't cause any output by default
+
+main = do
+ forkIO (do m <- newEmptyMVar; takeMVar m)
+ print (sum [1..10000])
--- /dev/null
+module Main where
+
+import Exception
+import Concurrent
+import Prelude hiding (catch)
+
+-- the ThreadKilled exception doesn't cause any output by default
+
+main = do
+ m <- newEmptyMVar
+ id <- forkIO (takeMVar m)
+ yield
+ killThread id
+ putMVar m ()
+ print (sum [1..50000])
--- /dev/null
+1250025000