From af13bae2dfb9adaa7c4aa273961fc09cc7ba1b7a Mon Sep 17 00:00:00 2001 From: krasimir Date: Sun, 17 Jan 2010 17:05:21 +0000 Subject: now the linearization is completely based on PMCFG --- src/compiler/GF/Speech/PGFToCFG.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/compiler/GF/Speech/PGFToCFG.hs') diff --git a/src/compiler/GF/Speech/PGFToCFG.hs b/src/compiler/GF/Speech/PGFToCFG.hs index bd27deadf..4ac430704 100644 --- a/src/compiler/GF/Speech/PGFToCFG.hs +++ b/src/compiler/GF/Speech/PGFToCFG.hs @@ -37,7 +37,7 @@ pgfToCFG pgf lang = mkCFG (showCId (lookStartCat pgf)) extCats (startRules ++ co pinfo = fromMaybe (error "pgfToCFG: No parser.") (lookParser pgf lang) rules :: [(FCat,Production)] - rules = [(fcat,prod) | (fcat,set) <- IntMap.toList (PGF.productions pinfo) + rules = [(fcat,prod) | (fcat,set) <- IntMap.toList (PGF.pproductions pinfo) , prod <- Set.toList set] fcatCats :: Map FCat Cat @@ -58,7 +58,7 @@ pgfToCFG pgf lang = mkCFG (showCId (lookStartCat pgf)) extCats (startRules ++ co topdownRules cat = f cat [] where - f cat rules = maybe rules (Set.fold g rules) (IntMap.lookup cat (productions pinfo)) + f cat rules = maybe rules (Set.fold g rules) (IntMap.lookup cat (pproductions pinfo)) g (FApply funid args) rules = (functions pinfo ! funid,args) : rules g (FCoerce cat) rules = f cat rules -- cgit v1.2.3