From 676b0d6e8192c3cab92ca4cb8247cba00533402d Mon Sep 17 00:00:00 2001 From: hallgren Date: Mon, 8 Dec 2014 14:48:14 +0000 Subject: Haddock documentation: expose exportPGF, some other small improvements --- src/compiler/GF/Compiler.hs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/compiler/GF/Compiler.hs') diff --git a/src/compiler/GF/Compiler.hs b/src/compiler/GF/Compiler.hs index 57855b1b9..57d0b6e03 100644 --- a/src/compiler/GF/Compiler.hs +++ b/src/compiler/GF/Compiler.hs @@ -1,4 +1,4 @@ -module GF.Compiler (mainGFC, writePGF, linkGrammars) where +module GF.Compiler (mainGFC, linkGrammars, writePGF, writeOutputs) where import PGF import PGF.Internal(concretes,optimizePGF,unionPGF) @@ -56,7 +56,7 @@ compileSourceFiles opts fs = -- in the 'Options') from the output of 'parallelBatchCompile'. -- If a @.pgf@ file by the same name already exists and it is newer than the -- source grammar files (as indicated by the 'UTCTime' argument), it is not --- recreated. +-- recreated. Calls 'writePGF' and 'writeOutputs'. linkGrammars opts (t_src,~cnc_grs@(~(cnc,gr):_)) = do let abs = render (srcAbsName gr cnc) pgfFile = outputPath opts (grammarName' opts abs<.>"pgf") @@ -111,6 +111,8 @@ unionPGFFiles opts fs = readPGFVerbose f = putPointE Normal opts ("Reading " ++ f ++ "...") $ liftIO $ readPGF f +-- | Export the PGF to the 'OutputFormat's specified in the 'Options'. +-- Calls 'exportPGF'. writeOutputs :: Options -> PGF -> IOE () writeOutputs opts pgf = do sequence_ [writeOutput opts name str -- cgit v1.2.3