[GHC] #10125: Improper evaluation of type families

GHC ghc-devs at haskell.org
Mon Mar 2 13:19:58 UTC 2015


#10125: Improper evaluation of type families
-------------------------------------+-------------------------------------
        Reporter:  danilo2           |                   Owner:
            Type:  bug               |                  Status:  closed
        Priority:  high              |               Milestone:
       Component:  Compiler          |                 Version:  7.8.4
      Resolution:  invalid           |                Keywords:
Operating System:  Unknown/Multiple  |            Architecture:
 Type of failure:  None/Unknown      |  Unknown/Multiple
      Blocked By:                    |               Test Case:
 Related Tickets:                    |                Blocking:
                                     |  Differential Revisions:
-------------------------------------+-------------------------------------
Changes (by simonpj):

 * status:  new => closed
 * resolution:   => invalid


Comment:

 It's a bug in GHC 7.8.  The program should be rejected because you have an
 un-saturated application of `CmpNat` on the last line.  I'm afraid that
 GHC's type inference machinery is only capable of dealing with
 ''saturated'' applications of type families.  Sorry.  HEAD and 7.10 reject
 it with a decent message.

 I'll close as invalid because GHC doesn't claim to support it. Many people
 would like to do higher order type-family programming in this way, but
 it's an open question how to do so with predicable type inference.

 Simon

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


More information about the ghc-tickets mailing list