[commit: testsuite] master: Test case for #7901. (5535416)

git at git.haskell.org git at git.haskell.org
Mon Aug 19 06:17:03 CEST 2013


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

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/5535416500167a1167bf8b375acf999ad4b20924/testsuite

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

commit 5535416500167a1167bf8b375acf999ad4b20924
Author: Anders Papitto <anderspapitto at gmail.com>
Date:   Sun Aug 18 14:14:28 2013 -0700

    Test case for #7901.
    
    Signed-off-by: Austin Seipp <aseipp at pobox.com>


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

5535416500167a1167bf8b375acf999ad4b20924
 tests/parser/should_fail/ParserNoForallUnicode.hs     |    6 ++++++
 tests/parser/should_fail/ParserNoForallUnicode.stderr |    5 +++++
 tests/parser/should_fail/all.T                        |    1 +
 3 files changed, 12 insertions(+)

diff --git a/tests/parser/should_fail/ParserNoForallUnicode.hs b/tests/parser/should_fail/ParserNoForallUnicode.hs
new file mode 100644
index 0000000..e5591de
--- /dev/null
+++ b/tests/parser/should_fail/ParserNoForallUnicode.hs
@@ -0,0 +1,6 @@
+{-# LANGUAGE UnicodeSyntax #-}
+
+module ParserNoForallUnicode where
+
+id' :: ∀ a . a → a
+id' a = a
diff --git a/tests/parser/should_fail/ParserNoForallUnicode.stderr b/tests/parser/should_fail/ParserNoForallUnicode.stderr
new file mode 100644
index 0000000..a359864
--- /dev/null
+++ b/tests/parser/should_fail/ParserNoForallUnicode.stderr
@@ -0,0 +1,5 @@
+
+ParserNoForallUnicode.hs:5:8:
+    Illegal symbol '∀' in type
+    Perhaps you intended -XRankNTypes or similar flag
+    to enable explicit-forall syntax: ∀ <tvs>. <type>
diff --git a/tests/parser/should_fail/all.T b/tests/parser/should_fail/all.T
index 378a73f..f6d5716 100644
--- a/tests/parser/should_fail/all.T
+++ b/tests/parser/should_fail/all.T
@@ -72,6 +72,7 @@ test('NondecreasingIndentationFail', normal, compile_fail, [''])
 test('readFailTraditionalRecords1', normal, compile_fail, [''])
 test('readFailTraditionalRecords2', normal, compile_fail, [''])
 test('readFailTraditionalRecords3', normal, compile_fail, [''])
+test('ParserNoForallUnicode', normal, compile_fail, [''])
 test('ParserNoLambdaCase', when(compiler_lt('ghc', '7.5'), skip), compile_fail, [''])
 test('ParserNoMultiWayIf', when(compiler_lt('ghc', '7.5'), skip), compile_fail, [''])
 





More information about the ghc-commits mailing list