From 18324e5e045c95dc15fd8672ebc630c4e8f3ae20 Mon Sep 17 00:00:00 2001 From: aarne Date: Wed, 13 Mar 2013 14:48:23 +0000 Subject: [PATCH] =?UTF-8?q?Poss,Part,Count=20NP=20implemented=20in=20Finni?= =?UTF-8?q?sh:=20tehtaan=20johtaja,=20lasi=20viini=C3=A4,=20kolme=20pojist?= =?UTF-8?q?a?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/src/finnish/NounFin.gf | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/lib/src/finnish/NounFin.gf b/lib/src/finnish/NounFin.gf index d9cb0d0c1..cb5278cf5 100644 --- a/lib/src/finnish/NounFin.gf +++ b/lib/src/finnish/NounFin.gf @@ -221,6 +221,32 @@ concrete NounFin of Noun = CatFin ** open ResFin, MorphoFin, Prelude in { ApposCN cn np = {s = \\nf=> cn.s ! nf ++ np.s ! NPCase Nom ; h = cn.h } ; --- luvun x + PossNP cn np = {s = \\nf => np.s ! NPCase Gen ++ cn.s ! nf ; + h = cn.h + } ; + + PartNP cn np = {s = \\nf => cn.s ! nf ++ np.s ! NPCase Part ; + h = cn.h ---- gives "lasin viiniänsa" ; should be "lasinsa viiniä" + } ; + + + CountNP det np = + let + n : Number = case det.isNum of { + True => Sg ; + _ => det.n + } ; + in { + s = \\c => let k = npform2case n c in + det.sp ! k ++ np.s ! NPCase Elat ; -- cf DetNP above + a = agrP3 (case det.isDef of { + False => Sg ; -- autoja menee; kolme autoa menee + _ => det.n + }) ; + isPron = False ; isNeg = det.isNeg + } ; + + oper numN : NForm -> Number = \nf -> case nf of { NCase n _ => n ;