[GHC] #11621: GHC doesn't see () as a Constraint in type family

GHC ghc-devs at haskell.org
Mon Dec 3 16:23:20 UTC 2018


#11621: GHC doesn't see () as a Constraint in type family
-------------------------------------+-------------------------------------
        Reporter:  Iceland_jack      |                Owner:  (none)
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  Compiler (Type    |              Version:  7.10.1
  checker)                           |             Keywords:
      Resolution:                    |  ConstraintKinds
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:  #11715, #13742    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------
Changes (by RyanGlScott):

 * related:  #11715 => #11715, #13742


Comment:

 Astoundingly, this program appears to have fixed itself between GHC 8.4
 and 8.6, since this program:

 {{{#!hs
 {-# LANGUAGE DataKinds, TypeOperators, KindSignatures,
 MultiParamTypeClasses, TypeFamilies #-}

 import GHC.Exts

 class NotFound

 type family
   F b where
   F 'False = NotFound
   F 'True  = ()
 }}}

 Typechecks without issue on GHC 8.6.2 and HEAD. Should we go ahead and add
 a test case for this, or is this program fragile without a full fix for
 #11715?

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


More information about the ghc-tickets mailing list