From 9995a834ae44b32cc641cab7a6b908449d4de32b Mon Sep 17 00:00:00 2001 From: krasimir Date: Sun, 20 Jun 2010 08:45:31 +0000 Subject: [PATCH] getFCats -> getFIds in GeneratePMCFG --- src/compiler/GF/Compile/GeneratePMCFG.hs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/compiler/GF/Compile/GeneratePMCFG.hs b/src/compiler/GF/Compile/GeneratePMCFG.hs index 3e5249af5..a1a8e4e78 100644 --- a/src/compiler/GF/Compile/GeneratePMCFG.hs +++ b/src/compiler/GF/Compile/GeneratePMCFG.hs @@ -129,8 +129,8 @@ convertRule gr opts grammarEnv (PFRule fun args res ctypes ctype term) = do return $! grammarEnv2 where addRule lins (newCat', newArgs') env0 = - let [newCat] = getFCats env0 newCat' - (env1, newArgs) = List.mapAccumL (\env -> addFCoercion env . getFCats env) env0 newArgs' + let [newCat] = getFIds env0 newCat' + (env1, newArgs) = List.mapAccumL (\env -> addFCoercion env . getFIds env) env0 newArgs' (env2,funid) = addCncFun env1 (PGF.Data.CncFun (i2i fun) (mkArray lins)) @@ -500,7 +500,7 @@ expandHOAS opts (m,mo) env = return env {- env3 = foldl (\env (arg,res) -> addProduction env res (PApply funid (arg : replicate n fcatVar))) env2 - (zip (getFCats env2 arg) (getFCats env2 res)) + (zip (getFIds env2 arg) (getFIds env2 res)) in env3 where (arg,res) = case Map.lookup cat lincats of @@ -579,8 +579,8 @@ getConcr flags printnames (GrammarEnv last_id catSet seqSet funSet crcSet prodSe collect path paths (CPar _) = paths -getFCats :: GrammarEnv -> ProtoFCat -> [FId] -getFCats (GrammarEnv last_id catSet seqSet funSet crcSet prodSet) (PFCat n cat schema) = +getFIds :: GrammarEnv -> ProtoFCat -> [FId] +getFIds (GrammarEnv last_id catSet seqSet funSet crcSet prodSet) (PFCat n cat schema) = case IntMap.lookup n catSet >>= Map.lookup cat of Just (start,end,_) -> reverse (solutions (fmap (start +) $ variants schema) ()) where