[GHC] #15711: Kind inference of class variables does not examine associated types
GHC
ghc-devs at haskell.org
Fri Oct 5 21:25:07 UTC 2018
#15711: Kind inference of class variables does not examine associated types
-------------------------------------+-------------------------------------
Reporter: goldfire | Owner: (none)
Type: bug | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 8.6.1
Keywords: TypeInType | Operating System: Unknown/Multiple
Architecture: | Type of failure: None/Unknown
Unknown/Multiple |
Test Case: | Blocked By:
Blocking: | Related Tickets:
Differential Rev(s): | Wiki Page:
-------------------------------------+-------------------------------------
If I say this
{{{
{-# LANGUAGE TypeFamilies, PolyKinds, DataKinds #-}
module Bug where
class C a where
type F (x :: Maybe a)
}}}
then GHCi says this
{{{
*Bug> :k C
C :: k -> Constraint
}}}
That's silly. `C` should have kind `Type -> Constraint`, because the usage
of `a` in the kind of the associated type constraints `a`'s kind.
Will fix.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/15711>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list