diff options
author | Alfredo Di Napoli <alfredo@well-typed.com> | 2021-03-30 10:21:06 +0200 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2021-04-05 20:39:54 -0400 |
commit | 3483c3de2aa9c1a48d2e8a9271eadc5e3f4da70d (patch) | |
tree | c89a2434db2b05c602343c8addc27def0c1cfd1a /testsuite/tests/backpack | |
parent | 495281215ae0fdcb296b2b30c1efd3a683006f42 (diff) | |
download | haskell-3483c3de2aa9c1a48d2e8a9271eadc5e3f4da70d.tar.gz |
Correct warning for deprecated and unrecognised flags
Fixes #19616.
This commit changes the `GHC.Driver.Errors.handleFlagWarnings` function
to rely on the newly introduced `DiagnosticReason`. This allows us to
correctly pretty-print the flags which triggered some warnings and in
turn remove the cruft around this function (like the extra filtering
and the `shouldPrintWarning` function.
Diffstat (limited to 'testsuite/tests/backpack')
-rw-r--r-- | testsuite/tests/backpack/should_compile/bkp09.stderr | 2 | ||||
-rw-r--r-- | testsuite/tests/backpack/should_compile/bkp15.stderr | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/testsuite/tests/backpack/should_compile/bkp09.stderr b/testsuite/tests/backpack/should_compile/bkp09.stderr index 7428ab3eb8..1cb9ac5819 100644 --- a/testsuite/tests/backpack/should_compile/bkp09.stderr +++ b/testsuite/tests/backpack/should_compile/bkp09.stderr @@ -1,5 +1,5 @@ -bkp09.bkp:1:26: warning: +bkp09.bkp:1:26: warning: [-Wdeprecated-flags (in -Wdefault)] -XDatatypeContexts is deprecated: It was widely considered a misfeature, and has been removed from the Haskell language. [1 of 5] Processing p [1 of 1] Compiling H[sig] ( p/H.hsig, nothing ) diff --git a/testsuite/tests/backpack/should_compile/bkp15.stderr b/testsuite/tests/backpack/should_compile/bkp15.stderr index d1f29fae2c..a3c1b83851 100644 --- a/testsuite/tests/backpack/should_compile/bkp15.stderr +++ b/testsuite/tests/backpack/should_compile/bkp15.stderr @@ -1,5 +1,5 @@ -bkp15.bkp:1:26: warning: +bkp15.bkp:1:26: warning: [-Wdeprecated-flags (in -Wdefault)] -XDatatypeContexts is deprecated: It was widely considered a misfeature, and has been removed from the Haskell language. [1 of 5] Processing p [1 of 1] Compiling H[sig] ( p/H.hsig, nothing ) |