[GHC] #14938: Pattern matching on GADT does not refine type family parameters

GHC ghc-devs at haskell.org
Mon Mar 19 14:40:19 UTC 2018


#14938: Pattern matching on GADT does not refine type family parameters
-------------------------------------+-------------------------------------
        Reporter:  kcsongor          |                Owner:  (none)
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  Compiler (Type    |              Version:  8.2.2
  checker)                           |             Keywords:  GADTs,
      Resolution:                    |  TypeFamilies
Operating System:  Unknown/Multiple  |         Architecture:
 Type of failure:  GHC rejects       |  Unknown/Multiple
  valid program                      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by RyanGlScott):

 I'd be OK with requiring the user write `R x x Refl`. But in that case,
 the error message is pretty darn misleading. It's complaining about
 `Refl`, but the real error is due to the fact that `x` and `y` are
 distinct, right?

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


More information about the ghc-tickets mailing list