[commit: ghc] master: Fix error recovery for pattern synonyms (2896082)

git at git.haskell.org git at git.haskell.org
Mon Jun 25 14:35:13 UTC 2018


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

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

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

commit 2896082ec79f02b6388e038a8dae6cb22fe72dfc
Author: Simon Peyton Jones <simonpj at microsoft.com>
Date:   Mon Jun 25 11:42:46 2018 +0100

    Fix error recovery for pattern synonyms
    
    As Trac #15289 showed, we were carrying on after a type error
    in a pattern synonym, and then crashing.  This patch improves
    error handling for pattern synonyms.
    
    I also moved a bit of code from TcBinds into TcPatSyn, which
    helpfully narrows the API.


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

2896082ec79f02b6388e038a8dae6cb22fe72dfc
 compiler/typecheck/TcBinds.hs                    | 11 +--
 compiler/typecheck/TcPatSyn.hs                   | 86 ++++++++++++++++++++----
 compiler/typecheck/TcPatSyn.hs-boot              | 12 ++--
 testsuite/tests/patsyn/should_fail/T15289.stderr | 21 +++---
 testsuite/tests/patsyn/should_fail/all.T         |  2 +-
 5 files changed, 95 insertions(+), 37 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 2896082ec79f02b6388e038a8dae6cb22fe72dfc


More information about the ghc-commits mailing list