summaryrefslogtreecommitdiff
path: root/testsuite/tests/deriving
diff options
context:
space:
mode:
authorRyan Scott <ryan.gl.scott@gmail.com>2018-01-21 12:06:06 -0500
committerBen Gamari <ben@smart-cactus.org>2018-01-21 12:06:07 -0500
commit0074a08ea9dfd1416aa57a9504be73dcdf7a1e2b (patch)
treeaf5e2f5873f3ef7643caa3af4e24733bca6dba21 /testsuite/tests/deriving
parent765ba657c08453615521f5cb0b2418512e606743 (diff)
downloadhaskell-0074a08ea9dfd1416aa57a9504be73dcdf7a1e2b.tar.gz
Fix #14692 by correcting an off-by-one error in TcGenDeriv
A silly mistake in `gen_Show_binds` was causing derived `Show` instances for empty data types to case on the precedence argument instead of the actual value being showed. Test Plan: make test TEST=drv-empty-data Reviewers: bgamari Reviewed By: bgamari Subscribers: rwbarton, thomie, carter GHC Trac Issues: #14692 Differential Revision: https://phabricator.haskell.org/D4328
Diffstat (limited to 'testsuite/tests/deriving')
-rw-r--r--testsuite/tests/deriving/should_compile/drv-empty-data.stderr2
1 files changed, 1 insertions, 1 deletions
diff --git a/testsuite/tests/deriving/should_compile/drv-empty-data.stderr b/testsuite/tests/deriving/should_compile/drv-empty-data.stderr
index e131c1cf5b..5baf6a6c6e 100644
--- a/testsuite/tests/deriving/should_compile/drv-empty-data.stderr
+++ b/testsuite/tests/deriving/should_compile/drv-empty-data.stderr
@@ -7,7 +7,7 @@ Derived class instances:
GHC.Read.readListPrec = GHC.Read.readListPrecDefault
instance GHC.Show.Show (DrvEmptyData.Void a) where
- GHC.Show.showsPrec z = case z of
+ GHC.Show.showsPrec _ z = case z of
instance GHC.Classes.Ord (DrvEmptyData.Void a) where
GHC.Classes.compare _ z = GHC.Types.EQ