From 967a8fb8a14d9056c5f9ad0f105ab454fb2e0819 Mon Sep 17 00:00:00 2001 From: Meowyam Date: Wed, 11 May 2022 11:30:34 +0800 Subject: [PATCH] add extra functions to get VPS to work --- src/malay/AllMay.gf | 2 +- src/malay/IdiomMay.gf | 15 +++++++++++---- src/malay/NounMay.gf | 5 +++++ src/malay/PhraseMay.gf | 1 + src/malay/SentenceMay.gf | 3 +++ 5 files changed, 21 insertions(+), 5 deletions(-) diff --git a/src/malay/AllMay.gf b/src/malay/AllMay.gf index c965d873..2836b818 100644 --- a/src/malay/AllMay.gf +++ b/src/malay/AllMay.gf @@ -3,6 +3,6 @@ concrete AllMay of AllMayAbs = LangMay, ExtendMay - ** { + ** open ParadigmsMay in { lin sing_V2 = mkV2 "nyanyi" ; } ; diff --git a/src/malay/IdiomMay.gf b/src/malay/IdiomMay.gf index 79f6b362..38dbdb71 100644 --- a/src/malay/IdiomMay.gf +++ b/src/malay/IdiomMay.gf @@ -1,7 +1,7 @@ --1 Idiom: Idiomatic Expressions -concrete IdiomMay of Idiom = CatMay ** open Prelude, ResMay, VerbMay, NounMay, StructuralMay in { +concrete IdiomMay of Idiom = CatMay ** open Prelude, ResMay, VerbMay, QuestionMay, NounMay, StructuralMay in { -- This module defines constructions that are formed in fixed ways, -- often different even in closely related languages. @@ -14,10 +14,17 @@ concrete IdiomMay of Idiom = CatMay ** open Prelude, ResMay, VerbMay, NounMay, S subj = [] ; pred = \\vf,pol => vp.s ! Root ! pol -- force no prefix -- TODO check if legit? } ; -{- - -- GenericCl : VP -> Cl ; -- one sleeps - GenericCl = \vp -> predVP impersNP (passVP vp) ; + -- : NP -> Cl ; -- there is a house + ExistNP np = predVP np (useV copula) ; + + -- ExistIP : IP -> QCl ; -- which houses are there + ExistIP ip = QuestVP ip (useV copula) ; + + -- GenericCl : VP -> Cl ; -- one sleeps + GenericCl = \vp -> predVP emptyNP vp ; + +{- CleftNP : NP -> RS -> Cl ; -- it is I who did it CleftAdv : Adv -> S -> Cl ; -- it is here she slept diff --git a/src/malay/NounMay.gf b/src/malay/NounMay.gf index 65a33612..0fc84555 100644 --- a/src/malay/NounMay.gf +++ b/src/malay/NounMay.gf @@ -174,6 +174,11 @@ concrete NounMay of Noun = CatMay ** open ResMay, Prelude in { heavyMod = cn.heavyMod ++ rs.s ! P3 } ; + -- : CN -> Adv -> CN ; + AdvCN cn adv = cn ** { + heavyMod = cn.heavyMod ++ adv.s + } ; + {- -- : CN -> Adv -> CN ; AdvCN cn adv = cn ** { } ; diff --git a/src/malay/PhraseMay.gf b/src/malay/PhraseMay.gf index 3e7c99e4..17c00326 100644 --- a/src/malay/PhraseMay.gf +++ b/src/malay/PhraseMay.gf @@ -10,6 +10,7 @@ concrete PhraseMay of Phrase = CatMay ** open Prelude, ResMay in { UttIP ip = {s = ip.sp ! NF Sg Bare} ; UttImpSg pol imp = { s = pol.s ++ imp.s ! Sg ! pol.p } ; UttImpPol pol imp = {s = pol.s ++ imp.s ! Sg ! pol.p} ; + UttVP vp = {s = vp.s ! Active ! Pos} ; {- UttImpSg pol imp = UttImpPl pol imp = diff --git a/src/malay/SentenceMay.gf b/src/malay/SentenceMay.gf index e9075f17..c82ae487 100644 --- a/src/malay/SentenceMay.gf +++ b/src/malay/SentenceMay.gf @@ -34,6 +34,9 @@ lin } } ; + -- : VP -> SC ; + EmbedVP vp = {s = vp.s ! Root ! Pos} ; + {- -- : NP -> VS -> SSlash -> ClSlash ; -- (whom) she says that he loves SlashVS np vs ss = {} ;