mirror of
https://github.com/GrammaticalFramework/gf-rgl.git
synced 2026-05-27 17:08:54 -06:00
fixed SentAP and AdvAP for AdjPlace in ResChi
This commit is contained in:
@@ -18,12 +18,20 @@ concrete AdjectiveChi of Adjective = CatChi ** open ResChi, Prelude in {
|
|||||||
|
|
||||||
ReflA2 a = complexAP (a.s ++ appPrep a.c2 reflPron) ;
|
ReflA2 a = complexAP (a.s ++ appPrep a.c2 reflPron) ;
|
||||||
|
|
||||||
SentAP ap sc = complexAP (ap.s ++ sc.s) ;
|
|
||||||
|
-- SentAP ap sc = complexAP (ap.s ++ sc.s) ;
|
||||||
|
SentAP ap sc = ap ** {
|
||||||
|
|
||||||
|
s = table { adjPlace => ap.s ! adjPlace ++ sc.s }
|
||||||
|
} ;
|
||||||
|
|
||||||
AdAP ada ap = {s = ada.s ++ ap.s ; monoSyl = False ; hasAdA = True} ;
|
AdAP ada ap = {s = ada.s ++ ap.s ; monoSyl = False ; hasAdA = True} ;
|
||||||
|
|
||||||
UseA2 a = a ** {hasAdA = False} ;
|
UseA2 a = a ** {hasAdA = False} ;
|
||||||
|
|
||||||
AdvAP ap adv = complexAP (adv.s ++ ap.s) ; ----
|
-- AdvAP ap adv = complexAP (adv.s ++ ap.s) ;
|
||||||
|
AdvAP ap adv = ap ** {
|
||||||
|
s = table { adjPlace => adv.s ++ ap.s ! adjPlace }
|
||||||
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -96,6 +96,8 @@ param
|
|||||||
|
|
||||||
AdvType = ATPlace Bool | ATTime | ATManner | ATPoss ; -- ATPlace True = has zai_s already
|
AdvType = ATPlace Bool | ATTime | ATManner | ATPoss ; -- ATPlace True = has zai_s already
|
||||||
|
|
||||||
|
AdjPlace = Attr | Pred ; -- a green cat / the cat is green colour
|
||||||
|
|
||||||
-- parts of speech
|
-- parts of speech
|
||||||
|
|
||||||
oper
|
oper
|
||||||
@@ -113,15 +115,19 @@ oper
|
|||||||
-- for morphology
|
-- for morphology
|
||||||
|
|
||||||
Noun : Type = {s : Str ; c : Str} ;
|
Noun : Type = {s : Str ; c : Str} ;
|
||||||
Adj : Type = {s : Str ; monoSyl: Bool} ;
|
Adj : Type = {s : AdjPlace => Str ; monoSyl: Bool} ;
|
||||||
Verb : Type = {s,sn : Str ; pp,ds,dp,ep : Str ; neg : Str} ; --- sn=[] needed for "hen" as copula
|
Verb : Type = {s,sn : Str ; pp,ds,dp,ep : Str ; neg : Str} ; --- sn=[] needed for "hen" as copula
|
||||||
|
|
||||||
regNoun : Str -> Str -> Noun = \s,c -> {s = word s ; c = word c};
|
regNoun : Str -> Str -> Noun = \s,c -> {s = word s ; c = word c};
|
||||||
|
|
||||||
mkAdj : Str -> Bool -> Adj = \s,b -> {s = word s ; monoSyl = b};
|
mkAdj : Str -> Bool -> Adj = \s,b -> {s =
|
||||||
|
table {
|
||||||
|
_ => word s
|
||||||
|
};
|
||||||
|
monoSyl = b};
|
||||||
|
|
||||||
complexAP : Str -> Adj ** {hasAdA : Bool} =
|
complexAP : Str -> Adj ** {hasAdA : Bool} =
|
||||||
\s -> {s = s ; monoSyl = False ; hasAdA = False} ; --- not used for adding AdA
|
\s -> mkAdj s False ** {hasAdA = False} ; --- not used for adding AdA
|
||||||
|
|
||||||
simpleAdj : Str -> Adj = \s -> case s of {
|
simpleAdj : Str -> Adj = \s -> case s of {
|
||||||
? => mkAdj s True ; -- monosyllabic
|
? => mkAdj s True ; -- monosyllabic
|
||||||
|
|||||||
Reference in New Issue
Block a user