[GHC] #10493: Inaccessible code might be accessible with newtypes and Coercible
GHC
ghc-devs at haskell.org
Thu Oct 22 10:33:09 UTC 2015
#10493: Inaccessible code might be accessible with newtypes and Coercible
-------------------------------------+-------------------------------------
Reporter: goldfire | Owner: goldfire
Type: bug | Status: closed
Priority: normal | Milestone: 7.10.3
Component: Compiler | Version: 7.10.1
Resolution: fixed | Keywords:
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: None/Unknown | Test Case:
| typecheck/should_compile/T10493
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by bgamari):
Unfortunately while this fix was quite straightforward to merge to
`ghc-7.10`, it turns out that (I believe) we would also need merge this as
well for the fix to be effective,
{{{
commit ff82387d6fe61762fe4f507e8f9799f5bdc3c43a
Author: Richard Eisenberg <eir at cis.upenn.edu>
Date: Mon Jun 8 22:32:40 2015 -0400
Decompose wanted repr. eqs. when no matchable givens.
This is pursuant to a conversion with SPJ, where we agreed that
the logic behind Note [Instance and Given overlap] in TcInteract
applied to newtype decomposition for representational equality.
There is no bug report or test case, as tickling this kind of thing
is quite hard to do!
}}}
which is itself dependent upon,
{{{
commit 228ddb95ee137e7cef02dcfe2521233892dd61e0
Author: Simon Peyton Jones <simonpj at microsoft.com>
Date: Wed May 13 12:49:13 2015 +0100
Make the "matchable-given" check happen first
This change makes the matchable-given check apply uniformly to
- constraint tuples
- natural numbers
- Typeable
as well as to vanilla class constraints.
See Note [Instance and Given overlap] in TcInteract
}}}
which interacts with another patch not present in `ghc-7.10`,
{{{
commit a1275a762ec04c1159ae37199b1c8f998a5c5499
Author: Simon Peyton Jones <simonpj at microsoft.com>
Date: Wed Apr 29 13:43:09 2015 +0100
Improve improvement in the constraint solver
}}}
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/10493#comment:9>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list