diff options
author | Simon Peyton Jones <simonpj@microsoft.com> | 2015-02-06 16:38:52 +0000 |
---|---|---|
committer | Simon Peyton Jones <simonpj@microsoft.com> | 2015-02-06 16:38:52 +0000 |
commit | 43636e1b8cf4a6d4752a22b098a9edd0759a7600 (patch) | |
tree | b483be0b58a3d42720d507e7aef7726a0a538373 /testsuite/tests/mdo | |
parent | 0f75a3f0a15ac26e52dc3477fd6e5bc3cd5c6eca (diff) | |
download | haskell-43636e1b8cf4a6d4752a22b098a9edd0759a7600.tar.gz |
Fix Trac #10004: head [] exception when using recursive mdo
Diffstat (limited to 'testsuite/tests/mdo')
-rw-r--r-- | testsuite/tests/mdo/should_compile/T10004.hs | 6 | ||||
-rw-r--r-- | testsuite/tests/mdo/should_compile/all.T | 2 |
2 files changed, 8 insertions, 0 deletions
diff --git a/testsuite/tests/mdo/should_compile/T10004.hs b/testsuite/tests/mdo/should_compile/T10004.hs new file mode 100644 index 0000000000..8e6200e841 --- /dev/null +++ b/testsuite/tests/mdo/should_compile/T10004.hs @@ -0,0 +1,6 @@ +{-# LANGUAGE RecursiveDo #-} +module T10004 where + +bar :: IO () +bar = do rec {} + return () diff --git a/testsuite/tests/mdo/should_compile/all.T b/testsuite/tests/mdo/should_compile/all.T index 49be01fc59..ea55b12c74 100644 --- a/testsuite/tests/mdo/should_compile/all.T +++ b/testsuite/tests/mdo/should_compile/all.T @@ -6,3 +6,5 @@ test('mdo003', normal, compile_and_run, ['']) test('mdo004', only_compiler_types(['ghc']), compile_and_run, ['']) test('mdo005', normal, compile_and_run, ['']) test('mdo006', normal, compile, ['']) +test('T10004', normal, compile, ['']) + |