From 79a375a03efe4f60fc87910385568213bcb425eb Mon Sep 17 00:00:00 2001 From: Inari Listenmaa Date: Thu, 7 Feb 2019 11:10:47 +0100 Subject: [PATCH] (Pes) add beVerb and use in Lexicon for some compound verbs --- src/persian/LexiconPes.gf | 11 +++++------ src/persian/MorphoPes.gf | 21 ++++++++++++++++----- src/persian/ParadigmsPes.gf | 3 ++- 3 files changed, 23 insertions(+), 12 deletions(-) diff --git a/src/persian/LexiconPes.gf b/src/persian/LexiconPes.gf index 38bcf8735..4a44edf2d 100644 --- a/src/persian/LexiconPes.gf +++ b/src/persian/LexiconPes.gf @@ -1,8 +1,7 @@ --# -path=.:prelude:alltenses concrete LexiconPes of Lexicon = CatPes ** ---open ResPnb, Prelude in { - open ParadigmsPes, MorphoPes, Prelude in { + open ParadigmsPes, Prelude in { flags optimize=values ; @@ -94,11 +93,11 @@ concrete LexiconPes of Lexicon = CatPes ** go_V = mkV "رفتن" "رو"; green_A = mkA "سبز" ; harbour_N = mkN "بندر" "بنادر" inanimate; --- hate_V2 = mkV2 (compoundV "متنفر" (mkToBe "بودن" "باش" "هست")) "از" False; -- needs from/ verb to be + hate_V2 = mkV2 (compoundV "متنفر" beVerb) "از" False; -- needs from/ verb to be hat_N = mkN01 "کلاه" inanimate; hear_V2 = mkV2 (mkV "شنیدن" "شنو") "را" ; hill_N = mkN01 "تپه" inanimate; --- hope_VS = compoundV "امیدوار" (mkToBe "بودن" "باش" "هست"); + hope_VS = compoundV "امیدوار" beVerb; horse_N = mkN01 "اسب" animate; hot_A = mkA "داغ" ["داغ داغ"] ; house_N = mkN01 "خانه" inanimate; @@ -120,7 +119,7 @@ concrete LexiconPes of Lexicon = CatPes ** long_A = mkA "بلند" ; lose_V2 = mkV2 (compoundV "گم" doVerb) "را" ; love_N = mkN01 "عشق" inanimate; - love_V2 = mkV2 (compoundV "دوست" haveVerb) "را"; -- also possible: love_V2 = mkV2 (compoundV "عاشق" (mkToBe "بودن" "باش" "هست")); + love_V2 = mkV2 (compoundV "دوست" haveVerb) "را"; -- also possible: love_V2 = mkV2 (compoundV "عاشق" beVerb); man_N = mkN02 "مرد" animate; married_A2 = mkA "متأهل" ""; meat_N = mkN01 "گوشت" inanimate; @@ -314,7 +313,7 @@ concrete LexiconPes of Lexicon = CatPes ** burn_V = mkV "سوختن" "سوز" ; dig_V = mkV_2 "کندن" ; fall_V = mkV_1 "افتادن" ; - --float_V = compoundV "شناور" (mkToBe "بودن" "باش" "هست") ; + float_V = compoundV "شناور" beVerb ; flow_V = compoundV "جاری" (mkV "شدن" "شو") ; fly_V = compoundV "پرواز" doVerb ; freeze_V = compoundV "یخ" hitVerb ; diff --git a/src/persian/MorphoPes.gf b/src/persian/MorphoPes.gf index b21e30423..9b5e2a97f 100644 --- a/src/persian/MorphoPes.gf +++ b/src/persian/MorphoPes.gf @@ -146,7 +146,7 @@ oper mkVerb : (x1,x2 : Str) -> Verb = \inf,root2 -> let root1 = tk 1 inf ; - impRoot = impRoot root2 + impRoot = impRoot root2 in { s = table { Root1 => root1 ; Root2 => root2 ; @@ -154,7 +154,7 @@ oper Imp Pos Sg => addBh impRoot ; Imp Pos Pl => addBh impRoot + "ید" ; Imp Neg Sg => "ن" + impRoot ; - Imp Neg Pl => "ن" + impRoot + "ید" ; + Imp Neg Pl => "ن" + impRoot + "ید" ; Vvform ag => mkvVform root2 ag ; VF p t ag => mkCmnVF root1 root2 p t ag } } ; @@ -279,7 +279,7 @@ oper Ag Pl P2 => zwnj s "اید" ; Ag Pl P3 => zwnj s "اند" } ; - pluperfectSuffix : Agr -> Str -> Str = \ag,s -> s ++ + pluperfectSuffix : Agr -> Str -> Str = \ag,s -> s ++ case ag of { -- not suffix, just using consistent naming scheme :-P /IL Ag Sg P1 => "بودم" ; Ag Sg P2 => "بودی" ; @@ -293,7 +293,7 @@ oper ---------------------------------- haveVerb : Verb = {s = table { - Root1 => "داشت" ; + Root1 => "داشت" ; Root2 => "دار" ; Inf => "داشتن" ; Imp Pos Sg => "بدار" ; @@ -315,5 +315,16 @@ oper _ => mkCmnVF dasht dar pol t ag } ; - + beVerb : Verb = { s = table { + Vvform agr => imperfectSuffixD agr "باش" ; + Imp Pos Sg => "باش" ; + Imp Pos Pl => "باشید" ; + Imp Neg Sg => "نباش" ; + Imp Neg Pl => "نباشید" ; + Inf => "بودن" ; + Root1 => "بود" ; + Root2 => "باش" ; + VF pol tense agr => mkCmnVF "بود" "باش" pol tense agr + } + } ; } diff --git a/src/persian/ParadigmsPes.gf b/src/persian/ParadigmsPes.gf index 3a14ce671..e70358291 100644 --- a/src/persian/ParadigmsPes.gf +++ b/src/persian/ParadigmsPes.gf @@ -106,7 +106,8 @@ oper mkV : Str -> Str -> V = \s1, s2 -> mkVerb s1 s2 ** {lock_V = <>} ; -- mkVerb takes both the Infinitive and the present root(root2) and is applied for iregular verbs - haveVerb : V = M.haveVerb ; + haveVerb : V = lin V M.haveVerb ; + beVerb : V = lin V M.beVerb ; mkV_1 : Str -> V = \s -> mkVerb1 s ** {lock_V = <>} ;