[commit: ghc] master: Fix used-variable calculation (Trac #12548) (6305674)

git at git.haskell.org git at git.haskell.org
Mon Dec 5 17:40:30 UTC 2016


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

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

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

commit 6305674f310633d159a4df4e2e0d033a698599d1
Author: Simon Peyton Jones <simonpj at microsoft.com>
Date:   Mon Dec 5 13:17:35 2016 +0000

    Fix used-variable calculation (Trac #12548)
    
    The used-variable calculation for pattern synonyms is a little
    tricky, for reasons described in RnBinds
    Note [Pattern synonym builders don't yield dependencies]
    
    It was right semantically, but the "unused-variable warning" was
    wrong, which led to Trac #12548.


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

6305674f310633d159a4df4e2e0d033a698599d1
 compiler/hsSyn/HsUtils.hs                       |  8 ++++-
 compiler/rename/RnBinds.hs                      | 48 ++++++++++++++++---------
 compiler/typecheck/TcBinds.hs                   |  1 +
 compiler/typecheck/TcEnv.hs                     |  9 +----
 testsuite/tests/rename/should_compile/T12548.hs | 12 +++++++
 testsuite/tests/rename/should_compile/all.T     |  1 +
 6 files changed, 54 insertions(+), 25 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 6305674f310633d159a4df4e2e0d033a698599d1


More information about the ghc-commits mailing list