[commit: ghc] master: Suggest correct replacement flag name for -dppr-ticks (2fc9c3e)
git at git.haskell.org
git at git.haskell.org
Wed Apr 12 18:53:22 UTC 2017
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/2fc9c3e3df06cac9bdc1f109065f66a45fd78a9e/ghc
>---------------------------------------------------------------
commit 2fc9c3e3df06cac9bdc1f109065f66a45fd78a9e
Author: Reid Barton <rwbarton at gmail.com>
Date: Wed Apr 12 14:10:39 2017 -0400
Suggest correct replacement flag name for -dppr-ticks
It told me to use -fno-suppress-ticks, but it should have been
-dno-suppress-ticks.
Test Plan: tested -dppr-ticks and -frewrite-rules manually
Reviewers: austin, bgamari
Reviewed By: bgamari
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D3430
>---------------------------------------------------------------
2fc9c3e3df06cac9bdc1f109065f66a45fd78a9e
compiler/main/DynFlags.hs | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/compiler/main/DynFlags.hs b/compiler/main/DynFlags.hs
index a4095f1..07e9517 100644
--- a/compiler/main/DynFlags.hs
+++ b/compiler/main/DynFlags.hs
@@ -3520,9 +3520,9 @@ deprecatedForExtension lang turn_on
flag | turn_on = lang
| otherwise = "No" ++ lang
-useInstead :: String -> TurnOnFlag -> String
-useInstead flag turn_on
- = "Use -f" ++ no ++ flag ++ " instead"
+useInstead :: String -> String -> TurnOnFlag -> String
+useInstead prefix flag turn_on
+ = "Use " ++ prefix ++ no ++ flag ++ " instead"
where
no = if turn_on then "" else "no-"
@@ -3642,7 +3642,7 @@ dFlagsDeps = [
-- Please keep the list of flags below sorted alphabetically
flagSpec "ppr-case-as-let" Opt_PprCaseAsLet,
depFlagSpec' "ppr-ticks" Opt_PprShowTicks
- (\turn_on -> useInstead "suppress-ticks" (not turn_on)),
+ (\turn_on -> useInstead "-d" "suppress-ticks" (not turn_on)),
flagSpec "suppress-ticks" Opt_SuppressTicks,
flagSpec "suppress-coercions" Opt_SuppressCoercions,
flagSpec "suppress-idinfo" Opt_SuppressIdInfo,
@@ -3734,7 +3734,7 @@ fFlagsDeps = [
flagSpec "regs-graph" Opt_RegsGraph,
flagSpec "regs-iterative" Opt_RegsIterative,
depFlagSpec' "rewrite-rules" Opt_EnableRewriteRules
- (useInstead "enable-rewrite-rules"),
+ (useInstead "-f" "enable-rewrite-rules"),
flagSpec "shared-implib" Opt_SharedImplib,
flagSpec "spec-constr" Opt_SpecConstr,
flagSpec "spec-constr-keen" Opt_SpecConstrKeen,
More information about the ghc-commits
mailing list