From 3f9b4e7855cf4594708a9fbad194c89540d2cf1e Mon Sep 17 00:00:00 2001 From: aarne Date: Wed, 31 Mar 2004 12:30:34 +0000 Subject: Added support for cf and ebnf formats --- src/GF/API/IOGrammar.hs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/GF/API') diff --git a/src/GF/API/IOGrammar.hs b/src/GF/API/IOGrammar.hs index 9b6fe0c5a..b535c9be0 100644 --- a/src/GF/API/IOGrammar.hs +++ b/src/GF/API/IOGrammar.hs @@ -39,7 +39,11 @@ shellStateFromFiles :: Options -> ShellState -> FilePath -> IOE ShellState shellStateFromFiles opts st file = case fileSuffix file of "gfcm" -> do (_,_,cgr) <- compileOne opts (compileEnvShSt st []) file - ioeErr $ updateShellState opts st (cgr,(emptyMGrammar,[])) + ioeErr $ updateShellState opts st (cgr,(emptyMGrammar,[])) + s | elem s ["cf","ebnf"] -> do + let osb = addOptions (options [beVerbose]) opts + grts <- compileModule osb st file + ioeErr $ updateShellState opts st grts _ -> do let osb = if oElem showOld opts then addOptions (options [beVerbose]) opts -- for old, no emit -- cgit v1.2.3