[commit: ghc] ghc-8.0: Special-case implicit params in superclass expansion (6217147)
git at git.haskell.org
git at git.haskell.org
Mon Jan 25 15:58:03 UTC 2016
Repository : ssh://git@git.haskell.org/ghc
On branch : ghc-8.0
Link : http://ghc.haskell.org/trac/ghc/changeset/6217147e0895e98b08e597660ea941a544943a4d/ghc
>---------------------------------------------------------------
commit 6217147e0895e98b08e597660ea941a544943a4d
Author: Simon Peyton Jones <simonpj at microsoft.com>
Date: Fri Jan 22 16:34:18 2016 +0000
Special-case implicit params in superclass expansion
This issue came up in Trac #11480, and is documented in
Note [When superclasses help] in TcRnTypes.
We were getting a spurious warning
T11480.hs:1:1: warning:
solveWanteds: too many iterations (limit = 4)
The fix is easy. A bit of refactoring along the way.
The original bug report in Trac #11480 appears to work
fine in HEAD and the 8.0 branch but I added a regression
test in this commit as well.
(cherry picked from commit ff21795a0b9253e811a45626d5686e981ed07f82)
>---------------------------------------------------------------
6217147e0895e98b08e597660ea941a544943a4d
compiler/typecheck/TcCanonical.hs | 11 +--
compiler/typecheck/TcRnTypes.hs | 81 +++++++++++++++++-----
compiler/typecheck/TcSMonad.hs | 9 +--
compiler/typecheck/TcSimplify.hs | 12 +++-
testsuite/tests/polykinds/T11480a.hs | 26 +++++++
testsuite/tests/polykinds/all.T | 1 +
testsuite/tests/typecheck/should_compile/T11480.hs | 9 +++
testsuite/tests/typecheck/should_compile/all.T | 1 +
8 files changed, 118 insertions(+), 32 deletions(-)
Diff suppressed because of size. To see it, use:
git diff-tree --root --patch-with-stat --no-color --find-copies-harder --ignore-space-at-eol --cc 6217147e0895e98b08e597660ea941a544943a4d
More information about the ghc-commits
mailing list