[GHC] #13337: GHC doesn't think a type is of kind *, despite having evidence for it

GHC ghc-devs at haskell.org
Tue Mar 14 19:12:59 UTC 2017


#13337: GHC doesn't think a type is of kind *, despite having evidence for it
-------------------------------------+-------------------------------------
        Reporter:  RyanGlScott       |                Owner:  goldfire
            Type:  bug               |               Status:  patch
        Priority:  normal            |            Milestone:  8.2.1
       Component:  Compiler (Type    |              Version:  8.0.2
  checker)                           |
      Resolution:                    |             Keywords:  TypeInType
Operating System:  Unknown/Multiple  |         Architecture:
 Type of failure:  GHC rejects       |  Unknown/Multiple
  valid program                      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):  Phab:D3315
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by Ben Gamari <ben@…>):

 In [changeset:"e0c433c81182c934ee4c4cc5c6cf25a1b6fb8d83/ghc"
 e0c433c8/ghc]:
 {{{
 #!CommitTicketReference repository="ghc"
 revision="e0c433c81182c934ee4c4cc5c6cf25a1b6fb8d83"
 Fix #13337.

 The big change is the introduction of solveSomeEqualities. This
 is just like solveEqualities, but it doesn't fail if there are unsolved
 equalities when it's all done. Anything unsolved is re-emitted. This
 is appropriate if we are not kind-generalizing, so this new form
 is used when decideKindGeneralizationPlan says not to.

 We initially thought that any use of solveEqualities would be tied
 to kind generalization, but this isn't true. For example, we need
 to solveEqualities a bunch in the "tc" pass in TcTyClsDecls (which
 is really desugaring). These equalities are all surely going to be
 soluble (if they weren't the "kc" pass would fail), but we still
 need to solve them again. Perhaps if the "kc" pass produced type-
 checked output that is then desugared, solveEqualities really would
 be tied only to kind generalization.

 Updates haddock submodule.

 Test Plan: ./validate, typecheck/should_compile/T13337

 Reviewers: simonpj, bgamari, austin

 Reviewed By: simonpj

 Subscribers: RyanGlScott, rwbarton, thomie

 Differential Revision: https://phabricator.haskell.org/D3315
 }}}

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


More information about the ghc-tickets mailing list