summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGabor Greif <ggreif@gmail.com>2015-06-22 15:40:01 +0200
committerGabor Greif <ggreif@gmail.com>2015-06-22 15:42:34 +0200
commite60dbf30adfcc0ba90ed9271239c0c8a7bc14f06 (patch)
tree54f5b4a33db18fd7f79fd8e13de29f18f23d96d8
parentb5a2e8763fcf0e2b4c57e12f2b2e5817e5ce9df0 (diff)
downloadhaskell-e60dbf30adfcc0ba90ed9271239c0c8a7bc14f06.tar.gz
Check KnownSymbol => Typeable deduction
verifying fix for #10348
-rw-r--r--testsuite/tests/typecheck/should_compile/T10348.hs6
1 files changed, 4 insertions, 2 deletions
diff --git a/testsuite/tests/typecheck/should_compile/T10348.hs b/testsuite/tests/typecheck/should_compile/T10348.hs
index 7380d81e09..dadb8aa7cf 100644
--- a/testsuite/tests/typecheck/should_compile/T10348.hs
+++ b/testsuite/tests/typecheck/should_compile/T10348.hs
@@ -1,9 +1,10 @@
-{-# LANGUAGE AutoDeriveTypeable, GADTs, DataKinds, KindSignatures, StandaloneDeriving #-}
+{-# LANGUAGE AutoDeriveTypeable, GADTs, DataKinds, KindSignatures, StandaloneDeriving, TypeOperators #-}
module T10348 where
import GHC.TypeLits
import Data.Typeable
+import Data.Proxy
data Foo (n :: Nat) where
Hey :: KnownNat n => Foo n
@@ -27,4 +28,5 @@ f1 = typeRep
g2 :: KnownSymbol a => Proxy a -> TypeRep
g2 = typeRep
-
+pEqT :: (KnownSymbol a, KnownSymbol b) => Proxy a -> Proxy b -> Maybe (a :~: b)
+pEqT Proxy Proxy = eqT