summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJose Pedro Magalhaes <jpm@cs.uu.nl>2011-11-16 16:09:10 +0000
committerJose Pedro Magalhaes <jpm@cs.uu.nl>2011-11-16 20:47:39 +0100
commit8c44438de7ef0b599d80f3ee7713a4c8b46fc647 (patch)
tree2045f2bb22879013c2088b6362f01935806bb852
parent6c094deac50fdc707e9d4d8d3e7e8a5392f58d3d (diff)
downloadhaskell-8c44438de7ef0b599d80f3ee7713a4c8b46fc647.tar.gz
Add kind annotations
This is now necessary because previously we were being too liberal in figuring out the kinds of phantom type variables.
-rw-r--r--testsuite/tests/indexed-types/should_compile/OversatDecomp.hs2
-rw-r--r--testsuite/tests/simplCore/should_compile/T4903a.hs2
-rw-r--r--testsuite/tests/simplCore/should_compile/T5303.hs2
-rw-r--r--testsuite/tests/typecheck/should_compile/T1470.hs4
-rw-r--r--testsuite/tests/typecheck/should_compile/T3018.hs2
-rw-r--r--testsuite/tests/typecheck/should_compile/T4969.hs5
6 files changed, 9 insertions, 8 deletions
diff --git a/testsuite/tests/indexed-types/should_compile/OversatDecomp.hs b/testsuite/tests/indexed-types/should_compile/OversatDecomp.hs
index a93256c92c..898c4d8e06 100644
--- a/testsuite/tests/indexed-types/should_compile/OversatDecomp.hs
+++ b/testsuite/tests/indexed-types/should_compile/OversatDecomp.hs
@@ -5,7 +5,7 @@ module OversatDecomp where
class Blah f a where
blah :: a -> T f f a
-class A f where
+class A (f :: * -> *) where
type T f :: (* -> *) -> * -> *
wrapper :: Blah f a => a -> T f f a
diff --git a/testsuite/tests/simplCore/should_compile/T4903a.hs b/testsuite/tests/simplCore/should_compile/T4903a.hs
index e78859c55f..8c8700038e 100644
--- a/testsuite/tests/simplCore/should_compile/T4903a.hs
+++ b/testsuite/tests/simplCore/should_compile/T4903a.hs
@@ -14,7 +14,7 @@ class El phi ix where
class Fam phi where
from :: phi ix -> ix -> PF phi I0 ix
-type family PF phi :: (* -> *) -> * -> *
+type family PF (phi :: * -> *) :: (* -> *) -> * -> *
data I0 a = I0 a
diff --git a/testsuite/tests/simplCore/should_compile/T5303.hs b/testsuite/tests/simplCore/should_compile/T5303.hs
index b19eb22dff..18a4f982c0 100644
--- a/testsuite/tests/simplCore/should_compile/T5303.hs
+++ b/testsuite/tests/simplCore/should_compile/T5303.hs
@@ -4,7 +4,7 @@ module T5303( showContextSeries ) where
import Control.Monad.State.Strict( StateT )
import Control.Monad.Trans ( lift )
-data Tree m = Tree {}
+data Tree (m :: * -> *) = Tree {}
data FL (a :: * -> * -> *) x z where
(:>:) :: a x y -> FL a y z -> FL a x z
diff --git a/testsuite/tests/typecheck/should_compile/T1470.hs b/testsuite/tests/typecheck/should_compile/T1470.hs
index 8419a94627..d466e487e9 100644
--- a/testsuite/tests/typecheck/should_compile/T1470.hs
+++ b/testsuite/tests/typecheck/should_compile/T1470.hs
@@ -1,11 +1,11 @@
-{-# LANGUAGE MultiParamTypeClasses, FlexibleContexts, FlexibleInstances, OverlappingInstances, UndecidableInstances #-}
+{-# LANGUAGE MultiParamTypeClasses, FlexibleContexts, FlexibleInstances, OverlappingInstances, UndecidableInstances, KindSignatures #-}
-- Trac #1470
module Foo where
class Sat a
-class Data ctx a
+class Data (ctx :: * -> *) a
instance Sat (ctx Char) => Data ctx Char
instance (Sat (ctx [a]), Data ctx a) => Data ctx [a]
diff --git a/testsuite/tests/typecheck/should_compile/T3018.hs b/testsuite/tests/typecheck/should_compile/T3018.hs
index 9ef5b56e60..ffecfc2788 100644
--- a/testsuite/tests/typecheck/should_compile/T3018.hs
+++ b/testsuite/tests/typecheck/should_compile/T3018.hs
@@ -8,7 +8,7 @@ module T3018 where
import Control.Monad
-- minimal Data/Rep classes
-data Rep ctx a
+data Rep (ctx :: * -> *) a
class Data (ctx :: * -> *) a where rep :: Rep ctx a
diff --git a/testsuite/tests/typecheck/should_compile/T4969.hs b/testsuite/tests/typecheck/should_compile/T4969.hs
index 084420e660..ce2e820f22 100644
--- a/testsuite/tests/typecheck/should_compile/T4969.hs
+++ b/testsuite/tests/typecheck/should_compile/T4969.hs
@@ -1,7 +1,8 @@
{-# OPTIONS_GHC -w #-}
{-# LANGUAGE MultiParamTypeClasses, FunctionalDependencies,
FlexibleContexts, FlexibleInstances,
- OverlappingInstances, UndecidableInstances #-}
+ OverlappingInstances, UndecidableInstances,
+ KindSignatures #-}
-- Cut down from a larger core-lint error
@@ -26,7 +27,7 @@ data FreshThings = Fresh
newtype NewName a = NewName a
newtype LetDef = LetDef NiceDeclaration
-newtype TCMT m a = TCM ()
+newtype TCMT (m :: * -> *) a = TCM ()
localToAbstract :: ToAbstract c a => c -> (a -> TCMT IO b) -> TCMT IO b
localToAbstract = undefined