diff --git a/src/abstract/Extend.gf b/src/abstract/Extend.gf index a3b49a63..15e07143 100644 --- a/src/abstract/Extend.gf +++ b/src/abstract/Extend.gf @@ -116,6 +116,11 @@ abstract Extend = Cat ** { ProgrVPSlash : VPSlash -> VPSlash; +-- construct VPSlash from A2 and N2 + + A2VPSlash : A2 -> VPSlash ; -- is married to (that person) + N2VPSlash : N2 -> VPSlash ; -- is a mother of (that person) + -- existential for mathematics ExistsNP : NP -> Cl ; -- there exists a number / there exist numbers @@ -126,7 +131,7 @@ abstract Extend = Cat ** { ExistMassCN : CN -> Cl ; -- there is beer / there is no beer ExistPluralCN : CN -> Cl ; -- there are trees / there are no trees --- generalisation of existential, with adverb as a parameter +-- generalisation of existential, with adverb as an argument AdvIsNP : Adv -> NP -> Cl ; -- here is the tree / here are the trees AdvIsNPAP : Adv -> NP -> AP -> Cl ; -- here are the instructions documented diff --git a/src/common/ExtendFunctor.gf b/src/common/ExtendFunctor.gf index a8018891..296eeaae 100644 --- a/src/common/ExtendFunctor.gf +++ b/src/common/ExtendFunctor.gf @@ -51,6 +51,8 @@ lin PastPartAgentAP = variants {} ; -- VPSlash -> NP -> AP ; -- (opportunity) lost by the company NominalizeVPSlashNP = variants {} ; -- VPSlash -> NP -> NP ; ProgrVPSlash = variants {} ; -- VPSlash -> VPSlash ; + A2VPSlash = variants {} ; -- A2 -> VPSlash ; + N2VPSlash = variants {} ; -- N2 -> VPSlash ; ExistsNP = ExistNP ; -- NP -> Cl ; -- there exists a number / there exist numbers ExistCN cn = ExistNP (DetCN (DetQuant IndefArt NumSg) cn) ; ExistMassCN cn = ExistNP (MassNP cn) ; diff --git a/src/english/ExtendEng.gf b/src/english/ExtendEng.gf index 872e2772..c46b7eed 100644 --- a/src/english/ExtendEng.gf +++ b/src/english/ExtendEng.gf @@ -16,7 +16,7 @@ concrete ExtendEng of Extend = GerundAdv, GerundCN, GerundNP, IAdvAdv, ICompAP, InOrderToVP, MkVPS, NominalizeVPSlashNP, PassAgentVPSlash, PassVPSlash, ProgrVPSlash, PastPartAP, PastPartAgentAP, PositAdVAdj, PredVPS, PredVPSVV, PredetRNP, PrepCN, EmbedSSlash, PredIAdvVP, PresPartAP, PurposeVP, ReflPoss, ReflPron, ReflRNP, SlashBareV2S, SlashV2V, StrandQuestSlash, StrandRelSlash, - UncontractedNeg, UttAccIP, UttAccNP, UttAdV, UttDatIP, UttDatNP, UttVPShort, WithoutVP, BaseVPS2, ConsVPS2, ConjVPS2, ComplVPS2, MkVPS2 + UncontractedNeg, UttAccIP, UttAccNP, UttAdV, UttDatIP, UttDatNP, UttVPShort, WithoutVP, BaseVPS2, ConsVPS2, ConjVPS2, ComplVPS2, MkVPS2, A2VPSlash, N2VPSlash ] with (Grammar = GrammarEng) ** @@ -225,6 +225,19 @@ concrete ExtendEng of Extend = ProgrVPSlash vp = insertObjc (\\a => vp.ad ! a ++ vp.prp ++ vp.p ++ vp.s2 ! a) (predAux auxBe ** {c2 = vp.c2; gapInMiddle = vp.gapInMiddle; missingAdv = vp.missingAdv}); + N2VPSlash n2 = + let prep : Prep = mkPrep n2.c2 ; + dummyVPS : VPSlash = SlashV2a (mkV2 (mkV "dummy") prep); + in dummyVPS ** -- has necessary fields for VPSlash, and c2 from the N2 + UseComp (CompCN (UseN2 n2)) ; -- has all the right fields except for c2 + + A2VPSlash a2 = + let prep : Prep = mkPrep a2.c2 ; + dummyVPS : VPSlash = SlashV2a (mkV2 (mkV "dummy") prep) ; + in dummyVPS ** -- has necessary fields for VPSlash, and c2 from the A2 + UseComp (CompAP (UseA2 a2)) ; -- has all the right fields except for c2 + + --- AR 7/3/2013 ComplSlashPartLast vps np = case vps.gapInMiddle of { _ => insertObjPartLast (\\_ => vps.c2 ++ np.s ! NPAcc) vps --- diff --git a/src/swedish/ExtendSwe.gf b/src/swedish/ExtendSwe.gf index 813468fb..727b95b2 100644 --- a/src/swedish/ExtendSwe.gf +++ b/src/swedish/ExtendSwe.gf @@ -14,7 +14,8 @@ concrete ExtendSwe of Extend = CatSwe ** RNP, RNPList, ReflRNP, ReflPron, ReflPoss, PredetRNP, ConjRNP, Base_rr_RNP, Base_nr_RNP, Base_rn_RNP, Cons_rr_RNP, Cons_nr_RNP, ReflPossPron, CompoundN, CompoundAP, AdvIsNP, - UttAccNP + UttAccNP, + A2VPSlash, N2VPSlash ] with (Grammar = GrammarSwe) ** @@ -70,6 +71,23 @@ in { PassAgentVPSlash vps np = insertObjPost (\\a => vps.c2.s ++ vps.n3 ! a) (insertObj (\\_ => (PrepNP by8agent_Prep np).s) (passiveVP vps)) ; + + N2VPSlash n2 = + let vp : CatSwe.VP = UseComp (CompCN (UseN2 n2)) ; + dummyVPS : VPSlash = SlashV2a (P.mkV2 "dummy") ; + in dummyVPS ** -- has necessary fields for VPSlash + vp ** -- has all the right fields except for c2 + {c2 = n2.c2} ; -- has the right c2 + + + + A2VPSlash a2 = + let vp : CatSwe.VP = UseComp (CompAP (UseA2 a2)) ; + dummyVPS : VPSlash = SlashV2a (P.mkV2 "dummy") ; + in dummyVPS ** -- has necessary fields for VPSlash + vp ** -- has all the right fields except for c2 + {c2 = a2.c2} ; -- has the right c2 + lin UttVPShort vp = {s = infVP vp (agrP3 Utr Sg)} ; lincat @@ -147,11 +165,11 @@ in { } ; c2 = vp.c2 } ; - + ComplVPS2 vps2 np = { s = \\o,a => vps2.s !o ! a ++ vps2.c2.s ++ np.s ! NPAcc } ; - + ConjVPS2 c xs = conjunctDistrTable2 Order Agr c xs ** {c2 = xs.c2} ; lincat @@ -210,7 +228,7 @@ in { Cons_nr_RNP x xs = consrTable Agr comma {s = \\a => x.s ! NPAcc} xs ; ReflPossPron = M.mkQuant "sin" "sitt" "sina" ; - + lin ApposNP np1 np2 = {s = \\nform => np1.s ! nform ++ comma ++ np2.s ! nform; a = np1.a; isPron = False} ;