[commit: ghc] master: testsuite: Add test for #15067 (0f046aa)
git at git.haskell.org
git at git.haskell.org
Sat May 5 17:27:28 UTC 2018
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/0f046aae5c9552771e489dac8531744034f37cde/ghc
>---------------------------------------------------------------
commit 0f046aae5c9552771e489dac8531744034f37cde
Author: Ben Gamari <bgamari.foss at gmail.com>
Date: Fri May 4 14:26:30 2018 -0400
testsuite: Add test for #15067
Subscribers: thomie, carter, RyanGlScott
GHC Trac Issues: #15067
Differential Revision: https://phabricator.haskell.org/D4622
>---------------------------------------------------------------
0f046aae5c9552771e489dac8531744034f37cde
testsuite/tests/typecheck/should_fail/T15067.hs | 10 ++++++++++
testsuite/tests/typecheck/should_fail/T15067.stderr | 13 +++++++++++++
testsuite/tests/typecheck/should_fail/all.T | 1 +
3 files changed, 24 insertions(+)
diff --git a/testsuite/tests/typecheck/should_fail/T15067.hs b/testsuite/tests/typecheck/should_fail/T15067.hs
new file mode 100644
index 0000000..ff093db
--- /dev/null
+++ b/testsuite/tests/typecheck/should_fail/T15067.hs
@@ -0,0 +1,10 @@
+{-# LANGUAGE UnboxedSums #-}
+module T15067 where
+
+import Type.Reflection
+
+floopadoop :: TypeRep (# Bool | Int #)
+floopadoop = typeRep
+
+rubadub :: (# True | 4 #)
+rubadub = typeRep
diff --git a/testsuite/tests/typecheck/should_fail/T15067.stderr b/testsuite/tests/typecheck/should_fail/T15067.stderr
new file mode 100644
index 0000000..a16d799
--- /dev/null
+++ b/testsuite/tests/typecheck/should_fail/T15067.stderr
@@ -0,0 +1,13 @@
+
+T15067.hs:7:14:
+ No instance for (Typeable (# 'GHC.Types.LiftedRep #))
+ arising from a use of ‘typeRep’
+ GHC can't yet do polykinded
+ Typeable ((# 'GHC.Types.LiftedRep #) :: *
+ -> *
+ -> TYPE
+ ('GHC.Types.SumRep
+ '['GHC.Types.LiftedRep,
+ 'GHC.Types.LiftedRep]))
+ In the expression: typeRep
+ In an equation for ‘floopadoop’: floopadoop = typeRep
diff --git a/testsuite/tests/typecheck/should_fail/all.T b/testsuite/tests/typecheck/should_fail/all.T
index a4150ea..9dd00f8 100644
--- a/testsuite/tests/typecheck/should_fail/all.T
+++ b/testsuite/tests/typecheck/should_fail/all.T
@@ -473,3 +473,4 @@ test('T14761b', normal, compile_fail, [''])
test('T14884', normal, compile_fail, [''])
test('T14904a', normal, compile_fail, [''])
test('T14904b', normal, compile_fail, [''])
+test('T15067', expect_broken(15067), compile_fail, [''])
More information about the ghc-commits
mailing list