summaryrefslogtreecommitdiff
path: root/next-lib/src
diff options
context:
space:
mode:
authoraarne <aarne@cs.chalmers.se>2008-12-03 16:23:54 +0000
committeraarne <aarne@cs.chalmers.se>2008-12-03 16:23:54 +0000
commit2440854310c96fff410fb4d90dc7759cec785b3d (patch)
tree2b7c2116f834b21a593bba3677afbc6c759360f1 /next-lib/src
parent2f7fd8a59763e313a0d40cc807ce5da4d3366917 (diff)
accusative for Finnish numeral determiners
Diffstat (limited to 'next-lib/src')
-rw-r--r--next-lib/src/finnish/LexiconFin.gf4
-rw-r--r--next-lib/src/finnish/NounFin.gf29
-rw-r--r--next-lib/src/finnish/ResFin.gf11
3 files changed, 24 insertions, 20 deletions
diff --git a/next-lib/src/finnish/LexiconFin.gf b/next-lib/src/finnish/LexiconFin.gf
index 0347ad898..0591ca178 100644
--- a/next-lib/src/finnish/LexiconFin.gf
+++ b/next-lib/src/finnish/LexiconFin.gf
@@ -210,8 +210,8 @@ lin
wait_V2 = mkV2 (mkV "odottaa") partitive ;
walk_V = mkV "kävellä" "käveli" ;
warm_A = mkA
- (mkN "lämmin" "lämpimän" "lämpimänä" "lämmintä" "lämpimään"
- "lämpiminä" "lämpimissä" "lämpimien" "lämpimiä" "lämpimiin"
+ (mkN "lämmin" "lämpimän" "lämmintä" "lämpimänä" "lämpimään"
+ "lämpiminä" "lämpimiä" "lämpimien" "lämpimissä" "lämpimiin"
)
"lämpimämpi" "lämpimin" ;
war_N = mkN "sota" ;
diff --git a/next-lib/src/finnish/NounFin.gf b/next-lib/src/finnish/NounFin.gf
index 6923fe45f..4a7234402 100644
--- a/next-lib/src/finnish/NounFin.gf
+++ b/next-lib/src/finnish/NounFin.gf
@@ -13,21 +13,26 @@ concrete NounFin of Noun = CatFin ** open ResFin, MorphoFin, Prelude in {
True => Sg ;
_ => det.n
} ;
- ncase : Case -> NForm = \c ->
+ ncase : NPForm -> Case * NForm = \c ->
+ let k = npform2case n c
+ in
case <n, c, det.isNum, det.isPoss, det.isDef> of {
- <_, Nom, True,_,_> => NCase Sg Part ; -- kolme kytkintä(ni)
- <_, _, True,False,_> => NCase Sg c ; -- kolmeksi kytkimeksi
- <Pl,Nom, _,_,False> => NCase Pl Part ; -- kytkimiä
- <_, Nom,_,True,_> => NPossNom n ; -- kytkime+ni on/ovat...
- <_, Gen,_,True,_> => NPossNom n ; -- kytkime+ni vika
- <_, Transl,_,True,_> => NPossTransl n ; -- kytkim(e|i)kse+ni
- <_, Illat,_,True,_> => NPossIllat n ; -- kytkim(ee|ii)+ni
+ <_, NPAcc, True,_,_> => <Nom,NCase Sg Part> ; -- kolme kytkintä(ni)
+ <_, NPCase Nom, True,_,_> => <Nom,NCase Sg Part> ; -- kolme kytkintä(ni)
+ <_, _, True,False,_> => <k, NCase Sg k> ; -- kolmeksi kytkimeksi
+ <Pl,NPCase Nom, _,_,False> => <k, NCase Pl Part> ; -- kytkimiä
+ <_, NPCase Nom,_,True,_> => <k, NPossNom n> ; -- kytkime+ni on/ovat...
+ <_, NPCase Gen,_,True,_> => <k, NPossNom n> ; -- kytkime+ni vika
+ <_, NPCase Transl,_,True,_> => <k, NPossTransl n> ; -- kytkim(e|i)kse+ni
+ <_, NPCase Illat,_,True,_> => <k, NPossIllat n> ; -- kytkim(ee|ii)+ni
- _ => NCase n c -- kytkin, kytkimen,...
+ _ => <k, NCase n k> -- kytkin, kytkimen,...
}
in {
- s = \\c => let k = npform2case n c in
- det.s1 ! k ++ cn.s ! ncase k ++ det.s2 ;
+ s = \\c => let
+ k = ncase c ;
+ in
+ det.s1 ! k.p1 ++ cn.s ! k.p2 ++ det.s2 ;
a = agrP3 (case det.isDef of {
False => Sg ; -- autoja menee; kolme autoa menee
_ => det.n
@@ -91,7 +96,7 @@ concrete NounFin of Noun = CatFin ** open ResFin, MorphoFin, Prelude in {
sp = \\c => quant.sp ! num.n ! c ++ num.s ! Sg ! c ;
s2 = quant.s2 ;
n = num.n ;
- isNum = case num.n of {Sg => False ; _ => True} ;
+ isNum = num.isNum ; -- case num.n of {Sg => False ; _ => True} ;
isPoss = quant.isPoss ;
isDef = quant.isDef
} ;
diff --git a/next-lib/src/finnish/ResFin.gf b/next-lib/src/finnish/ResFin.gf
index e26c96b26..e81238000 100644
--- a/next-lib/src/finnish/ResFin.gf
+++ b/next-lib/src/finnish/ResFin.gf
@@ -129,12 +129,11 @@ param
appCompl : Bool -> Polarity -> Compl -> NP -> Str = \isFin,b,co,np ->
let
- c = case <isFin, b, co.c, np.isPron,np.a.n> of {
- <_, Neg, NPAcc,_,_> => NPCase Part ; -- en näe taloa/sinua
- <_, Pos, NPAcc,True,_> => NPAcc ; -- näen/täytyy sinut
- <True, Pos, NPAcc,False,Sg> => NPCase Gen ; -- näen talon
- <False,Pos, NPAcc,_,_> => NPCase Nom ; -- täytyy talo/sinut; näen talot
- <_,_,coc,_,_> => coc
+ c = case <isFin, b, co.c, np.isPron> of {
+ <_, Neg, NPAcc,_> => NPCase Part ; -- en näe taloa/sinua
+ <_, Pos, NPAcc,True> => NPAcc ; -- näen/täytyy sinut
+ <False,Pos, NPAcc,False> => NPCase Nom ; -- täytyy nähdä talo
+ <_,_,coc,_> => coc
} ;
nps = np.s ! c
in