mirror of
https://github.com/GrammaticalFramework/gf-rgl.git
synced 2026-05-27 08:58:55 -06:00
overloaded compoundN
This commit is contained in:
@@ -1533,11 +1533,25 @@ mkN2 = overload {
|
|||||||
mkN2 : N -> Prep -> N2 = \n,p -> lin N2 n ** {c2=p};
|
mkN2 : N -> Prep -> N2 = \n,p -> lin N2 n ** {c2=p};
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
compoundN : A -> N -> N = \a,n -> lin N {
|
compoundN = overload {
|
||||||
s = \\spec,num => a.s ! spec ! genNum n.g num ++ n.s ! Indef ! num ;
|
compoundN : A -> N -> N = \a,n -> lin N {
|
||||||
count_form = a.s ! Indef ! genNum n.g Pl ++ n.count_form ;
|
s = \\spec,num => a.s ! spec ! genNum n.g num ++ n.s ! Indef ! num ;
|
||||||
vocative = \\num => a.s ! Indef ! genNum n.g num ++ n.vocative ! num ;
|
count_form = a.s ! Indef ! genNum n.g Pl ++ n.count_form ;
|
||||||
g = n.g
|
vocative = \\num => a.s ! Indef ! genNum n.g num ++ n.vocative ! num ;
|
||||||
|
g = n.g
|
||||||
|
} ;
|
||||||
|
compoundN : N -> Str -> N = \n,adv -> lin N {
|
||||||
|
s = \\spec,num => n.s ! spec ! num ++ adv ;
|
||||||
|
count_form = n.count_form ++ adv ;
|
||||||
|
vocative = \\num => n.vocative ! num ++ adv ;
|
||||||
|
g = n.g
|
||||||
|
} ;
|
||||||
|
compoundN : Str -> N -> N = \pref,n -> lin N {
|
||||||
|
s = \\spec,num => pref ++ n.s ! spec ! num ;
|
||||||
|
count_form = pref ++ n.count_form ;
|
||||||
|
vocative = \\num => pref ++ n.vocative ! num ;
|
||||||
|
g = n.g
|
||||||
|
}
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
mkPN : Str -> PN = \s -> lin PN {s=s} ;
|
mkPN : Str -> PN = \s -> lin PN {s=s} ;
|
||||||
|
|||||||
@@ -184,4 +184,10 @@ oper mkPron : (_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> Pron =
|
|||||||
}
|
}
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
|
genNum : Gender -> Number -> GenNum = \g,n ->
|
||||||
|
case n of {
|
||||||
|
Sg => GSg g ;
|
||||||
|
Pl => GPl
|
||||||
|
} ;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user