[GHC] #9117: Coercible constraint solver misses one

GHC ghc-devs at haskell.org
Fri May 16 02:12:50 UTC 2014


#9117: Coercible constraint solver misses one
-------------------------------------+------------------------------------
        Reporter:  goldfire          |            Owner:  nomeata
            Type:  bug               |           Status:  new
        Priority:  normal            |        Milestone:
       Component:  Compiler          |          Version:  7.8.2
      Resolution:                    |         Keywords:
Operating System:  Unknown/Multiple  |     Architecture:  Unknown/Multiple
 Type of failure:  None/Unknown      |       Difficulty:  Unknown
       Test Case:                    |       Blocked By:
        Blocking:                    |  Related Tickets:
-------------------------------------+------------------------------------

Comment (by goldfire):

 But doesn't the constraint solver already deal with overlap somehow? For
 example, if we have `newtype MyMaybe a = Mk (Maybe a)`, and we want
 `Coercible (MyMaybe Int) (MyMaybe Age)`, there are two ways to get
 this.... unless there is a role annotation on `MyMaybe`, meaning only the
 unwrap-coerce-wrap solution is available, or unless the constructor is not
 available, when only the coerce-directly solution is available. So, if
 this all works, there has to be some way of dealing with the overlap and a
 small amount of "search". Is the case in this ticket somehow
 different/worse?

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


More information about the ghc-tickets mailing list