1
0
forked from GitHub/gf-core

for backward compatibility we have the old parse function again. the old functionality is exposed by parse_

This commit is contained in:
krasimir
2010-04-30 20:18:26 +00:00
parent 1c590e41f4
commit 9e7b914c3c
5 changed files with 23 additions and 18 deletions

View File

@@ -310,7 +310,7 @@ cat pgf mcat = fromMaybe (PGF.startCat pgf) mcat
parse' :: PGF -> String -> Maybe PGF.Type -> Maybe PGF.Language -> [(PGF.Language,[PGF.Tree])]
parse' pgf input mcat mfrom =
[(from,ts) | from <- froms, canParse pgf from, (PGF.ParseResult ts,_) <- [PGF.parse pgf from cat input]]
[(from,ts) | from <- froms, canParse pgf from, (PGF.ParseResult ts,_) <- [PGF.parse_ pgf from cat input]]
where froms = maybe (PGF.languages pgf) (:[]) mfrom
cat = fromMaybe (PGF.startCat pgf) mcat