[commit: ghc] ghc-8.0: Add test for #12732 (4227f3e)

git at git.haskell.org git at git.haskell.org
Thu Nov 10 21:42:23 UTC 2016


Repository : ssh://git@git.haskell.org/ghc

On branch  : ghc-8.0
Link       : http://ghc.haskell.org/trac/ghc/changeset/4227f3ea715960cc272a525f37e5d67ba232ae24/ghc

>---------------------------------------------------------------

commit 4227f3ea715960cc272a525f37e5d67ba232ae24
Author: Ryan Scott <ryan.gl.scott at gmail.com>
Date:   Fri Oct 28 17:00:29 2016 -0400

    Add test for #12732
    
    (cherry picked from commit 60343a419ab44d387cfd11f0dd2b522fd922e63a)


>---------------------------------------------------------------

4227f3ea715960cc272a525f37e5d67ba232ae24
 testsuite/tests/partial-sigs/should_fail/T12732.hs     | 6 ++++++
 testsuite/tests/partial-sigs/should_fail/T12732.stderr | 6 ++++++
 testsuite/tests/partial-sigs/should_fail/all.T         | 1 +
 3 files changed, 13 insertions(+)

diff --git a/testsuite/tests/partial-sigs/should_fail/T12732.hs b/testsuite/tests/partial-sigs/should_fail/T12732.hs
new file mode 100644
index 0000000..60bcde6
--- /dev/null
+++ b/testsuite/tests/partial-sigs/should_fail/T12732.hs
@@ -0,0 +1,6 @@
+module T12732 where
+
+(a ... b) xs
+  | a == x
+  , (l, _:r) <- break (== x) xs
+  = l ++ [x]
diff --git a/testsuite/tests/partial-sigs/should_fail/T12732.stderr b/testsuite/tests/partial-sigs/should_fail/T12732.stderr
new file mode 100644
index 0000000..5188f62
--- /dev/null
+++ b/testsuite/tests/partial-sigs/should_fail/T12732.stderr
@@ -0,0 +1,6 @@
+
+T12732.hs:4:10: error: Variable not in scope: x
+
+T12732.hs:5:27: error: Variable not in scope: x
+
+T12732.hs:6:11: error: Variable not in scope: x
diff --git a/testsuite/tests/partial-sigs/should_fail/all.T b/testsuite/tests/partial-sigs/should_fail/all.T
index a676a02..ef200d7 100644
--- a/testsuite/tests/partial-sigs/should_fail/all.T
+++ b/testsuite/tests/partial-sigs/should_fail/all.T
@@ -61,3 +61,4 @@ test('T10045', normal, compile_fail, [''])
 test('T10999', normal, compile_fail, [''])
 test('T11122', normal, compile, [''])
 test('T11976', normal, compile_fail, [''])
+test('T12732', normal, compile_fail, ['-fobject-code -fdefer-typed-holes'])



More information about the ghc-commits mailing list