change the library root namespace from GF.GFCC to PGF

This commit is contained in:
krasimir
2008-05-29 17:55:05 +00:00
parent cb374f5617
commit 3f2f0d1bea
41 changed files with 152 additions and 258 deletions

View File

@@ -0,0 +1,22 @@
module GF.Compile.Export where
import PGF.Data (GFCC)
import PGF.Raw.Print (printTree)
import PGF.Raw.Convert (fromGFCC)
import GF.Compile.GFCCtoHaskell
import GF.Compile.GFCCtoJS
import GF.Infra.Option
import GF.Text.UTF8
-- top-level access to code generation
prGFCC :: OutputFormat -> GFCC -> String
prGFCC fmt gr = case fmt of
FmtGFCC -> printGFCC gr
FmtJavaScript -> gfcc2js gr
FmtHaskell -> grammar2haskell gr
FmtHaskellGADT -> grammar2haskellGADT gr
printGFCC :: GFCC -> String
printGFCC = encodeUTF8 . printTree . fromGFCC