mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-05-27 11:48:55 -06:00
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 ;
|
flags optimize = all_subs ;
|
||||||
|
|
||||||
@@ -33,18 +33,24 @@ lin
|
|||||||
pot1to19 d = {s = d.s ! DTeen; n = Pl} ;
|
pot1to19 d = {s = d.s ! DTeen; n = Pl} ;
|
||||||
pot0as1 n = {s = n.s ! DUnit; n = n.n } ;
|
pot0as1 n = {s = n.s ! DUnit; n = n.n } ;
|
||||||
pot1 d = {s = d.s ! DTen; n = Pl} ;
|
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 ;
|
pot1as2 n = n ;
|
||||||
pot2 d =
|
pot2 d = {s = \\g =>
|
||||||
{s = \\g => d.s ! DUnit ! invNum ++ cardOrd "hundert" "hunderte" ! g ; n = Pl} ;
|
multiple (d.s ! DUnit) d.n ++ cardOrd "hundert" "hunderte" ! g ; n = Pl} ;
|
||||||
pot2plus d e =
|
pot2plus d e = {s = \\g =>
|
||||||
{s = \\g => d.s ! DUnit ! invNum ++ "hundert" ++ e.s ! g ; n = Pl} ;
|
multiple (d.s ! DUnit) d.n ++ "hundert" ++ BIND ++ e.s ! g ; n = Pl} ;
|
||||||
pot2as3 n = n ;
|
pot2as3 n = n ;
|
||||||
pot3 n =
|
pot3 n = {s = \\g =>
|
||||||
{s = \\g => n.s ! invNum ++ cardOrd "tausend" "tausendte" ! g ; n = Pl} ; ----
|
multiple n.s n.n ++ cardOrd "tausend" "tausendte" ! g ; n = Pl} ; ----
|
||||||
pot3plus n m =
|
pot3plus n m = {s = \\g =>
|
||||||
{s = \\g => n.s ! invNum ++ "tausend" ++ m.s ! g ; n = Pl} ;
|
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
|
lincat
|
||||||
Dig = TDigit ;
|
Dig = TDigit ;
|
||||||
|
|||||||
@@ -298,6 +298,11 @@ computeTermOpt rec gr = comput True where
|
|||||||
|
|
||||||
compSelect g (S t' v') = case v' of
|
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
|
_ -> case t' of
|
||||||
FV ccs -> mapM (\c -> comp g (S c v')) ccs >>= returnC . variants
|
FV ccs -> mapM (\c -> comp g (S c v')) ccs >>= returnC . variants
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user