From 04eb0d6c4de23a4cfe3953e7496f5bc4b5b1d53c Mon Sep 17 00:00:00 2001 From: Ben Gamari Date: Sun, 29 Dec 2019 14:18:47 -0500 Subject: Enable -Wstar-is-type in -Wall As noted in [proposal 0143][proposal] this is supposed to happen in 8.12. Also fix an incorrect claim in the users guide that -Wstar-is-type is enabled by default. [proposal]: https://github.com/ghc-proposals/ghc-proposals/blob/master/proposals/0143-remove-star-kind.rst --- compiler/main/DynFlags.hs | 3 ++- docs/users_guide/using-warnings.rst | 1 - testsuite/tests/wcompat-warnings/WCompatWarningsOn.stderr | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/compiler/main/DynFlags.hs b/compiler/main/DynFlags.hs index 97bc2fece1..42205ac0b2 100644 --- a/compiler/main/DynFlags.hs +++ b/compiler/main/DynFlags.hs @@ -4903,7 +4903,8 @@ minusWallOpts Opt_WarnUntickedPromotedConstructors, Opt_WarnMissingPatternSynonymSignatures, Opt_WarnUnusedRecordWildcards, - Opt_WarnRedundantRecordWildcards + Opt_WarnRedundantRecordWildcards, + Opt_WarnStarIsType ] -- | Things you get with -Weverything, i.e. *all* known warnings flags diff --git a/docs/users_guide/using-warnings.rst b/docs/users_guide/using-warnings.rst index 20566b77ad..ca1945c743 100644 --- a/docs/users_guide/using-warnings.rst +++ b/docs/users_guide/using-warnings.rst @@ -44,7 +44,6 @@ generally likely to indicate bugs in your program. These are: * :ghc-flag:`-Wtabs` * :ghc-flag:`-Wunrecognised-warning-flags` * :ghc-flag:`-Winaccessible-code` - * :ghc-flag:`-Wstar-is-type` * :ghc-flag:`-Wstar-binder` The following flags are simple ways to select standard "packages" of warnings: diff --git a/testsuite/tests/wcompat-warnings/WCompatWarningsOn.stderr b/testsuite/tests/wcompat-warnings/WCompatWarningsOn.stderr index b0d7bb2636..7d3c2a6982 100644 --- a/testsuite/tests/wcompat-warnings/WCompatWarningsOn.stderr +++ b/testsuite/tests/wcompat-warnings/WCompatWarningsOn.stderr @@ -13,7 +13,7 @@ Template.hs:16:3: warning: [-Wnoncanonical-monoid-instances (in -Wcompat)] in the instance declaration for ‘Monoid S’. Define as ‘mappend = (<>)’ -Template.hs:20:15: warning: [-Wstar-is-type (in -Wcompat)] +Template.hs:20:15: warning: [-Wstar-is-type (in -Wall, -Wcompat)] Using ‘*’ (or its Unicode variant) to mean ‘Data.Kind.Type’ relies on the StarIsType extension, which will become deprecated in the future. -- cgit v1.2.1