diff options
author | Michael Walker <mike@barrucadu.co.uk> | 2016-02-25 17:34:07 +0100 |
---|---|---|
committer | Herbert Valerio Riedel <hvr@gnu.org> | 2016-02-25 23:44:08 +0100 |
commit | bb5afd3c274011c5ea302210b4c290ec1f83209c (patch) | |
tree | b6c2000e466e894207ce28dc65346853120f8548 /testsuite/tests/driver | |
parent | 1badf157be3b7f604ba1ac64d2ea044d783e6e50 (diff) | |
download | haskell-bb5afd3c274011c5ea302210b4c290ec1f83209c.tar.gz |
Print which warning-flag controls an emitted warning
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.
This also adds a new flag `-f(no-)show-warning-groups` to control
whether to show which warning-group (such as `-Wall` or `-Wcompat`)
a warning belongs to. This flag is on by default.
This implements #10752
Reviewed By: quchen, bgamari, hvr
Differential Revision: https://phabricator.haskell.org/D1943
Diffstat (limited to 'testsuite/tests/driver')
-rw-r--r-- | testsuite/tests/driver/werror.stderr | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/testsuite/tests/driver/werror.stderr b/testsuite/tests/driver/werror.stderr index 00240a07b3..09424963b2 100644 --- a/testsuite/tests/driver/werror.stderr +++ b/testsuite/tests/driver/werror.stderr @@ -1,20 +1,22 @@ -werror.hs:6:1: warning: +werror.hs:6:1: warning: [-Wmissing-signatures (in -Wall)] Top-level binding with no type signature: main :: IO () -werror.hs:7:13: warning: +werror.hs:7:13: warning: [-Wname-shadowing (in -Wall)] This binding for ‘main’ shadows the existing binding defined at werror.hs:6:1 -werror.hs:7:13: warning: Defined but not used: ‘main’ +werror.hs:7:13: warning: [-Wunused-local-binds (in -Wextra, -Wunused-binds)] + Defined but not used: ‘main’ werror.hs:8:1: warning: Tab character found here. Please use spaces instead. -werror.hs:10:1: warning: Defined but not used: ‘f’ +werror.hs:10:1: warning: [-Wunused-local-binds (in -Wextra, -Wunused-binds)] + Defined but not used: ‘f’ -werror.hs:10:1: warning: +werror.hs:10:1: warning: [-Wmissing-signatures (in -Wall)] Top-level binding with no type signature: f :: forall t t1. [t] -> [t1] |