From 1f62af0e2c42a37c6ea5b86828a4f37d13c7b12a Mon Sep 17 00:00:00 2001 From: Inari Listenmaa Date: Wed, 25 Sep 2019 11:53:27 +0200 Subject: [PATCH] (Som) Add ImpVP and UttImp{Sg,Pl,Pol} --- src/somali/CatSom.gf | 2 +- src/somali/PhraseSom.gf | 8 +++++--- src/somali/SentenceSom.gf | 6 +++--- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/src/somali/CatSom.gf b/src/somali/CatSom.gf index 52af918d0..eb1747c78 100644 --- a/src/somali/CatSom.gf +++ b/src/somali/CatSom.gf @@ -16,7 +16,7 @@ concrete CatSom of Cat = CommonX - [Adv,IAdv] ** open ResSom, Prelude in { Cl = ResSom.ClSlash ; ClSlash = ResSom.ClSlash ; SSlash = ResSom.Sentence ; -- sentence missing NP; e.g. "she has looked at" - Imp = SS ; -- imperative e.g. "look at this" + Imp = {s : Number => Polarity => Str} ; -- imperative e.g. "look at this" --2 Questions and interrogatives diff --git a/src/somali/PhraseSom.gf b/src/somali/PhraseSom.gf index c9c18c396..0a20b76e4 100644 --- a/src/somali/PhraseSom.gf +++ b/src/somali/PhraseSom.gf @@ -8,9 +8,11 @@ concrete PhraseSom of Phrase = CatSom ** open Prelude, ResSom in { UttIAdv iadv = iadv ; UttImpSg pol imp = - let ma = case pol.p of { Pos => [] ; Neg => "ma" } - in { s = ma ++ imp.s } ; - UttImpPl = UttImpSg ; + let ha = case pol.p of {Pos => [] ; Neg => "ha"} + in {s = ha ++ imp.s ! Sg ! pol.p} ; + UttImpPl pol imp = + let ha = case pol.p of {Pos => [] ; Neg => "ha"} + in {s = ha ++ imp.s ! Pl ! pol.p} ; UttImpPol = UttImpSg ; UttIP ip = {s = ip.s ! Abs} ; diff --git a/src/somali/SentenceSom.gf b/src/somali/SentenceSom.gf index e09de077b..27167f21f 100644 --- a/src/somali/SentenceSom.gf +++ b/src/somali/SentenceSom.gf @@ -29,12 +29,12 @@ lin -- : Temp -> Pol -> ClSlash -> SSlash ; -- (that) she had not seen UseSlash t p cls = { s = \\isSubord => let cl = cl2sentence isSubord cls in - t.s ++ p.s ++ cl.s ! t.t ! t.a ! p.p + t.s ++ p.s ++ cl.s ! t.t ! t.a ! p.p } ; --2 Imperatives -- : VP -> Imp ; - --ImpVP vp = { s = linVP vp } ; + ImpVP vp = {s = \\num,pol => linVP (VImp num pol) Statement vp} ; --2 Embedded sentences @@ -54,7 +54,7 @@ lin -- : Temp -> Pol -> Cl -> S ; UseCl t p cls = { s = \\isSubord => let cl = cl2sentence isSubord cls in - t.s ++ p.s ++ cl.s ! t.t ! t.a ! p.p + t.s ++ p.s ++ cl.s ! t.t ! t.a ! p.p } ; -- : Temp -> Pol -> QCl -> QS ;