[commit: ghc] wip/D1934: Print which warning-flag controls an emitted warning. (ed0d72d)

git at git.haskell.org git at git.haskell.org
Tue Feb 23 10:53:54 UTC 2016


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

On branch  : wip/D1934
Link       : http://ghc.haskell.org/trac/ghc/changeset/ed0d72d892b2e70099aaac758343e1e733478c1e/ghc

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

commit ed0d72d892b2e70099aaac758343e1e733478c1e
Author: Michael Walker <mike at barrucadu.co.uk>
Date:   Sat Feb 20 09:15:46 2016 +0100

    Print which warning-flag controls an emitted warning.
    
    Summary:
    Both gcc and clang tell which warning flag a reported warning can be
    controlled with, this patch makes ghc do the same. More generally, this
    allows for annotated compiler output, where an optional annotation is
    displayed in brackets after the severity.
    
    Fixes T10752.
    
    Reviewers: austin, hvr, goldfire, bgamari
    
    Subscribers: goldfire, thomie
    
    Differential Revision: https://phabricator.haskell.org/D1934


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

ed0d72d892b2e70099aaac758343e1e733478c1e
 compiler/coreSyn/CoreLint.hs                       |   7 +-
 compiler/deSugar/Coverage.hs                       |   2 +-
 compiler/ghci/Debugger.hs                          |   2 +-
 compiler/ghci/Linker.hs                            |   7 +-
 compiler/iface/BinIface.hs                         |   4 +-
 compiler/iface/LoadIface.hs                        |   3 +-
 compiler/main/CodeOutput.hs                        |   2 +-
 compiler/main/DriverPipeline.hs                    |   4 +-
 compiler/main/DynFlags.hs                          |  11 ++-
 compiler/main/ErrUtils.hs                          |  46 ++++++---
 compiler/main/ErrUtils.hs-boot                     |   1 +
 compiler/main/GhcMake.hs                           |  12 +--
 compiler/main/SysTools.hs                          |   6 +-
 compiler/main/TidyPgm.hs                           |   3 +-
 compiler/rename/RnBinds.hs                         |   4 +-
 compiler/rename/RnEnv.hs                           |  20 ++--
 compiler/rename/RnNames.hs                         |  80 +++++++++-------
 compiler/rename/RnSource.hs                        |  42 +++++---
 compiler/rename/RnTypes.hs                         |   2 +-
 compiler/simplCore/CoreMonad.hs                    |   2 +-
 compiler/simplCore/SimplCore.hs                    |   3 +-
 compiler/simplStg/SimplStg.hs                      |   3 +-
 compiler/typecheck/Inst.hs                         |   4 +-
 compiler/typecheck/TcAnnotations.hs                |   2 +-
 compiler/typecheck/TcBinds.hs                      |  24 ++---
 compiler/typecheck/TcClassDcl.hs                   |  10 +-
 compiler/typecheck/TcDeriv.hs                      |   6 +-
 compiler/typecheck/TcErrors.hs                     |  16 ++--
 compiler/typecheck/TcExpr.hs                       |   3 +-
 compiler/typecheck/TcForeign.hs                    |   6 +-
 compiler/typecheck/TcInstDcls.hs                   |   4 +-
 compiler/typecheck/TcMatches.hs                    |   3 +-
 compiler/typecheck/TcPat.hs                        |   2 +-
 compiler/typecheck/TcRnDriver.hs                   |   7 +-
 compiler/typecheck/TcRnMonad.hs                    |  92 ++++++++++++------
 compiler/typecheck/TcSMonad.hs                     |   5 +-
 compiler/typecheck/TcSimplify.hs                   |   2 +-
 compiler/typecheck/TcSplice.hs                     |   4 +-
 compiler/typecheck/TcTyClsDecls.hs                 |   4 +-
 compiler/typecheck/TcValidity.hs                   |   5 +-
 ghc/GHCi/UI.hs                                     |   4 +-
 .../tests/deSugar/should_compile/ds041.stderr      |  10 +-
 .../tests/deSugar/should_compile/ds053.stderr      |   3 +-
 .../tests/dependent/should_compile/T11241.stderr   |   2 +-
 .../tests/deriving/should_compile/T4966.stderr     |  10 +-
 .../deriving/should_compile/deriving-1935.stderr   |  24 ++---
 .../tests/deriving/should_compile/drv003.stderr    |  16 ++--
 .../tests/deriving/should_fail/drvfail006.stderr   |  12 ++-
 .../tests/deriving/should_fail/drvfail008.stderr   |  12 ++-
 testsuite/tests/driver/werror.stderr               |  12 ++-
 testsuite/tests/ffi/should_compile/T1357.stderr    |   4 +-
 .../tests/ghc-api/apirecomp001/apirecomp001.stderr |  12 +--
 testsuite/tests/ghci/prog011/prog011.stderr        |   7 +-
 testsuite/tests/ghci/prog011/prog011.stdout        |   3 -
 testsuite/tests/ghci/scripts/T4316.stdout          |   2 -
 testsuite/tests/ghci/scripts/T5820.stderr          |   8 +-
 testsuite/tests/ghci/scripts/T8353.stderr          |   6 +-
 testsuite/tests/ghci/scripts/ghci019.stderr        |   2 +-
 .../haddock/haddock_examples/haddock.Test.stderr   |  12 ++-
 .../indexed-types/should_compile/Class3.stderr     |   8 +-
 .../indexed-types/should_compile/Simple2.stderr    |  48 +++++-----
 .../indexed-types/should_compile/T3023.stderr      |   2 +-
 .../indexed-types/should_compile/T8889.stderr      |   2 +-
 .../should_compile/UnusedTyVarWarnings.stderr      |  13 +--
 .../UnusedTyVarWarningsNamedWCs.stderr             |  10 +-
 .../tests/indexed-types/should_fail/T7862.stderr   |  12 +--
 testsuite/tests/module/mod128.stderr               |   3 +-
 testsuite/tests/module/mod14.stderr                |   2 +-
 testsuite/tests/module/mod176.stderr               |   2 +-
 testsuite/tests/module/mod177.stderr               |   2 +-
 testsuite/tests/module/mod5.stderr                 |   2 +-
 testsuite/tests/module/mod89.stderr                |   4 +-
 .../MonadFailWarningsWithRebindableSyntax.stderr   |   2 +-
 .../should_fail/overloadedrecfldsfail05.stderr     |   2 +-
 .../should_fail/overloadedrecfldsfail06.stderr     |  14 +--
 .../should_fail/overloadedrecfldsfail11.stderr     |   2 +-
 .../should_fail/overloadedrecfldsfail12.stderr     |   6 +-
 testsuite/tests/parser/should_compile/T2245.stderr |   6 +-
 testsuite/tests/parser/should_compile/T3303.stderr |   4 +-
 .../tests/parser/should_compile/read014.stderr     |  10 +-
 .../should_compile/ExprSigLocal.stderr             |   4 +-
 .../partial-sigs/should_compile/SplicesUsed.stderr |  22 ++---
 .../partial-sigs/should_compile/T10403.stderr      |   6 +-
 .../partial-sigs/should_compile/T10438.stderr      |   2 +-
 .../partial-sigs/should_compile/T10463.stderr      |  14 +--
 .../partial-sigs/should_compile/T10519.stderr      |   2 +-
 .../partial-sigs/should_compile/T11016.stderr      |   4 +-
 .../partial-sigs/should_compile/T11192.stderr      |   4 +-
 .../partial-sigs/should_compile/TypedSplice.stderr |  28 +++---
 .../WarningWildcardInstantiations.stderr           |  14 +--
 .../should_fail/Defaulting1MROff.stderr            |   2 +-
 .../tests/partial-sigs/should_fail/T11122.stderr   |   2 +-
 .../tests/patsyn/should_compile/T11283.stderr      |   2 +-
 testsuite/tests/patsyn/should_fail/T11053.stderr   |  10 +-
 testsuite/tests/rename/should_compile/T1789.stderr |   8 +-
 testsuite/tests/rename/should_compile/T17a.stderr  |   4 +-
 testsuite/tests/rename/should_compile/T17b.stderr  |   4 +-
 testsuite/tests/rename/should_compile/T17c.stderr  |   4 +-
 testsuite/tests/rename/should_compile/T17d.stderr  |   4 +-
 testsuite/tests/rename/should_compile/T17e.stderr  |   8 +-
 testsuite/tests/rename/should_compile/T1972.stderr |   7 +-
 testsuite/tests/rename/should_compile/T3262.stderr |   4 +-
 testsuite/tests/rename/should_compile/T3371.stderr |   3 +-
 testsuite/tests/rename/should_compile/T3449.stderr |   3 +-
 testsuite/tests/rename/should_compile/T4489.stderr |   4 +-
 testsuite/tests/rename/should_compile/T5331.stderr |   6 +-
 testsuite/tests/rename/should_compile/T5334.stderr |  22 ++---
 testsuite/tests/rename/should_compile/T5867.stderr |   4 +-
 testsuite/tests/rename/should_compile/T7085.stderr |   2 +-
 .../tests/rename/should_compile/T7145b.stderr      |   3 +-
 testsuite/tests/rename/should_compile/T7167.stderr |   3 +-
 testsuite/tests/rename/should_compile/T9778.stderr |   7 +-
 testsuite/tests/rename/should_compile/mc10.stderr  |   3 +-
 testsuite/tests/rename/should_compile/rn037.stderr |   2 +-
 testsuite/tests/rename/should_compile/rn039.stderr |   2 +-
 testsuite/tests/rename/should_compile/rn040.stderr |   6 +-
 testsuite/tests/rename/should_compile/rn041.stderr |   9 +-
 testsuite/tests/rename/should_compile/rn046.stderr |   4 +-
 testsuite/tests/rename/should_compile/rn047.stderr |   3 +-
 testsuite/tests/rename/should_compile/rn050.stderr |   4 +-
 testsuite/tests/rename/should_compile/rn055.stderr |   3 +-
 testsuite/tests/rename/should_compile/rn063.stderr |   6 +-
 testsuite/tests/rename/should_compile/rn064.stderr |   2 +-
 testsuite/tests/rename/should_compile/rn066.stderr |   4 +-
 testsuite/tests/rename/should_fail/T2723.stderr    |   2 +-
 testsuite/tests/rename/should_fail/T5211.stderr    |   2 +-
 testsuite/tests/rename/should_fail/T5281.stderr    |   2 +-
 testsuite/tests/rename/should_fail/T5892a.stderr   |  14 +--
 testsuite/tests/rename/should_fail/T7454.stderr    |   2 +-
 testsuite/tests/rename/should_fail/T8149.stderr    |   2 +-
 testsuite/tests/semigroup/SemigroupWarnings.stderr |   4 +-
 .../tests/simplCore/should_compile/simpl020.stderr |   8 +-
 .../typecheck/prog001/typecheck.prog001.stderr     |   8 +-
 .../tests/typecheck/should_compile/HasKey.stderr   |   8 +-
 .../tests/typecheck/should_compile/T10935.stderr   |  10 +-
 .../tests/typecheck/should_compile/T10971a.stderr  |  16 ++--
 .../tests/typecheck/should_compile/T2497.stderr    |   3 +-
 .../tests/typecheck/should_compile/T3696.stderr    |   4 +-
 .../tests/typecheck/should_compile/T4912.stderr    |   4 +-
 .../tests/typecheck/should_compile/T7903.stderr    |  16 ++--
 .../tests/typecheck/should_compile/T9497a.stderr   |  12 +--
 .../tests/typecheck/should_compile/holes.stderr    |   8 +-
 .../tests/typecheck/should_compile/holes2.stderr   |   2 +-
 .../tests/typecheck/should_compile/tc078.stderr    |  16 ++--
 .../tests/typecheck/should_compile/tc115.stderr    |   8 +-
 .../tests/typecheck/should_compile/tc116.stderr    |   8 +-
 .../tests/typecheck/should_compile/tc125.stderr    |  41 ++++----
 .../tests/typecheck/should_compile/tc126.stderr    |  16 ++--
 .../tests/typecheck/should_compile/tc161.stderr    |   8 +-
 .../tests/typecheck/should_compile/tc175.stderr    |   8 +-
 .../tests/typecheck/should_compile/tc243.stderr    |   2 +-
 .../tests/typecheck/should_compile/tc254.stderr    |   6 +-
 testsuite/tests/typecheck/should_fail/T5051.stderr |   8 +-
 .../tests/typecheck/should_fail/tcfail204.stderr   |   2 +-
 .../tests/warnings/minimal/WarnMinimal.stderr      | 106 ++++++++++-----------
 .../tests/warnings/should_compile/DeprU.stderr     |   4 +-
 .../tests/warnings/should_compile/PluralS.stderr   |   4 +-
 .../warnings/should_compile/T10890/T10890_2.stderr |   2 +-
 .../tests/warnings/should_compile/T11077.stderr    |   2 +-
 .../tests/warnings/should_compile/T11128.stderr    |   8 +-
 .../tests/warnings/should_compile/T11128b.stderr   |   4 +-
 .../tests/warnings/should_compile/T2526.stderr     |   2 +-
 .../tests/warnings/should_compile/T9178.stderr     |   2 +-
 .../wcompat-warnings/WCompatWarningsOn.stderr      |   6 +-
 164 files changed, 788 insertions(+), 648 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 ed0d72d892b2e70099aaac758343e1e733478c1e


More information about the ghc-commits mailing list