HEAD: `KnownNat` does not imply `Typeable` any more
As Iavor confirmed (https://mail.haskell.org/pipermail/ghc-devs/2015-April/008885.html) there is a regression on HEAD relative to ghc-7.11.20150215. Here is a reproduction snippet:
{-# LANGUAGE AutoDeriveTypeable, GADTs, DataKinds, KindSignatures, StandaloneDeriving #-}
import GHC.TypeLits
import Data.Typeable
data Foo (n :: Nat) where
Hey :: KnownNat n => Foo n
deriving instance Show (Foo n)
data T t where
T :: (Show t, Typeable t) => t -> T t
deriving instance Show (T n)
With ghci-7.11.20150407 I now see more constraints
*Main> :t T Hey
T Hey :: (Typeable n, KnownNat n) => T (Foo n)
OTOH ghci-7.11.20150215 only wanted KnownNat:
*Main> :t T Hey
T Hey :: KnownNat n => T (Foo n)
Trac metadata
| Trac field | Value |
|---|---|
| Version | 7.11 |
| Type | Bug |
| TypeOfFailure | OtherFailure |
| Priority | normal |
| Resolution | Unresolved |
| Component | Compiler (Type checker) |
| Test case | |
| Differential revisions | |
| BlockedBy | |
| Related | |
| Blocking | |
| CC | |
| Operating system | |
| Architecture |