[GHC] #13192: Ambiguity Caused By PolyKind and Not Helpful Error Messages

GHC ghc-devs at haskell.org
Fri Jan 27 14:40:56 UTC 2017


#13192: Ambiguity Caused By PolyKind and Not Helpful Error Messages
-------------------------------------+-------------------------------------
        Reporter:  Shayan-Najd       |                Owner:
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  Compiler          |              Version:  8.1
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
 Type of failure:  Poor/confusing    |  Unknown/Multiple
  error message                      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by rwbarton):

 Why does it also not work if I change the definition of `F` to
 {{{
 type family   F  (x :: *) :: k
 }}}
 in which case ghci tells me the instance is
 {{{
 type instance F k (I k a) = a   -- Defined at I.hs:7:16
 }}}
 but ghc gives the same error regarding `identity`. Is `k` not determined
 by the result kind of the type family, i.e., the fact that `F (I a)`
 appears as a type argument to `(->)`?

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/13192#comment:2>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list