[GHC] #10524: PolyKinds doesn't interact well with DeriveFunctor
GHC
ghc-devs at haskell.org
Tue Jun 16 22:48:12 UTC 2015
#10524: PolyKinds doesn't interact well with DeriveFunctor
-------------------------------------+-------------------------------------
Reporter: RyanGlScott | Owner:
Type: bug | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 7.10.1
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
Type of failure: GHC rejects | Unknown/Multiple
valid program | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Revisions:
-------------------------------------+-------------------------------------
Comment (by RyanGlScott):
Oh, right. So in both GHC 7.10 and 7.11, the derived kinds for the type
variables in {{{(Functor f, Functor g) => Functor (Compose f g)}}} are
incorrect, but GHC 7.11 defers the errors until later.
In that case, can this can of problem be fixed? Would {{{deriving}}}
clauses always be able to infer the correct kinds, or would it be
necessary in some cases to specify the kinds in a standalone
{{{deriving}}} statement, e.g.,
{{{#!hs
deriving instance (Functor (f :: * -> *), Functor (g :: * -> *)) =>
Functor (Compose f g)
}}}
(The kind signatures wouldn't be needed here due to the explicit
{{{Functor}}} constraint, but you get the idea.)
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/10524#comment:4>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list