summaryrefslogtreecommitdiff
path: root/testsuite/tests/typecheck/should_fail/T14048a.stderr
diff options
context:
space:
mode:
authorRyan Scott <ryan.gl.scott@gmail.com>2019-06-15 20:21:34 -0400
committerMarge Bot <ben+marge-bot@smart-cactus.org>2019-06-23 17:20:41 -0400
commit9bbcc3be51180dcefde0c89daf8ad6f69c680b40 (patch)
tree48f73da9fec88627232dbddbef7221e268085849 /testsuite/tests/typecheck/should_fail/T14048a.stderr
parent5a502cd1431b535a12dced0479b75c5f7dbfb01c (diff)
downloadhaskell-9bbcc3be51180dcefde0c89daf8ad6f69c680b40.tar.gz
Refactor UnliftedNewtypes-relation kind signature validity checks
This fixes three infelicities related to the programs that are (and aren't) accepted with `UnliftedNewtypes`: * Enabling `UnliftedNewtypes` would permit newtypes to have return kind `Id Type`, which had disastrous results (i.e., GHC panics). * Data family declarations ending in kind `TYPE r` (for some `r`) weren't being accepted if `UnliftedNewtypes` wasn't enabled, despite the GHC proposal specifying otherwise. * GHC wasn't warning about programs that _would_ typecheck if `UnliftedNewtypes` were enabled in certain common cases. As part of fixing these issues, I factored out the logic for checking all of the various properties about data type/data family return kinds into a single `checkDataKindSig` function. I also cleaned up some of the formatting in the existing error message that gets thrown. Fixes #16821, fixes #16827, and fixes #16829.
Diffstat (limited to 'testsuite/tests/typecheck/should_fail/T14048a.stderr')
-rw-r--r--testsuite/tests/typecheck/should_fail/T14048a.stderr4
1 files changed, 2 insertions, 2 deletions
diff --git a/testsuite/tests/typecheck/should_fail/T14048a.stderr b/testsuite/tests/typecheck/should_fail/T14048a.stderr
index 48a91c7525..d75b423df3 100644
--- a/testsuite/tests/typecheck/should_fail/T14048a.stderr
+++ b/testsuite/tests/typecheck/should_fail/T14048a.stderr
@@ -1,5 +1,5 @@
T14048a.hs:6:1: error:
- • Kind signature on data type declaration has non-* return kind
- Constraint
+ • Kind signature on data type declaration has non-*
+ return kind ‘Constraint’
• In the data declaration for ‘Foo’