[commit: ghc] master: Expand given superclasses more eagerly (ce97b72)

git at git.haskell.org git at git.haskell.org
Wed Jun 22 21:18:19 UTC 2016


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/ce97b7298d54bdfccd9dcf366a69c5617b4eb43f/ghc

>---------------------------------------------------------------

commit ce97b7298d54bdfccd9dcf366a69c5617b4eb43f
Author: Simon Peyton Jones <simonpj at microsoft.com>
Date:   Wed Jun 22 14:17:58 2016 +0100

    Expand given superclasses more eagerly
    
    This patch fixes Trac #12175, another delicate corner case of
    Note [Instance and Given overlap] in TcInteract.
    
    In #12175 we were not expanding given superclasses eagerly
    enough. It was easy to fix, and is actually rather neater than
    before.
    
    See Note [Eagerly expand given superclasses] in TcCanonical.
    The main change is to move the eager expansion of given superclasses
    to canClassNC.


>---------------------------------------------------------------

ce97b7298d54bdfccd9dcf366a69c5617b4eb43f
 compiler/typecheck/TcCanonical.hs                  | 87 ++++++++++++++--------
 compiler/typecheck/TcInteract.hs                   | 10 ++-
 compiler/typecheck/TcRnTypes.hs                    | 10 ++-
 compiler/typecheck/TcSMonad.hs                     |  2 +-
 compiler/typecheck/TcSimplify.hs                   | 12 +--
 .../tests/indexed-types/should_compile/T12175.hs   | 36 +++++++++
 testsuite/tests/indexed-types/should_compile/all.T |  1 +
 7 files changed, 113 insertions(+), 45 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 ce97b7298d54bdfccd9dcf366a69c5617b4eb43f


More information about the ghc-commits mailing list