forked from GitHub/gf-rgl
(Hun) Remove PlAcc from stems, turns out it wasn't needed
According to https://www.researchgate.net/publication/268175865_Does_Hungarian_have_a_case_system p. 45, the allomorph for plural accusative is predictable.
This commit is contained in:
@@ -132,8 +132,7 @@ lin floor_N = mkN "padló" "padlót" ;
|
|||||||
-- lin flow_V = mkV "" ;
|
-- lin flow_V = mkV "" ;
|
||||||
lin flower_N = mkN "virág" "virágot" "virágok" "virága" ;
|
lin flower_N = mkN "virág" "virágot" "virágok" "virága" ;
|
||||||
lin fly_V = mkV "repül" ;
|
lin fly_V = mkV "repül" ;
|
||||||
lin fog_N = mkN "köd" "ködöt" "ködön" "ködhöz"
|
lin fog_N = mkN "köd" "ködöt" "ködön" "ködhöz" "ködök"
|
||||||
"ködök" "ködöket"
|
|
||||||
"köde" "ködünk" "ködei" ;
|
"köde" "ködünk" "ködei" ;
|
||||||
lin foot_N = leg_N ; --same as leg, to specify "lábfej"
|
lin foot_N = leg_N ; --same as leg, to specify "lábfej"
|
||||||
lin forest_N = mkN "erdő" "erdőt" ;
|
lin forest_N = mkN "erdő" "erdőt" ;
|
||||||
@@ -320,8 +319,7 @@ lin shirt_N = mkN "ing" "inget"; --shirt like t-shirt or the more formal?
|
|||||||
lin shoe_N = mkN "cipő" "cipőt" ;
|
lin shoe_N = mkN "cipő" "cipőt" ;
|
||||||
lin shop_N = mkN "üzlet" "üzletet";
|
lin shop_N = mkN "üzlet" "üzletet";
|
||||||
lin short_A = mkA "rövid" ; --in short text, if human length then "alacsony"
|
lin short_A = mkA "rövid" ; --in short text, if human length then "alacsony"
|
||||||
lin silver_N = mkN "ezüst" "ezüstöt" "ezüstön" "ezüsthöz"
|
lin silver_N = mkN "ezüst" "ezüstöt" "ezüstön" "ezüsthöz" "ezüstök"
|
||||||
"ezüstök" "ezüstöket"
|
|
||||||
"ezüstje" "ezüstünk" "ezüstjei" ;
|
"ezüstje" "ezüstünk" "ezüstjei" ;
|
||||||
-- lin sing_V = mkV "" ;
|
-- lin sing_V = mkV "" ;
|
||||||
-- lin sister_N = mkN "" ;
|
-- lin sister_N = mkN "" ;
|
||||||
|
|||||||
@@ -37,7 +37,7 @@ oper
|
|||||||
s = \\nc => case nc of {
|
s = \\nc => case nc of {
|
||||||
|
|
||||||
-- All plural forms and Sg Acc use the "lova" stem
|
-- All plural forms and Sg Acc use the "lova" stem
|
||||||
PlStem | PlAcc | SgAccStem
|
PlStem | SgAccStem
|
||||||
=> nLova.s ! nc ;
|
=> nLova.s ! nc ;
|
||||||
|
|
||||||
SgSup | -- Sg Sup has vowel o/ö, not a/e
|
SgSup | -- Sg Sup has vowel o/ö, not a/e
|
||||||
@@ -64,8 +64,8 @@ oper
|
|||||||
in nFalu ** {
|
in nFalu ** {
|
||||||
s = \\nc => case nc of {
|
s = \\nc => case nc of {
|
||||||
|
|
||||||
-- All plural forms and Sg Acc, Sg Sup use the "falu" stem
|
-- All plural forms use the "falva" stem
|
||||||
PlStem | PlAcc => nFalva.s ! nc ;
|
PlStem => nFalva.s ! nc ;
|
||||||
|
|
||||||
-- The plural morpheme before possessive suffixes is i
|
-- The plural morpheme before possessive suffixes is i
|
||||||
PossdPl => nFalu.s ! nc + "i" ;
|
PossdPl => nFalu.s ! nc + "i" ;
|
||||||
@@ -95,7 +95,6 @@ oper
|
|||||||
s = \\nc => case nc of {
|
s = \\nc => case nc of {
|
||||||
|
|
||||||
SgSup -- All plural forms and Sg Acc and Sg Sup use the "majmo" stem
|
SgSup -- All plural forms and Sg Acc and Sg Sup use the "majmo" stem
|
||||||
| PlAcc
|
|
||||||
| PlStem
|
| PlStem
|
||||||
| SgAccStem => nMajmo.s ! nc ;
|
| SgAccStem => nMajmo.s ! nc ;
|
||||||
|
|
||||||
@@ -197,7 +196,7 @@ oper
|
|||||||
in nTolla ** {
|
in nTolla ** {
|
||||||
s = \\nc => case nc of {
|
s = \\nc => case nc of {
|
||||||
-- All plural forms and Sg Acc use the "tolla" stem
|
-- All plural forms and Sg Acc use the "tolla" stem
|
||||||
PlStem | PlAcc | SgAccStem => nTolla.s ! nc ;
|
PlStem | SgAccStem => nTolla.s ! nc ;
|
||||||
|
|
||||||
PossdSg_PossrPl1 => napj + harm "u" "ü" ! nToll.h ;
|
PossdSg_PossrPl1 => napj + harm "u" "ü" ! nToll.h ;
|
||||||
|
|
||||||
@@ -221,7 +220,7 @@ oper
|
|||||||
in nMadara ** {
|
in nMadara ** {
|
||||||
s = \\nc => case nc of {
|
s = \\nc => case nc of {
|
||||||
-- All plural forms and Sg Acc use the "tolla" stem
|
-- All plural forms and Sg Acc use the "tolla" stem
|
||||||
PlStem | PlAcc | SgAccStem => nMadara.s ! nc ;
|
PlStem | SgAccStem => nMadara.s ! nc ;
|
||||||
|
|
||||||
PossdSg_PossrPl1 => madar + harm "u" "ü" ! nMadara.h ;
|
PossdSg_PossrPl1 => madar + harm "u" "ü" ! nMadara.h ;
|
||||||
|
|
||||||
@@ -241,8 +240,8 @@ oper
|
|||||||
-- TODO: teher ~ terhet (consonant-crossing)
|
-- TODO: teher ~ terhet (consonant-crossing)
|
||||||
|
|
||||||
-- Worst case constructor: takes all stems
|
-- Worst case constructor: takes all stems
|
||||||
worstCaseNoun : (x1,_,_,_,_,_,_,_,x10 : Str) -> Harm -> Noun =
|
worstCaseNoun : (x1,_,_,_,_,_,_,x8 : Str) -> Harm -> Noun =
|
||||||
\nomsg,accsg,supsg,allsg,nompl,accpl,possdSg_possrP3sg,possdSg_PossrPl1,possdPl,h ->
|
\nomsg,accsg,supsg,allsg,nompl,possdSg_possrP3sg,possdSg_PossrPl1,possdPl,h ->
|
||||||
let sgstem = tk 3 allsg ; -- remove -hoz/hez/höz
|
let sgstem = tk 3 allsg ; -- remove -hoz/hez/höz
|
||||||
sginsstem : Str = case vowFinal sgstem of {
|
sginsstem : Str = case vowFinal sgstem of {
|
||||||
True => sgstem + "v" ;
|
True => sgstem + "v" ;
|
||||||
@@ -255,7 +254,6 @@ oper
|
|||||||
SgAccStem => init accsg ; -- remove t; same stem used for other forms
|
SgAccStem => init accsg ; -- remove t; same stem used for other forms
|
||||||
SgInsStem => sginsstem ;
|
SgInsStem => sginsstem ;
|
||||||
PlStem => nompl ;
|
PlStem => nompl ;
|
||||||
PlAcc => accpl ;
|
|
||||||
PossdSg_PossrP3 => init possdSg_possrP3sg ; -- remove -a/e
|
PossdSg_PossrP3 => init possdSg_possrP3sg ; -- remove -a/e
|
||||||
PossdSg_PossrPl1 => tk 2 possdSg_PossrPl1 ; -- remove -nk
|
PossdSg_PossrPl1 => tk 2 possdSg_PossrPl1 ; -- remove -nk
|
||||||
PossdPl => possdPl } ;
|
PossdPl => possdPl } ;
|
||||||
@@ -481,7 +479,6 @@ oper
|
|||||||
-- Variant of case forms when the noun stem ends in consonant.
|
-- Variant of case forms when the noun stem ends in consonant.
|
||||||
endCaseCons : NumCaseStem -> HarmForms = \c -> case c of {
|
endCaseCons : NumCaseStem -> HarmForms = \c -> case c of {
|
||||||
SgSup => harm3 "on" "en" "ön" ;
|
SgSup => harm3 "on" "en" "ön" ;
|
||||||
PlAcc => harm3 "ot" "et" "öt" ;
|
|
||||||
SgAccStem => harm3 "o" "e" "ö" ;
|
SgAccStem => harm3 "o" "e" "ö" ;
|
||||||
SgAll => harm3 "hoz" "hez" "höz" ;
|
SgAll => harm3 "hoz" "hez" "höz" ;
|
||||||
PossdPl => harm1 "i" ; -- TODO figure out allomorphs
|
PossdPl => harm1 "i" ; -- TODO figure out allomorphs
|
||||||
@@ -492,7 +489,6 @@ oper
|
|||||||
-- Variant where accusative has the allomorph -at
|
-- Variant where accusative has the allomorph -at
|
||||||
endCaseConsAccAt : NumCaseStem -> HarmForms = \c -> case c of {
|
endCaseConsAccAt : NumCaseStem -> HarmForms = \c -> case c of {
|
||||||
SgAccStem => harm3 "a" "e" "ö" ;
|
SgAccStem => harm3 "a" "e" "ö" ;
|
||||||
PlAcc => harm3 "at" "et" "öt" ;
|
|
||||||
_ => endCaseCons c
|
_ => endCaseCons c
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
@@ -541,11 +537,7 @@ oper
|
|||||||
|"zz"|"ss"|"ll"|"rr"|"nn"|"ns"|"nsz"|"nz")> => endCaseConsAcc ;
|
|"zz"|"ss"|"ll"|"rr"|"nn"|"ns"|"nsz"|"nz")> => endCaseConsAcc ;
|
||||||
<True,_> => endCaseConsAccAt ;
|
<True,_> => endCaseConsAccAt ;
|
||||||
_ => endCaseCons } ;
|
_ => endCaseCons } ;
|
||||||
endCasePl : NumCaseStem -> HarmForms =
|
|
||||||
case <plural, useAt> of {
|
|
||||||
<"ak",_> => endCaseConsAccAt ;
|
|
||||||
<_,True> => endCaseConsAccAt ;
|
|
||||||
_ => endCaseCons } ;
|
|
||||||
-- Last consonant doubles before instrumental and translative
|
-- Last consonant doubles before instrumental and translative
|
||||||
duplConsStem : Str = case vowFinal w of {
|
duplConsStem : Str = case vowFinal w of {
|
||||||
True => w ;
|
True => w ;
|
||||||
@@ -557,14 +549,14 @@ oper
|
|||||||
-- Before Sg Ins, Tra:
|
-- Before Sg Ins, Tra:
|
||||||
-- * Double the last letter if consonant
|
-- * Double the last letter if consonant
|
||||||
-- * Add v if vowel (comes from endCaseSg)
|
-- * Add v if vowel (comes from endCaseSg)
|
||||||
SgInsStem => duplConsStem + endCaseSg SgInsStem ! h ;
|
SgInsStem => duplConsStem + endCaseSg SgInsStem ! h ;
|
||||||
|
|
||||||
-- endCaseCons, because we only use -k as plural morpheme.
|
-- endCaseCons, because we only use -k as plural morpheme.
|
||||||
-- If we add possessive forms with allomorph -i, then revise.
|
-- Possessive forms with allomorph -i are handled separately.
|
||||||
c@(PlStem|PlAcc) => w + plural + endCasePl c ! h ;
|
PlStem => w + plural ;
|
||||||
|
|
||||||
-- All other singular forms and stems
|
-- All other singular forms and stems
|
||||||
c => w + endCaseSg c ! h } ;
|
c => w + endCaseSg c ! h } ;
|
||||||
|
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
@@ -574,7 +566,7 @@ oper
|
|||||||
|
|
||||||
endCase : Case -> HarmForms = \c -> case c of {
|
endCase : Case -> HarmForms = \c -> case c of {
|
||||||
Nom => harm1 [] ;
|
Nom => harm1 [] ;
|
||||||
Acc => harm3 "ot" "et" "öt" ;
|
Acc => harm "at" "et" ; -- NB. this is only used for plural acc!
|
||||||
Dat => harm "nak" "nek" ;
|
Dat => harm "nak" "nek" ;
|
||||||
Ade => harm "nál" "nél" ;
|
Ade => harm "nál" "nél" ;
|
||||||
Sup => harm3 "on" "en" "ön" ;
|
Sup => harm3 "on" "en" "ön" ;
|
||||||
|
|||||||
@@ -135,8 +135,8 @@ oper
|
|||||||
mkN : (x1,_,_,x4 : Str) -> N =
|
mkN : (x1,_,_,x4 : Str) -> N =
|
||||||
\n,a,pln,possd -> lin N (regNoun4 n a pln possd) ;
|
\n,a,pln,possd -> lin N (regNoun4 n a pln possd) ;
|
||||||
|
|
||||||
mkN : (x1,_,_,_,_,_,_,_,x9 : Str) -> N =
|
mkN : (x1,_,_,_,_,_,_,x8 : Str) -> N =
|
||||||
\a,b,c,d,e,f,g,h,i -> lin N (worstCaseNoun a b c d e f g h i (getHarm a)) ;
|
\a,b,c,d,e,f,g,h -> lin N (worstCaseNoun a b c d e f g h (getHarm a)) ;
|
||||||
|
|
||||||
mkN : Str -> Harmony -> N =
|
mkN : Str -> Harmony -> N =
|
||||||
\s,h -> lin N (mkNounHarm h (pluralAllomorph s) s) ;
|
\s,h -> lin N (mkNounHarm h (pluralAllomorph s) s) ;
|
||||||
|
|||||||
@@ -71,7 +71,7 @@ param
|
|||||||
|
|
||||||
NumCaseStem =
|
NumCaseStem =
|
||||||
SgNom | SgAccStem | SgSup -- These may use 2-3 different stems
|
SgNom | SgAccStem | SgSup -- These may use 2-3 different stems
|
||||||
| PlAcc -- May have irregular vowel in suffix
|
-- May have irregular vowel in suffix
|
||||||
| SgAll -- May have irregular vowel in suffix
|
| SgAll -- May have irregular vowel in suffix
|
||||||
| SgInsStem -- Instrumental and translative: -v after vowels
|
| SgInsStem -- Instrumental and translative: -v after vowels
|
||||||
| SgStem -- Rest of the cases in Sg
|
| SgStem -- Rest of the cases in Sg
|
||||||
@@ -152,7 +152,6 @@ oper
|
|||||||
SgAccStem => "SgAccStem" ;
|
SgAccStem => "SgAccStem" ;
|
||||||
SgSup => "SgSup" ;
|
SgSup => "SgSup" ;
|
||||||
SgAll => "SgAll" ;
|
SgAll => "SgAll" ;
|
||||||
PlAcc => "PlAcc" ;
|
|
||||||
SgInsStem => "SgInsStem" ;
|
SgInsStem => "SgInsStem" ;
|
||||||
SgStem => "SgStem" ;
|
SgStem => "SgStem" ;
|
||||||
PlStem => "PlStem" ;
|
PlStem => "PlStem" ;
|
||||||
|
|||||||
@@ -29,7 +29,6 @@ oper
|
|||||||
<Sg,Acc> => bind (cn.s ! SgAccStem) "t" ;
|
<Sg,Acc> => bind (cn.s ! SgAccStem) "t" ;
|
||||||
<Sg,Sup> => cn.s ! SgSup ;
|
<Sg,Sup> => cn.s ! SgSup ;
|
||||||
<Sg,All> => cn.s ! SgAll ;
|
<Sg,All> => cn.s ! SgAll ;
|
||||||
<Pl,Acc> => cn.s ! PlAcc ;
|
|
||||||
<Pl,Nom> => cn.s ! PlStem ; -- don't use applyCase', it adds a BIND which breaks everything!
|
<Pl,Nom> => cn.s ! PlStem ; -- don't use applyCase', it adds a BIND which breaks everything!
|
||||||
<Sg,Ins|Tra> => applyCase' SgInsStem ;
|
<Sg,Ins|Tra> => applyCase' SgInsStem ;
|
||||||
<Pl,Ins|Tra> => bind (bind (cn.s ! PlStem) "k") (endCase cas ! cn.h) ;
|
<Pl,Ins|Tra> => bind (bind (cn.s ! PlStem) "k") (endCase cas ! cn.h) ;
|
||||||
|
|||||||
Reference in New Issue
Block a user