1
0
forked from GitHub/gf-core

Store FCFPInfo (all information needed for FCFG parsing) in GFCC files, and in the internal DataGFCC.GFCC structure. The parsing information format is still in flux.

This commit is contained in:
bringert
2008-01-03 17:10:05 +00:00
parent 43ddb41d31
commit af1a3a2473
11 changed files with 203 additions and 55 deletions

View File

@@ -22,10 +22,8 @@ importGrammar mgr0 opts files = do
let name = justModuleName (last files)
let (abs,gfcc0) = mkCanon2gfcc opts name gr
gfcc1 <- checkGFCCio gfcc0
return $ if oElem (iOpt "noopt") opts then gfcc1 else optGFCC gfcc1
return $ addParsers $ if oElem (iOpt "noopt") opts then gfcc1 else optGFCC gfcc1
"gfcc" ->
mapM file2gfcc files >>= return . foldl1 unionGFCC
let gfcc3 = unionGFCC (gfcc mgr0) gfcc2
return $ MultiGrammar gfcc3
(nubBy (\ (x,_) (y,_) -> x == y) (gfcc2parsers gfcc3 ++ parsers mgr0))
-- later coming parsers override
return $ MultiGrammar gfcc3