summaryrefslogtreecommitdiff
path: root/src/GF/Compile/Export.hs
diff options
context:
space:
mode:
authorbjorn <bjorn@bringert.net>2008-09-30 11:52:11 +0000
committerbjorn <bjorn@bringert.net>2008-09-30 11:52:11 +0000
commit446aa1b5db35402dbdd0821eec4ea1bbbed7d0f9 (patch)
treec54c17659508ce9252f54622b1ac8878aef0bb77 /src/GF/Compile/Export.hs
parent794fbd4a416ef53d289545eb83455ee745115fec (diff)
Added --cfg option for specifying which CFG transformations to use. Added startcatonly CFG trasnformation. Removed output formats that are now easily done with --cfg: "regular", "nolr".
Diffstat (limited to 'src/GF/Compile/Export.hs')
-rw-r--r--src/GF/Compile/Export.hs17
1 files changed, 7 insertions, 10 deletions
diff --git a/src/GF/Compile/Export.hs b/src/GF/Compile/Export.hs
index f24e840c3..8fb4cbed8 100644
--- a/src/GF/Compile/Export.hs
+++ b/src/GF/Compile/Export.hs
@@ -40,23 +40,20 @@ exportPGF opts fmt pgf =
FmtProlog -> multi "pl" grammar2prolog
FmtProlog_Abs -> multi "pl" grammar2prolog_abs
FmtBNF -> single "bnf" bnfPrinter
- FmtEBNF -> single "ebnf" (ebnfPrinter sisr)
- FmtNoLR -> single "ebnf" (nonLeftRecursivePrinter sisr)
- FmtRegular -> single "ebnf" regularPrinter
+ FmtEBNF -> single "ebnf" (ebnfPrinter opts)
FmtFCFG -> single "fcfg" fcfgPrinter
- FmtSRGS_XML -> single "grxml" (srgsXmlPrinter sisr)
- FmtSRGS_XML_NonRec -> single "grxml" srgsXmlNonRecursivePrinter
- FmtSRGS_ABNF -> single "gram" (srgsAbnfPrinter sisr)
- FmtSRGS_ABNF_NonRec -> single "gram" srgsAbnfNonRecursivePrinter
- FmtJSGF -> single "jsgf" (jsgfPrinter sisr)
- FmtGSL -> single "gsl" gslPrinter
+ FmtSRGS_XML -> single "grxml" (srgsXmlPrinter opts)
+ FmtSRGS_XML_NonRec -> single "grxml" (srgsXmlNonRecursivePrinter opts)
+ FmtSRGS_ABNF -> single "gram" (srgsAbnfPrinter opts)
+ FmtSRGS_ABNF_NonRec -> single "gram" (srgsAbnfNonRecursivePrinter opts)
+ FmtJSGF -> single "jsgf" (jsgfPrinter opts)
+ FmtGSL -> single "gsl" (gslPrinter opts)
FmtVoiceXML -> single "vxml" grammar2vxml
FmtSLF -> single "slf" slfPrinter
FmtRegExp -> single "rexp" regexpPrinter
FmtFA -> single "dot" slfGraphvizPrinter
where
name = fromMaybe (prCId (absname pgf)) (moduleFlag optName opts)
- sisr = flag optSISR opts
hsPrefix = flag optHaskellPrefix opts
multi :: String -> (PGF -> String) -> [(FilePath,String)]