summaryrefslogtreecommitdiff
path: root/ghc/compiler/main
diff options
context:
space:
mode:
authorLemmih <lemmih@gmail.com>2006-02-10 17:17:28 +0000
committerLemmih <lemmih@gmail.com>2006-02-10 17:17:28 +0000
commita5b7c95f084eacc9133de9265f0d8bdbf6043fa1 (patch)
tree86dc451e1b2c7165a3668bbaf5f02298d1654ac0 /ghc/compiler/main
parentd7986e3b2e5151ef5f68ab62e3c93ad68a9220d1 (diff)
downloadhaskell-a5b7c95f084eacc9133de9265f0d8bdbf6043fa1.tar.gz
Completion for :set, :unset and :undef.
Diffstat (limited to 'ghc/compiler/main')
-rw-r--r--ghc/compiler/main/DynFlags.hs10
1 files changed, 10 insertions, 0 deletions
diff --git a/ghc/compiler/main/DynFlags.hs b/ghc/compiler/main/DynFlags.hs
index 82d3c37c1b..b1eb4332ab 100644
--- a/ghc/compiler/main/DynFlags.hs
+++ b/ghc/compiler/main/DynFlags.hs
@@ -41,6 +41,7 @@ module DynFlags (
-- parsing DynFlags
parseDynamicFlags,
+ allFlags,
-- misc stuff
machdepCCOpts, picCCOpts,
@@ -764,6 +765,15 @@ getStgToDo dflags
-- -----------------------------------------------------------------------------
-- DynFlags parser
+allFlags :: [String]
+allFlags = map ('-':) $
+ [ name | (name, optkind) <- dynamic_flags, ok optkind ] ++
+ map ("fno-"++) flags ++
+ map ("f"++) flags
+ where ok (PrefixPred _ _) = False
+ ok _ = True
+ flags = map fst fFlags
+
dynamic_flags :: [(String, OptKind DynP)]
dynamic_flags = [
( "n" , NoArg (setDynFlag Opt_DryRun) )