diff options
| author | bjorn <bjorn@bringert.net> | 2008-10-20 14:52:50 +0000 |
|---|---|---|
| committer | bjorn <bjorn@bringert.net> | 2008-10-20 14:52:50 +0000 |
| commit | d327d9da6c25349757fb87f4cc8bcb3ba69ca8f4 (patch) | |
| tree | 1f29c5b13fd793696b2d4f2e1cf952bf3f8fd059 /src/GF/Compile.hs | |
| parent | 6b8c9dd4c9a1e28ef22a1c1797143ffd8febef5d (diff) | |
Added --parser=ondemand flag.
Diffstat (limited to 'src/GF/Compile.hs')
| -rw-r--r-- | src/GF/Compile.hs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/GF/Compile.hs b/src/GF/Compile.hs index d4b3a9df3..e7e16013c 100644 --- a/src/GF/Compile.hs +++ b/src/GF/Compile.hs @@ -76,7 +76,10 @@ optimize opts = cse . suf buildParser :: Options -> PGF -> PGF buildParser opts = - if flag optBuildParser opts then addParsers opts else id + case flag optBuildParser opts of + BuildParser -> addParsers opts + DontBuildParser -> id + BuildParserOnDemand -> mapConcretes (\cnc -> cnc { cflags = Map.insert (mkCId "parser") "ondemand" (cflags cnc) }) batchCompile :: Options -> [FilePath] -> IOE SourceGrammar batchCompile opts files = do |
