[GHC] #9117: Coercible constraint solver misses one
GHC
ghc-devs at haskell.org
Fri May 16 07:30:23 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 nomeata):
> So, if this all works, there has to be some way of dealing with the
overlap and a small amount of "search".
Well, the way is „do whatever comes first“. It works because the rewrite
system is confluent (I hope that’s the right term), i.e. we don’t run into
dead ends if we do on or the other first.
> Is the case in this ticket somehow different/worse?
Yes, as `Coercible Foo1 Foo2` would be a dead end.
It ''might'' work to try `Coercible f g => Coercion (f a) (g a)` only if
no other instance matches. The code is able to do so, but I don’t
particularly like that. We can add it if we don’t have a better idea
''and'' there there is a use case for it.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9117#comment:5>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list