From c4931fccaf6ae5ed2c6d164f53f13d5d55c76a72 Mon Sep 17 00:00:00 2001 From: aarne Date: Fri, 7 Dec 2012 15:25:27 +0000 Subject: fixed external case for countries in PhrasebookFin --- examples/phrasebook/SentencesFin.gf | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) (limited to 'examples/phrasebook/SentencesFin.gf') diff --git a/examples/phrasebook/SentencesFin.gf b/examples/phrasebook/SentencesFin.gf index c704c4e57..608a42233 100644 --- a/examples/phrasebook/SentencesFin.gf +++ b/examples/phrasebook/SentencesFin.gf @@ -3,7 +3,9 @@ concrete SentencesFin of Sentences = NumeralFin ** SentencesI - IFemale, YouFamFemale, YouPolFemale, IMale, YouFamMale, YouPolMale, WeMale, WeFemale, YouPlurFamMale, YouPlurFamFemale, YouPlurPolFemale, YouPlurPolMale, NPPlace, CNPlace, placeNP, mkCNPlace, mkCNPlacePl, - GObjectPlease + GObjectPlease, + NPNationality, mkNPNationality, + Country, PCountry ] with (Syntax = SyntaxFin), (Symbolic = SymbolicFin), @@ -12,16 +14,21 @@ concrete SentencesFin of Sentences = NumeralFin ** SentencesI - flags optimize = noexpand ; + lincat + Country = {np : NP ; isExternal : Bool} ; + lin + PCountry x = mkPhrase (mkUtt x.np) ; oper + NPNationality = {lang : NP ; prop : A ; country : {np : NP ; isExternal : Bool}} ; NPPlace = {name : NP ; at : Adv ; to : Adv ; from : Adv} ; - CNPlace = {name : CN ; at : Prep ; to : Prep ; from : Prep ; isPl : Bool} ; + CNPlace = {name : CN ; isExternal : Bool ; isPl : Bool} ; placeNP : Det -> CNPlace -> NPPlace = \det,kind -> let name : NP = mkNP det kind.name in { name = name ; - at = mkAdv kind.at name ; - to = mkAdv kind.to name ; - from = mkAdv kind.from name + at = mkAdv (P.casePrep (if_then_else P.Case kind.isExternal P.adessive P.inessive)) name ; + to = mkAdv (P.casePrep (if_then_else P.Case kind.isExternal P.allative P.illative)) name ; + from = mkAdv (P.casePrep (if_then_else P.Case kind.isExternal P.ablative P.elative)) name } ; lin -- cgit v1.2.3