- ( "warn-dodgy-foreign-imports", Opt_WarnDodgyForeignImports, const Supported ),
- ( "warn-dodgy-imports", Opt_WarnDodgyImports, const Supported ),
- ( "warn-duplicate-exports", Opt_WarnDuplicateExports, const Supported ),
- ( "warn-hi-shadowing", Opt_WarnHiShadows, const Supported ),
- ( "warn-implicit-prelude", Opt_WarnImplicitPrelude, const Supported ),
- ( "warn-incomplete-patterns", Opt_WarnIncompletePatterns, const Supported ),
- ( "warn-incomplete-record-updates", Opt_WarnIncompletePatternsRecUpd, const Supported ),
- ( "warn-missing-fields", Opt_WarnMissingFields, const Supported ),
- ( "warn-missing-methods", Opt_WarnMissingMethods, const Supported ),
- ( "warn-missing-signatures", Opt_WarnMissingSigs, const Supported ),
- ( "warn-name-shadowing", Opt_WarnNameShadowing, const Supported ),
- ( "warn-overlapping-patterns", Opt_WarnOverlappingPatterns, const Supported ),
- ( "warn-simple-patterns", Opt_WarnSimplePatterns, const Supported ),
- ( "warn-type-defaults", Opt_WarnTypeDefaults, const Supported ),
- ( "warn-monomorphism-restriction", Opt_WarnMonomorphism, const Supported ),
- ( "warn-unused-binds", Opt_WarnUnusedBinds, const Supported ),
- ( "warn-unused-imports", Opt_WarnUnusedImports, const Supported ),
- ( "warn-unused-matches", Opt_WarnUnusedMatches, const Supported ),
- ( "warn-warnings-deprecations", Opt_WarnWarningsDeprecations, const Supported ),
- ( "warn-deprecated-flags", Opt_WarnDeprecatedFlags, const Supported ),
- ( "warn-orphans", Opt_WarnOrphans, const Supported ),
- ( "warn-tabs", Opt_WarnTabs, const Supported ),
- ( "warn-unrecognised-pragmas", Opt_WarnUnrecognisedPragmas, const Supported ),
- ( "print-explicit-foralls", Opt_PrintExplicitForalls, const Supported ),
- ( "strictness", Opt_Strictness, const Supported ),
- ( "static-argument-transformation", Opt_StaticArgumentTransformation, const Supported ),
- ( "full-laziness", Opt_FullLaziness, const Supported ),
- ( "liberate-case", Opt_LiberateCase, const Supported ),
- ( "spec-constr", Opt_SpecConstr, const Supported ),
- ( "cse", Opt_CSE, const Supported ),
- ( "ignore-interface-pragmas", Opt_IgnoreInterfacePragmas, const Supported ),
- ( "omit-interface-pragmas", Opt_OmitInterfacePragmas, const Supported ),
- ( "do-lambda-eta-expansion", Opt_DoLambdaEtaExpansion, const Supported ),
- ( "ignore-asserts", Opt_IgnoreAsserts, const Supported ),
- ( "do-eta-reduction", Opt_DoEtaReduction, const Supported ),
- ( "case-merge", Opt_CaseMerge, const Supported ),
- ( "unbox-strict-fields", Opt_UnboxStrictFields, const Supported ),
- ( "method-sharing", Opt_MethodSharing, const Supported ),
- ( "dicts-cheap", Opt_DictsCheap, const Supported ),
- ( "excess-precision", Opt_ExcessPrecision, const Supported ),
- ( "asm-mangling", Opt_DoAsmMangling, const Supported ),
- ( "print-bind-result", Opt_PrintBindResult, const Supported ),
- ( "force-recomp", Opt_ForceRecomp, const Supported ),
- ( "hpc-no-auto", Opt_Hpc_No_Auto, const Supported ),
- ( "rewrite-rules", Opt_RewriteRules, const Supported ),
- ( "break-on-exception", Opt_BreakOnException, const Supported ),
- ( "break-on-error", Opt_BreakOnError, const Supported ),
- ( "print-evld-with-show", Opt_PrintEvldWithShow, const Supported ),
- ( "print-bind-contents", Opt_PrintBindContents, const Supported ),
- ( "run-cps", Opt_RunCPSZ, const Supported ),
- ( "convert-to-zipper-and-back", Opt_ConvertToZipCfgAndBack, const Supported ),
- ( "vectorise", Opt_Vectorise, const Supported ),
- ( "regs-graph", Opt_RegsGraph, const Supported ),
- ( "regs-iterative", Opt_RegsIterative, const Supported ),
+ ( "warn-dodgy-foreign-imports", Opt_WarnDodgyForeignImports, nop ),
+ ( "warn-dodgy-exports", Opt_WarnDodgyExports, nop ),
+ ( "warn-dodgy-imports", Opt_WarnDodgyImports, nop ),
+ ( "warn-duplicate-exports", Opt_WarnDuplicateExports, nop ),
+ ( "warn-hi-shadowing", Opt_WarnHiShadows, nop ),
+ ( "warn-implicit-prelude", Opt_WarnImplicitPrelude, nop ),
+ ( "warn-incomplete-patterns", Opt_WarnIncompletePatterns, nop ),
+ ( "warn-incomplete-record-updates", Opt_WarnIncompletePatternsRecUpd, nop ),
+ ( "warn-missing-fields", Opt_WarnMissingFields, nop ),
+ ( "warn-missing-import-lists", Opt_WarnMissingImportList, nop ),
+ ( "warn-missing-methods", Opt_WarnMissingMethods, nop ),
+ ( "warn-missing-signatures", Opt_WarnMissingSigs, nop ),
+ ( "warn-missing-local-sigs", Opt_WarnMissingLocalSigs, nop ),
+ ( "warn-name-shadowing", Opt_WarnNameShadowing, nop ),
+ ( "warn-overlapping-patterns", Opt_WarnOverlappingPatterns, nop ),
+ ( "warn-type-defaults", Opt_WarnTypeDefaults, nop ),
+ ( "warn-monomorphism-restriction", Opt_WarnMonomorphism, nop ),
+ ( "warn-unused-binds", Opt_WarnUnusedBinds, nop ),
+ ( "warn-unused-imports", Opt_WarnUnusedImports, nop ),
+ ( "warn-unused-matches", Opt_WarnUnusedMatches, nop ),
+ ( "warn-warnings-deprecations", Opt_WarnWarningsDeprecations, nop ),
+ ( "warn-deprecations", Opt_WarnWarningsDeprecations, nop ),
+ ( "warn-deprecated-flags", Opt_WarnDeprecatedFlags, nop ),
+ ( "warn-orphans", Opt_WarnOrphans, nop ),
+ ( "warn-identities", Opt_WarnIdentities, nop ),
+ ( "warn-auto-orphans", Opt_WarnAutoOrphans, nop ),
+ ( "warn-tabs", Opt_WarnTabs, nop ),
+ ( "warn-unrecognised-pragmas", Opt_WarnUnrecognisedPragmas, nop ),
+ ( "warn-lazy-unlifted-bindings", Opt_WarnLazyUnliftedBindings, nop),
+ ( "warn-unused-do-bind", Opt_WarnUnusedDoBind, nop ),
+ ( "warn-wrong-do-bind", Opt_WarnWrongDoBind, nop ),
+ ( "warn-alternative-layout-rule-transitional", Opt_WarnAlternativeLayoutRuleTransitional, nop ),
+ ( "print-explicit-foralls", Opt_PrintExplicitForalls, nop ),
+ ( "strictness", Opt_Strictness, nop ),
+ ( "specialise", Opt_Specialise, nop ),
+ ( "float-in", Opt_FloatIn, nop ),
+ ( "static-argument-transformation", Opt_StaticArgumentTransformation, nop ),
+ ( "full-laziness", Opt_FullLaziness, nop ),
+ ( "liberate-case", Opt_LiberateCase, nop ),
+ ( "spec-constr", Opt_SpecConstr, nop ),
+ ( "cse", Opt_CSE, nop ),
+ ( "ignore-interface-pragmas", Opt_IgnoreInterfacePragmas, nop ),
+ ( "omit-interface-pragmas", Opt_OmitInterfacePragmas, nop ),
+ ( "expose-all-unfoldings", Opt_ExposeAllUnfoldings, nop ),
+ ( "do-lambda-eta-expansion", Opt_DoLambdaEtaExpansion, nop ),
+ ( "ignore-asserts", Opt_IgnoreAsserts, nop ),
+ ( "do-eta-reduction", Opt_DoEtaReduction, nop ),
+ ( "case-merge", Opt_CaseMerge, nop ),
+ ( "unbox-strict-fields", Opt_UnboxStrictFields, nop ),
+ ( "method-sharing", Opt_MethodSharing,
+ \_ -> deprecate "doesn't do anything any more"),
+ -- Remove altogether in GHC 7.2
+ ( "dicts-cheap", Opt_DictsCheap, nop ),
+ ( "excess-precision", Opt_ExcessPrecision, nop ),
+ ( "eager-blackholing", Opt_EagerBlackHoling, nop ),
+ ( "asm-mangling", Opt_DoAsmMangling, nop ),
+ ( "print-bind-result", Opt_PrintBindResult, nop ),
+ ( "force-recomp", Opt_ForceRecomp, nop ),
+ ( "hpc-no-auto", Opt_Hpc_No_Auto, nop ),
+ ( "rewrite-rules", Opt_EnableRewriteRules, useInstead "enable-rewrite-rules" ),
+ ( "enable-rewrite-rules", Opt_EnableRewriteRules, nop ),
+ ( "break-on-exception", Opt_BreakOnException, nop ),
+ ( "break-on-error", Opt_BreakOnError, nop ),
+ ( "print-evld-with-show", Opt_PrintEvldWithShow, nop ),
+ ( "print-bind-contents", Opt_PrintBindContents, nop ),
+ ( "run-cps", Opt_RunCPS, nop ),
+ ( "run-cpsz", Opt_RunCPSZ, nop ),
+ ( "new-codegen", Opt_TryNewCodeGen, nop ),
+ ( "convert-to-zipper-and-back", Opt_ConvertToZipCfgAndBack, nop ),
+ ( "vectorise", Opt_Vectorise, nop ),
+ ( "regs-graph", Opt_RegsGraph, nop ),
+ ( "regs-iterative", Opt_RegsIterative, nop ),
+ ( "gen-manifest", Opt_GenManifest, nop ),
+ ( "embed-manifest", Opt_EmbedManifest, nop ),
+ ( "ext-core", Opt_EmitExternalCore, nop ),
+ ( "shared-implib", Opt_SharedImplib, nop ),
+ ( "ghci-sandbox", Opt_GhciSandbox, nop ),
+ ( "building-cabal-package", Opt_BuildingCabalPackage, nop ),
+ ( "implicit-import-qualified", Opt_ImplicitImportQualified, nop )
+ ]
+
+-- | These @-f\<blah\>@ flags can all be reversed with @-fno-\<blah\>@
+fLangFlags :: [FlagSpec ExtensionFlag]
+fLangFlags = [