summaryrefslogtreecommitdiff
path: root/testsuite
diff options
context:
space:
mode:
authorRyan Scott <ryan.gl.scott@gmail.com>2017-10-11 08:43:37 -0400
committerRyan Scott <ryan.gl.scott@gmail.com>2017-10-11 08:43:37 -0400
commit9c3f73168a6f7f6632b6a3ffd2cfcd774976a7f1 (patch)
treea4948cc0902b35453e49b39015463f92d762ba1f /testsuite
parentf20cf982f126aea968ed6a482551550ffb6650cf (diff)
downloadhaskell-9c3f73168a6f7f6632b6a3ffd2cfcd774976a7f1.tar.gz
Fix #10816 by renaming FixitySigs more consistently
Summary: #10816 surfaced because we were renaming top-level fixity declarations with a different code path (`rnSrcFixityDecl`) than the code path for fixity declarations inside of type classes, which is not privy to names that exist in the type namespace. Luckily, the fix is simple: use `rnSrcFixityDecl` in both places. Test Plan: make test TEST=T10816 Reviewers: austin, bgamari, simonpj Reviewed By: simonpj Subscribers: simonpj, rwbarton, thomie GHC Trac Issues: #10816 Differential Revision: https://phabricator.haskell.org/D4077
Diffstat (limited to 'testsuite')
-rw-r--r--testsuite/tests/rename/should_compile/T10816.hs11
-rw-r--r--testsuite/tests/rename/should_compile/all.T1
2 files changed, 12 insertions, 0 deletions
diff --git a/testsuite/tests/rename/should_compile/T10816.hs b/testsuite/tests/rename/should_compile/T10816.hs
new file mode 100644
index 0000000000..3f8cc604f0
--- /dev/null
+++ b/testsuite/tests/rename/should_compile/T10816.hs
@@ -0,0 +1,11 @@
+{-# LANGUAGE TypeOperators, TypeFamilies #-}
+module T10816 where
+
+class C a where
+ type a # b
+ infix 4 #
+
+ type a *** b
+ type a +++ b
+ infixr 5 ***, +++
+ (***), (+++) :: a -> a -> a
diff --git a/testsuite/tests/rename/should_compile/all.T b/testsuite/tests/rename/should_compile/all.T
index 0b46f90e17..4eb584febe 100644
--- a/testsuite/tests/rename/should_compile/all.T
+++ b/testsuite/tests/rename/should_compile/all.T
@@ -139,6 +139,7 @@ test('T7969', [], run_command, ['$MAKE -s --no-print-directory T7969'])
test('T9127', normal, compile, [''])
test('T4426', normal, compile_fail, [''])
test('T9778', normal, compile, ['-fwarn-unticked-promoted-constructors'])
+test('T10816', normal, compile, [''])
test('T11164', [], multimod_compile, ['T11164', '-v0'])
test('T11167', normal, compile, [''])
test('T11167_ambig', normal, compile, [''])