1
0
forked from GitHub/gf-core

fixed pre expressions, parsing {} patterns, and the path in resource Make.hs

This commit is contained in:
aarne
2009-05-25 12:19:32 +00:00
parent 3efb7a671b
commit a71aed81fd
5 changed files with 19 additions and 6 deletions

View File

@@ -198,7 +198,8 @@ unlexer abstr ls =
-- | Runs the gf executable in compile mode with the given arguments.
run_gfc :: [String] -> IO ()
run_gfc args =
do let args' = ["-batch","-gf-lib-path=."] ++ filter (not . null) args ++ ["+RTS"] ++ rts_flags ++ ["-RTS"]
do let args' = ["-batch"] ++ filter (not . null) args ++ ["+RTS"] ++ rts_flags ++ ["-RTS"]
--- do let args' = ["-batch","-gf-lib-path=."] ++ filter (not . null) args ++ ["+RTS"] ++ rts_flags ++ ["-RTS"] --- why path? AR
putStrLn $ "Running: " ++ default_gf ++ " " ++ unwords (map showArg args')
e <- rawSystem default_gf args'
case e of

View File

@@ -34,8 +34,16 @@ elisEl = pre { "el" ; "l'" / vocal } ;
elisLa = pre { "la" ; "l'" / vocalForta } ;
elisEm = pre { "em" ; "m'" / vocal } ;
elisEt = pre { "et" ; "t'" / vocal } ;
-- AR after pre syntax change 25/5/2009
elisEs = pre {
pre { "es" ; "s'" / vocal} ;
"se" / strs { "s" } } ;
vocal => "s'" ;
"s" => "se" ;
_ => "es"
} ;
--elisEs = pre {
-- pre { "es" ; "s'" / vocal} ;
-- "se" / strs { "s" } } ;
}

View File

@@ -182,7 +182,10 @@ oper
} ;
elisPoss : Str -> Str = \s ->
pre {s + "a" ; s + "on" / voyelle} ;
pre {
voyelle => s + "on" ;
_ => s + "a"
} ;
--2 Determiners

View File

@@ -375,8 +375,8 @@ param Place = attr | indep ;
param Size = nom | sgg | plg ;
--param Gend = masc | fem | neut ;
oper mille : Size => Str = table {
{nom} => "тысяча" ;
{sgg} => "тысячи" ;
nom => "тысяча" ;
sgg => "тысячи" ;
_ => "тысяч"} ;
oper gg : Str -> Gender => Str = \s -> table {_ => s} ;

View File

@@ -483,6 +483,7 @@ Patt2
| '#' Ident '.' Ident { PM $2 $4 }
| '_' { PW }
| Ident { PV $1 }
| '{' Ident '}' { PC $2 [] }
| Ident '.' Ident { PP $1 $3 [] }
| Integer { PInt $1 }
| Double { PFloat $1 }