[GHC] #12468: GADTs don't refine hole types

GHC ghc-devs at haskell.org
Wed Aug 10 22:50:22 UTC 2016


#12468: GADTs don't refine hole types
-------------------------------------+-------------------------------------
        Reporter:  benjamin.hodgson  |                Owner:
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  Compiler (Type    |              Version:  8.0.1
  checker)                           |
      Resolution:                    |             Keywords:
Operating System:  MacOS X           |         Architecture:
 Type of failure:  Incorrect         |  Unknown/Multiple
  warning at compile-time            |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by benjamin.hodgson):

 Thanks for the reply! I see what you mean about `a` and `Int` both being
 good options to show for the hole type. However, I do think it would still
 be helpful to have ''some'' indicator in the error message of the fact
 that the context gives us a useful equality. Something along the lines of:

 {{{
     • Found hole: _ :: a
       ...
     • NB: a ~ [b]
 }}}

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


More information about the ghc-tickets mailing list