summaryrefslogtreecommitdiff
path: root/testsuite/tests/concurrent/should_run/T5238.hs
blob: 1de60c4e80dcff6280a7c50754a796c2d9329f71 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
{-# LANGUAGE UnicodeSyntax #-}
{-# LANGUAGE ScopedTypeVariables #-}

import Control.Exception
import GHC.Conc

main = do
  ms1 ← getMaskingState
  atomically $ (throwSTM Overflow) `catchSTM`
               (\(e ∷ SomeException) → return ())
  ms2 ← getMaskingState
  putStrLn $ show (ms1, ms2)