diff options
Diffstat (limited to 'testsuite/tests/core-to-stg')
-rw-r--r-- | testsuite/tests/core-to-stg/T22937.hs | 11 | ||||
-rw-r--r-- | testsuite/tests/core-to-stg/T22937.stdout | 1 | ||||
-rw-r--r-- | testsuite/tests/core-to-stg/all.T | 1 |
3 files changed, 13 insertions, 0 deletions
diff --git a/testsuite/tests/core-to-stg/T22937.hs b/testsuite/tests/core-to-stg/T22937.hs new file mode 100644 index 0000000000..fe9aa62746 --- /dev/null +++ b/testsuite/tests/core-to-stg/T22937.hs @@ -0,0 +1,11 @@ +{-# LANGUAGE MagicHash #-} + +import GHC.Exts +import GHC.IO +import System.IO + +main :: IO () +main = do + IO $ \s -> keepAlive# () s (\s' f -> unIO f s') + (putStrLn "This should get printed.") + hFlush stdout diff --git a/testsuite/tests/core-to-stg/T22937.stdout b/testsuite/tests/core-to-stg/T22937.stdout new file mode 100644 index 0000000000..2474f121fc --- /dev/null +++ b/testsuite/tests/core-to-stg/T22937.stdout @@ -0,0 +1 @@ +This should get printed. diff --git a/testsuite/tests/core-to-stg/all.T b/testsuite/tests/core-to-stg/all.T index baab982cb4..6cdc87b83e 100644 --- a/testsuite/tests/core-to-stg/all.T +++ b/testsuite/tests/core-to-stg/all.T @@ -1,3 +1,4 @@ # Tests for CorePrep and CoreToStg test('T19700', normal, compile, ['-O']) +test('T22937', normal, compile_and_run, ['']) |