mirror of
https://github.com/GrammaticalFramework/gf-rgl.git
synced 2026-06-26 11:36:27 -06:00
make CompoundN more flexible
This commit is contained in:
+10
-1
@@ -59,7 +59,16 @@ lin ApposNP np1 np2 = np1 ** { -- guessed by KA
|
||||
} ;
|
||||
} ;
|
||||
|
||||
lin CompoundN a b = lin N {s = \\n => b.s ! n ++ a.s ! Sg ; g = b.g} ; -- connessione internet = internet connection
|
||||
lin CompoundN a b = lin N {
|
||||
s = \\n => b.s ! n ++
|
||||
case b.relType of {
|
||||
NRelPrep p => prepCase (CPrep p) ; -- tasa de suicidio
|
||||
NRelNoPrep => [] -- connessione internet = internet connection
|
||||
} ++
|
||||
a.s ! Sg ;
|
||||
g = b.g ;
|
||||
relType = b.relType
|
||||
} ;
|
||||
|
||||
lin UseDAP = \dap ->
|
||||
let
|
||||
|
||||
@@ -393,16 +393,16 @@ oper
|
||||
regGenN : Str -> Gender -> N ;
|
||||
regN : Str -> N ;
|
||||
mk2N : (oeil,yeux : Str) -> Gender -> N ;
|
||||
mk2N x y g = mkCNomIrreg x y g ** {lock_N = <>} ;
|
||||
mk2N x y g = mkCNomIrreg x y g ** {relType = NRelPrep P_de; lock_N = <>} ;
|
||||
regN x = regGenN x g where {
|
||||
g = case <x : Str> of {
|
||||
_ + ("e" | "ion") => Fem ;
|
||||
_ => Masc
|
||||
}
|
||||
} ;
|
||||
regGenN x g = mkNomReg x g ** {lock_N = <>} ;
|
||||
regGenN x g = mkNomReg x g ** {relType = NRelPrep P_de; lock_N = <>} ;
|
||||
compN : N -> Str -> N ;
|
||||
compN x y = {s = \\n => x.s ! n ++ y ; g = x.g ; lock_N = <>} ;
|
||||
compN x y = {s = \\n => x.s ! n ++ y ; g = x.g ; relType = NRelPrep P_de ; lock_N = <>} ;
|
||||
|
||||
mkN = overload {
|
||||
mkN : Str -> N = regN ;
|
||||
|
||||
Reference in New Issue
Block a user