[commit: ghc] master: Fix #14578 by checking isCompoundHsType in more places (1bd91a7)

git at git.haskell.org git at git.haskell.org
Thu Dec 21 00:44:21 UTC 2017


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

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

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

commit 1bd91a7ac60eba3b0c019e2228f4b2b07f8cd5ad
Author: Ryan Scott <ryan.gl.scott at gmail.com>
Date:   Wed Dec 20 19:25:18 2017 -0500

    Fix #14578 by checking isCompoundHsType in more places
    
    Summary:
    The `HsType` pretty-printer does not automatically insert
    parentheses where necessary for type applications, so a function
    `isCompoundHsType` was created in D4056 towards this purpose.
    However, it was not used in as many places as it ought to be,
    resulting in #14578.
    
    Test Plan: make test TEST=T14578
    
    Reviewers: alanz, bgamari, simonpj
    
    Reviewed By: alanz, simonpj
    
    Subscribers: simonpj, rwbarton, thomie, carter
    
    GHC Trac Issues: #14578
    
    Differential Revision: https://phabricator.haskell.org/D4266


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

1bd91a7ac60eba3b0c019e2228f4b2b07f8cd5ad
 compiler/hsSyn/HsTypes.hs                          |  12 ++-
 compiler/hsSyn/HsUtils.hs                          |   8 +-
 testsuite/tests/deriving/should_compile/T14578.hs  |  15 +++
 .../tests/deriving/should_compile/T14578.stderr    | 115 +++++++++++++++++++++
 testsuite/tests/deriving/should_compile/all.T      |   1 +
 5 files changed, 145 insertions(+), 6 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 1bd91a7ac60eba3b0c019e2228f4b2b07f8cd5ad


More information about the ghc-commits mailing list