mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-04-09 04:59:31 -06:00
A couple of haddock documentation improvements
This commit is contained in:
@@ -46,6 +46,10 @@ link opts (cnc,gr) =
|
||||
srcAbsName gr cnc = err (const cnc) id $ abstractOfConcrete gr cnc
|
||||
|
||||
-- | Compile the given grammar files and everything they depend on.
|
||||
-- Compiled modules are stored in @.gfo@ files (unless the @-tags@ option is
|
||||
-- used, in which case tags files are produced instead).
|
||||
-- Existing @.gfo@ files are reused if they are up-to-date
|
||||
-- (unless the option @-src@ aka @-force-recomp@ is used).
|
||||
batchCompile :: Options -> [FilePath] -> IOE (UTCTime,(ModuleName,Grammar))
|
||||
batchCompile opts files = do
|
||||
(gr,menv) <- foldM (compileModule opts) emptyCompileEnv files
|
||||
|
||||
@@ -19,13 +19,16 @@ import GF.Infra.Ident(moduleNameS)
|
||||
import GF.Text.Pretty
|
||||
import qualified Data.ByteString.Lazy as BS
|
||||
|
||||
-- | Compile the given grammar files and everything they depend on.
|
||||
-- This function compiles modules in parallel.
|
||||
-- | Compile the given grammar files and everything they depend on,
|
||||
-- like 'batchCompile'. This function compiles modules in parallel.
|
||||
-- It keeps modules compiled in /present/ and /alltenses/ mode apart,
|
||||
-- storing the @.gfo@ files in separate subdirectories to avoid creating
|
||||
-- the broken PGF files that can result from mixing different modes in the
|
||||
-- same concrete syntax.
|
||||
|
||||
--
|
||||
-- The first argument is supposed to be the number of jobs to run in
|
||||
-- parallel, but this has not been implemented yet. Instead you have to
|
||||
-- use the GHC run-time flag @+RTS -N -RTS@ to enable parallelism.
|
||||
parallelBatchCompile jobs opts rootfiles0 =
|
||||
do rootfiles <- mapM canonical rootfiles0
|
||||
lib_dir <- canonical =<< getLibraryDirectory opts
|
||||
|
||||
Reference in New Issue
Block a user