blob: 380c15467d7da616851b027285a8a47666152f11 (
plain)
1
2
3
4
5
6
7
8
9
|
import Control.Exception
import GHC.Conc
main = do
t1 <- mask_ $ forkIO yield
t2 <- forkIO $ killThread t1
threadDelay 100000
threadStatus t1 >>= print
threadStatus t2 >>= print
|