forked from GitHub/gf-core
spacing of German numerals
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
concrete NumeralGer of Numeral = CatGer ** open MorphoGer in {
|
||||
concrete NumeralGer of Numeral = CatGer ** open MorphoGer, Prelude in {
|
||||
|
||||
flags optimize = all_subs ;
|
||||
|
||||
@@ -33,18 +33,24 @@ lin
|
||||
pot1to19 d = {s = d.s ! DTeen; n = Pl} ;
|
||||
pot0as1 n = {s = n.s ! DUnit; n = n.n } ;
|
||||
pot1 d = {s = d.s ! DTen; n = Pl} ;
|
||||
pot1plus d e = {s = \\g => e.s ! DUnit ! invNum ++ "und" ++ d.s ! DTen ! g; n = Pl} ;
|
||||
pot1plus d e = {s = \\g =>
|
||||
e.s ! DUnit ! invNum ++ BIND ++ "und" ++ BIND ++ d.s ! DTen ! g; n = Pl} ;
|
||||
pot1as2 n = n ;
|
||||
pot2 d =
|
||||
{s = \\g => d.s ! DUnit ! invNum ++ cardOrd "hundert" "hunderte" ! g ; n = Pl} ;
|
||||
pot2plus d e =
|
||||
{s = \\g => d.s ! DUnit ! invNum ++ "hundert" ++ e.s ! g ; n = Pl} ;
|
||||
pot2 d = {s = \\g =>
|
||||
multiple (d.s ! DUnit) d.n ++ cardOrd "hundert" "hunderte" ! g ; n = Pl} ;
|
||||
pot2plus d e = {s = \\g =>
|
||||
multiple (d.s ! DUnit) d.n ++ "hundert" ++ BIND ++ e.s ! g ; n = Pl} ;
|
||||
pot2as3 n = n ;
|
||||
pot3 n =
|
||||
{s = \\g => n.s ! invNum ++ cardOrd "tausend" "tausendte" ! g ; n = Pl} ; ----
|
||||
pot3plus n m =
|
||||
{s = \\g => n.s ! invNum ++ "tausend" ++ m.s ! g ; n = Pl} ;
|
||||
pot3 n = {s = \\g =>
|
||||
multiple n.s n.n ++ cardOrd "tausend" "tausendte" ! g ; n = Pl} ; ----
|
||||
pot3plus n m = {s = \\g =>
|
||||
multiple n.s n.n ++ "tausend" ++ BIND ++ m.s ! g ; n = Pl} ;
|
||||
|
||||
oper
|
||||
multiple : (CardOrd => Str) -> Number -> Str = \d,n ->
|
||||
case n of {Sg => [] ; _ => d ! invNum ++ BIND} ;
|
||||
|
||||
--------------------
|
||||
|
||||
lincat
|
||||
Dig = TDigit ;
|
||||
|
||||
@@ -297,7 +297,12 @@ computeTermOpt rec gr = comput True where
|
||||
_ -> return p
|
||||
|
||||
compSelect g (S t' v') = case v' of
|
||||
FV vs -> mapM (\c -> comp g (S t' c)) vs >>= returnC . variants
|
||||
FV vs -> mapM (\c -> comp g (S t' c)) vs >>= returnC . variants
|
||||
|
||||
---- S (T i cs) e -> prawitz g i (S t') cs e -- AR 8/7/2010 sometimes better
|
||||
---- S (V i cs) e -> prawitzV g i (S t') cs e -- sometimes much worse
|
||||
|
||||
|
||||
_ -> case t' of
|
||||
FV ccs -> mapM (\c -> comp g (S c v')) ccs >>= returnC . variants
|
||||
|
||||
|
||||
Reference in New Issue
Block a user