summaryrefslogtreecommitdiff
path: root/testsuite/tests/rename
diff options
context:
space:
mode:
authorSimon Peyton Jones <simonpj@microsoft.com>2015-07-08 23:42:28 +0100
committerSimon Peyton Jones <simonpj@microsoft.com>2015-07-08 23:42:28 +0100
commit4f9d6008c04b71fc9449b3dc10861f757539ed0f (patch)
treec9698c18a01694e6fa4afa32d96727792ba55715 /testsuite/tests/rename
parent85b14a777917edd2d6b7d4b3584496cab28bada6 (diff)
downloadhaskell-4f9d6008c04b71fc9449b3dc10861f757539ed0f.tar.gz
Fix Trac #10618 (out of scope operator)
Out of scope variables now generate HsUnboundVar, and the fixity re-jigging wasn't taking this into account.
Diffstat (limited to 'testsuite/tests/rename')
-rw-r--r--testsuite/tests/rename/should_fail/T10618.hs3
-rw-r--r--testsuite/tests/rename/should_fail/T10618.stderr6
-rw-r--r--testsuite/tests/rename/should_fail/all.T1
3 files changed, 10 insertions, 0 deletions
diff --git a/testsuite/tests/rename/should_fail/T10618.hs b/testsuite/tests/rename/should_fail/T10618.hs
new file mode 100644
index 0000000000..28b665f6fb
--- /dev/null
+++ b/testsuite/tests/rename/should_fail/T10618.hs
@@ -0,0 +1,3 @@
+module T10618 where
+
+foo = Just $ Nothing <> Nothing
diff --git a/testsuite/tests/rename/should_fail/T10618.stderr b/testsuite/tests/rename/should_fail/T10618.stderr
new file mode 100644
index 0000000000..01e194877f
--- /dev/null
+++ b/testsuite/tests/rename/should_fail/T10618.stderr
@@ -0,0 +1,6 @@
+
+T10618.hs:3:22: error:
+ Variable not in scope: (<>) :: Maybe (Maybe a0) -> Maybe a1 -> t
+ Perhaps you meant one of these:
+ ‘<$>’ (imported from Prelude), ‘*>’ (imported from Prelude),
+ ‘<$’ (imported from Prelude)
diff --git a/testsuite/tests/rename/should_fail/all.T b/testsuite/tests/rename/should_fail/all.T
index 0df986889d..bfd81c51f9 100644
--- a/testsuite/tests/rename/should_fail/all.T
+++ b/testsuite/tests/rename/should_fail/all.T
@@ -133,3 +133,4 @@ test('T9032',
normal,
run_command,
['$MAKE -s --no-print-directory T9032'])
+test('T10618', normal, compile_fail, [''])