summaryrefslogtreecommitdiff
path: root/compiler/main/DynFlags.hs
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/main/DynFlags.hs')
-rw-r--r--compiler/main/DynFlags.hs15
1 files changed, 6 insertions, 9 deletions
diff --git a/compiler/main/DynFlags.hs b/compiler/main/DynFlags.hs
index acdecf26bb..b6664f222e 100644
--- a/compiler/main/DynFlags.hs
+++ b/compiler/main/DynFlags.hs
@@ -814,6 +814,7 @@ data WarningFlag =
| Opt_WarnMissingExportList
| Opt_WarnInaccessibleCode
| Opt_WarnStarIsType -- Since 8.6
+ | Opt_WarnStarBinder -- Since 8.6
| Opt_WarnImplicitKindVars -- Since 8.6
deriving (Eq, Show, Enum)
@@ -3857,6 +3858,7 @@ wWarningFlagsDeps = [
flagSpec "simplifiable-class-constraints" Opt_WarnSimplifiableClassConstraints,
flagSpec "missing-home-modules" Opt_WarnMissingHomeModules,
flagSpec "unrecognised-warning-flags" Opt_WarnUnrecognisedWarningFlags,
+ flagSpec "star-binder" Opt_WarnStarBinder,
flagSpec "star-is-type" Opt_WarnStarIsType,
flagSpec "partial-fields" Opt_WarnPartialFields ]
@@ -4365,7 +4367,6 @@ impliedXFlags
, (LangExt.TypeInType, turnOn, LangExt.DataKinds)
, (LangExt.TypeInType, turnOn, LangExt.PolyKinds)
, (LangExt.TypeInType, turnOn, LangExt.KindSignatures)
- , (LangExt.TypeInType, turnOff, LangExt.StarIsType)
-- AutoDeriveTypeable is not very useful without DeriveDataTypeable
, (LangExt.AutoDeriveTypeable, turnOn, LangExt.DeriveDataTypeable)
@@ -4377,9 +4378,6 @@ impliedXFlags
, (LangExt.ImpredicativeTypes, turnOn, LangExt.RankNTypes)
- -- See Note [When is StarIsType enabled]
- , (LangExt.TypeOperators, turnOff, LangExt.StarIsType)
-
-- Record wild-cards implies field disambiguation
-- Otherwise if you write (C {..}) you may well get
-- stuff like " 'a' not in scope ", which is a bit silly
@@ -4407,12 +4405,10 @@ impliedXFlags
-- programs expect '*' to be synonymous with 'Type', so by default StarIsType is
-- enabled.
--
--- However, programs that use TypeOperators might expect to repurpose '*' for
--- multiplication or another binary operation, so we make TypeOperators imply
--- NoStarIsType.
+-- Programs that use TypeOperators might expect to repurpose '*' for
+-- multiplication or another binary operation, but making TypeOperators imply
+-- NoStarIsType caused too much breakage on Hackage.
--
--- It is still possible to have TypeOperators and StarIsType enabled at the same
--- time, although it's not recommended.
-- Note [Documenting optimisation flags]
-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -4562,6 +4558,7 @@ standardWarnings -- see Note [Documenting warning flags]
Opt_WarnTabs,
Opt_WarnUnrecognisedWarningFlags,
Opt_WarnSimplifiableClassConstraints,
+ Opt_WarnStarBinder,
Opt_WarnInaccessibleCode
]