summaryrefslogtreecommitdiff
path: root/src/compiler/GF/Compile/GeneratePMCFG.hs
diff options
context:
space:
mode:
authorhallgren <hallgren@chalmers.se>2012-10-19 19:56:00 +0000
committerhallgren <hallgren@chalmers.se>2012-10-19 19:56:00 +0000
commit1195db1da3f8e0c1b7edf39cac604b2bf8482aab (patch)
treeedc5401028e550e687fd101287790268bd95b5d5 /src/compiler/GF/Compile/GeneratePMCFG.hs
parent921b37834c66eeaba18147c5ab027b1f062b8829 (diff)
Consistenly use SourceGrammar instead of [SourceModule] when calling compiler passes
Diffstat (limited to 'src/compiler/GF/Compile/GeneratePMCFG.hs')
-rw-r--r--src/compiler/GF/Compile/GeneratePMCFG.hs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/compiler/GF/Compile/GeneratePMCFG.hs b/src/compiler/GF/Compile/GeneratePMCFG.hs
index bb4c5b549..13ac8d26f 100644
--- a/src/compiler/GF/Compile/GeneratePMCFG.hs
+++ b/src/compiler/GF/Compile/GeneratePMCFG.hs
@@ -43,13 +43,13 @@ import Control.Exception
----------------------------------------------------------------------
-- main conversion function
-generatePMCFG :: Options -> [SourceModule] -> SourceModule -> IO SourceModule
-generatePMCFG opts mos cmo@(cm,cmi) = do
+generatePMCFG :: Options -> SourceGrammar -> SourceModule -> IO SourceModule
+generatePMCFG opts sgr cmo@(cm,cmi) = do
(seqs,js) <- mapAccumWithKeyM (addPMCFG opts gr am cm) Map.empty (jments cmi)
when (verbAtLeast opts Verbose) $ hPutStrLn stderr ""
return (cm,cmi{mseqs = Just (mkSetArray seqs), jments = js})
where
- gr = mGrammar (cmo:mos)
+ gr = prependModule sgr cmo
MTConcrete am = mtype cmi
mapAccumWithKeyM :: (Monad m, Ord k) => (a -> k -> b -> m (a,c)) -> a