From 42d06dfafd73c0f3d9250b06aed162e4902aa589 Mon Sep 17 00:00:00 2001 From: Krasimir Angelov Date: Thu, 7 Aug 2025 12:19:10 +0200 Subject: [PATCH] added some missing funs and cats --- src/latin/CatLat.gf | 4 +++- src/latin/ParadigmsLat.gf | 26 ++++++++++++++++++++++++++ 2 files changed, 29 insertions(+), 1 deletion(-) diff --git a/src/latin/CatLat.gf b/src/latin/CatLat.gf index 8394fe0d..9c8436ea 100644 --- a/src/latin/CatLat.gf +++ b/src/latin/CatLat.gf @@ -85,7 +85,9 @@ concrete CatLat of Cat = CommonX-[Adv] ** open ResLat, ParamX, Prelude in { N = Noun ; N2 = Noun ** { c : Prep } ; N3 = Noun ** { c : Prep ; c2 : Prep } ; - PN = { s : Case => Str ; n : Number ; g : Gender } ; + PN, LN = { s : Case => Str ; n : Number ; g : Gender } ; + GN = { s : Str ; g : Sex } ; + SN = { s : Sex => Str ; pl : Str } ; A2 = Adjective ** { c : Prep} ; linref diff --git a/src/latin/ParadigmsLat.gf b/src/latin/ParadigmsLat.gf index 360789ab..78f4ee20 100644 --- a/src/latin/ParadigmsLat.gf +++ b/src/latin/ParadigmsLat.gf @@ -110,6 +110,12 @@ oper = \p,c -> lin Adv (mkFullAdverb p c nonExist); }; + mkAdV : Str -> AdV + = \s -> lin AdV {s=s} ; + mkAdA : Str -> AdA + = \s -> lin AdA {s=s} ; + mkAdN : Str -> AdN + = \s -> lin AdN {s=s} ; mkConj = overload { @@ -147,4 +153,24 @@ oper mkA2V : A -> Prep -> A2V = \a,p -> lin A2V ( lin A2 ( a ** { c = p } ) ) ; AV : Type = A ; mkAV : A -> AV = \a -> lin AV a ; + + mkLN : N -> Number -> LN = \noun,num -> lin PN (noun ** { s = noun.s ! num ; n = num } ) ; + + mkGN = overload { + mkGN : Str -> GN = \s -> lin GN {s = s ; g = Male}; -- default gender male + mkGN : Str -> Sex -> GN = \s,g -> lin GN {s = s ; g = g} ; -- set other gender + } ; + + mkSN = overload { + mkSN : Str -> SN = \s -> lin SN {s = \\_=>s; pl = s}; -- default gender utrum + mkSN : Str -> Str -> Str -> SN = + \male,female,pl -> lin SN {s = table {Male => male; + Female => female} ; + pl = pl + } ; + } ; + + mkInterj : Str -> Interj + = \s -> lin Interj {s=s} ; + }