Ticket #7020 (closed bug: fixed)
Kind variable generalization problem
Description
Consider the following tangle of definitions:
{-# LANGUAGE KindSignatures, RankNTypes, PolyKinds, GADTs,
FlexibleContexts, DataKinds, TypeFamilies #-}
import GHC.Exts
data family Sing (a :: k)
class SingKind (Any :: k) => SingI (s :: k) where
sing :: Sing s
data SingInstance :: k -> * where
SingInstance :: SingI a => SingInstance a
class (b ~ Any) => SingKind (b :: k) where
singInstance :: forall (a :: k). Sing a -> SingInstance a
When compiling (with 7.5.20120620), I get this error message:
Kind mis-match
The first argument of `SingKind' should have kind `k1',
but `Any' has kind `k'
In the class declaration for `SingI'
I believe that the code should compile, though I'll admit I'm not 100% convinced.
Change History
Note: See
TracTickets for help on using
tickets.
