Recognise US spelling for specialisation flags.
authorTim McGilchrist <timmcgil@gmail.com>
Sat, 1 Oct 2016 04:28:26 +0000 (00:28 -0400)
committerBen Gamari <ben@smart-cactus.org>
Sat, 1 Oct 2016 21:02:31 +0000 (17:02 -0400)
The user guide says that we allow the user to use `specialise` or
`specialize` interchangeably but this wasn't the case for the relevant
flags. This patch adds aliases for the flags which control
specialisation.

Reviewers: erikd, austin, mpickering, bgamari

Reviewed By: mpickering, bgamari

Subscribers: mpickering, thomie

Differential Revision: https://phabricator.haskell.org/D2542

GHC Trac Issues: #12575

compiler/main/DynFlags.hs

index a972716..cc11d3d 100644 (file)
@@ -3296,7 +3296,9 @@ wWarningFlagsDeps = [
   flagSpec "overflowed-literals"         Opt_WarnOverflowedLiterals,
   flagSpec "overlapping-patterns"        Opt_WarnOverlappingPatterns,
   flagSpec "missed-specialisations"      Opt_WarnMissedSpecs,
+  flagSpec "missed-specializations"      Opt_WarnMissedSpecs,
   flagSpec "all-missed-specialisations"  Opt_WarnAllMissedSpecs,
+  flagSpec "all-missed-specializations"  Opt_WarnAllMissedSpecs,
   flagSpec' "safe"                       Opt_WarnSafe setWarnSafe,
   flagSpec "trustworthy-safe"            Opt_WarnTrustworthySafe,
   flagSpec "tabs"                        Opt_WarnTabs,
@@ -3429,8 +3431,11 @@ fFlagsDeps = [
   flagSpec "shared-implib"                    Opt_SharedImplib,
   flagSpec "spec-constr"                      Opt_SpecConstr,
   flagSpec "specialise"                       Opt_Specialise,
+  flagSpec "specialize"                       Opt_Specialise,
   flagSpec "specialise-aggressively"          Opt_SpecialiseAggressively,
+  flagSpec "specialize-aggressively"          Opt_SpecialiseAggressively,
   flagSpec "cross-module-specialise"          Opt_CrossModuleSpecialise,
+  flagSpec "cross-module-specialize"          Opt_CrossModuleSpecialise,
   flagSpec "static-argument-transformation"   Opt_StaticArgumentTransformation,
   flagSpec "strictness"                       Opt_Strictness,
   flagSpec "use-rpaths"                       Opt_RPath,