From bf0fd5696065a02b074a93750717f95ac05ca61e Mon Sep 17 00:00:00 2001 From: Inari Listenmaa Date: Wed, 30 Jan 2019 16:23:11 +0100 Subject: [PATCH] (Ara) Use PerGenNum in the table for RCl and RS; compiles 15sec faster --- src/arabic/CatAra.gf | 2 +- src/arabic/NounAra.gf | 4 ++-- src/arabic/RelativeAra.gf | 6 +++--- src/arabic/ResAra.gf | 8 ++++---- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/arabic/CatAra.gf b/src/arabic/CatAra.gf index 201a3280..10fcfb70 100644 --- a/src/arabic/CatAra.gf +++ b/src/arabic/CatAra.gf @@ -13,7 +13,7 @@ concrete CatAra of Cat = CommonX - [Utt] ** open ResAra, Prelude, ParamX in { SSlash, S = {s : Order => Str} ; -- subordinate clause has nominal word order and subject in acc QS = {s : QForm => Str} ; - RS = {s : Agr => Case => Str} ; -- case because the relative pronoun inflects in case + RS = {s : PerGenNum => Case => Str} ; -- case because the relative pronoun inflects in case -- Sentence diff --git a/src/arabic/NounAra.gf b/src/arabic/NounAra.gf index 108f09bf..4f918f61 100644 --- a/src/arabic/NounAra.gf +++ b/src/arabic/NounAra.gf @@ -199,13 +199,13 @@ lin RelCN cn rs = cn ** { s2 = \\n,s,c => cn.s2 ! n ! s ! c - ++ rs.s ! {pgn=Per3 cn.g n ; isPron=False} ! c ; + ++ rs.s ! Per3 cn.g n ! c ; isHeavy = True } ; RelNP np rs = np ** { - s = \\c => np.s ! c ++ rs.s ! np.a ! c ; + s = \\c => np.s ! c ++ rs.s ! np.a.pgn ! c ; isHeavy = True } ; diff --git a/src/arabic/RelativeAra.gf b/src/arabic/RelativeAra.gf index 4f0054ad..6b652929 100644 --- a/src/arabic/RelativeAra.gf +++ b/src/arabic/RelativeAra.gf @@ -1,5 +1,5 @@ concrete RelativeAra of Relative = CatAra ** - open ResAra in { + open Prelude,ResAra in { flags coding=utf8; lin @@ -13,7 +13,7 @@ concrete RelativeAra of Relative = CatAra ** s = \\t,p,agr,c => let npS : Case => Str = \\_ => rp.s ! agr2ragr agr c ; - np : ResAra.NP = agrNP agr ** {s = npS} ; + np : ResAra.NP = agrNP {pgn=agr;isPron=False} ** {s = npS} ; cl = predVP np vp ; in cl.s ! t ! p ! Nominal @@ -23,7 +23,7 @@ concrete RelativeAra of Relative = CatAra ** RelSlash rp cls = cls ** { s = \\t,p,agr,c => let --empty : Agr -> NP = emptyNP ; - obj : ResAra.NP = pgn2pron agr.pgn ; -- head is repeated as a clitic object pronoun + obj : ResAra.NP = pgn2pron agr ; -- head is repeated as a clitic object pronoun cl : ResAra.Cl = complClSlash obj cls ; in rp.s ! agr2ragr agr c ++ cl.s ! t ! p ! VOS } ; diff --git a/src/arabic/ResAra.gf b/src/arabic/ResAra.gf index 62164573..fe41d758 100644 --- a/src/arabic/ResAra.gf +++ b/src/arabic/ResAra.gf @@ -469,7 +469,7 @@ param | VPImp | VPGer ; - VType = -- indicates if there is a predicate (xabar): + VType = -- indicates if there is a predicate (xabar): Copula -- 1) disappears in equational sentences -- 2) its argument ('xabar') is in the pred field -- 3) it is negated with laysa @@ -729,8 +729,8 @@ param oper agr2ragr = overload { - agr2ragr : Agr -> Case -> RAgr = \a,c -> - let gn = pgn2gn a.pgn in case of { + agr2ragr : PerGenNum -> Case -> RAgr = \pgn,c -> + let gn = pgn2gn pgn in case of { => RSg x ; => RDl x c ; => RPl x } ; @@ -741,7 +741,7 @@ oper Pl => RPl g } } ; - RCl : Type = {s : Tense => Polarity => Agr => Case => Str} ; + RCl : Type = {s : Tense => Polarity => PerGenNum => Case => Str} ; RP : Type = {s : RAgr => Str } ; -----------------------------------------------------------------------------