[commit: ghc] master: Test Trac #10742 (64dba51)

git at git.haskell.org git at git.haskell.org
Thu Aug 6 13:50:25 UTC 2015


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/64dba5119fdecb4a5b6a2993919a963d02171783/ghc

>---------------------------------------------------------------

commit 64dba5119fdecb4a5b6a2993919a963d02171783
Author: Simon Peyton Jones <simonpj at microsoft.com>
Date:   Thu Aug 6 14:50:35 2015 +0100

    Test Trac #10742


>---------------------------------------------------------------

64dba5119fdecb4a5b6a2993919a963d02171783
 testsuite/tests/polykinds/T10742.hs | 14 ++++++++++++++
 testsuite/tests/polykinds/all.T     |  1 +
 2 files changed, 15 insertions(+)

diff --git a/testsuite/tests/polykinds/T10742.hs b/testsuite/tests/polykinds/T10742.hs
new file mode 100644
index 0000000..3b0b1a7
--- /dev/null
+++ b/testsuite/tests/polykinds/T10742.hs
@@ -0,0 +1,14 @@
+{-# LANGUAGE GADTs #-}
+{-# LANGUAGE DataKinds #-}
+{-# LANGUAGE TypeOperators #-}
+{-# OPTIONS_GHC -fno-warn-redundant-constraints #-}
+
+module T10742 where
+
+import GHC.TypeLits
+
+data T a where MkT :: T Int
+
+test :: ((x <=? y) ~ 'True, (y <=? z) ~ 'True)
+     => proxy x y z -> ()
+test _ = case MkT of MkT -> ()
diff --git a/testsuite/tests/polykinds/all.T b/testsuite/tests/polykinds/all.T
index 55041dc..c073c1b 100644
--- a/testsuite/tests/polykinds/all.T
+++ b/testsuite/tests/polykinds/all.T
@@ -120,3 +120,4 @@ test('T10570', normal, compile_fail, [''])
 test('T10670', normal, compile, [''])
 test('T10670a', normal, compile, [''])
 test('T10134', normal, multimod_compile, ['T10134.hs','-v0'])
+test('T10742', normal, compile, [''])



More information about the ghc-commits mailing list