mirror of
https://github.com/GrammaticalFramework/gf-rgl.git
synced 2026-07-01 11:38:34 -06:00
make CompoundN more flexible
This commit is contained in:
@@ -67,10 +67,14 @@ concrete ExtendPor of Extend = CatPor ** ExtendRomanceFunctor -
|
||||
|
||||
lin
|
||||
CompoundN noun noun2 = { -- order is different because that's needed for correct translation from english
|
||||
s = \\n => noun2.s ! n
|
||||
++ variants {"de" ; genForms "do" "da" ! noun.g}
|
||||
++ noun.s ! Sg ;
|
||||
g = noun2.g
|
||||
s = \\n => noun2.s ! n ++
|
||||
case noun2.relType of {
|
||||
NRelPrep p => artDef True noun.g Sg (CPrep p) ; -- tasa de suicidio
|
||||
NRelNoPrep => [] -- connessione internet = internet connection
|
||||
} ++
|
||||
noun.s ! Sg ;
|
||||
g = noun2.g ;
|
||||
relType = noun2.relType
|
||||
} ;
|
||||
|
||||
CompoundAP noun adj = {
|
||||
|
||||
@@ -102,7 +102,7 @@ oper
|
||||
--2 Nouns
|
||||
|
||||
regN : Str -> N ; --%
|
||||
regN x = lin N (mkNomReg x) ;
|
||||
regN x = lin N (mkNomReg x ** {relType=NRelPrep P_de}) ;
|
||||
|
||||
femN : N -> N ; --%
|
||||
femN n = n ** {g = feminine} ;
|
||||
@@ -111,7 +111,7 @@ oper
|
||||
mascN n = n ** {g = masculine} ;
|
||||
|
||||
mk2N : (bastão, bastões : Str) -> Gender -> N ; --%
|
||||
mk2N x y g = lin N (mkNounIrreg x y g) ;
|
||||
mk2N x y g = lin N (mkNounIrreg x y g ** {relType=NRelPrep P_de}) ;
|
||||
|
||||
-- The regular function takes the singular form and the gender, and
|
||||
-- computes the plural and the gender by a heuristic (see MorphoPor
|
||||
|
||||
Reference in New Issue
Block a user