Wikcionario
eswiktionary
https://es.wiktionary.org/wiki/Wikcionario:Portada
MediaWiki 1.47.0-wmf.10
case-sensitive
Medio
Especial
Discusión
Usuario
Usuario discusión
Wikcionario
Wikcionario discusión
Archivo
Archivo discusión
MediaWiki
MediaWiki discusión
Plantilla
Plantilla discusión
Ayuda
Ayuda discusión
Categoría
Categoría discusión
Apéndice
Apéndice Discusión
Tesauro
Tesauro discusión
TimedText
TimedText talk
Módulo
Módulo discusión
Evento
Evento discusión
fit
0
7581
6121389
5903103
2026-07-11T12:54:20Z
Adelpine
34679
Agrega una transcripción AFI (elaboración propia) y los hablantes de la otra
6121389
wikitext
text/x-wiki
{{desambiguación|fît}}
== {{lengua|fr}} ==
{{pron-graf|leng=fr
|h=fis
|h2=fît}}
=== Forma verbal ===
;1: {{f.v|leng=fr|faire|3s|pret ind|indicativo|pron=il, elle, on}}.
== {{lengua|en}} ==
{{pron-graf|leng=en
|pron=Received Pronunciation, General American, Canadá, Australia|fono=fɪt|audio=en-us-fit.ogg|aunota=California|audio2=LL-Q1860 (eng)-Wodencafe-fit.wav|aunota2=Texas|audio3=LL-Q1860 (eng)-Grendelkhan-fit.wav|aunota3=Connecticut
|2pron1=Nueva Zelanda|2fono1=fət
}}
=== Etimología 1 ===
{{etimología|leng=en|enm|fit}}.
==== {{sustantivo|en}} ====
{{en.sust|c}}
;1: [[ajuste|Ajuste]] (de ropa).
==== {{adjetivo|en}} ====
{{en.adj|c}}
;2: [[adecuado|Adecuado]].
;3: [[apto|Apto]].
;4: En forma.
;5: [[atractivo|Atractivo]] (de una persona).
{{ámbito|leng=en|Reino Unido}}
;6: [[preparado|Preparado]].
==== {{verbo|en}} ====
;7: [[caber|Caber]].
;8: [[adecuar|Adecuarse]] a.
;9: [[encajar|Encajar]].
;10: [[tomar|Tomarle]] las medidas.
;11: [[equipar|Equipar]].
==== Conjugación ====
{{en.v|fitted;fit}}
=== Etimología 2 ===
{{etimología|leng=en|incierta}}. Posiblemente del inglés antiguo {{l+|ang|fitt}} (canción).
==== {{sustantivo|en}} ====
{{en.sust|c}}
;1: Sección de un poema o balada.
{{uso|arcaico}}
=== Etimología 3 ===
{{etimología|leng=en|incierta}}. Posiblemente del inglés antiguo {{l+|ang|fitt}} (conflicto). Probablemente cognante del italiano {{l+|ang|fitta}} (dolor).
==== {{sustantivo|en}} ====
{{en.sust|c}}
;1: [[ataque|Ataque]] (de [[epilepsia]], [[rabia]], o [[tos]]).
;2: [[rapto|Rapto]] y [[arrebato]].
;3: [[acceso|Acceso]] (de [[ira]]).
=== Forma flexiva ===
==== Forma verbal ====
;1: {{fv-en|fit|pasado simple|irr=x}}.
;2: {{fv-en|fit|participio pasado|irr=x}}.
==== Conjugación ====
{{en.v|fitted;fit}}
== {{lengua|vo}} ==
{{pron-graf|leng=vo|fono=fit}}
=== Etimología ===
{{etimología|leng=vo}}
=== {{sustantivo|vo}} ===
;1: [[pez|Pez]], [[pescado]].
==== Declinación ====
{{vo.sust}}
== Referencias y notas ==
<references />
awh6vwjtyy9fo70uhesb2nirk6epwmj
témer
0
25915
6121419
4716141
2026-07-11T15:42:42Z
Tmagc
158167
6121419
wikitext
text/x-wiki
{{desambiguación|temer|}}
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Etimología ===
{{etimología|leng=ca|la|timeo}}.
=== {{verbo transitivo|ca}} ===
;1: {{plm|temer}}.
=== Conjugación ===
{{ca.v}}
== Referencias y notas ==
<references />
9pg7ez14bl248fk2eu4wz4dw9mz09m4
era
0
30009
6121393
6042861
2026-07-11T13:35:10Z
Jemily1
121719
añado forma verbal en catalán
6121393
wikitext
text/x-wiki
{{desambiguación|Era|éra|erra|Erra|ẽrà}}
== {{lengua|es}} ==
{{pron-graf}}
=== Etimología 1 ===
{{etimología|la|aera}}.
==== {{sustantivo femenino|es}} ====
{{es.sust}}
;1: Periodo geológico de larga duración.
;2: Punto fijo y fecha determinada de un suceso, desde el cual se empiezan a contar los años. Sirve para los cómputos cronológicos.<ref name="drae1925">{{DLE1925}}</ref>
==== Locuciones ====
* [[era común]]
* [[era cristiana]]
* [[era de César]]
* [[era de Cristo]]
* [[era española]]
* [[era vulgar]]
==== Véase también ====
{{w|era geológica}}
==== Traducciones ====
{{trad-arriba}}
{{trad-abajo}}
=== Etimología 2 ===
{{etimología|la|area|alt=ārea}}.
==== {{sustantivo femenino|es}} ====
{{es.sust}}
[[File:Image taken from page 323 of 'La Tierra de María Santísima. Colección de cuadros andaluces ... Ilustraciones de J. Garcia y Ramos'.jpg|thumb|Trillando en la era. Dibujo de José García Ramos]]
;1 {{csem|agricultura}}: Espacio de tierra limpia y firme para [[labranza]], a veces [[empedrado]], donde se extendían las [[mies]]es para [[trillar]]las y [[limpiar]]las.<ref name="drae1925" />
;2 {{csem|agricultura}}: {{plm|cuadro}} pequeño de tierra destinado al cultivo de flores u [[hortaliza]]s.<ref name="drae1925" />
;3 {{csem|construcción}}: Suelo [[apisonado]] y preparado por los albañiles para [[majar]] el [[yeso]], hacer las mezclas o para arreglar sobre él los [[solado]]s.<ref name="drae1925" />
;4 {{csem|minería}}: Sitio llano cerca de las [[mina]]s, donde se machacan y limpian los minerales.<ref name="drae1925" />
==== Locuciones ====
* [[alzar de eras]]
* [[levantar de eras]]
==== Véase también ====
{{w|era (lugar de trabajo)}}
==== Traducciones ====
{{trad-arriba}}
{{trad-abajo}}
=== Etimología 3 ===
{{etimología|incierta|}}. Quizás del acortamiento de "ya era".
==== {{interjección|es}} ====
{{es.sust}}
;1: {{impropia|Expresa que algo ya ocurrido no tiene importancia en el presente o que no vale la pena pensar en ello.}}
{{ámbito|Chile}}
{{uso|vulgar}}
==== Traducciones ====
{{trad-arriba}}
{{trad-abajo}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{forma verbo|erar|m=indicativo|p=3s|t=presente}}.
;2: {{forma verbo|erar|afirmativo=sí|p=2s|t=imperativo}}.
{{relacionado|eres|nota1=imperativo negativo}}.
;3: {{forma verbo|ser|m=indicativo|p=1s|t=imperfecto}}.
;4: {{forma verbo|ser|m=indicativo|p=3s|t=imperfecto}}.
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|1s|imp|ind|pron=jo}}.
;2: {{f.v|leng=ca|ser|3s|imp|ind|pron=ell, ella, vostè}}.
== {{lengua|en}} ==
{{pron-graf|leng=en
|1pron1=Received Pronunciation|1fono1=ˈɪə.ɹə|1fone2=ˈɪə̯.ɹə|1fone3=ˈɪː.ɹə|1audio3=en-uk-era.ogg
|2pron1=EE. UU.|2fono1=ˈɛɹ.ə|2audio1=En-us-era.ogg|2aunota1=California|2fono2=ˈɪɚ.ə
|3pron1=Australia|3fono1=ˈɪə.ɹə|3fone2=ˈɪə̯.ɹə
|4pron1=Nueva Zelanda|4fono1=iə.ɹə|4fone2=ˈi̞ə̯.ɹə|4fone3=ˈiː.ɹə
|g1=æra|gnota1=arcaica|h1=error|hnota1=acentos no róticos de EE. UU.
|ls=2}}
=== Etimología ===
{{etimología|leng=en|la-lat|aera}}.
=== {{sustantivo|en}} ===
{{en.sust|c}}
;1: {{plm|era}}.
== Referencias y notas ==
<references />
sekv8yubbt7d5em9ckqb7tha6a5hkut
fou
0
50496
6121403
5839186
2026-07-11T13:58:18Z
Jemily1
121719
añado esta forma verbal en catalán
6121403
wikitext
text/x-wiki
{{desambiguación|fóu}}
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|3s|ind|ind|pron=ell, ella, vostè}}.
== {{lengua|fr}} ==
{{pron-graf|leng=fr}}
=== Etimología 1 ===
{{etimología|leng=fr|la|follis}}.
==== {{adjetivo|fr}} ====
{{fr.adj}}
;1: {{plm|loco}}.
{{uso|setc|leng=fr}}
=== Etimología 2 ===
{{etimología|leng=fr|es|alfil}}.
==== {{sustantivo masculino|fr}} ====
{{fr.sust}}
;1: {{plm|alfil}}.
;2: {{plm|bufón}}.
== Referencias y notas ==
<references />
8mk1ama6szmrfp22xb8jepeiyljodih
eren
0
74027
6121399
6100403
2026-07-11T13:45:45Z
Jemily1
121719
creo esta forma verbal en catalán
6121399
wikitext
text/x-wiki
{{desambiguación|Eren}}
== {{lengua|br}} ==
{{swadesh|br|137eren}}
{{pron-graf|leng=br|1fono1=ˈeː.rɛn|v1=aeren|v2=aeriñ}}
=== Etimología 1 ===
{{etimología|leng=br}}.
==== {{verbo|br}} ====
;1: {{plm|liar}}, [[ligar]].<ref>{{Brezhoneg21}}</ref>
;2: {{plm|enlazar}}.<ref name=trou>{{Troude1886}}</ref>
;3: {{plm|unir}}, [[juntar]].<ref name=trou />
{{sinónimo|leng=br|koulmañ|stagañ}}.
==== Conjugación ====
{{inflect.br.verbo|e|re|ren}}
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|3p|imp|ind|pron=ells, elles, vostès}}.
== Referencias y notas ==
<references />
k4efu1tj7mxq4pey1jop24mewkgjna4
tobacco
0
89649
6121424
5935505
2026-07-12T01:45:31Z
Adelpine
34679
Separa una transcripción AFI por dialecto o país y agrega otras (elaboración propia)
6121424
wikitext
text/x-wiki
== {{lengua|en}} ==
{{pron-graf|leng=en
|pron=Received Pronunciation|fono=təˈbæk.əʊ
|2pron=General American, Standard Canadian|2fono=təˈbæk.oʊ|2audio=LL-Q1860 (eng)-Simplificationalizer-tobacco.wav|2aunota=Nueva Jersey
|3pron=California|3fono=təˈbæk.oʊ|3fone2=təˈbæk.əʊ|3fnota2=California Vowel Shift|3audio2=en-us-tobacco.ogg
|4pron=Australia|4fono=təˈbæk.əʉ|4fone2=təˈbæk.ɐʉ|4fnota2=algunos hablantes
|5pron=Nueva Zelanda|5fono=təˈbæk.ɐʉ
|ls=3}}
=== Etimología ===
{{etimología|leng=en|es|tabaco}}.<ref>{{etymonline}}</ref>
=== {{sustantivo|en}} ===
{{en.sust|gi|tobaccos|tobaccoes}}
;1: {{plm|tabaco}}.
== Referencias y notas ==
<references />
kcrkga7o2q5lwl8cf8a18la7gpavr6d
eres
0
101126
6121394
5656786
2026-07-11T13:37:28Z
Jemily1
121719
añado forma verbal en catalán
6121394
wikitext
text/x-wiki
{{desambiguación|Eres|erres|errés}}
== {{lengua|es}} ==
{{pron-graf}}
=== Forma verbal ===
;1: {{forma verbo|erar|m=subjuntivo|p=2s|t=presente}}.
{{uso}} se emplea también para el {{l|es|imperativo}} negativo: «no ''eres''».
{{relacionado|era|nota1=imperativo afirmativo}}.
;2: {{forma verbo|ser|m=indicativo|p=2s|t=presente}}.
{{ámbito}}Áreas tuteantes.
{{sinónimo|sos|soi|erís|nota=voseo|nota2=voseo chileno|nota3=voseo chileno}}.
== Referencias y notas ==
<references />
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|2s|imp|ind|pron=tu}}.
914600ycfuhyc2nsfudoh3o12euo3f3
6121395
6121394
2026-07-11T13:38:23Z
Jemily1
121719
pongo las referencias al final
6121395
wikitext
text/x-wiki
{{desambiguación|Eres|erres|errés}}
== {{lengua|es}} ==
{{pron-graf}}
=== Forma verbal ===
;1: {{forma verbo|erar|m=subjuntivo|p=2s|t=presente}}.
{{uso}} se emplea también para el {{l|es|imperativo}} negativo: «no ''eres''».
{{relacionado|era|nota1=imperativo afirmativo}}.
;2: {{forma verbo|ser|m=indicativo|p=2s|t=presente}}.
{{ámbito}}Áreas tuteantes.
{{sinónimo|sos|soi|erís|nota=voseo|nota2=voseo chileno|nota3=voseo chileno}}.
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|2s|imp|ind|pron=tu}}.
jutvughcke0o0undwafckosdlwhnd8m
6121396
6121395
2026-07-11T13:39:29Z
Jemily1
121719
pongo las referencias al final
6121396
wikitext
text/x-wiki
{{desambiguación|Eres|erres|errés}}
== {{lengua|es}} ==
{{pron-graf}}
=== Forma verbal ===
;1: {{forma verbo|erar|m=subjuntivo|p=2s|t=presente}}.
{{uso}} se emplea también para el {{l|es|imperativo}} negativo: «no ''eres''».
{{relacionado|era|nota1=imperativo afirmativo}}.
;2: {{forma verbo|ser|m=indicativo|p=2s|t=presente}}.
{{ámbito}}Áreas tuteantes.
{{sinónimo|sos|soi|erís|nota=voseo|nota2=voseo chileno|nota3=voseo chileno}}.
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|2s|imp|ind|pron=tu}}.
== Referencias y notas ==
<references />
15g9fgzz9nwaxez2vx0rf0l977b6ivf
budget
0
106260
6121388
6121380
2026-07-11T12:33:58Z
Adelpine
34679
Agrega una transcripción AFI (elaboración propia)
6121388
wikitext
text/x-wiki
== {{lengua|en}} ==
{{pron-graf|leng=en
|pron=Received Pronunciation|fono=ˈbʌd͡ʒ.ɪt
|2pron=General American, Standard Canadian|2fono=ˈbʌd͡ʒ.ɪt|2audio=en-us-budget.ogg|2aunota=no nativo, [ˈbʌ.d͡ʒɪ.t]|2fono2=ˈbʌd͡ʒ.ət
|3pron=Australia|3fono=ˈbɐd͡ʒ.ɪt|3fono2=ˈbɐd͡ʒ.ət
|4pron=Nueva Zelanda|4fono=ˈbɐd͡ʒ.ət
|ls=2
}}
=== Etimología ===
{{etimología|leng=en|enm|bogett|sig=no}}.
=== {{sustantivo|en}} ===
{{en.sust|c}}
;1: {{plm|presupuesto}}.
=== {{adjetivo|en}} ===
;2: {{plm|presupuestal}}.
;3: {{plm|económico}}
=== {{verbo transitivo|en}} ===
;4: {{plm|presupuestar}}
=== Conjugación ===
{{en.v}}
== Referencias y notas ==
<references />
hbi5bhh94gv9zn12di2trovlp7ecs0m
6121392
6121388
2026-07-11T13:14:08Z
Adelpine
34679
Corrige una transcripción AFI y agrega otras tomadas de [[en:budget]]
6121392
wikitext
text/x-wiki
== {{lengua|en}} ==
{{pron-graf|leng=en
|pron=Received Pronunciation|fono=ˈbʌd͡ʒ.ɪt
|2pron=General American, Standard Canadian|2fono=ˈbʌd͡ʒ.ɪt|2audio=en-us-budget.ogg|2aunota=no nativo, [ˈbʌ.d͡ʒɪt]|2fono2=ˈbʌd͡ʒ.ət
|3pron=Australia|3fono=ˈbɐd͡ʒ.ɪt|3fono2=ˈbɐd͡ʒ.ət
|4pron=Nueva Zelanda|4fono=ˈbɐd͡ʒ.ət
|5pron=Sur de Asia|5fono=ˈbəd͡ʒ.ɛt|5fono2=ˈbəd͡ʒ.ət
|ls=2
}}
=== Etimología ===
{{etimología|leng=en|enm|bogett|sig=no}}.
=== {{sustantivo|en}} ===
{{en.sust|c}}
;1: {{plm|presupuesto}}.
=== {{adjetivo|en}} ===
;2: {{plm|presupuestal}}.
;3: {{plm|económico}}
=== {{verbo transitivo|en}} ===
;4: {{plm|presupuestar}}
=== Conjugación ===
{{en.v}}
== Referencias y notas ==
<references />
jai7t1rnuadcpkki8kzt5z2566wao0i
Castejón
0
131219
6121390
4235350
2026-07-11T13:11:08Z
Jemily1
121719
desambiguación añadida
6121390
wikitext
text/x-wiki
{{desambiguación|Castejon}}
== {{lengua|es}} ==
{{pron-graf}}
=== Etimología ===
{{etimología}}
=== {{sustantivo propio|es}} ===
;1: {{apellido}} <!-- Francisco Morales y Castejón de Arroyo, gobernador de Chile -->
== Referencias y notas ==
<references />
o4gt2o4hkon7jwboujy5qhgrykdt57x
Castejon
0
148844
6121391
6065520
2026-07-11T13:11:41Z
Jemily1
121719
desambiguación añadida
6121391
wikitext
text/x-wiki
{{desambiguación|Castejón}}
== {{lengua|es}} ==
{{pron-graf}}
=== Etimología ===
{{etimología|eu}}
=== {{sustantivo propio|es}} ===
;1: {{apellido}}.<ref>{{Juan de Garay}}</ref>
== Referencias y notas ==
<references />
qndo304tqutox3r2t22lzq65mlggl70
seré
0
152053
6121407
6022984
2026-07-11T14:10:33Z
Jemily1
121719
creo esta forma verbal en catalán
6121407
wikitext
text/x-wiki
{{desambiguación|Sere|}}
== {{lengua|es}} ==
{{pron-graf}}
=== Forma verbal ===
;1: {{forma verbo|ser|p=1s|t=futuro|m=indicativo}}.
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|1s|fut|ind|pron=jo}}.
== Referencias y notas ==
<references />
sfd7gmjw7d9pys0cdcdfv1w7p752627
fui
0
167414
6121400
6032869
2026-07-11T13:50:15Z
Jemily1
121719
creo esta forma verbal en catalán
6121400
wikitext
text/x-wiki
== {{lengua|es}} ==
{{pron-graf}}
=== Forma verbal ===
;1: {{forma verbo|ser|p=1s|t=pret ind|m=indicativo}}.
;2: {{forma verbo|ir|yo|pret ind|ind|pronominal=s}}.
== {{lengua|ast}} ==
{{pron-graf|leng=ast}}
=== Forma verbal ===
;1: {{forma verbo|leng=ast|ser|p=1s|t=pret ind|m=indicativo}}.
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|1s|ind|ind|pron=jo}}.
== {{lengua|la}} ==
{{pron-graf|leng=la|ayuda1=fuī}}
=== Forma verbal ===
;1: {{forma verbo|leng=la|sum|1s|nopron=x|perfecto|ind|act=x}}.
== Referencias y notas ==
<references />
oau1sv4790p7tbuwcvx3qjchsuth848
serás
0
280118
6121411
5968936
2026-07-11T15:11:15Z
Jemily1
121719
añado desambiguación
6121411
wikitext
text/x-wiki
{{desambiguación|seras|seràs}}
== {{lengua|es}} ==
{{pron-graf}}
=== Forma verbal ===
;1: {{forma verbo|ser|p=2stv|t=futuro|m=indicativo}}.
== Referencias y notas ==
<references />
62e5sye1elwr42eyz8r4v8iblszufuj
serán
0
280126
6121417
5961807
2026-07-11T15:19:36Z
Jemily1
121719
desambiguación añadida
6121417
wikitext
text/x-wiki
{{desambiguación|seran}}
== {{lengua|es}} ==
{{pron-graf}}
=== Forma verbal ===
;1: {{forma verbo|ser|p=3p|t=futuro|m=indicativo}}.
== Referencias y notas ==
<references />
dw60kn1n2pqy7k9by51ziec3j7wjqhw
seria
0
790531
6121418
6022185
2026-07-11T15:22:36Z
Jemily1
121719
añado esta forma verbal en catalán
6121418
wikitext
text/x-wiki
{{desambiguación|sería|seriá}}
== {{lengua|es}} ==
{{pron-graf}}
=== Forma adjetiva ===
;1: {{forma adjetivo|serio|género=femenino|número=singular}}.
=== Forma verbal ===
;2: {{forma verbo|seriar|m=indicativo|p=3s|t=presente}}.
;3: {{forma verbo|seriar|2s|imperativo|afirmativo=s}}.
{{uso}} para el negativo se emplea el presente del {{l|es|subjuntivo}}: «no ''{{l|es|series}}''».
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|1s|cond|pron=jo}}.
;2: {{f.v|leng=ca|ser|3s|cond|pron=ell, ella, vostè}}
== Referencias y notas ==
<references />
dc79drlowvso4a3u26oqz2dhfmxkr5e
series
0
790557
6121420
6051788
2026-07-11T17:06:02Z
Jemily1
121719
añado esta forma verbal en catalán
6121420
wikitext
text/x-wiki
{{desambiguación|seriés}}
== {{lengua|es}} ==
{{pron-graf}}
=== Forma sustantiva femenina ===
;1: {{forma sustantivo plural|serie}}.
=== Forma verbal ===
;2: {{forma verbo|seriar|p=2s|t=presente|m=subjuntivo}}.
{{uso}} se emplea también para el [[imperativo]] negativo: «no ''series''».
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|2s|cond|pron=tu}}.
== Referencias y notas ==
<references />
0s82q5yrakefbhue9bbmfwfwpay3zll
serien
0
790559
6121423
4633713
2026-07-11T17:13:14Z
Jemily1
121719
añado esta forma verbal en catalán
6121423
wikitext
text/x-wiki
== {{lengua|es}} ==
{{pron-graf}}
=== Forma verbal ===
;1: {{forma verbo|seriar|3p|t=presente|m=subjuntivo}}.
;2: {{forma verbo|seriar|p=ustedes|t=imperativo}}.
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|3p|cond|pron=ells, elles, vostès}}.
== Referencias y notas ==
<references />
el5a4y9k167pcndqbu8u2nmc30x6rce
exultar
0
875971
6121428
5808923
2026-07-12T04:37:16Z
Tmagc
158167
6121428
wikitext
text/x-wiki
{{desambiguación}}
== {{lengua|es}} ==
{{pron-graf}}
=== Etimología ===
{{etimología|regresiva|exultante}}
=== {{verbo intransitivo|es}} ===
;1: Mostrar [[euforia]] o [[júbilo]].<ref name="drae">{{DRAE2001}}</ref>
{{sinónimo|regocijarse|alborozarse|entusiasmarse|gozar}}
=== Conjugación ===
{{es.v}}
=== Traducciones ===
{{trad-arriba}}
{{t|nl|i1=s|t1=jubelen|t2=juichen}}
{{trad-abajo}}
== Referencias y notas ==
<references />
4gx3asn9vrocfqc36x2hozlreccdti3
algarabía
0
971025
6121434
6120385
2026-07-12T05:49:31Z
Tmagc
158167
/* {{sustantivo femenino|es}} */
6121434
wikitext
text/x-wiki
== {{lengua|es}} ==
{{pron-graf}}
=== Etimología 1 ===
{{etimología|ar|العربية|alt=اَلْعَرَبِيَّة|transcripción=al-ʿarabiyya}} ("la [[lengua]] [[árabe]]").
==== {{sustantivo femenino|es}} ====
{{es.sust}}
;1: {{plm|ruido}} generado por un gran conjunto de personas que hablan al mismo tiempo.
{{sinónimo|barullo|griterío}}.
{{uso|coloquial}}
{{ejemplo|Una voz profunda con acento extranjero sobresalió entre la ''algarabía'' de la calle, apartándole de sus reflexiones.|título=Kengi y la magia de las palabras|editorial=Ediciones SM|páginas=101|c=libro|a=Paolo Lanzotti|fecha=1999}}
;2: {{plm|lenguaje}} o escritura [[ininteligible]].<ref name="dlc1914">{{DLC1914|48}}</ref>
{{uso|coloquial}}
;3: {{plm|lengua}} [[árabe]].<ref name="dlc1914" />
{{uso|poco usado}}
==== Traducciones ====
{{trad-arriba}}
{{trad-abajo}}
=== Etimología 2 ===
{{etimología|incierta}}.
==== {{sustantivo femenino|es}} ====
{{es.sust}}
;1 {{csem|}}: {{taxón|Parentucellia viscosa}} Planta anual silvestre, de la familia de las [[escrofulariácea]]s, de seis a ocho decímetros de altura, de tallo nudoso que produce dos vástagos opuestos, los cuales echan también sus ramos de dos en dos, con hojas lanceoladas y tomentosas, y flores amarillas. De esta planta se hacen escobas.<ref>{{DLE1925}}</ref>
== Referencias y notas ==
<references />
kkw921otm66obj206wzxgy4mjvyrk0t
exultante
0
1002592
6121429
5952631
2026-07-12T04:37:49Z
Tmagc
158167
6121429
wikitext
text/x-wiki
{{desambiguación|}}
== {{lengua|es}} ==
{{pron-graf}}
=== Etimología ===
{{etimología|la|exsultans|alt=exsultantis}}.
=== {{adjetivo|es}} ===
{{es.adj|ng}}
;1: Que muestra extrema alegría o gozo.
{{sinónimo|jubiloso|eufórico}}
=== Traducciones ===
{{trad-arriba}}
{{t|en|t1=elated}}
{{trad-abajo}}
== Referencias y notas ==
<references />
bvyx3d6mtro37e7avusxk7m3leyf7ds
lanthanum
0
1009592
6121435
6072035
2026-07-12T09:40:13Z
MSchoentgen
119096
/* Etimología */
6121435
wikitext
text/x-wiki
== {{lengua|en}} ==
{{pron-graf|leng=en|1fone1=ˈlænθənəm}}
=== Etimología ===
{{etimología|leng=en|grc|λανθάνω|tr=lanthánō}} y el sufijo {{l+|es|-um}}
=== {{sustantivo|en}} ===
;1: {{plm|lantano}}.
== Referencias y notas ==
<references />
i7ft5a9yd43jy2sgjep2m9lwdg66i22
seras
0
1015758
6121412
5126700
2026-07-11T15:12:19Z
Jemily1
121719
añado desambiguación
6121412
wikitext
text/x-wiki
{{desambiguación|serás|seràs}}
== {{lengua|fr}} ==
{{pron-graf|leng=fr|fono=sə.ʁa}}
=== Forma verbal ===
;1: {{f.v|leng=fr|être|2s|futuro|indicativo|pron=tu|glosa=ser}}
== Referencias y notas ==
<references />
6fw9qsx80jt2rjzd4382ok90fudrx7d
Módulo:flex/la
828
1059810
6121431
6110113
2026-07-12T04:50:35Z
Tmagc
158167
6121431
Scribunto
text/plain
-- FLEXIÓN DEL LATÍN
-- Adaptado desde en.wikt por Tmagc
local export = {}
local unpack = unpack or table.unpack
local insert = table.insert
local concat = table.concat
local m_table = require("Módulo:tabla")
local list_to_set = m_table.listToSet
local keys_to_list = m_table.keysToList
local insert_if_not = m_table.insertIfNot
local deep_copy = m_table.deepCopy
local contains = m_table.contains
local append = m_table.append
local merge = m_table.merge
local m_str = require("Módulo:string")
local u = m_str.char
local match = m_str.match
local sub = m_str.sub
local gsub = m_str.gsub
local gsubb = m_str.gsubb
local split = m_str.split
local gsplit = m_str.gsplit
local find = m_str.find
local m_str_avanzado = require("Módulo:string/avanzado")
local toNFD = m_str_avanzado.toNFD
local toNFC = m_str_avanzado.toNFC
local m_flex = require("Módulo:flex")
local f = m_flex.f
local f_links = m_flex.f_links
local parsear_arreglo = m_flex.parsear_arreglo
local separar_palabras = m_flex.separar_palabras
local combinar_copulativa = m_flex.combinar_copulativa
local sobreescribir_formas = m_flex.sobreescribir_formas
local desactivar_formas = m_flex.desactivar_formas
local agregar_enlaces = m_flex.agregar_enlaces
local formatear_formas = m_flex.formatear_formas
local comprobar_defectivo = m_flex.comprobar_defectivo
local renderizar_tabla = m_flex.renderizar_tabla
local renderizar_encabezado = m_flex.renderizar_encabezado
local COLOR_H = m_flex.COLOR_H
local COLOR_NP = m_flex.COLOR_NP
local COLOR_IND = m_flex.COLOR_IND
local COLOR_COND = m_flex.COLOR_COND
local COLOR_SUBJ = m_flex.COLOR_SUBJ
local COLOR_IMPER = m_flex.COLOR_IMPER
local MACRON = u(0x304)
local BREVE = u(0x306)
local DIAER = u(0x308)
local DBREVE = u(0x361)
local ACCENT = "[" .. MACRON .. BREVE .. DIAER .. DBREVE .. "]"
local VOWEL = "[aæeioœuyAÆEIOŒUY]"
local cons_to_vowel = {
["j"] = "i", ["J"] = "I",
["v"] = "u", ["V"] = "U",
}
local function normalizar_enlace(x)
x = toNFD(x)
x = gsub(x, ACCENT, "")
return toNFC(x)
end
local function join(a, b)
a, b = toNFD(a), toNFD(b)
-- If the first part ends in "j" or "v", convert it to "i" or "u" unless
-- the second part begins with a vowel.
if not match(b, "^" .. VOWEL) then
a = gsub(a, "[jvJV]$", cons_to_vowel)
end
return toNFC(a..b)
end
local function add_form(decl, slot, stem, suf)
if type(slot) == "string" then
slot = {slot}
end
for _,slt in ipairs(slot) do
if type(decl[slt]) == "nil" or decl[slt] == "" then
decl[slt] = {}
elseif type(decl[slt]) == "string" then
decl[slt] = {decl[slt]}
end
insert_if_not(decl[slt], join(stem, suf))
end
end
local function remove_forms(decl, forms)
for form,_ in pairs(decl) do
for _,rx in ipairs(forms) do
if form:find(rx) then
forms[form] = {}
break
end
end
end
end
local function merge_forms(forms, forms2, keys)
keys = keys or forms2
for key,arr in pairs(keys) do
if not forms[key] then
forms[key] = {}
end
if type(forms2[key]) == "string" then
insert_if_not(forms[key], forms2[key])
elseif type(forms2[key]) == "table" then
for _,a in ipairs(forms2[key]) do
insert_if_not(forms[key], a)
end
end
end
end
local noun_decl = {}
noun_decl["0"] = function(data, args)
local forms = data.forms
local stem = args[1]
insert_if_not(data.title, "indeclinable")
insert_if_not(data.categories, "LA:Sustantivos indeclinables")
forms["nom_sg"] = stem
forms["gen_sg"] = stem
forms["dat_sg"] = stem
forms["acc_sg"] = stem
forms["abl_sg"] = stem
forms["voc_sg"] = stem
forms["nom_pl"] = stem
forms["gen_pl"] = stem
forms["dat_pl"] = stem
forms["acc_pl"] = stem
forms["abl_pl"] = stem
forms["voc_pl"] = stem
-- with locative
if data.loc then
forms["loc_sg"] = stem
forms["loc_pl"] = stem
end
end
local function alt_gen_pl_in_um(stem, forms, types, subtitles, i_stem)
if types.genplum then
add_form(forms, "gen_pl", stem, (i_stem and "i" or "") .. "um")
elseif types.not_genplum then
-- FIXME: not a contraction.
-- insert_if_not(subtitles, "uncontracted genitive plural")
end
end
noun_decl["1"] = function(data, args)
local forms, types, loc, subtitles = data.forms, data.types, data.loc, data.subtitles
local stem = args[1]
-- normal 1st
local nom_sg = "a"
local gen_loc_sg = "ae"
local dat_sg = "ae"
local acc_sg = "am"
local abl_sg = "ā"
local voc_sg = "a"
local nom_voc_pl = "ae"
local gen_pl = "ārum"
local dat_abl_loc_pl = "īs"
local acc_pl = "ās"
insert_if_not(data.title, "primera declinación")
insert_if_not(data.categories, "LA:Sustantivos de la primera declinación")
-- ām
if types.am then
nom_sg = "ām"
acc_sg = "ām"
abl_sg = {"ām", "ā"}
voc_sg = "ām"
-- all Greek
elseif types.Greek then
insert_if_not(data.title, "griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
--Greek Ma
if types.Ma then
nom_sg = "ās"
acc_sg = "ān"
voc_sg = "ā"
-- Greek Me
elseif types.Me then
nom_sg = "ēs"
acc_sg = "ēn"
abl_sg = "ē"
voc_sg = "ē"
-- Greek
else
nom_sg = "ē"
gen_loc_sg = "ēs"
acc_sg = "ēn"
abl_sg = "ē"
voc_sg = "ē"
end
end
-- ābus
if types.abus then
dat_abl_loc_pl = "ābus"
end
add_form(forms, "nom_sg", stem, nom_sg)
add_form(forms, "gen_sg", stem, gen_loc_sg)
add_form(forms, "dat_sg", stem, dat_sg)
add_form(forms, "acc_sg", stem, acc_sg)
add_form(forms, "abl_sg", stem, abl_sg)
add_form(forms, "voc_sg", stem, voc_sg)
add_form(forms, {"nom_pl", "voc_pl"}, stem, nom_voc_pl)
add_form(forms, "gen_pl", stem, gen_pl)
add_form(forms, {"dat_pl", "abl_pl"}, stem, dat_abl_loc_pl)
add_form(forms, "acc_pl", stem, acc_pl)
-- with locative
if loc then
add_form(forms, "loc_sg", stem, gen_loc_sg)
add_form(forms, "loc_pl", stem, dat_abl_loc_pl)
end
end
noun_decl["2"] = function(data, args)
local forms, types, subtitles, notes = data.forms, data.types, data.subtitles, data.notes
local stem1, stem2 = args[1], args[2]
insert_if_not(data.title, "segunda declinación")
insert_if_not(data.categories, "LA:Sustantivos de la segunda declinación")
-- normal 2nd
forms["nom_sg"] = stem1 .. "us"
forms["gen_sg"] = stem1 .. "ī"
forms["dat_sg"] = stem1 .. "ō"
forms["acc_sg"] = stem1 .. "um"
forms["abl_sg"] = stem1 .. "ō"
forms["voc_sg"] = stem1 .. "e"
forms["nom_pl"] = stem1 .. "ī"
forms["gen_pl"] = stem1 .. "ōrum"
forms["dat_pl"] = stem1 .. "īs"
forms["acc_pl"] = stem1 .. "ōs"
forms["abl_pl"] = stem1 .. "īs"
forms["voc_pl"] = stem1 .. "ī"
-- all neuter
if types.N then
forms["nom_sg"] = stem1 .. "um"
forms["voc_sg"] = stem1 .. "um"
forms["nom_pl"] = stem1 .. "a"
forms["acc_pl"] = stem1 .. "a"
forms["voc_pl"] = stem1 .. "a"
-- neuter ium
if types.ium then
forms["nom_sg"] = stem1 .. "ium"
forms["gen_sg"] = {stem1 .. "iī", stem1 .. "ī{†}"}
forms["dat_sg"] = stem1 .. "iō"
forms["acc_sg"] = stem1 .. "ium"
forms["abl_sg"] = stem1 .. "iō"
forms["voc_sg"] = stem1 .. "ium"
forms["nom_pl"] = stem1 .. "ia"
forms["gen_pl"] = stem1 .. "iōrum"
forms["dat_pl"] = stem1 .. "iīs"
forms["acc_pl"] = stem1 .. "ia"
forms["abl_pl"] = stem1 .. "iīs"
forms["voc_pl"] = stem1 .. "ia"
-- neuter us, plural a
elseif types.a then
forms["nom_sg"] = stem1 .. "us"
forms["acc_sg"] = stem1 .. "us"
forms["voc_sg"] = stem1 .. "us"
forms["nom_pl"] = stem1 .. "a"
forms["acc_pl"] = stem1 .. "a"
forms["voc_pl"] = stem1 .. "a"
-- -vom (aevom, etc.)
elseif types.vom then
forms["nom_sg"] = stem1 .. "om"
forms["acc_sg"] = stem1 .. "om"
forms["voc_sg"] = stem1 .. "om"
-- neuter Greek in -os (cētos)
elseif types.Greek and types.us then
insert_if_not(data.title, "griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = stem1 .. "os"
forms["acc_sg"] = stem1 .. "os"
forms["voc_sg"] = stem1 .. "os"
forms["nom_pl"] = stem1 .. "ē"
forms["gen_pl"] = stem1 .. "ōn"
forms["acc_pl"] = stem1 .. "ē"
forms["voc_pl"] = stem1 .. "ē"
-- neuter Greek
elseif types.Greek then
insert_if_not(data.title, "griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = stem1 .. "on"
forms["acc_sg"] = stem1 .. "on"
forms["voc_sg"] = stem1 .. "on"
-- neuter us
elseif types.us then
forms["nom_sg"] = stem1 .. "us"
forms["acc_sg"] = stem1 .. "us"
forms["voc_sg"] = stem1 .. "us"
forms["nom_pl"] = stem1 .. "ī"
forms["acc_pl"] = stem1 .. "ōs"
forms["voc_pl"] = stem1 .. "ī"
end
-- er
elseif types.er then
forms["nom_sg"] = stem1
forms["gen_sg"] = stem2 .. "ī"
forms["dat_sg"] = stem2 .. "ō"
forms["acc_sg"] = stem2 .. "um"
forms["abl_sg"] = stem2 .. "ō"
forms["voc_sg"] = stem1
forms["nom_pl"] = stem2 .. "ī"
forms["gen_pl"] = stem2 .. "ōrum"
forms["dat_pl"] = stem2 .. "īs"
forms["acc_pl"] = stem2 .. "ōs"
forms["abl_pl"] = stem2 .. "īs"
forms["voc_pl"] = stem2 .. "ī"
-- ius
elseif types.ius then
forms["nom_sg"] = stem1 .. "ius"
forms["gen_sg"] = {stem1 .. "iī", stem1 .. "ī{†}"}
forms["dat_sg"] = stem1 .. "iō"
forms["acc_sg"] = stem1 .. "ium"
forms["abl_sg"] = stem1 .. "iō"
if types.voci then
-- Only for proper names and fīlius, genius
forms["voc_sg"] = stem1 .. "ī"
else
forms["voc_sg"] = stem1 .. "ie"
end
forms["nom_pl"] = stem1 .. "iī"
forms["gen_pl"] = stem1 .. "iōrum"
forms["dat_pl"] = stem1 .. "iīs"
forms["acc_pl"] = stem1 .. "iōs"
forms["abl_pl"] = stem1 .. "iīs"
forms["voc_pl"] = stem1 .. "iī"
-- -vos (servos, etc.)
elseif types.vos then
forms["nom_sg"] = stem1 .. "os"
forms["acc_sg"] = stem1 .. "om"
-- Greek
elseif types.Greek then
insert_if_not(data.title, "griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = stem1 .. "os"
forms["acc_sg"] = stem1 .. "on"
if data.num == "pl" then
forms["nom_pl"] = stem1 .. "oe"
forms["voc_pl"] = stem1 .. "oe"
else
forms["nom_pl"] = {stem1 .. "ī", stem1 .. "oe"}
forms["voc_pl"] = {stem1 .. "ī", stem1 .. "oe"}
end
elseif types.not_Greek then
insert_if_not(data.title, "no griego")
end
-- with -um genitive plural
alt_gen_pl_in_um(stem2, forms, types, subtitles, types.ius or types.ium)
-- with locative
if data.loc then
if types.ius or types.ium then
forms["loc_sg"] = stem2 .. "iī"
forms["loc_pl"] = stem2 .. "iīs"
else
forms["loc_sg"] = stem2 .. "ī"
forms["loc_pl"] = stem2 .. "īs"
end
end
end
local acc_sg_i_stem_subtypes = {
acc_im = {
-- amussis, basis, buris, cucumis, gummis, mephitis, paraphrasis, poesis, ravis, sitis, tussis, (vis) [abl -ī];
-- cannabis, senapis, sinapis [abl -e, -ī]
acc_sg = {"im"},
title = {"accusative singular in ''-im''"},
},
acc_im_in = {
-- cities, rivers, gods, e.g. Bilbilis, Syrtis, Tiberis, Anubis, Osiris [abl -ī];
-- Baetis, Tigris [acc -e, -ī]
acc_sg = {"im", "in"},
title = {"accusative singular in ''-im'' or ''-in''"},
},
acc_im_in_em = {
-- e.g. tigris, river Līris
acc_sg = {"im", "in", "em"},
title = {"accusative singular in ''-im'', ''-in'' or ''-em''"},
},
acc_im_em = {
acc_sg = {"im", "em"},
title = {"accusative singular in ''-im'' or ''-em''"},
},
acc_im_occ_em = {
-- febris, pelvis, puppis, restis, securis, turris [abl -ī, -e]
acc_sg = {"im", "em"},
title = {"accusative singular in ''-im'' or occasionally ''-em''"},
},
acc_em_im = {
-- aqualis, clavis, lens, navis [abl -e, -ī];
-- cutis, restis [abl -e]
acc_sg = {"em", "im"},
title = {"accusative singular in ''-em'' or ''-im''"},
},
}
local abl_sg_i_stem_subtypes = {
abl_i = {
-- amussis, basis, buris, cucumis, gummis, mephitis, paraphrasis, poesis, ravis, sitis, tussis, (vis) [acc -im];
-- cities, rivers, gods, e.g. Bilbilis, Syrtis, Tiberis, Anubis, Osiris [acc -im or -in];
-- canalis "water pipe", months in -is or -er, nouns originally i-stem adjectives such as aedilis, affinis, bipennis, familiaris, sodalis, volucris, etc. [acc -em]
abl_sg = {"ī"},
title = {"ablative singular in ''-ī''"},
},
abl_i_e = {
-- febris, pelvis, puppis, restis, securis, turris [acc -im, -em]
abl_sg = {"ī", "e"},
title = {"ablative singular in ''-ī'' or ''-e''"},
},
abl_e_i = {
-- cannabis, senapis, sinapis [acc -im];
-- Baetis, Tigris [acc -im, -in];
-- aqualis, clavis, lens, navis [acc -em, -im];
-- finis, mugilis, occiput, pugil, rus, supellex, vectis [acc -em]
abl_sg = {"e", "ī"},
title = {"ablative singular in ''-e'' or ''-ī''"},
},
abl_e_occ_i = {
-- amnis, anguis, avis, civis, classis, fustis, ignis, imber, orbis, pars, postis, sors, unguis, vesper [acc -em]
abl_sg = {"e", "ī"},
title = {"ablative singular in ''-e'' or occasionally ''-ī''"},
},
}
local function extract_stem(form, ending)
local base = match(form, "^(.*)" .. ending .. "$")
if not base then
error("Form " .. form .. " should end in -" .. ending)
end
return base
end
local function count_vowels(stem)
return select(2, toNFD(stem):gsub("[aeiouyAEIOUY]", ""))
end
noun_decl["3"] = function(data, args)
local forms, types, subtitles, notes = data.forms, data.types, data.subtitles, data.notes
local stem1, stem2 = args[1], args[2]
-- local function non_i_stem_type()
-- return (count_vowels(stem1) > count_vowels(stem2) and "parisyllabic" or "imparisyllabic") .. " non-i-stem"
-- end
insert_if_not(data.title, "tercera declinación")
insert_if_not(data.categories, "LA:Sustantivos de la tercera declinación")
--normal 3rd
forms["nom_sg"] = stem1
forms["gen_sg"] = stem2 .. "is"
forms["dat_sg"] = stem2 .. "ī"
forms["acc_sg"] = stem2 .. "em"
forms["abl_sg"] = stem2 .. "e"
forms["voc_sg"] = stem1
forms["nom_pl"] = stem2 .. "ēs"
forms["gen_pl"] = stem2 .. "um"
forms["dat_pl"] = stem2 .. "ibus"
forms["acc_pl"] = stem2 .. "ēs"
forms["abl_pl"] = stem2 .. "ibus"
forms["voc_pl"] = stem2 .. "ēs"
local acc_sg_i_stem_subtype = false
local not_acc_sg_i_stem_subtype = false
for subtype, _ in pairs(types) do
if acc_sg_i_stem_subtypes[subtype] then
acc_sg_i_stem_subtype = true
break
end
end
for acc_sg_subtype, _ in pairs(acc_sg_i_stem_subtypes) do
if types["not_" .. acc_sg_subtype] then
not_acc_sg_i_stem_subtype = true
break
end
end
local abl_sg_i_stem_subtype = false
local not_abl_sg_i_stem_subtype = false
for subtype, _ in pairs(types) do
if abl_sg_i_stem_subtypes[subtype] then
abl_sg_i_stem_subtype = true
break
end
end
for abl_sg_subtype, _ in pairs(abl_sg_i_stem_subtypes) do
if types["not_" .. abl_sg_subtype] then
not_abl_sg_i_stem_subtype = true
break
end
end
-- all Greek
if types.Greek then
insert_if_not(data.title, "griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
-- Greek er
if types.er then
stem1 = extract_stem(stem1, "ēr")
forms["nom_sg"] = stem1 .. "ēr"
forms["gen_sg"] = stem1 .. "eris"
forms["dat_sg"] = stem1 .. "erī"
forms["acc_sg"] = {stem1 .. "era", stem1 .. "erem"}
forms["abl_sg"] = stem1 .. "ere"
forms["voc_sg"] = stem1 .. "ēr"
forms["nom_pl"] = stem1 .. "erēs"
forms["gen_pl"] = stem1 .. "erum"
forms["dat_pl"] = stem1 .. "eribus"
forms["acc_pl"] = stem1 .. "erēs"
forms["abl_pl"] = stem1 .. "eribus"
forms["voc_pl"] = stem1 .. "erēs"
-- Greek on
elseif types.on then
stem1 = extract_stem(stem1, "ōn")
forms["nom_sg"] = stem1 .. "ōn"
forms["gen_sg"] = {stem1 .. "ontis", stem1 .. "ontos"}
forms["dat_sg"] = stem1 .. "ontī"
forms["acc_sg"] = stem1 .. "onta"
forms["abl_sg"] = stem1 .. "onte"
forms["voc_sg"] = stem1 .. "ōn"
forms["nom_pl"] = stem1 .. "ontēs"
forms["gen_pl"] = {stem1 .. "ontum", stem1 .. "ontium"}
forms["dat_pl"] = stem1 .. "ontibus"
forms["acc_pl"] = {stem1 .. "ontēs", stem1 .. "ontās"}
forms["abl_pl"] = stem1 .. "ontibus"
forms["voc_pl"] = stem1 .. "ontēs"
-- Greek i-stem
elseif types.I then
forms["gen_sg"] = {stem2 .. "is", stem2 .. "eōs", stem2 .. "ios"}
forms["acc_sg"] = {stem2 .. "im", stem2 .. "in", stem2 .. "em{MED}"}
forms["abl_sg"] = {stem2 .. "ī", stem2 .. "e{MED}"}
forms["voc_sg"] = {stem2 .. "is", stem2 .. "i"}
forms["nom_pl"] = {stem2 .. "ēs", stem2 .. "eis"}
forms["gen_pl"] = {stem2 .. "ium", stem2 .. "eōn"}
forms["acc_pl"] = {stem2 .. "ēs", stem2 .. "eis"}
forms["voc_pl"] = {stem2 .. "ēs", stem2 .. "eis"}
if types.poetic_esi then
forms["dat_pl"] = {stem2 .. "ibus", stem2 .. "esi{L}"}
forms["abl_pl"] = {stem2 .. "ibus", stem2 .. "esi{L}"}
end
-- normal Greek
else
forms["gen_sg"] = stem2 .. "os"
if match(toNFD(stem2), "[yY]" .. ACCENT .. "*$") then
forms["acc_sg"] = stem2 .. "n"
else
forms["acc_sg"] = stem2 .. "a"
end
forms["nom_pl"] = stem2 .. "es"
forms["acc_pl"] = stem2 .. "as"
forms["voc_pl"] = stem2 .. "es"
if match(toNFD(stem1), "[iyIY]" .. ACCENT .. "*s$") then
-- Per Hiley, words in -is and -ys have a poetic vocative
-- without the -s, but otherwise the vocative is the same
-- as the nominative.
forms["voc_sg"] = {stem1, (stem1:gsub("s$", "")).."{L}"}
end
end
elseif types.not_Greek then
insert_if_not(data.title, "no griego")
end
-- polis
if types.polis then
stem1 = extract_stem(stem1, "polis")
insert_if_not(data.title, "parcialmente griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = stem1 .. "polis"
forms["gen_sg"] = stem1 .. "polis"
forms["dat_sg"] = stem1 .. "polī"
forms["acc_sg"] = {stem1 .. "polim", stem1 .. "polin"}
forms["abl_sg"] = stem1 .. "polī"
forms["voc_sg"] = {stem1 .. "polis", stem1 .. "polī"}
end
-- all neuter
if types.N then
forms["acc_sg"] = stem1
-- neuter I stem
if types.I then
-- pure variety
if types.pure then
forms["abl_sg"] = stem2 .. "ī"
forms["nom_pl"] = stem2 .. "ia"
forms["gen_pl"] = stem2 .. "ium"
forms["acc_pl"] = stem2 .. "ia"
forms["voc_pl"] = stem2 .. "ia"
-- non-pure variety (rare)
else
forms["nom_pl"] = stem2 .. "a"
forms["gen_pl"] = {stem2 .. "ium", stem2 .. "um"}
forms["acc_pl"] = stem2 .. "a"
forms["voc_pl"] = stem2 .. "a"
end
-- normal neuter
else
forms["nom_pl"] = stem2 .. "a"
forms["acc_pl"] = stem2 .. "a"
forms["voc_pl"] = stem2 .. "a"
end
-- I stem
elseif types.I or acc_sg_i_stem_subtype or abl_sg_i_stem_subtype then
forms["gen_pl"] = stem2 .. "ium"
-- Per Allen and Greenough, Hiley and others, the acc_pl in -īs
-- applied originally to all i-stem nouns, and was current as an
-- alternative form up through Caesar.
forms["acc_pl"] = {stem2 .. "ēs", stem2 .. "īs"}
-- pure variety
if types.pure then
forms["acc_sg"] = stem2 .. "im"
forms["abl_sg"] = stem2 .. "ī"
forms["nom_pl"] = stem2 .. "īs"
forms["acc_pl"] = stem2 .. "īs"
forms["voc_pl"] = stem2 .. "īs"
end
local num = data.num
for subtype, _ in pairs(types) do
local acc_sg_i_stem_props = acc_sg_i_stem_subtypes[subtype]
if acc_sg_i_stem_props then
forms["acc_sg"] = {}
for _, ending in ipairs(acc_sg_i_stem_props.acc_sg) do
insert_if_not(forms["acc_sg"], stem2 .. ending)
end
-- if num ~= "pl" then
-- for _, t in ipairs(acc_sg_i_stem_props.title) do
-- insert_if_not(subtitles, t)
-- end
-- end
break
end
end
-- FIXME: needs to be done for neuter nouns as well.
for subtype, _ in pairs(types) do
local abl_sg_i_stem_props = abl_sg_i_stem_subtypes[subtype]
if abl_sg_i_stem_props then
forms["abl_sg"] = {}
for _, ending in ipairs(abl_sg_i_stem_props.abl_sg) do
insert_if_not(forms["abl_sg"], stem2 .. ending)
end
-- if num ~= "pl" then
-- for _, t in ipairs(abl_sg_i_stem_props.title) do
-- insert_if_not(subtitles, t)
-- end
-- end
break
end
end
end
-- with locative
if data.loc then
-- As far as I can tell, in general both dative singular and
-- ablative singular could be used for the third-declension locative,
-- with different time periods preferring different forms.
-- http://dcc.dickinson.edu/grammar/latin/3rd-declension-locative-case
-- mentions rūrī along with either Carthāginī or Carthāgine.
-- Wikipedia in https://en.wikipedia.org/wiki/Locative_case#Latin
-- says this:
--
-- In archaic times, the locative singular of third declension nouns
-- was still interchangeable between ablative and dative forms, but in
-- the Augustan Period the use of the ablative form became fixed.
-- Therefore, both forms "rūrī" and "rūre" may be encountered.
--
-- Lewis and Short confirm this.
local loc_sg = forms["dat_sg"]
if type(loc_sg) == "table" then
loc_sg = deep_copy(loc_sg)
else
loc_sg = {loc_sg}
end
local abl_sg = forms["abl_sg"]
if type(abl_sg) == "table" then
for _, form in ipairs(abl_sg) do
insert_if_not(loc_sg, deep_copy(form))
end
else
insert_if_not(loc_sg, abl_sg)
end
forms["loc_sg"] = loc_sg
forms["loc_pl"] = deep_copy(forms["abl_pl"])
--The following is what we used to have, but I simply cannot believe it.
--if types.Greek and not types.s then
-- forms["loc_pl"] = stem2 .. "ēs"
--end
end
end
noun_decl["4"] = function(data, args)
local forms, types, subtitles, notes = data.forms, data.types, data.subtitles, data.notes
local stem = args[1]
insert_if_not(data.title, "cuarta declinación")
insert_if_not(data.categories, "LA:Sustantivos de la cuarta declinación")
-- normal 4th
forms["nom_sg"] = stem .. "us"
forms["gen_sg"] = stem .. "ūs"
forms["dat_sg"] = stem .. "uī"
forms["acc_sg"] = stem .. "um"
forms["abl_sg"] = stem .. "ū"
forms["voc_sg"] = stem .. "us"
forms["nom_pl"] = stem .. "ūs"
forms["gen_pl"] = stem .. "uum"
forms["dat_pl"] = stem .. "ibus"
forms["acc_pl"] = stem .. "ūs"
forms["abl_pl"] = stem .. "ibus"
forms["voc_pl"] = stem .. "ūs"
if types.echo then
for slot in pairs(forms) do
if slot ~= "gen_sg" then
forms[slot] = stem .. "ō"
end
end
add_form(forms, "acc_sg", stem, "ōn")
elseif types.Callisto then
for slot in pairs(forms) do
if slot ~= "gen_sg" then
forms[slot] = stem .. "ō"
end
end
end
-- neuter
if types.N then
forms["nom_sg"] = stem .. "ū̆{?}"
forms["gen_sg"] = {stem .. "ūs{C}", stem .. "ū{S}"}
forms["dat_sg"] = {stem .. "uī{C}", stem .. "ū{S}"}
forms["acc_sg"] = stem .. "ū̆{?}"
forms["voc_sg"] = stem .. "ū̆{?}"
forms["nom_pl"] = stem .. "ua"
forms["acc_pl"] = stem .. "ua"
forms["voc_pl"] = stem .. "ua"
end
-- ubus
if types.ubus then
forms["dat_pl"] = stem .. "ubus"
forms["abl_pl"] = stem .. "ubus"
end
-- with locative
if data.loc then
forms["loc_sg"] = forms["abl_sg"]
forms["loc_pl"] = forms["abl_pl"]
end
end
noun_decl["5"] = function(data, args)
local forms, types = data.forms, data.types
local stem = args[1]
insert_if_not(data.title, "quinta declinación")
insert_if_not(data.categories, "LA:Sustantivos de la quinta declinación")
-- ies
if types.i then
stem = stem .. "i"
end
forms["nom_sg"] = stem .. "ēs"
forms["gen_sg"] = stem .. "eī"
forms["dat_sg"] = stem .. "eī"
forms["acc_sg"] = stem .. "em"
forms["abl_sg"] = stem .. "ē"
forms["voc_sg"] = stem .. "ēs"
forms["nom_pl"] = stem .. "ēs"
forms["gen_pl"] = stem .. "ērum"
forms["dat_pl"] = stem .. "ēbus"
forms["acc_pl"] = stem .. "ēs"
forms["abl_pl"] = stem .. "ēbus"
forms["voc_pl"] = stem .. "ēs"
-- ies
if types.i then
forms["gen_sg"] = stem .. "ēī"
forms["dat_sg"] = stem .. "ēī"
end
--with locative
if data.loc then
forms["loc_sg"] = stem .. "ē"
forms["loc_pl"] = stem .. "ēbus"
end
end
noun_decl["sgpl"] = function(data, args)
local forms = data.forms
local stem1, stem2 = args[1], args[2]
insert_if_not(data.title, "indeclinable")
insert_if_not(data.categories, "LA:Sustantivos indeclinables")
forms["nom_sg"] = stem1
forms["gen_sg"] = stem1
forms["dat_sg"] = stem1
forms["acc_sg"] = stem1
forms["abl_sg"] = stem1
forms["voc_sg"] = stem1
forms["nom_pl"] = stem2
forms["gen_pl"] = stem2
forms["dat_pl"] = stem2
forms["acc_pl"] = stem2
forms["abl_pl"] = stem2
forms["voc_pl"] = stem2
-- with locative
if data.loc then
forms["loc_sg"] = stem1
forms["loc_pl"] = stem2
end
end
noun_decl["indecl"] = function(data, args)
local forms = data.forms
local stem = args[1]
insert_if_not(data.title, "indeclinable")
insert_if_not(data.categories, "LA:Sustantivos indeclinables")
forms["nom_sg"] = stem
forms["gen_sg"] = {}
forms["dat_sg"] = {}
forms["acc_sg"] = stem
forms["abl_sg"] = {}
forms["voc_sg"] = {}
forms["nom_pl"] = {}
forms["gen_pl"] = {}
forms["dat_pl"] = {}
forms["acc_pl"] = {}
forms["abl_pl"] = {}
forms["voc_pl"] = {}
-- with locative (for multiword terms)
if data.loc then
forms["loc_sg"] = {}
forms["loc_pl"] = {}
end
data.num = "sg"
end
noun_decl["irreg"] = function(data, args)
local forms, subtitles, notes = data.forms, data.subtitles, data.notes
local stem = args[1]
insert_if_not(data.title, "irregular")
insert_if_not(data.categories, "LA:Sustantivos irregulares")
forms["nom_sg"] = {}
forms["gen_sg"] = {}
forms["dat_sg"] = {}
forms["acc_sg"] = {}
forms["abl_sg"] = {}
forms["voc_sg"] = {}
forms["nom_pl"] = {}
forms["gen_pl"] = {}
forms["dat_pl"] = {}
forms["acc_pl"] = {}
forms["abl_pl"] = {}
forms["voc_pl"] = {}
if stem == "bōs" then
data.decl = "3"
local stem1, stem2 = "bōs", "bov"
noun_decl["3"](data, {stem1, stem2})
add_form(forms, "abl_sg", stem2, "īd{†}")
add_form(forms, "gen_pl", "bo", "um")
add_form(forms, "gen_pl", stem2, "erum")
add_form(forms, "dat_pl", "", "bōbus")
add_form(forms, "dat_pl", "", "būbus")
add_form(forms, "abl_pl", "", "bōbus")
add_form(forms, "abl_pl", "", "būbus")
elseif stem:match("^[dD]eus$") then
data.decl = "2"
local dD = stem:sub(1, 1)
forms["nom_sg"] = dD .. "eus"
forms["gen_sg"] = dD .. "eī"
forms["dat_sg"] = dD .. "eō"
forms["acc_sg"] = dD .. "eum"
forms["abl_sg"] = dD .. "eō"
forms["voc_sg"] = {dD .. "eus", dD .. "ee"}
if stem == "deus" then
forms["nom_pl"] = {"dī", "diī", "deī"}
forms["gen_pl"] = {"deōrum", "deum"}
forms["dat_pl"] = {"dīs", "diīs", "deīs"}
forms["acc_pl"] = "deōs"
forms["abl_pl"] = {"dīs", "diīs", "deīs"}
forms["voc_pl"] = {"dī", "diī", "deī"}
end
elseif stem == "domus" then
data.decl = "4,2"
insert_if_not(data.title, "cuarta/segunda declinación")
forms["nom_sg"] = "domus"
forms["gen_sg"] = {"domūs", "domī"}
forms["dat_sg"] = {"domuī", "domō", "domū"}
forms["acc_sg"] = "domum"
forms["abl_sg"] = {"domū", "domō"}
forms["voc_sg"] = "domus"
forms["loc_sg"] = "domī"
forms["nom_pl"] = "domūs"
forms["gen_pl"] = {"domuum", "domōrum"}
forms["dat_pl"] = "domibus"
forms["acc_pl"] = {"domūs", "domōs"}
forms["abl_pl"] = "domibus"
forms["voc_pl"] = "domūs"
forms["loc_pl"] = {}
data.loc = true
elseif match(stem, "^[IÏJ]ēs[uū]" .. BREVE .. "?s$") then
local ij = sub(stem, 1, 1)
local uu = match(stem, "[uū]" .. BREVE .. "?")
forms["nom_sg"] = stem
forms["gen_sg"] = ij .. "ēsū"
forms["dat_sg"] = ij .. "ēsū"
forms["acc_sg"] = ij .. "ēs" .. uu .. "m"
forms["abl_sg"] = ij .. "ēsū"
forms["voc_sg"] = ij .. "ēsū"
data.num = "sg"
elseif stem == "Mōsēs" or stem == "Moesēs" or match(stem, "^M[oō]" .. BREVE .. "?[īȳ]sēs$") then
local mos = sub(stem, 1, -3)
forms["nom_sg"] = stem
forms["gen_sg"] = {mos .. "ī", mos .. "ēī", mos .. "is", mos .. "ēn", mos .. "eōs"}
forms["dat_sg"] = mos .. "ī"
forms["acc_sg"] = {mos .. "ēn", mos .. "em"}
forms["abl_sg"] = {mos .. "e", mos .. "ēn", mos .. "ī"}
forms["voc_sg"] = {mos .. "ēs", mos .. "ē"}
data.num = "sg"
elseif stem:match("^[ij]ūgerum$") then
data.decl = "2,3"
local ij = stem:sub(1, 1)
insert_if_not(data.title, "segunda/tercera declinación híbrido")
forms["nom_sg"] = ij .. "ūgerum"
forms["gen_sg"] = ij .. "ūgerī"
forms["dat_sg"] = ij .. "ūgerō"
forms["acc_sg"] = ij .. "ūgerum"
forms["abl_sg"] = ij .. "ūgerō"
forms["voc_sg"] = ij .. "ūgerum"
forms["nom_pl"] = ij .. "ūgera"
forms["gen_pl"] = ij .. "ūgerum"
forms["dat_pl"] = ij .. "ūgeribus"
forms["acc_pl"] = ij .. "ūgera"
forms["abl_pl"] = {ij .. "ūgeribus", ij .. "ūgerīs{†}"}
forms["voc_pl"] = ij .. "ūgera"
elseif stem == "sūs" then
data.decl = "3"
forms["nom_sg"] = "sūs"
forms["gen_sg"] = "suis"
forms["dat_sg"] = "suī"
forms["acc_sg"] = "suem"
forms["abl_sg"] = "sue"
forms["voc_sg"] = "sūs"
forms["nom_pl"] = "suēs"
forms["gen_pl"] = "suum"
forms["dat_pl"] = {"suibus", "sūbus", "subus"}
forms["acc_pl"] = "suēs"
forms["abl_pl"] = {"suibus", "sūbus", "subus"}
forms["voc_pl"] = "suēs"
elseif stem == "ēthos" then
data.decl = "3"
insert_if_not(data.title, "tercera declinación, griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = "ēthos"
forms["gen_sg"] = "ētheos"
forms["acc_sg"] = "ēthos"
forms["voc_sg"] = "ēthos"
forms["nom_pl"] = {"ēthea", "ēthē"}
forms["dat_pl"] = {"ēthesi", "ēthesin"}
forms["acc_pl"] = {"ēthea", "ēthē"}
forms["abl_pl"] = {"ēthesi", "ēthesin"}
forms["voc_pl"] = {"ēthea", "ēthē"}
elseif stem == "Athōs" then
data.decl = "2"
insert_if_not(data.title, "segunda declinación, griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = "Athōs"
forms["gen_sg"] = "Athō"
forms["dat_sg"] = "Athō"
forms["acc_sg"] = {"Athō", "Athōn"}
forms["abl_sg"] = "Athō"
forms["voc_sg"] = "Athōs"
data.num = "sg"
elseif stem:match("^[uv]ēnum$") then
data.decl = "4,2"
local uv = stem:sub(1, 1)
insert_if_not(data.title, "cuarta/segunda declinación, defectivo")
forms["dat_sg"] = {uv .. "ēnuī", uv .. "ēnō"}
forms["acc_sg"] = uv .. "ēnum"
data.num = "sg"
elseif stem:match("^[uv]īs$") then
data.decl = "3"
local uv = stem:sub(1, 1)
insert_if_not(data.title, "defectivo")
forms["nom_sg"] = uv .. "īs"
forms["gen_sg"] = uv .. "īs"
forms["dat_sg"] = uv .. "ī"
forms["acc_sg"] = uv .. "im"
forms["abl_sg"] = uv .. "ī"
forms["voc_sg"] = uv .. "īs"
forms["nom_pl"] = uv .. "īrēs"
forms["gen_pl"] = uv .. "īrium"
forms["dat_pl"] = uv .. "īribus"
forms["acc_pl"] = {uv .. "īrēs", uv .. "īrīs"}
forms["abl_pl"] = uv .. "īribus"
forms["voc_pl"] = uv .. "īrēs"
else
error("Stem " .. stem .. " not recognized.")
end
end
local adj_decl = {}
adj_decl["0+"] = function(data, args)
local forms, categories = data.forms, data.categories
local stem = args[1]
insert_if_not(data.title, "indeclinable")
insert_if_not(categories, "LA:Adjetivos indeclinables")
forms["nom_sg_m"] = stem
forms["nom_pl_m"] = stem
forms["gen_sg_m"] = stem
forms["gen_pl_m"] = stem
forms["dat_sg_m"] = stem
forms["dat_pl_m"] = stem
forms["acc_sg_m"] = stem
forms["acc_pl_m"] = stem
forms["abl_sg_m"] = stem
forms["abl_pl_m"] = stem
forms["voc_sg_m"] = stem
forms["voc_pl_m"] = stem
forms["loc_sg_m"] = stem
forms["loc_pl_m"] = stem
end
adj_decl["1&2+"] = function(data, args)
local forms, types, pos, subtitles, categories = data.forms, data.types, data.pos, data.subtitles, data.categories
local stem = args[1]
insert_if_not(data.title, "primera y segunda declinación")
insert_if_not(categories, "LA:Adjetivos de la primera declinación")
insert_if_not(categories, "LA:Adjetivos de la segunda declinación")
local original
if types.er then
local final2 = stem:sub(-2)
if final2 == "er" then
-- insert_if_not(categories, "LA:Sustantivos de la primera declinación")
-- insert_if_not(categories, "LA:Sustantivos de la segunda declinación")
elseif final2 == "ur" then
-- insert_if_not(categories, "LA:Sustantivos de la primera declinación")
-- insert_if_not(categories, "LA:Sustantivos de la segunda declinación")
else
error("Unrecognized ''-r'' stem (doesn't end in ''-er'' or ''-ur''): " .. stem)
end
stem, original = args[2], stem
end
local us = "us"
local a_sf = "a"
local um = "um"
local ae_gsf = "ae"
local am = "am"
local a_macron = "ā"
local i_pl = stem .. "ī"
if types.greekA or types.greekE then
insert_if_not(data.title, "griego")
insert_if_not(categories, "LA:Sustantivos griegos")
if types.greekA then
us = "os"
um = "on"
am = "ān"
else
us = "os"
a_sf = "ē"
um = "on"
ae_gsf = "ēs"
am = "ēn"
a_macron = "ē"
end
i_pl = {i_pl, stem .. "oe"}
end
forms["nom_sg_m"] = original or (stem .. us)
forms["nom_sg_f"] = stem .. a_sf
forms["nom_sg_n"] = stem .. um
forms["nom_pl_m"] = i_pl
forms["nom_pl_f"] = stem .. "ae"
forms["nom_pl_n"] = stem .. "a"
forms["gen_sg_m"] = stem .. "ī"
forms["gen_sg_f"] = stem .. ae_gsf
forms["gen_sg_n"] = stem .. "ī"
forms["gen_pl_m"] = stem .. "ōrum"
forms["gen_pl_f"] = stem .. "ārum"
forms["gen_pl_n"] = stem .. "ōrum"
forms["dat_sg_m"] = stem .. "ō"
forms["dat_sg_f"] = stem .. "ae"
forms["dat_sg_n"] = stem .. "ō"
forms["dat_pl_m"] = stem .. "īs"
forms["dat_pl_f"] = stem .. "īs"
forms["dat_pl_n"] = stem .. "īs"
forms["acc_sg_m"] = stem .. um
forms["acc_sg_f"] = stem .. am
forms["acc_sg_n"] = stem .. um
forms["acc_pl_m"] = stem .. "ōs"
forms["acc_pl_f"] = stem .. "ās"
forms["acc_pl_n"] = stem .. "a"
forms["abl_sg_m"] = stem .. "ō"
forms["abl_sg_f"] = stem .. a_macron
forms["abl_sg_n"] = stem .. "ō"
forms["abl_pl_m"] = stem .. "īs"
forms["abl_pl_f"] = stem .. "īs"
forms["abl_pl_n"] = stem .. "īs"
forms["voc_sg_m"] = original or (stem .. "e")
forms["voc_sg_f"] = stem .. a_sf
forms["voc_sg_n"] = stem .. um
forms["voc_pl_m"] = i_pl
forms["voc_pl_f"] = stem .. "ae"
forms["voc_pl_n"] = stem .. "a"
if types.ius then
insert_if_not(data.title, "pronominal")
--insert_if_not(subtitles, "with genitive singular in ''-ī̆us'' and dative singular in ''-ī''")
forms["gen_sg_m"] = stem .. "ī̆us"
forms["gen_sg_f"] = stem .. "ī̆us"
forms["gen_sg_n"] = stem .. "ī̆us"
forms["dat_sg_m"] = stem .. "ī"
forms["dat_sg_f"] = stem .. "ī"
forms["dat_sg_n"] = stem .. "ī"
elseif types.not_ius then
insert_if_not(data.title, "no pronominal")
--insert_if_not(subtitles, "with normal genitive and dative singular")
end
if stem == "me" then
forms["voc_sg_m"] = "mī"
end
if types.ic then
--insert_if_not(subtitles, "with genitive singular ending in ''-ius'' and dative singular ending in ''-ic''")
local oc = "oc"
local oc_macron = "ōc"
if stem == "ill" then
oc = "uc"
oc_macron = "ūc"
end
forms["nom_sg_m"] = stem .. "ic"
forms["nom_sg_f"] = stem .. "aec"
forms["nom_sg_n"] = stem .. oc
forms["nom_pl_n"] = stem .. "aec"
forms["gen_sg_m"] = stem .. "uius"
forms["gen_sg_f"] = stem .. "uius"
forms["gen_sg_n"] = stem .. "uius"
forms["dat_sg_m"] = stem .. "uic"
forms["dat_sg_f"] = stem .. "uic"
forms["dat_sg_n"] = stem .. "uic"
forms["acc_sg_m"] = stem .. "unc"
forms["acc_sg_f"] = stem .. "anc"
forms["acc_sg_n"] = stem .. oc
forms["acc_pl_n"] = stem .. "aec"
forms["abl_sg_m"] = stem .. "ōc"
forms["abl_sg_f"] = stem .. "āc"
forms["abl_sg_n"] = stem .. oc_macron
forms["voc_sg_m"] = {}
forms["voc_sg_f"] = {}
forms["voc_sg_n"] = {}
forms["voc_pl_m"] = {}
forms["voc_pl_f"] = {}
forms["voc_pl_n"] = {}
end
if types.distr then
if stem:sub(-1) == "n" then
forms["gen_pl_m"] = {stem .. "um", stem .. "ōrum{R}"}
forms["gen_pl_f"] = {stem .. "um", stem .. "ārum{R}"}
forms["gen_pl_n"] = {stem .. "um", stem .. "ōrum{R}"}
else
error("Unrecognized distributive numeral stem (doesn't end in ''n''): " .. stem)
end
original = stem
stem = args[2]
end
forms["loc_sg_m"] = deep_copy(forms["gen_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["gen_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["gen_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_f"] = deep_copy(forms["abl_pl_f"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
adj_decl["1-1+"] = function(data, args)
local forms, subtitles, categories = data.forms, data.subtitles, data.categories
local stem = args[1]
insert_if_not(data.title, "primera declinación")
insert_if_not(categories, "LA:Adjetivos de la primera declinación")
forms["nom_sg_m"] = stem .. "a"
forms["nom_pl_m"] = stem .. "ae"
forms["nom_pl_n"] = stem .. "a"
forms["gen_sg_m"] = stem .. "ae"
forms["gen_pl_m"] = stem .. "ārum"
forms["dat_sg_m"] = stem .. "ae"
forms["dat_pl_m"] = stem .. "īs"
forms["acc_sg_m"] = stem .. "am"
forms["acc_sg_n"] = stem .. "a"
forms["acc_pl_m"] = stem .. "ās"
forms["acc_pl_n"] = stem .. "a"
forms["abl_sg_m"] = stem .. "ā"
forms["abl_pl_m"] = stem .. "īs"
forms["voc_sg_m"] = stem .. "a"
forms["voc_pl_m"] = stem .. "ae"
forms["voc_pl_n"] = stem .. "a"
forms["loc_sg_m"] = deep_copy(forms["gen_sg_m"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
end
adj_decl["2-2+"] = function(data, args)
local forms, types, pos, subtitles, categories = data.forms, data.types, data.pos, data.subtitles, data.categories
local stem = args[1]
insert_if_not(data.title, "segunda declinación")
insert_if_not(categories, "LA:Adjetivos de la segunda declinación")
local us = "us"
local um = "um"
local i_pl = stem .. "ī"
if types.greek then
insert_if_not(data.title, "griego")
insert_if_not(categories, "LA:Sustantivos griegos")
us = "os"
um = "on"
i_pl = {i_pl, stem .. "oe"}
end
forms["nom_sg_m"] = stem .. us
forms["nom_sg_n"] = stem .. um
forms["nom_pl_m"] = i_pl
forms["nom_pl_n"] = stem .. "a"
forms["gen_sg_m"] = stem .. "ī"
forms["gen_sg_n"] = stem .. "ī"
forms["gen_pl_m"] = stem .. "ōrum"
forms["gen_pl_n"] = stem .. "ōrum"
forms["dat_sg_m"] = stem .. "ō"
forms["dat_sg_n"] = stem .. "ō"
forms["dat_pl_m"] = stem .. "īs"
forms["dat_pl_n"] = stem .. "īs"
forms["acc_sg_m"] = stem .. um
forms["acc_sg_n"] = stem .. um
forms["acc_pl_m"] = stem .. "ōs"
forms["acc_pl_n"] = stem .. "a"
forms["abl_sg_m"] = stem .. "ō"
forms["abl_sg_n"] = stem .. "ō"
forms["abl_pl_m"] = stem .. "īs"
forms["abl_pl_n"] = stem .. "īs"
forms["voc_sg_m"] = stem .. "e"
forms["voc_sg_n"] = stem .. um
forms["voc_pl_m"] = i_pl
forms["voc_pl_n"] = stem .. "a"
forms["loc_sg_m"] = deep_copy(forms["gen_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["gen_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
local function abl_i_e(...)
local function update_slot(forms, slot, f, do_copy)
if not forms[slot] then
return do_copy
elseif do_copy then
f = deep_copy(f)
end
forms[slot] = f
return true
end
function abl_i_e(stem, forms, types)
local f, do_copy
if types["abl_e_i"] then
f = {stem .. "e", stem .. "ī"}
elseif types["abl_i_e"] then
f = {stem .. "ī", stem .. "e"}
else
return
end
do_copy = update_slot(forms, "abl_sg_m", f, do_copy)
do_copy = update_slot(forms, "abl_sg_f", f, do_copy)
-- Neuter doesn't take -e with i-stems.
if not types.I then
update_slot(forms, "abl_sg_n", f, do_copy)
end
end
return abl_i_e(...)
end
adj_decl["3-1+"] = function(data, args)
local forms, types, pos, subtitles, notes, categories = data.forms, data.types, data.pos, data.subtitles, data.notes, data.categories
local stem1, stem2 = args[1], args[2]
-- local singpos = singularize(pos)
insert_if_not(data.title, "tercera declinación, dos terminaciones")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación con dos terminaciones")
forms["nom_sg_m"] = stem1
forms["nom_sg_n"] = stem1
forms["nom_pl_m"] = stem2 .. "ēs"
forms["nom_pl_n"] = stem2 .. "ia"
forms["gen_sg_m"] = stem2 .. "is"
forms["gen_sg_n"] = stem2 .. "is"
forms["gen_pl_m"] = stem2 .. "ium"
forms["gen_pl_n"] = stem2 .. "ium"
forms["dat_sg_m"] = stem2 .. "ī"
forms["dat_sg_n"] = stem2 .. "ī"
forms["dat_pl_m"] = stem2 .. "ibus"
forms["dat_pl_n"] = stem2 .. "ibus"
forms["acc_sg_m"] = stem2 .. "em"
forms["acc_sg_n"] = stem1
forms["acc_pl_m"] = {stem2 .. "īs", stem2 .. "ēs"}
forms["acc_pl_n"] = stem2 .. "ia"
forms["abl_sg_m"] = stem2 .. "ī"
forms["abl_sg_n"] = stem2 .. "ī"
forms["abl_pl_m"] = stem2 .. "ibus"
forms["abl_pl_n"] = stem2 .. "ibus"
abl_i_e(stem2, forms, types)
forms["voc_sg_m"] = stem1
forms["voc_sg_n"] = stem1
forms["voc_pl_m"] = stem2 .. "ēs"
forms["voc_pl_n"] = stem2 .. "ia"
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
if types.par then
forms["nom_pl_n"] = stem2 .. "a"
forms["gen_pl_m"] = stem2 .. "um"
forms["gen_pl_n"] = stem2 .. "um"
forms["abl_sg_m"] = stem2 .. "e"
forms["abl_sg_n"] = stem2 .. "e"
forms["loc_sg_m"] = {stem2 .. "ī", stem2 .. "e"} -- Really?
forms["loc_sg_n"] = {stem2 .. "ī", stem2 .. "e"} -- Why does this happen?
forms["acc_pl_n"] = stem2 .. "a"
forms["voc_pl_n"] = stem2 .. "a"
end
local es_base = stem1:match("^(.-)ēs$")
if es_base and es_base == stem2 then
if types.greek then
forms["nom_sg_n"] = {stem2 .. "ē̆s{?}"}
forms["acc_sg_n"] = {stem2 .. "ē̆s{?}"}
forms["voc_sg_m"] = {stem2 .. "ē̆s{?}"}
forms["voc_sg_n"] = {stem2 .. "ē̆s{?}"}
forms["nom_pl_n"] = {stem2 .. "a{?}", stem2 .. "ia{?}"}
forms["acc_pl_n"] = {stem2 .. "a{?}", stem2 .. "ia{?}"}
forms["voc_pl_n"] = {stem2 .. "a{?}", stem2 .. "ia{?}"}
forms["abl_sg_m"] = {stem2 .. "e{?}", stem2 .. "ī{?}"}
forms["abl_sg_n"] = {stem2 .. "e{?}", stem2 .. "ī{?}"}
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["gen_pl_m"] = {stem2 .. "um{?}", stem2 .. "ium{?}"}
forms["gen_pl_n"] = {stem2 .. "um{?}", stem2 .. "ium{?}"}
insert_if_not(data.title, "griego")
insert_if_not(categories, "LA:Adjetivos griegos")
elseif types.not_greek then
insert_if_not(data.title, "no griego")
end
end
end
adj_decl["3-def+"] = function(data, args)
local forms, types, pos, subtitles, notes, categories = data.forms, data.types, data.pos, data.subtitles, data.notes, data.categories
local stem1, stem2 = args[1], args[2]
-- local singpos = singularize(pos)
insert_if_not(data.title, "tercera declinación, defectivo")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación")
forms["nom_sg_m"] = stem1
forms["nom_sg_n"] = stem1
forms["nom_pl_m"] = stem2 .. "ēs"
forms["nom_pl_n"] = stem2 .. "ia"
forms["gen_sg_m"] = stem2 .. "is"
forms["gen_sg_n"] = stem2 .. "is"
forms["gen_pl_m"] = stem2 .. "ium"
forms["gen_pl_n"] = stem2 .. "ium"
forms["dat_sg_m"] = stem2 .. "ī"
forms["dat_sg_n"] = stem2 .. "ī"
forms["dat_pl_m"] = stem2 .. "ibus"
forms["dat_pl_n"] = stem2 .. "ibus"
forms["acc_sg_m"] = stem2 .. "em"
forms["acc_sg_n"] = stem1
forms["acc_pl_m"] = stem2 .. "ēs"
forms["acc_pl_n"] = stem2 .. "ia"
forms["abl_sg_m"] = stem2 .. "ī"
forms["abl_sg_n"] = stem2 .. "ī"
forms["abl_pl_m"] = stem2 .. "ibus"
forms["abl_pl_n"] = stem2 .. "ibus"
forms["voc_sg_m"] = stem1
forms["voc_sg_n"] = stem1
forms["voc_pl_m"] = stem2 .. "ēs"
forms["voc_pl_n"] = stem2 .. "ia"
if types.tor then
insert_if_not(data.title, "tercera declinación, solo en masculino")
insert_if_not(categories, "LA:Adjetivos solo en masculino")
remove_forms(forms, {"_f$", "_n$"})
forms["nom_sg_m"] = stem1
forms["gen_sg_m"] = stem2 .. "is"
forms["dat_sg_m"] = stem2 .. "ī"
forms["acc_sg_m"] = stem2 .. "em"
forms["abl_sg_m"] = stem2 .. "e"
forms["voc_sg_m"] = stem1
forms["nom_pl_m"] = stem2 .. "ēs"
forms["gen_pl_m"] = stem2 .. "um"
forms["dat_pl_m"] = stem2 .. "ibus"
forms["acc_pl_m"] = stem2 .. "ēs"
forms["abl_pl_m"] = stem2 .. "ibus"
forms["voc_pl_m"] = stem2 .. "ēs"
end
if types.trix then
insert_if_not(data.title, "tercera declinación, solo en femenino o en neutro plural")
insert_if_not(categories, "LA:Adjetivos solo en femenino")
insert_if_not(categories, "LA:Adjetivos solo en neutro")
remove_forms(forms, {"_m$", "sg_n$"})
forms["nom_sg_f"] = stem1
forms["gen_sg_f"] = stem2 .. "is"
forms["dat_sg_f"] = stem2 .. "ī"
forms["acc_sg_f"] = stem2 .. "em"
forms["abl_sg_f"] = {stem2 .. "e", stem2 .. "ī"}
forms["voc_sg_f"] = stem1
forms["nom_pl_f"] = stem2 .. "ēs"
forms["gen_pl_f"] = stem2 .. "ium"
forms["dat_pl_f"] = stem2 .. "ibus"
forms["acc_pl_f"] = stem2 .. "ēs"
forms["abl_pl_f"] = stem2 .. "ibus"
forms["voc_pl_f"] = stem2 .. "ēs"
end
if types.trixf then
insert_if_not(data.title, "tercera declinación, solo en femenino")
insert_if_not(categories, "LA:Adjetivos solo en femenino")
remove_forms(forms, {"_m$","_n$"})
forms["nom_sg_f"] = stem1
forms["gen_sg_f"] = stem2 .. "is"
forms["dat_sg_f"] = stem2 .. "ī"
forms["acc_sg_f"] = stem2 .. "em"
forms["abl_sg_f"] = {stem2 .. "e", stem2 .. "ī"}
forms["voc_sg_f"] = stem1
forms["nom_pl_f"] = stem2 .. "ēs"
forms["gen_pl_f"] = stem2 .. "ium"
forms["dat_pl_f"] = stem2 .. "ibus"
forms["acc_pl_f"] = stem2 .. "ēs"
forms["abl_pl_f"] = stem2 .. "ibus"
forms["voc_pl_f"] = stem2 .. "ēs"
end
if types.idis then
insert_if_not(data.title, "tercera declinación, solo en femenino")
insert_if_not(categories, "LA:Adjetivos solo en femenino")
remove_forms(forms, {"_m$","_n$"})
forms["nom_sg_f"] = stem1
forms["gen_sg_f"] = {stem2 .. "is", stem2 .. "os"}
forms["dat_sg_f"] = stem2 .. "ī"
forms["acc_sg_f"] = {stem2 .. "em", stem2 .. "a"}
forms["abl_sg_f"] = stem2 .. "e"
forms["voc_sg_f"] = stem1
forms["nom_pl_f"] = {stem2 .. "ēs", stem2 .. "es"}
forms["gen_pl_f"] = stem2 .. "um"
forms["dat_pl_f"] = stem2 .. "ibus"
forms["acc_pl_f"] = {stem2 .. "ēs", stem2 .. "as"}
forms["abl_pl_f"] = stem2 .. "ibus"
forms["voc_pl_f"] = {stem2 .. "ēs", stem2 .. "es"}
end
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["abl_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_f"] = deep_copy(forms["abl_pl_f"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
adj_decl["3-C+"] = function(data, args)
local forms, types, pos, categories = data.forms, data.types, data.pos, data.categories
local stem1 = args[1]
local stem2 = stem1 .. "ōr"
insert_if_not(data.title, "tercera declinación, comparativo")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación")
insert_if_not(categories, "LA:Adjetivos comparativos")
forms["nom_sg_m"] = stem1 .. "or"
forms["nom_sg_n"] = stem1 .. "us"
forms["nom_pl_m"] = stem2 .. "ēs"
forms["nom_pl_n"] = stem2 .. "a"
forms["gen_sg_m"] = stem2 .. "is"
forms["gen_sg_n"] = stem2 .. "is"
forms["gen_pl_m"] = stem2 .. "um"
forms["gen_pl_n"] = stem2 .. "um"
forms["dat_sg_m"] = stem2 .. "ī"
forms["dat_sg_n"] = stem2 .. "ī"
forms["dat_pl_m"] = stem2 .. "ibus"
forms["dat_pl_n"] = stem2 .. "ibus"
forms["acc_sg_m"] = stem2 .. "em"
forms["acc_sg_n"] = stem1 .. "us"
forms["acc_pl_m"] = {stem2 .. "ēs", stem2 .. "īs"}
forms["acc_pl_n"] = stem2 .. "a"
forms["abl_sg_m"] = stem2 .. "ī"
forms["abl_sg_n"] = stem2 .. "ī"
forms["abl_pl_m"] = stem2 .. "ibus"
forms["abl_pl_n"] = stem2 .. "ibus"
abl_i_e(stem2, forms, types)
forms["voc_sg_m"] = stem1 .. "or"
forms["voc_sg_n"] = stem1 .. "us"
forms["voc_pl_m"] = stem2 .. "ēs"
forms["voc_pl_n"] = stem2 .. "a"
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
adj_decl["3-P+"] = function(data, args)
local forms, notes = data.forms, data.notes
local stem2 = args[2]
adj_decl["3-1+"](data, args)
insert_if_not(data.title, "tercera declinación, participio")
insert_if_not(data.categories, "LA:Adjetivos de la tercera declinación")
forms["abl_sg_m"] = {stem2 .. "e{PART}", stem2 .. "ī{ADJ}"}
forms["abl_sg_n"] = {stem2 .. "e{PART}", stem2 .. "ī{ADJ}"}
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["acc_pl_m"] = {stem2 .. "ēs", stem2 .. "īs"}
end
adj_decl["3-2+"] = function(data, args)
local forms, types, pos, categories = data.forms, data.types, data.pos, data.categories
local stem = args[1]
-- local singpos = singularize(pos)
insert_if_not(data.title, "tercera declinación, dos terminaciones")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación con dos terminaciones")
forms["nom_sg_m"] = stem .. "is"
forms["nom_sg_n"] = stem .. "e"
forms["nom_pl_m"] = stem .. "ēs"
forms["nom_pl_n"] = stem .. "ia"
forms["gen_sg_m"] = stem .. "is"
forms["gen_sg_n"] = stem .. "is"
forms["gen_pl_m"] = stem .. "ium"
forms["gen_pl_n"] = stem .. "ium"
forms["dat_sg_m"] = stem .. "ī"
forms["dat_sg_n"] = stem .. "ī"
forms["dat_pl_m"] = stem .. "ibus"
forms["dat_pl_n"] = stem .. "ibus"
forms["acc_sg_m"] = stem .. "em"
forms["acc_sg_n"] = stem .. "e"
forms["acc_pl_m"] = {stem .. "īs", stem .. "ēs"}
forms["acc_pl_n"] = stem .. "ia"
forms["abl_sg_m"] = stem .. "ī"
forms["abl_sg_n"] = stem .. "ī"
forms["abl_pl_m"] = stem .. "ibus"
forms["abl_pl_n"] = stem .. "ibus"
-- abl_i_e(stem, forms, types) -- enable once [[Module:la-nominal]] has ben updated
forms["voc_sg_m"] = stem .. "is"
forms["voc_sg_n"] = stem .. "e"
forms["voc_pl_m"] = stem .. "ēs"
forms["voc_pl_n"] = stem .. "ia"
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
adj_decl["3-3+"] = function(data, args)
local forms, types, pos, categories = data.forms, data.types, data.pos, data.categories
local stem1, stem2 = args[1], args[2]
-- local singpos = singularize(pos)
insert_if_not(data.title, "tercera declinación")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación con tres terminaciones")
forms["nom_sg_m"] = stem1
forms["nom_sg_f"] = stem2 .. "is"
forms["nom_sg_n"] = stem2 .. "e"
forms["nom_pl_m"] = stem2 .. "ēs"
forms["nom_pl_f"] = stem2 .. "ēs"
forms["nom_pl_n"] = stem2 .. "ia"
forms["gen_sg_m"] = stem2 .. "is"
forms["gen_sg_f"] = stem2 .. "is"
forms["gen_sg_n"] = stem2 .. "is"
forms["gen_pl_m"] = stem2 .. "ium"
forms["gen_pl_f"] = stem2 .. "ium"
forms["gen_pl_n"] = stem2 .. "ium"
forms["dat_sg_m"] = stem2 .. "ī"
forms["dat_sg_f"] = stem2 .. "ī"
forms["dat_sg_n"] = stem2 .. "ī"
forms["dat_pl_m"] = stem2 .. "ibus"
forms["dat_pl_f"] = stem2 .. "ibus"
forms["dat_pl_n"] = stem2 .. "ibus"
forms["acc_sg_m"] = stem2 .. "em"
forms["acc_sg_f"] = stem2 .. "em"
forms["acc_sg_n"] = stem2 .. "e"
forms["acc_pl_m"] = {stem2 .. "īs", stem2 .. "ēs"}
forms["acc_pl_f"] = {stem2 .. "īs", stem2 .. "ēs"}
forms["acc_pl_n"] = stem2 .. "ia"
forms["abl_sg_m"] = stem2 .. "ī"
forms["abl_sg_f"] = stem2 .. "ī"
forms["abl_sg_n"] = stem2 .. "ī"
forms["abl_pl_m"] = stem2 .. "ibus"
forms["abl_pl_f"] = stem2 .. "ibus"
forms["abl_pl_n"] = stem2 .. "ibus"
-- abl_i_e(stem2, forms, types) -- enable once [[Module:la-nominal]] has ben updated
forms["voc_sg_m"] = stem1
forms["voc_sg_f"] = stem2 .. "is"
forms["voc_sg_n"] = stem2 .. "e"
forms["voc_pl_m"] = stem2 .. "ēs"
forms["voc_pl_f"] = stem2 .. "ēs"
forms["voc_pl_n"] = stem2 .. "ia"
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["abl_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_f"] = deep_copy(forms["abl_pl_f"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
adj_decl["indecl+"] = function(data, args)
local forms, subtitles, categories = data.forms, data.subtitles, data.categories
local stem = args[1]
insert_if_not(data.title, "indeclinable")
insert_if_not(categories, "LA:Adjetivos indeclinables")
forms["nom_sg_m"] = stem
forms["nom_pl_m"] = {}
forms["gen_sg_m"] = {}
forms["gen_pl_m"] = {}
forms["dat_sg_m"] = {}
forms["dat_pl_m"] = {}
forms["acc_sg_m"] = stem
forms["acc_pl_m"] = {}
forms["abl_sg_m"] = {}
forms["abl_pl_m"] = {}
forms["voc_sg_m"] = {}
forms["voc_pl_m"] = {}
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
end
adj_decl["irreg+"] = function(data,args)
local forms, types, pos, notes, categories = data.forms, data.types, data.pos, data.notes, data.categories
local arg1 = args[1]
insert_if_not(data.title, "irregular")
insert_if_not(categories, "LA:Adjetivos irregulares")
if arg1 == "duo" or arg1 == "ambō" then
local stem = sub(arg1, 1, -2)
-- data.title = stem == "amb" and "irregular adjective" or "numeral"
data.num = "pl"
local stem_with_o = stem .. (stem == "amb" and "ō" or "o")
forms["nom_pl_m"] = stem_with_o
forms["nom_pl_f"] = stem .. "ae"
forms["nom_pl_n"] = stem_with_o
forms["gen_pl_m"] = stem .. "ōrum"
forms["gen_pl_f"] = stem .. "ārum"
forms["gen_pl_n"] = stem .. "ōrum"
forms["dat_pl_m"] = stem .. "ōbus"
forms["dat_pl_f"] = stem .. "ābus"
forms["dat_pl_n"] = stem .. "ōbus"
forms["acc_pl_m"] = {stem .. "ōs", stem_with_o}
forms["acc_pl_f"] = stem .. "ās"
forms["acc_pl_n"] = stem_with_o
forms["abl_pl_m"] = stem .. "ōbus"
forms["abl_pl_f"] = stem .. "ābus"
forms["abl_pl_n"] = stem .. "ōbus"
forms["voc_pl_m"] = stem_with_o
forms["voc_pl_f"] = stem .. "ae"
forms["voc_pl_n"] = stem_with_o
if stem == "du" then
forms["gen_pl_m"] = {forms["gen_pl_m"], "duum", "duom{†}"}
forms["gen_pl_n"] = {forms["gen_pl_n"], "duum", "duom{†}"}
end
elseif arg1:sub(-6) == "mīlle" then
insert_if_not(data.title, "numeral semiindeclinable")
local stem = arg1:sub(1, -3)
forms["nom_sg_m"] = stem .. "le"
forms["nom_pl_m"] = {stem .. "ia", stem .. "lia"}
forms["gen_sg_m"] = stem .. "le"
forms["gen_pl_m"] = {stem .. "ium", stem .. "lium"}
forms["dat_sg_m"] = stem .. "le"
forms["dat_pl_m"] = {stem .. "ibus", stem .. "libus"}
forms["acc_sg_m"] = stem .. "le"
forms["acc_pl_m"] = {stem .. "ia", stem .. "lia"}
forms["abl_sg_m"] = stem .. "le"
forms["abl_pl_m"] = {stem .. "ibus", stem .. "libus"}
forms["voc_sg_m"] = stem .. "le"
forms["voc_pl_m"] = {stem .. "ia", stem .. "lia"}
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
elseif arg1 == "ille" or arg1 == "iste" or arg1 == "ipse" or arg1 == "olle" then
local stem = arg1:sub(1, -2)
types.ius = true
adj_decl["1&2+"](data, {stem})
insert_if_not(data.title, "demostrativo") -- .. " " .. singularize(data.pos)
forms["nom_sg_m"] = arg1
if arg1 == "ipse" then
add_form(forms, "nom_sg_n", stem, "ud{MED}")
add_form(forms, "acc_sg_n", stem, "ud{MED}")
else
forms["nom_sg_n"] = stem .. "ud"
forms["acc_sg_n"] = stem .. "ud"
end
forms["voc_sg_m"] = {}
forms["voc_sg_f"] = {}
forms["voc_sg_n"] = {}
forms["voc_pl_m"] = {}
forms["voc_pl_f"] = {}
forms["voc_pl_n"] = {}
elseif arg1 == "illic" or arg1 == "istic" or arg1 == "isthic" then
insert_if_not(data.title, "demostrativo") -- .. " " .. singularize(data.pos)
local stem = arg1:sub(1, -3)
forms["nom_sg_m"] = stem .. "ic"
forms["nom_sg_f"] = stem .. "aec"
forms["nom_sg_n"] = {stem .. "uc", stem .. "ucce", stem .. "oc"}
forms["gen_sg_m"] = stem .. "ī̆usce"
forms["gen_sg_f"] = stem .. "ī̆usce"
forms["gen_sg_n"] = stem .. "ī̆usce"
forms["dat_sg_m"] = stem .. "īc"
forms["dat_sg_f"] = stem .. "īc"
forms["dat_sg_n"] = stem .. "īc"
forms["acc_sg_m"] = stem .. "unc"
forms["acc_sg_f"] = stem .. "anc"
forms["acc_sg_n"] = {stem .. "uc", stem .. "ucce", stem .. "oc"}
forms["abl_sg_m"] = stem .. "ōc"
forms["abl_sg_f"] = stem .. "āc"
forms["abl_sg_n"] = stem .. "ōc"
forms["loc_sg_m"] = deep_copy(forms["gen_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["gen_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["gen_sg_n"])
forms["nom_pl_m"] = stem .. "īsce"
forms["nom_pl_f"] = stem .. "aec"
forms["nom_pl_n"] = stem .. "aec"
forms["gen_pl_m"] = stem .. "ōrunc{?}"
forms["gen_pl_f"] = stem .. "ārunc{?}"
forms["gen_ok_n"] = stem .. "ōrunc{?}"
forms["dat_pl_m"] = stem .. "īsce"
forms["dat_pl_f"] = stem .. "īsce"
forms["dat_pl_n"] = stem .. "īsce"
forms["acc_pl_m"] = stem .. "ōsce"
forms["acc_pl_f"] = stem .. "āsce"
forms["acc_pl_n"] = stem .. "aec"
forms["abl_pl_m"] = stem .. "īsce"
forms["abl_pl_f"] = stem .. "īsce"
forms["abl_pl_n"] = stem .. "īsce"
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_f"] = deep_copy(forms["abl_pl_f"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
elseif arg1 == "hice" then
insert_if_not(data.title, "demostrativo") -- .. " pronoun"
forms["nom_sg_m"] = "hice"
forms["nom_sg_f"] = "haece"
forms["nom_sg_n"] = "hoce"
forms["nom_pl_m"] = "hīce"
forms["nom_pl_f"] = "haece"
forms["nom_pl_n"] = "haece"
forms["gen_sg_m"] = "huiusce"
forms["gen_sg_f"] = "huiusce"
forms["gen_sg_n"] = "huiusce"
forms["gen_pl_m"] = {"hōrunce", "hōrumce"}
forms["gen_pl_f"] = {"hārunce", "hārumce"}
forms["gen_pl_n"] = {"hōrunce", "hōrumce"}
forms["dat_sg_m"] = "huīce"
forms["dat_sg_f"] = "huīce"
forms["dat_sg_n"] = "huīce"
forms["dat_pl_m"] = "hīsce"
forms["dat_pl_f"] = "hīsce"
forms["dat_pl_n"] = "hīsce"
forms["acc_sg_m"] = "hunce"
forms["acc_sg_f"] = "hance"
forms["acc_sg_n"] = "hoce"
forms["acc_pl_m"] = "hōsce"
forms["acc_pl_f"] = "hāsce"
forms["acc_pl_n"] = "haece"
forms["abl_sg_m"] = "hōce"
forms["abl_sg_f"] = "hāce"
forms["abl_sg_n"] = "hōce"
forms["abl_pl_m"] = "hīsce"
forms["abl_pl_f"] = "hīsce"
forms["abl_pl_n"] = "hīsce"
forms["loc_sg_m"] = deep_copy(forms["gen_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["gen_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["gen_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_f"] = deep_copy(forms["abl_pl_f"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
elseif arg1 == "plūs" then
insert_if_not(data.title, "comparativo")
insert_if_not(data.categories, "LA:Sustantivos de la tercera declinación")
insert_if_not(data.categories, "LA:Sustantivos de la tercera declinación con una terminación")
data.note = "Ninguna de las formas en singular se usaron en latín clásico"
forms["nom_sg_n"] = "plūs"
forms["nom_pl_m"] = "plūrēs"
forms["nom_pl_n"] = "plūra"
forms["gen_sg_m"] = "plūris"
forms["gen_sg_n"] = "plūris"
forms["gen_pl_m"] = "plūrium"
forms["gen_pl_n"] = "plūrium"
forms["dat_sg_m"] = "plūrī"
forms["dat_sg_n"] = "plūrī"
forms["dat_pl_m"] = "plūribus"
forms["dat_pl_n"] = "plūribus"
forms["acc_sg_m"] = "plūrem"
forms["acc_sg_f"] = "plūrem"
forms["acc_sg_n"] = "plūs"
forms["acc_pl_m"] = {"plūrēs", "plūrīs"}
forms["acc_pl_n"] = "plūra"
forms["abl_sg_m"] = {"plūrī", "plūre"}
forms["abl_sg_f"] = {"plūrī", "plūre"}
forms["abl_sg_n"] = {"plūrī", "plūre"}
forms["abl_pl_m"] = "plūribus"
forms["abl_pl_n"] = "plūribus"
forms["voc_sg_n"] = "plūs"
forms["voc_pl_m"] = "plūrēs"
forms["voc_pl_n"] = "plūra"
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["abl_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
elseif match(arg1, "^egō̆?$") or arg1 == "nōs" then
insert_if_not(data.title, "pronombre nominativo")
forms["nom_sg_m"] = arg1
forms["nom_pl_m"] = "nōs"
forms["gen_sg_m"] = "meī"
forms["gen_pl_m"] = {"nostrī", "nostrum"}
forms["dat_sg_m"] = "mihī̆"
forms["dat_pl_m"] = "nōbīs"
forms["acc_sg_m"] = {"mē", "mēmē"}
forms["acc_pl_m"] = "nōs"
forms["abl_sg_m"] = {"mē", "mēmē"}
forms["abl_pl_m"] = "nōbīs"
forms["voc_sg_m"] = arg1
forms["voc_pl_m"] = "nōs"
elseif arg1 == "tū" or arg1 == "vōs" then
insert_if_not(data.title, "pronombre nominativo")
forms["nom_sg_m"] = arg1
forms["nom_pl_m"] = "vōs"
forms["gen_sg_m"] = "tuī"
forms["gen_pl_m"] = {"vestrī", "vestrum"}
forms["dat_sg_m"] = "tibī̆"
forms["dat_pl_m"] = "vōbīs"
forms["acc_sg_m"] = {"tē", "tētē"}
forms["acc_pl_m"] = "vōs"
forms["abl_sg_m"] = {"tē", "tētē"}
forms["abl_pl_m"] = "vōbīs"
forms["voc_sg_m"] = arg1
forms["voc_pl_m"] = "vōs"
elseif arg1 == "suī" then
insert_if_not(data.title, "pronombre reflexivo")
forms["nom_sg_m"] = {}
forms["nom_pl_m"] = {}
forms["gen_sg_m"] = arg1
forms["gen_pl_m"] = forms["gen_sg_m"]
forms["dat_sg_m"] = "sibī̆"
forms["dat_pl_m"] = forms["dat_sg_m"]
forms["acc_sg_m"] = {"sē", "sēsē"}
forms["acc_pl_m"] = {"sē", "sēsē"}
forms["abl_sg_m"] = {"sē", "sēsē"}
forms["abl_pl_m"] = {"sē", "sēsē"}
forms["voc_sg_m"] = {}
forms["voc_pl_m"] = {}
elseif arg1 == "is" or arg1 == "īdem" then
insert_if_not(data.title, "pronombre demostrativo")
forms["nom_sg_m"] = "is"
forms["nom_sg_f"] = "ea"
forms["nom_sg_n"] = "id"
forms["nom_pl_m"] = {"iī", "eī", "ī"}
forms["nom_pl_f"] = "eae"
forms["nom_pl_n"] = "ea"
forms["gen_sg_m"] = {"eius", "ejus"}
forms["gen_sg_f"] = {"eius", "ejus"}
forms["gen_sg_n"] = {"eius", "ejus"}
forms["gen_pl_m"] = {"eōrum", "eum"}
forms["gen_pl_f"] = "eārum"
forms["gen_pl_n"] = {"eōrum", "eum"}
forms["dat_sg_m"] = {"eī", "e͡i", "ēī"}
forms["dat_sg_f"] = {"eī", "e͡i", "ēī", "eae"}
forms["dat_sg_n"] = {"eī", "e͡i", "ēī"}
forms["dat_pl_m"] = {"iīs", "eīs", "īs"}
forms["dat_pl_f"] = {"iīs", "eīs", "īs", "eābus"}
forms["dat_pl_n"] = {"iīs", "eīs", "īs"}
forms["acc_sg_m"] = "eum"
forms["acc_sg_f"] = "eam"
forms["acc_sg_n"] = "id"
forms["acc_pl_m"] = "eōs"
forms["acc_pl_f"] = "eās"
forms["acc_pl_n"] = "ea"
forms["abl_sg_m"] = "eō"
forms["abl_sg_f"] = "eā"
forms["abl_sg_n"] = "eō"
forms["abl_pl_m"] = {"iīs", "eīs", "īs"}
forms["abl_pl_f"] = {"iīs", "eīs", "īs"}
forms["abl_pl_n"] = {"iīs", "eīs", "īs"}
if arg1 == "īdem" then
forms["nom_sg_m"] = "ī"
forms["nom_sg_n"] = "i"
forms["acc_sg_n"] = "i"
end
elseif arg1 == "quis" or arg1 == "quī" then
data.note = "La forma ''qua'' es preferida frente a ''quae'' cuando se usa como indefinido"
local id = "id"
if arg1 == "quī" then
insert_if_not(data.title, "determinante relativo/interrogativo")
id = "od"
forms["nom_sg_m"] = {"quī", "quis", "quei{†}"}
forms["nom_sg_f"] = {"quae", "qua"}
forms["acc_sg_f"] = "quam"
forms["abl_sg_m"] = "quō"
forms["abl_sg_f"] = "quā"
forms["abl_sg_n"] = "quō"
else
insert_if_not(data.title, "pronombre relativo/interrogativo")
forms["nom_sg_m"] = {"quis", "quī"}
forms["nom_sg_f"] = {"quae", "qua", "quis{†}"}
forms["acc_sg_f"] = {"quam", "quem{†}"}
forms["abl_sg_m"] = {"quō", "quī"}
forms["abl_sg_f"] = {"quā", "quī"}
forms["abl_sg_n"] = {"quō", "quī"}
end
forms["nom_sg_n"] = "qu"..id
forms["nom_pl_m"] = {"quī", "quei{†}"}
forms["nom_pl_f"] = "quae"
forms["nom_pl_n"] = {"quae", "qua"}
forms["gen_sg_m"] = {"cuius", "quoius{†}"}
forms["gen_sg_f"] = {"cuius", "quoius{†}"}
forms["gen_sg_n"] = {"cuius", "quoius{†}"}
forms["gen_pl_m"] = "quōrum"
forms["gen_pl_f"] = "quārum"
forms["gen_pl_n"] = "quōrum"
forms["dat_sg_m"] = {"cui", "quoi{†}", "quoiei{†}"}
forms["dat_sg_f"] = {"cui", "quoi{†}", "quoiei{†}"}
forms["dat_sg_n"] = {"cui", "quoi{†}", "quoiei{†}"}
forms["dat_pl_m"] = {"quibus", "quīs", "queis{†}"}
forms["dat_pl_f"] = {"quibus", "quīs", "queis{†}"}
forms["dat_pl_n"] = {"quibus", "quīs", "queis{†}"}
forms["acc_sg_m"] = "quem"
forms["acc_sg_n"] = "qu"..id
forms["acc_pl_m"] = "quōs"
forms["acc_pl_f"] = "quās"
forms["acc_pl_n"] = {"quae", "qua"}
forms["abl_pl_m"] = {"quibus", "quīs", "queis{†}"}
forms["abl_pl_f"] = {"quibus", "quīs", "queis{†}"}
forms["abl_pl_n"] = {"quibus", "quīs", "queis{†}"}
elseif arg1 == "aliquī" then
insert_if_not(data.title, "determinante indefinido")
forms["nom_sg_m"] = {"aliquī{DET/ADJ}", "aliquis{PRON/SUST}"}
forms["nom_sg_f"] = {"aliqua", "aliquae{R}"}
forms["nom_sg_n"] = "aliquod"
forms["nom_pl_m"] = "aliquī"
forms["nom_pl_f"] = "aliquae"
forms["nom_pl_n"] = "aliqua"
forms["gen_sg_m"] = {"alicuius", "aliquoius{†}"}
forms["gen_sg_f"] = {"alicuius", "aliquoius{†}"}
forms["gen_sg_n"] = {"alicuius", "aliquoius{†}"}
forms["gen_pl_m"] = "aliquōrum"
forms["gen_pl_f"] = "aliquārum"
forms["gen_pl_n"] = "aliquōrum"
forms["dat_sg_m"] = {"alicui", "aliquoi{†}"}
forms["dat_sg_f"] = {"alicui", "aliquoi{†}"}
forms["dat_sg_n"] = {"alicui", "aliquoi{†}"}
forms["dat_pl_m"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
forms["dat_pl_f"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
forms["dat_pl_n"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
forms["acc_sg_m"] = "aliquem"
forms["acc_sg_f"] = "aliquam"
forms["acc_sg_n"] = "aliquod"
forms["acc_pl_m"] = "aliquōs"
forms["acc_pl_f"] = "aliquās"
forms["acc_pl_n"] = "aliqua"
forms["abl_sg_m"] = "aliquō"
forms["abl_sg_f"] = "aliquā"
forms["abl_sg_n"] = "aliquō"
forms["abl_pl_m"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
forms["abl_pl_f"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
forms["abl_pl_n"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
elseif arg1 == "quisquam" then
insert_if_not(data.title, "determinante indefinido, concordancia en negativo")
data.note = "En latín clásico, era preferidas las formas de ''ūllus'' en lugar de las esta voz para el femenino y el neutro."
forms["nom_sg_m"] = "quisquam"
forms["nom_sg_f"] = {"quaequam", "quisquam{†}"}
forms["nom_sg_n"] = "quodquam"
forms["nom_pl_m"] = "quīquam"
forms["nom_pl_f"] = "quaequam"
forms["nom_pl_n"] = "quaequam"
forms["gen_sg_m"] = "cuiusquam"
forms["gen_sg_f"] = "cuiusquam"
forms["gen_sg_n"] = "cuiusquam"
forms["gen_pl_m"] = "quōrumquam"
forms["gen_pl_f"] = "quārumquam"
forms["gen_pl_n"] = "quōrumquam"
forms["dat_sg_m"] = "cuiquam"
forms["dat_sg_f"] = "cuiquam"
forms["dat_sg_n"] = "cuiquam"
forms["dat_pl_m"] = "quibusquam"
forms["dat_pl_f"] = "quibusquam"
forms["dat_pl_n"] = "quibusquam"
forms["acc_sg_m"] = "quemquam"
forms["acc_sg_f"] = {"quamquam", "quemquam{†}"}
forms["acc_sg_n"] = "quodquam"
forms["acc_pl_m"] = "quōsquam"
forms["acc_pl_f"] = "quāsquam"
forms["acc_pl_n"] = "quaequam"
forms["abl_sg_m"] = {"quōquam", "quīquam{†}"}
forms["abl_sg_f"] = "quāquam"
forms["abl_sg_n"] = "quōquam"
forms["abl_pl_m"] = "quibusquam"
forms["abl_pl_f"] = "quibusquam"
forms["abl_pl_n"] = "quibusquam"
forms["voc_sg_m"] = "quisquam"
forms["voc_sg_f"] = "quaequam"
forms["voc_sg_n"] = "quodquam"
forms["voc_pl_m"] = "quīquam"
forms["voc_pl_f"] = "quaequam"
forms["voc_pl_n"] = "quaequam"
elseif arg1 == "quisquis" then
insert_if_not(data.title, "pronombre relativo/interrogativo")
forms["nom_sg_m"] = "quisquis"
forms["nom_sg_f"] = "quisquis"
forms["nom_sg_n"] = {"quidquid", "quicquid"}
forms["nom_pl_m"] = "quīquī"
forms["nom_pl_f"] = "quaequae"
forms["nom_pl_n"] = "quaequae"
forms["gen_sg_m"] = "cuiuscuius"
forms["gen_sg_f"] = "cuiuscuius"
forms["gen_sg_n"] = "cuiuscuius"
forms["gen_pl_m"] = "quōrumquōrum"
forms["gen_pl_f"] = "quārumquārum"
forms["gen_pl_n"] = "quōrumquōrum"
forms["dat_sg_m"] = "cuicui"
forms["dat_sg_f"] = "cuicui"
forms["dat_sg_n"] = "cuicui"
forms["dat_pl_m"] = {"quibusquibus", "quīsquīs"}
forms["dat_pl_f"] = {"quibusquibus", "quīsquīs"}
forms["dat_pl_n"] = {"quibusquibus", "quīsquīs"}
forms["acc_sg_m"] = "quemquem"
forms["acc_sg_f"] = "quamquam"
forms["acc_sg_n"] = {"quidquid", "quicquid"}
forms["acc_pl_m"] = "quōsquōs"
forms["acc_pl_f"] = "quāsquās"
forms["acc_pl_n"] = "quaequae"
forms["abl_sg_m"] = "quōquō"
forms["abl_sg_f"] = "quāquā"
forms["abl_sg_n"] = "quōquō"
forms["abl_pl_m"] = {"quibusquibus", "quīsquīs"}
forms["abl_pl_f"] = {"quibusquibus", "quīsquīs"}
forms["abl_pl_n"] = {"quibusquibus", "quīsquīs"}
forms["voc_sg_m"] = "quisquis"
forms["voc_sg_f"] = "quisquis"
forms["voc_sg_n"] = {"quidquid", "quicquid"}
forms["voc_pl_m"] = "quīquī"
forms["voc_pl_f"] = "quaequae"
forms["voc_pl_n"] = "quaequae"
elseif arg1 == "ecquis" then
insert_if_not(data.title, "pronombre interrogativo")
forms["nom_sg_m"] = {"ecquis", "ecquī"}
forms["nom_sg_f"] = {"ecqua", "ecquae"}
forms["nom_sg_n"] = "ecquid"
forms["nom_pl_m"] = "ecquī"
forms["nom_pl_f"] = "ecquae"
forms["nom_pl_n"] = {"ecqua", "ecquae"}
forms["gen_sg_m"] = "eccuius"
forms["gen_sg_f"] = "eccuius"
forms["gen_sg_n"] = "eccuius"
forms["dat_sg_m"] = "eccui"
forms["dat_sg_f"] = "eccui"
forms["dat_sg_n"] = "eccui"
forms["acc_sg_m"] = "ecquem"
forms["acc_sg_f"] = "ecquam"
forms["acc_sg_n"] = "ecquod"
forms["acc_pl_m"] = "ecquōs"
forms["acc_pl_f"] = "ecquās"
forms["acc_pl_n"] = {"ecqua", "ecquae"}
forms["abl_sg_m"] = {"ecquō", "ecquī"}
forms["abl_sg_f"] = {"ecquā", "ecquī"}
forms["abl_sg_n"] = {"ecquō", "ecquī"}
elseif arg1 == "quīdam" then
insert_if_not(data.title, "pronombre indefinido")
forms["nom_sg_m"] = "quīdam"
forms["nom_sg_f"] = "quaedam"
forms["nom_sg_n"] = "quiddam"
forms["nom_pl_m"] = {"quīdam", "quēsdam{†}"}
forms["nom_pl_f"] = "quaedam"
forms["nom_pl_n"] = "quaedam"
forms["gen_sg_m"] = {"cuiusdam", "quoiusdam{†}"}
forms["gen_sg_f"] = {"cuiusdam", "quoiusdam{†}"}
forms["gen_sg_n"] = {"cuiusdam", "quoiusdam{†}"}
forms["gen_pl_m"] = {"quōrundam", "quōrumdam"}
forms["gen_pl_f"] = {"quārundam", "quārumdam"}
forms["gen_pl_n"] = {"quōrundam", "quōrumdam"}
forms["dat_sg_m"] = {"cuidam", "quoidam{†}"}
forms["dat_sg_f"] = {"cuidam", "quoidam{†}"}
forms["dat_sg_n"] = {"cuidam", "quoidam{†}"}
forms["dat_pl_m"] = {"quibusdam", "quīsdam{†}"}
forms["dat_pl_f"] = {"quibusdam", "quīsdam{†}"}
forms["dat_pl_n"] = {"quibusdam", "quīsdam{†}"}
forms["acc_sg_m"] = {"quendam", "quemdam"}
forms["acc_sg_f"] = {"quandam", "quamdam"}
forms["acc_sg_n"] = "quiddam"
forms["acc_pl_m"] = {"quōsdam", "quēsdam{†}"}
forms["acc_pl_f"] = "quāsdam"
forms["acc_pl_n"] = "quaedam"
forms["abl_sg_m"] = "quōdam"
forms["abl_sg_f"] = "quādam"
forms["abl_sg_n"] = "quōdam"
forms["abl_pl_m"] = {"quibusdam", "quīsdam{†}"}
forms["abl_pl_f"] = {"quibusdam", "quīsdam{†}"}
forms["abl_pl_n"] = {"quibusdam", "quīsdam{†}"}
elseif arg1 == "nēmō" then
insert_if_not(data.title, "Determinante y pronombre, concordancia en negativo")
forms["nom_sg_m"] = "nēmō"
forms["nom_sg_f"] = "nēmō"
forms["gen_sg_m"] = {"nūllī̆us", "nēminis{R}"}
forms["gen_sg_f"] = {"nūllī̆us", "nēminis{R}"}
forms["dat_sg_m"] = "nēminī"
forms["dat_sg_f"] = "nēminī"
forms["acc_sg_m"] = "nēminem"
forms["acc_sg_f"] = "nēminem"
forms["abl_sg_m"] = {"nūllō", "nēmine{R}"}
forms["abl_sg_f"] = {"nūllā", "nēmine{R}"}
else
error('adjective ' .. arg1 .. ' not recognized')
end
end
local function extract_base(lemma, ending)
if ending:find("(", nil, true) then
return match(lemma, ending)
end
return match(lemma, "^(.*)" .. ending .. "$")
end
local function get_noun_subtype_by_ending(lemma, stem2, decltype, specified_subtypes,
endings_and_subtypes)
for _, ending_and_subtypes in ipairs(endings_and_subtypes) do
local ending = ending_and_subtypes[1]
local subtypes = ending_and_subtypes[2]
local not_this_subtype = false
if (
specified_subtypes.pl and not contains(subtypes, "pl") or
contains(subtypes, "both") and not specified_subtypes.both
) then
-- We now require that plurale tantum terms specify a plural-form lemma.
-- The autodetected subtypes will include 'pl' for such lemmas; if not,
-- we fail this entry. Additionally, if the rule contains 'both', it
-- must be explicitly specified to match.
not_this_subtype = true
else
for _, subtype in ipairs(subtypes) do
-- A subtype is directly canceled by specifying -SUBTYPE.
-- In addition, M or F as a subtype is canceled by N, and
-- vice-versa, but M doesn't cancel F or vice-versa; instead,
-- we simply ignore the conflicting gender specification when
-- constructing the combination of specified and inferred subtypes.
-- The reason for this is that neuters have distinct declensions
-- from masculines and feminines, but masculines and feminines have
-- the same declension, and various nouns in Latin that are
-- normally masculine are exceptionally feminine and vice-versa
-- (nauta, agricola, fraxinus, malus "apple tree", manus, rēs,
-- etc.).
--
-- In addition, sg as a subtype is canceled by pl and vice-versa.
-- It's also possible to specify both, which will override sg but
-- not cancel it (in the sense that it won't prevent the relevant
-- rule from matching). For example, there's a rule specifying that
-- lemmas beginning with a capital letter and ending in -ius take
-- the ius.voci.sg subtypes. Specifying such a lemma with the
-- subtype both will result in the ius.voci.both subtypes, whereas
-- specifying such a lemma with the subtype pl will cause this rule
-- not to match, and it will fall through to a less specific rule
-- that returns just the ius subtype, which will be combined with
-- the explicitly specified pl subtype to produce ius.pl.
if specified_subtypes["-" .. subtype] or
subtype == "N" and (specified_subtypes.M or specified_subtypes.F) or
(subtype == "M" or subtype == "F") and specified_subtypes.N or
subtype == "sg" and specified_subtypes.pl or
subtype == "pl" and specified_subtypes.sg then
not_this_subtype = true
break
end
end
end
if not not_this_subtype then
if type(ending) == "table" then
local lemma_ending = ending[1]
local stem2_ending = ending[2]
local base = extract_base(lemma, lemma_ending)
if base and base .. stem2_ending == stem2 then
return base, stem2, subtypes
end
else
local base = extract_base(lemma, ending)
if base then
return base, stem2, subtypes
end
end
end
end
if decltype then
error("Unrecognized ending for declension-" .. decltype .. " noun: " .. lemma)
end
return lemma, stem2, keys_to_list(specified_subtypes)
end
local patterns = {
{"[mM]a", "%0t"},
{"e", ""},
{"([aoAO])([lr])", "%1" .. MACRON .. "%2"},
{"[eE]l", "%0l"},
{"([mM])en", "%1in"},
{"([tT]ūd)ō", "%1in"},
{"([gG])ō", "%1in"},
{"[ōŌ]", "%1n"},
{"er", "r"},
{"[ēi]s", ""},
{"([āēīōūȳĀĒĪŌŪȲ]n)s", function(v)
return (gsub(toNFD(v), MACRON, "") .. "t")
end},
{"([cC])eps", "%1ipit"},
{"([bp])s", "%1"},
{"us", "or"},
{"s", "t"},
{"ex", "ic"},
{"x", "c"},
}
local function make_stem2(stem)
local n
for _, pattern in ipairs(patterns) do
local key = pattern[1]
stem, n = gsub(stem, key .. "$", pattern[2])
if n > 0 then
-- debug_track("la-utilities/" .. key) REVISAR
return toNFC(stem)
end
end
-- debug_track("la-utilities") REVISAR
return stem
end
local function detect_noun_subtype(lemma, stem2, typ, subtypes)
local base, _
if typ == "1" then
return get_noun_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"ām", {"F", "am"}},
{"ās", {"M", "Greek", "Ma"}},
{"ēs", {"M", "Greek", "Me"}},
{"ē", {"F", "Greek"}},
{"ae", {"F", "pl"}},
{"a", {"F"}},
})
elseif typ == "2" then
local detected_subtypes
lemma, stem2, detected_subtypes = get_noun_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"^(.*r)$", {"M", "er"}},
{"^(.*v)os$", {"M", "vos"}},
{"^(.*v)om$", {"N", "vom"}},
-- If the lemma ends in -os and the user said N or -M, then the
-- following won't apply, and the second (neuter) -os will applly.
{"os", {"M", "Greek"}},
{"os", {"N", "Greek", "us"}},
{"on", {"N", "Greek"}},
-- -ius beginning with a capital letter is assumed a proper name,
-- and takes the voci subtype (vocative in -ī) along with the ius
-- subtype and sg-only. Other nouns in -ius just take the ius
-- subtype. Explicitly specify "sg" so that if .pl is given,
-- this rule won't apply.
{"^(%u.*)ius$", {"M", "ius", "voci", "sg"}},
{"ius", {"M", "ius"}},
{"ium", {"N", "ium"}},
-- If the lemma ends in -us and the user said N or -M, then the
-- following won't apply, and the second (neuter) -us will applly.
{"us", {"M"}},
{"us", {"N", "us"}},
{"um", {"N"}},
{"iī", {"M", "ius", "pl"}},
{"ia", {"N", "ium", "pl"}},
-- If the lemma ends in -ī and the user said N or -M, then the
-- following won't apply, and the second (neuter) -ī will applly.
{"ī", {"M", "pl"}},
{"ī", {"N", "us", "pl"}},
{"oe", {"M", "Greek", "pl"}},
{"a", {"N", "pl"}},
})
stem2 = stem2 or lemma
return lemma, stem2, detected_subtypes
elseif typ == "3" then
if subtypes.pl then
if subtypes.Greek then
base = lemma:match("^(.*)erēs$")
if base then
return base .. "ēr", base .. "er", {"er"}
end
base = lemma:match("^(.*)ontēs$")
if base then
return base .. "ōn", base .. "ont", {"on"}
end
base = lemma:match("^(.*)es$")
if base then
return base, stem2 or base, {}
end
error("Unrecognized ending for declension-3 plural Greek noun: " .. lemma)
end
base = lemma:match("^(.*)ia$")
if base then
return base, stem2 or base, {"N", "I", "pure"}
end
base = lemma:match("^(.*)a$")
if base then
return base, stem2 or base, {"N"}
end
base = lemma:match("^(.*)ēs$")
if base then
return base, stem2 or base, {}
end
error("Unrecognized ending for declension-3 plural noun: " .. lemma)
end
stem2 = stem2 or make_stem2(lemma)
local detected_subtypes
if subtypes.Greek then
base, _, detected_subtypes = get_noun_subtype_by_ending(lemma, stem2, nil, subtypes, {
{{"is", ""}, {"I"}},
{"ēr", {"er"}},
{"ōn", {"on"}},
})
if base then
return lemma, stem2, detected_subtypes
end
return lemma, stem2, {}
end
if not subtypes.N then
base, _, detected_subtypes = get_noun_subtype_by_ending(lemma, stem2, nil, subtypes, {
{{"^(%u.*pol)is$", ""}, {"F", "polis", "sg", "loc"}},
{{"tūdō", "tūdin"}, {"F"}},
{{"tās", "tāt"}, {"F"}},
{{"tūs", "tūt"}, {"F"}},
{{"tiō", "tiōn"}, {"F"}},
{{"siō", "siōn"}, {"F"}},
{{"xiō", "xiōn"}, {"F"}},
{{"gō", "gin"}, {"F"}},
{{"or", "ōr"}, {"M"}},
{{"tr[iī]x", "trīc"}, {"F"}},
{{"is", ""}, {"I"}},
{{"^(%l.*)ēs$", ""}, {"I"}},
})
if base then
return lemma, stem2, detected_subtypes
end
end
base, _, detected_subtypes = get_noun_subtype_by_ending(lemma, stem2, nil, subtypes, {
{{"us", "or"}, {"N"}},
{{"us", "er"}, {"N"}},
{{"ma", "mat"}, {"N"}},
{{"men", "min"}, {"N"}},
{{"^(%u.*)e$", ""}, {"N", "sg"}},
{{"e", ""}, {"N", "I", "pure"}},
{{"al", "āl"}, {"N", "I", "pure"}},
{{"ar", "ār"}, {"N", "I", "pure"}},
})
if base then
return lemma, stem2, detected_subtypes
end
return lemma, stem2, {}
elseif typ == "4" then
if subtypes.echo or subtypes.Callisto then
base = lemma:match("^(.*)ō$")
if not base then
error("Declension-4 noun of subtype .echo or .Callisto should end in -ō: " .. lemma)
end
if subtypes.Callisto then
return base, nil, {"F", "sg"}
else
return base, nil, {"F"}
end
end
return get_noun_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"us", {"M"}},
{"ū̆", {"N"}},
{"ūs", {"M", "pl"}},
{"ua", {"N", "pl"}},
})
elseif typ == "5" then
return get_noun_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"iēs", {"F", "i"}},
{"iēs", {"F", "i", "pl"}},
{"ēs", {"F"}},
{"ēs", {"F", "pl"}},
})
elseif typ == "sgpl" then
return lemma, stem2, {}
elseif typ == "irreg" and lemma == "domus" then
-- [[domus]] auto-sets data.loc = true, but we need to know this
-- before declining the noun so we can propagate it to other segments.
return lemma, nil, {"loc"}
elseif typ == "indecl" or typ == "irreg" and (
lemma == "Deus" or match(lemma, "^[IJ]ēs[uū]s$") or
lemma == "Athōs" or lemma == "vēnum"
) then
-- Indeclinable nouns, and certain irregular nouns, set data.num = "sg",
-- but we need to know this before declining the noun so we can
-- propagate it to other segments.
return get_noun_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"", {"both"}},
{"", {"sg"}},
{"", {"pl"}},
})
elseif typ == "indecl" or typ == "irreg" then
return lemma, nil, {}
else
return nil, nil, {}
end
end
-- Given ENDINGS_AND_SUBTYPES (a list of four-tuples of ENDING, RETTYPE,
-- SUBTYPES, PROCESS_RETVAL), check each ENDING in turn against LEMMA and
-- STEM2. If it matches, return a four-tuple BASE, STEM2, RETTYPE, NEW_SUBTYPES
-- where BASE is normally the remainder of LEMMA minus the ending, STEM2 is
-- as passed in, RETTYPE is as passed in, and NEW_SUBTYPES is the same as
-- SUBTYPES minus any subtypes beginning with a hyphen. If no endings match,
-- throw an error if DECLTYPPE is non-nil, mentioning the DECLTYPE
-- (user-specified declension); but if DECLTYPE is nil, just return the tuple
-- nil, nil, nil, nil.
--
-- In order for a given entry to match, ENDING must match and also the subtypes
-- in SUBTYPES (a list) must not be incompatible with the passed-in
-- user-specified subtypes SPECIFIED_SUBTYPES (a set, i.e. a table where the
-- keys are strings and the value is always true). "Incompatible" means that
-- a given SUBTYPE is specified in either one and -SUBTYPE in the other, or
-- that "pl" is found in SPECIFIED_SUBTYPES and not in SUBTYPES.
--
-- The ending spec in ENDINGS_AND_SUBTYPES is one of the following:
--
-- 1. A simple string, e.g. "tūdō", specifying an ending.
-- 2. A regex that should match the entire lemma (it should be anchored at
-- the beginning with ^ and at the end with $), and contains a single
-- capturing group to match the base.
-- 3. A pair {SIMPLE_STRING_OR_REGEX, STEM2_ENDING} where
-- SIMPLE_STRING_OR_REGEX is one of the previous two possibilities and
-- STEM2_ENDING is a string specifying the corresponding ending that must
-- be present in STEM2. If this form is used, the combination of
-- base + STEM2_ENDING must exactly match STEM2 in order for this entry
-- to be considered a match. An example is {"is", ""}, which will match
-- lemma == "follis", stem2 == "foll", but not lemma == "lapis",
-- stem2 == "lapid".
--
-- If PROCESS_STEM2 is given and the returned STEM2 would be nil, call
-- process_stem2(BASE) to get the STEM2 to return.
local function get_adj_type_and_subtype_by_ending(lemma, stem2, decltype,
specified_subtypes, endings_and_subtypes, process_stem2)
for _, ending_and_subtypes in ipairs(endings_and_subtypes) do
local ending = ending_and_subtypes[1]
local rettype = ending_and_subtypes[2]
local subtypes = ending_and_subtypes[3]
local process_retval = ending_and_subtypes[4]
local not_this_subtype = false
if (
specified_subtypes.pl and not contains(subtypes, "pl") or
contains(subtypes, "both") and not specified_subtypes.both
) then
-- We now require that plurale tantum terms specify a plural-form lemma.
-- The autodetected subtypes will include 'pl' for such lemmas; if not,
-- we fail this entry. Additionally, if the rule contains 'both', it
-- must be explicitly specified to match.
not_this_subtype = true
else
for _, subtype in ipairs(subtypes) do
-- A subtype is directly canceled by specifying -SUBTYPE.
if specified_subtypes["-" .. subtype] then
not_this_subtype = true
break
end
-- A subtype is canceled if the user specified SUBTYPE and
-- -SUBTYPE is given in the to-be-returned subtypes.
local must_not_be_present = subtype:match("^%-(.*)$")
if must_not_be_present and specified_subtypes[must_not_be_present] then
not_this_subtype = true
break
end
end
end
if not not_this_subtype then
local base
if type(ending) == "table" then
local lemma_ending = ending[1]
local stem2_ending = ending[2]
base = extract_base(lemma, lemma_ending)
if base and base .. stem2_ending ~= stem2 then
base = nil
end
else
base = extract_base(lemma, ending)
end
if base then
-- Remove subtypes of the form -SUBTYPE from the subtypes
-- to be returned.
local new_subtypes = {}
for _, subtype in ipairs(subtypes) do
if subtype:sub(1, 1) ~= "-" then
insert(new_subtypes, subtype)
end
end
if process_retval then
base, stem2 = process_retval(base, stem2)
end
if process_stem2 then
stem2 = stem2 or process_stem2(base)
end
return base, stem2, rettype, new_subtypes
end
end
end
if not decltype then
return lemma, stem2, nil, keys_to_list(specified_subtypes)
elseif decltype == "" then
error("Unrecognized ending for adjective: " .. lemma)
else
error("Unrecognized ending for declension-" .. decltype .. " adjective: " .. lemma)
end
end
-- Autodetect the type and subtype of an adjective given all the information
-- specified by the user: lemma, stem2, declension type and specified subtypes.
-- Four values are returned: the lemma base (i.e. the stem of the lemma, as
-- required by the declension functions), the value of stem2 to pass to the
-- declension function, the declension type and the autodetected subtypes.
-- Note that this will not detect a given subtype if -SUBTYPE is specified for
-- any subtype that would be returned, or if SUBTYPE is specified and -SUBTYPE
-- is among the subtypes that would be returned (such subtypes are filtered out
-- of the returned subtypes).
local function detect_adj_type_and_subtype(lemma, stem2, typ, subtypes)
local function base_as_stem2(base, stem2)
return base, base
end
local function constant_base(baseval)
return function(base, stem2)
return baseval, nil
end
end
local function decl12_stem2(base)
return base
end
local function decl3_stem2(base)
return make_stem2(base)
end
local decl12_entries = {
{"us", "1&2+", {}},
{"a", "1&2+", {}},
{"um", "1&2+", {}},
{"ī", "1&2+", {"pl"}},
{"ae", "1&2+", {"pl"}},
{"a", "1&2+", {"pl"}},
-- Nearly all -os adjectives are greekA
{"os", "1&2+", {"greekA", "-greekE"}},
{"os", "1&2+", {"greekE", "-greekA"}},
{"ē", "1&2+", {"greekE", "-greekA"}},
{"on", "1&2+", {"greekA", "-greekE"}},
{"on", "1&2+", {"greekE", "-greekA"}},
{"^(.*er)$", "1&2+", {"er"}},
{"^(.*ur)$", "1&2+", {"er"}},
{"^(h)ic$", "1&2+", {"ic"}},
}
local decl3_entries = {
{"^(.*er)$", "3-3+", {"I"}},
{"^(.*er)$", "3-3+", {}},
{"is", "3-2+", {"I"}},
{"is", "3-2+", {}},
{"e", "3-2+", {"I"}},
{"e", "3-2+", {}},
{"^(.*[ij])or$", "3-C+", {"abl_e_i", "-abl_i_e"}},
{"^(.*[ij])or$", "3-C+", {}},
{"^(min)or$", "3-C+", {"abl_e_i", "-abl_i_e"}},
{"^(min)or$", "3-C+", {}},
{"^(.*trīx)$", "3-def+", {"trix", "abl_i_e", "-abl_e_i"}},
{"^(.*trīx)$", "3-def+", {"trix"}},
{"^(.*tor)$", "3-def+", {"tor", "abl_i_e", "-abl_e_i"}},
{"^(.*tor)$", "3-def+", {"tor"}},
-- Detect -ēs as 3-1 without auto-inferring .pl if .pl
-- not specified. If we don't do this, the later entry for
-- -ēs will auto-infer .pl whenever -ēs is specified (which
-- won't work for adjectives like quadripēs, volucripēs).
-- Essentially, for declension-3 adjectives, we require that
-- .pl is given if the lemma is plural.
--
-- Most 3-1 adjectives are i-stem (e.g. audāx) so we require -I
-- to be given with non-i-stem adjectives. The first entry below
-- will apply when -I isn't given, the second when it is given.
{"^(.*ēs)$", "3-1+", {"I", "abl_i_e", "-abl_e_i"}},
{"^(.*ēs)$", "3-1+", {"I"}},
{"^(.*ēs)$", "3-1+", {"par", "abl_i_e", "-abl_e_i"}},
{"^(.*ēs)$", "3-1+", {"par"}},
{"^(.*[ij])ōrēs$", "3-C+", {"pl"}},
{"^(min)ōrēs$", "3-C+", {"pl"}},
-- If .pl with -ēs, we don't know if the adjective is 3-1, 3-2
-- or 3-3. Since 3-2 is probably the most common, we infer it
-- (as well as the fact that these adjectives *are* in a sense
-- 3-2 since they have a distinct neuter in -(i)a. Note that
-- we have two entries here; the first one will apply unless
-- -I is given, and will infer an i-stem adjective; the second
-- one will apply otherwise (and infer a non-i-stem 3-1 adjective).
{"ēs", "3-2+", {"pl", "I"}, base_as_stem2},
{"ēs", "3-1+", {"pl", "par"}, base_as_stem2},
-- Same for neuters.
{"ia", "3-2+", {"pl", "I"}, base_as_stem2},
{"a", "3-1+", {"pl", "par"}, base_as_stem2},
-- As above for -ēs but for miscellaneous singulars.
{"", "3-1+", {"I", "abl_i_e", "-abl_e_i"}},
{"", "3-1+", {"I"}},
{"", "3-1+", {"par", "abl_i_e", "-abl_e_i"}},
{"", "3-1+", {"par"}},
}
local function get_subtypes_and_endings(typ, f)
local subtypes_and_endings = {}
for _, v in ipairs(decl3_entries) do
if f(v) then
v = deep_copy(v)
v[2] = typ
insert(subtypes_and_endings, v)
end
end
return subtypes_and_endings
end
local function compare(spec)
return spec[2] == typ
end
if typ == "+" then
local base, new_stem2, rettype, new_subtypes = get_adj_type_and_subtype_by_ending(lemma, stem2, nil, subtypes, decl12_entries, decl12_stem2)
if rettype then
return base, new_stem2, rettype, new_subtypes
else
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, decl3_entries, decl3_stem2)
end
elseif typ == "3+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, decl3_entries, decl3_stem2)
elseif typ == "1&2+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, decl12_entries, decl12_stem2)
elseif typ == "1-1+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"a", typ, {}},
{"ae", typ, {"pl"}},
})
elseif typ == "2-2+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"us", typ, {}},
{"um", typ, {}},
{"ī", typ, {"pl"}},
{"a", typ, {"pl"}},
{"os", typ, {"greek"}},
{"on", typ, {"greek"}},
{"oe", typ, {"greek", "pl"}},
})
elseif typ == "3-1+" then
-- Use the specs from `decl3_entries`, but add the two i-stem 3-2+ specs when plural-only, as they're the same when 3-1+.
local subtypes_and_endings = get_subtypes_and_endings(typ, function(spec)
local spec1, spec2 = spec[1], spec[2]
return spec2 == typ or (spec2 == "3-2+" and spec1 == "ēs" or spec1 == "ia")
end)
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, subtypes_and_endings, decl3_stem2)
elseif typ == "3-def+" then
-- Like 3-1+ but defective in gender
local subtypes_and_endings = get_subtypes_and_endings(typ, compare)
insert(subtypes_and_endings, {"", typ, {"I"}})
insert(subtypes_and_endings, {"", typ, {"par"}})
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, subtypes_and_endings, decl3_stem2)
elseif typ == "3-2+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"is", typ, {}},
{"e", typ, {}},
-- Detect -ēs as 3-2 without auto-inferring .pl if .pl
-- not specified. If we don't do this, the later entry for
-- -ēs will auto-infer .pl whenever -ēs is specified (which
-- won't work for adjectives like isoscelēs). Essentially,
-- for declension-3 adjectives, we require that .pl is given
-- if the lemma is plural.
{"ēs", typ, {}},
{"ēs", typ, {"pl"}},
{"ia", typ, {"pl"}},
}, decl3_stem2)
elseif typ == "3-3+" or typ == "3-P+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"ēs", typ, {"pl"}, base_as_stem2},
{"ia", typ, {"pl"}, base_as_stem2},
{"", typ, {}},
}, decl3_stem2)
elseif typ == "3-C+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, get_subtypes_and_endings(typ, compare), decl3_stem2)
elseif typ == "irreg+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"^(duo)$", typ, {"pl"}},
{"^(ambō)$", typ, {"pl"}},
{"^(mīll?ia)$", typ, {"N", "pl"}, constant_base("mīlle")},
-- match ea
{"^(ea)$", typ, {}, constant_base("is")},
-- match id
{"^(id)$", typ, {}, constant_base("is")},
-- match plural eī, iī
{"^([ei]ī)$", typ, {"pl"}, constant_base("is")},
-- match plural ea, eae
{"^(eae?)$", typ, {"pl"}, constant_base("is")},
-- match eadem
{"^(eadem)$", typ, {}, constant_base("īdem")},
-- match īdem, idem
{"^([īi]dem)$", typ, {}, constant_base("īdem")},
-- match plural īdem
{"^(īdem)$", typ, {"pl"}},
-- match plural eadem, eaedem
{"^(eae?dem)$", typ, {"pl"}, constant_base("īdem")},
-- match illa, ipsa, ista; it doesn't matter if we overmatch because
-- we'll get an error as we use the stem itself in the returned base
{"^(i[lps][lst])a$", typ, {}, function(base, stem2) return base .. "e", nil end},
-- match illud, istud; as above, it doesn't matter if we overmatch
{"^(i[ls][lt])ud$", typ, {}, function(base, stem2) return base .. "e", nil end},
-- match ipsum
{"^(ipsum)$", typ, {}, constant_base("ipse")},
-- match plural illī, ipsī, istī; as above, it doesn't matter if we
-- overmatch
{"^(i[lps][lst])ī$", typ, {"pl"}, function(base, stem2) return base .. "e", nil end},
-- match plural illa, illae, ipsa, ipsae, ista, istae; as above, it
-- doesn't matter if we overmatch
{"^(i[lps][lst])ae?$", typ, {"pl"}, function(base, stem2) return base .. "e", nil end},
-- Detect quī as non-plural unless .pl specified.
{"^(quī)$", typ, {}},
-- Otherwise detect quī as plural.
{"^(quī)$", typ, {"pl"}},
-- Same for quae.
{"^(quae)$", typ, {}, constant_base("quī")},
{"^(quae)$", typ, {"pl"}, constant_base("quī")},
{"^(quid)$", typ, {}, constant_base("quis")},
{"^(quod)$", typ, {}, constant_base("quī")},
{"^(qui[cd]quid)$", typ, {}, constant_base("quisquis")},
{"^(quīquī)$", typ, {"pl"}, constant_base("quisquis")},
{"^(quaequae)$", typ, {"pl"}, constant_base("quisquis")},
-- match all remaining lemmas in lemma form
{"", typ, {}},
})
elseif typ == "indecl+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"", typ, {"both"}},
{"", typ, {"sg"}},
{"", typ, {"pl"}},
})
else -- 0+
return lemma, nil, typ, {}
end
end
local noun_lb = {
nom_sg = "sg.",
gen_sg = "sg.",
dat_sg = "sg.",
acc_sg = "sg.",
abl_sg = "sg.",
voc_sg = "sg.",
loc_sg = "sg.",
nom_pl = "pl.",
gen_pl = "pl.",
dat_pl = "pl.",
acc_pl = "pl.",
abl_pl = "pl.",
voc_pl = "pl.",
loc_pl = "pl."
}
function export.sust(frame)
local title_ = mw.title.getCurrentTitle()
local title = title_.fullText
local ns = title_.namespace
if ns ~= 0 then
return "Use esta plantilla en el espacio principal."
end
local params = {
[1] = {requerido=true},
["alt"] = {},
["num"] = {por_defecto = ""},
["núm"] = {alias_de = "num"},
["nota"] = {},
}
for form,_ in pairs(noun_lb) do
params[form] = {lista=true}
end
local parent_frame = frame:getParent()
local args = require("Módulo:parámetros").obtener_parametros(parent_frame.args, params)
local tpalabras = {}
for _,p in ipairs(args) do
p = match(p, "^(.-);") or p
local a, b = match(p, "^(.-)%.(.*)$")
assert(b, "error en especificaciones de palabra")
local r1 = match(a, "^([^/]+)/")
if not r1 then
r1 = a
end
if r1 == "idem" or r1 == "īdem" then -- REVISAR: parche para idem que internamente lo declina como si fuera "i"
insert(tpalabras, "ī")
else
insert(tpalabras, r1)
end
end
local palabras, separadores = separar_palabras(title, concat(tpalabras, "-"))
local L = #palabras
local M = 1
local declinfo
local titles = {}
local cats = {}
local genero
local nosg, nopl = true, true
for _,arg in ipairs(args) do
local formas = {}
for subarg in gsplit(arg, ";") do
local types = {}
local a, b = match(subarg, "^(.-)%.(.*)$")
assert(b, "error en especificaciones de palabra")
local c, d = match(b, "^(.-)%.(.*)$")
if d then
for spec in gsplit(d, "%.") do
spec = gsub(spec, "(.)%-", "%1_")
types[spec] = true
end
end
c = c or b
local r = split(a, "/")
local r1, r2, detected_subtypes = detect_noun_subtype(r[1], r[2], c, types)
for _, subtype in ipairs(detected_subtypes) do
if types["-" .. subtype] then
-- if a "cancel subtype" spec is given, remove the cancel spec
-- and don't apply the subtype
types["-" .. subtype] = nil
elseif (subtype == "M" or subtype == "F" or subtype == "N") and
(types.M or types.F or types.N) then
-- if gender already specified, don't create conflicting gender spec
elseif (subtype == "sg" or subtype == "pl" or subtype == "both") and
(types.sg or types.pl or types.both) then
-- if number restriction already specified, don't create conflicting
-- number restriction spec
else
types[subtype] = true
end
end
if not genero then
if types.M then
genero = "m"
end
if types.N then
genero = "n"
end
if types.F then
genero = "f"
end
end
local es_adj
if not r1 and genero then
local typ
r1, r2, typ, detected_subtypes = detect_adj_type_and_subtype(r[1], r[2], c, types)
if r1 then
c = typ
es_adj = true
end
end
assert(r1, "forma no reconocida: "..r[1])
local cb = es_adj and adj_decl[c] or noun_decl[c]
assert(cb, "Especifique el tipo de sustantivo correcto en el primer parámetro")
local data = {forms={}, types=types, pos="", subtitles="", notes="", categories=cats, title=titles, loc=types.loc, num=args.num}
cb(data, {r1, r2})
if es_adj then
local forms_ = {}
for form,arr in pairs(data.forms) do
local f1, f2 = form:match("^(.*)(_"..genero..")$")
if f1 then
forms_[f1] = arr
end
end
data.forms = forms_
end
if not types.sg then
nopl = false
end
if not types.pl then
nosg = false
end
if types.sg then
for key,_ in pairs(data.forms) do
if key:find("_pl") then
data.forms[key] = {}
end
end
end
if types.pl then
for key,_ in pairs(data.forms) do
if key:find("_sg") then
data.forms[key] = {}
end
end
end
merge_forms(formas, data.forms, noun_lb)
end
if not declinfo then
declinfo = formas
else
declinfo = combinar_copulativa(declinfo, formas, separadores[M])
M = M + 1
end
end
if declinfo["loc_sg"] and #declinfo["loc_sg"] == 0 then
declinfo["loc_sg"] = nil
end
if declinfo["loc_pl"] and #declinfo["loc_pl"] == 0 then
declinfo["loc_pl"] = nil
end
if nosg == false then
nosg = find(args["num"], "p")
end
if nopl == false then
nopl = find(args["num"], "s")
end
local forms = sobreescribir_formas(declinfo, args, false, {})
comprobar_defectivo(forms, {})
forms = desactivar_formas(forms,
function (form)
return (form:find("pl$") and nopl) or (form:find("sg$") and nosg)
end
)
local raiz_nom = f(forms["nom_sg"][1] or forms["nom_pl"][1] or "?")
local raiz_gen = f(forms["gen_sg"][1] or forms["gen_pl"][1] or "?")
forms = agregar_enlaces(forms, title, normalizar_enlace)
forms = formatear_formas(forms, noun_lb)
local t = {}
insert(t, {{""}, {"Singular"}, {"Plural"}, header=true, color=COLOR_H, class="pc"})
insert(t, {{"Nominativo", header=true, color=COLOR_H}, forms["nom_sg"], forms["nom_pl"]})
insert(t, {{"Genitivo", header=true, color=COLOR_H}, forms["gen_sg"], forms["gen_pl"]})
insert(t, {{"Dativo", header=true, color=COLOR_H}, forms["dat_sg"], forms["dat_pl"]})
insert(t, {{"Acusativo", header=true, color=COLOR_H}, forms["acc_sg"], forms["acc_pl"]})
insert(t, {{"Ablativo", header=true, color=COLOR_H}, forms["abl_sg"], forms["abl_pl"]})
insert(t, {{"Vocativo", header=true, color=COLOR_H}, forms["voc_sg"], forms["voc_pl"]})
if (forms["loc_sg"] and forms["loc_sg"][1]) or (forms["loc_pl"] and forms["loc_pl"][1]) then
insert(t, {{"Locativo", header=true, color=COLOR_H}, forms["loc_sg"], forms["loc_pl"]})
end
insert(t, {{args["nota"] or "", colspan=3}})
return renderizar_tabla(
frame,
"'''Declinación de ''"..raiz_nom..", "..raiz_gen.."'''''  tipo: "..concat(titles, ", "),
t,
ns == 0 and cats or {}
)
end
local adj_lb = {
nom_sg_m = "m.",
nom_sg_n = "n.",
nom_sg_f = "f.",
nom_pl_m = "m.",
nom_pl_n = "n.",
nom_pl_f = "f.",
gen_sg_m = "m.",
gen_sg_n = "n.",
gen_sg_f = "f.",
gen_pl_m = "m.",
gen_pl_n = "n.",
gen_pl_f = "f.",
dat_sg_m = "m.",
dat_sg_n = "n.",
dat_sg_f = "f.",
dat_pl_m = "m.",
dat_pl_n = "n.",
dat_pl_f = "f.",
acc_sg_m = "m.",
acc_sg_n = "n.",
acc_sg_f = "f.",
acc_pl_m = "m.",
acc_pl_n = "n.",
acc_pl_f = "f.",
abl_sg_m = "m.",
abl_sg_n = "n.",
abl_sg_f = "f.",
abl_pl_m = "m.",
abl_pl_n = "n.",
abl_pl_f = "f.",
voc_sg_m = "m.",
voc_sg_n = "n.",
voc_sg_f = "f.",
voc_pl_m = "m.",
voc_pl_n = "n.",
voc_pl_f = "f.",
}
function export.adj(frame)
local title_ = mw.title.getCurrentTitle()
local title = title_.fullText
local ns = title_.namespace
if ns ~= 0 then
return "Use esta plantilla en el espacio principal."
end
local params = {
[1] = {requerido=true},
["alt"] = {},
["num"] = {por_defecto = ""},
["núm"] = {alias_de="num"},
["gen"] = {por_defecto="mfn"},
["nota"] = {},
}
for form,_ in pairs(adj_lb) do
params[form] = {lista=true}
end
params["dat_pl"] = {lista=true}
params["abl_pl"] = {lista=true}
params["loc_pl"] = {lista=true}
local parent_frame = frame:getParent()
local args = require("Módulo:parámetros").obtener_parametros(parent_frame.args, params)
if args["dat_pl"][1] then
args["dat_pl_m"] = deep_copy(args["dat_pl"])
args["dat_pl_n"] = deep_copy(args["dat_pl"])
args["dat_pl_f"] = deep_copy(args["dat_pl"])
end
if args["abl_pl"][1] then
args["abl_pl_m"] = deep_copy(args["abl_pl"])
args["abl_pl_n"] = deep_copy(args["abl_pl"])
args["abl_pl_f"] = deep_copy(args["abl_pl"])
end
if args["loc_pl"][1] then
args["loc_pl_m"] = deep_copy(args["loc_pl"])
args["loc_pl_n"] = deep_copy(args["loc_pl"])
args["loc_pl_f"] = deep_copy(args["loc_pl"])
end
args["dat_pl"] = nil
args["abl_pl"] = nil
args["loc_pl"] = nil
assert(not find(title, " "), "locuciones no soportadas aún") -- REVISAR
local tpalabras = {}
for _,p in ipairs(args) do
p = match(p, "^(.-);") or p
local a, b = match(p, "^(.-)%.(.*)$")
assert(b, "error en especificaciones de palabra")
local r1 = match(a, "^([^/]+)/")
if not r1 then
r1 = a
end
if r1 == "idem" or r1 == "īdem" then -- REVISAR: parche para idem que internamente lo declina como si fuera "i"
insert(tpalabras, "ī")
else
insert(tpalabras, r1)
end
end
local palabras, separadores = separar_palabras(title, concat(tpalabras, "-"))
local L = #palabras
local M = 1
local declinfo
local titles = {}
local cats = {}
local nosg, nopl = true, true
for _,arg in ipairs(args) do
local formas = {}
for subarg in gsplit(arg, ";") do
local types = {}
local a, b = match(subarg, "^(.-)%.(.*)$")
a = a or subarg
b = b or "+"
local c, d = match(b, "^(.-)%.(.*)$")
if d then
for spec in gsplit(d, "%.") do
spec = gsub(spec, "(.)%-", "%1_")
types[spec] = true
end
end
c = c or b
local r = split(a, "/")
local r1, r2, typ, detected_subtypes = detect_adj_type_and_subtype(r[1], r[2], c, types)
for _, subtype in ipairs(detected_subtypes) do
if types["-" .. subtype] then
-- if a "cancel subtype" spec is given, remove the cancel spec
-- and don't apply the subtype
types["-" .. subtype] = nil
elseif (subtype == "M" or subtype == "F" or subtype == "N") and
(types.M or types.F or types.N) then
-- if gender already specified, don't create conflicting gender spec
elseif (subtype == "sg" or subtype == "pl" or subtype == "both") and
(types.sg or types.pl or types.both) then
-- if number restriction already specified, don't create conflicting
-- number restriction spec
else
types[subtype] = true
end
end
local cb = adj_decl[typ]
assert(cb, "Especifique el tipo de sustantivo correcto en el primer parámetro")
local data = {forms={}, types=types, pos="", subtitles="", notes="", categories=cats, title=titles, loc=types.loc, num=args.num}
cb(data, {r1, r2})
local formas_ = {} -- necesario crear otro arreglo para no modificar las claves durante la iteración
for form,arr in pairs(data.forms) do
local pref = match(form, "^(.*)_m$")
if pref and not data.forms[pref.."_f"] then
formas_[pref.."_f"] = deep_copy(arr)
end
if pref and not data.forms[pref.."_n"] then
formas_[pref.."_n"] = deep_copy(arr)
end
formas_[form] = arr
end
data.forms = formas_
if not types.sg then
nopl = false
end
if not types.pl then
nosg = false
end
if types.sg then
for key,_ in pairs(data.forms) do
if key:find("_pl") then
data.forms[key] = {}
end
end
end
if types.pl then
for key,_ in pairs(data.forms) do
if key:find("_sg") then
data.forms[key] = {}
end
end
end
merge_forms(formas, data.forms, adj_lb)
end
if not declinfo then
declinfo = formas
else
declinfo = combinar_copulativa(declinfo, formas, separadores[M])
M = M + 1
end
end
if nosg == false then
nosg = find(args["num"], "p")
end
if nopl == false then
nopl = find(args["num"], "s")
end
local m = find(args["gen"], "m")
local fem = find(args["gen"], "f")
local n = find(args["gen"], "n")
local forms = sobreescribir_formas(declinfo, args, false, {}, adj_lb)
comprobar_defectivo(forms)
forms = desactivar_formas(forms,
function (form)
return (form:find("pl") and nopl) or (form:find("sg") and nosg) or (form:find("m$") and not m) or (form:find("f$") and not fem) or (form:find("n$") and not n)
end
)
local raiz_m = f(forms["nom_sg_m"][1] or forms["nom_pl_m"][1] or "?")
local raiz_f = f(forms["nom_sg_f"][1] or forms["nom_pl_f"][1] or "?")
local raiz_n = f(forms["nom_sg_n"][1] or forms["nom_pl_n"][1] or "?")
forms = agregar_enlaces(forms, title, normalizar_enlace)
forms = formatear_formas(forms, adj_lb)
local t = {}
insert(t, {{"Singular", colspan=4}, header=true, color=COLOR_H})
insert(t, {{""}, {"Masculino"}, {"Femenino"}, {"Neutro"}, header=true, color=COLOR_H, class="pc"})
insert(t, {{"Nominativo", header=true, color=COLOR_H}, forms["nom_sg_m"], forms["nom_sg_f"], forms["nom_sg_n"]})
insert(t, {{"Genitivo", header=true, color=COLOR_H}, forms["gen_sg_m"], forms["gen_sg_f"], forms["gen_sg_n"]})
insert(t, {{"Dativo", header=true, color=COLOR_H}, forms["dat_sg_m"], forms["dat_sg_f"], forms["dat_sg_n"]})
insert(t, {{"Acusativo", header=true, color=COLOR_H}, forms["acc_sg_m"], forms["acc_sg_f"], forms["acc_sg_n"]})
insert(t, {{"Ablativo", header=true, color=COLOR_H}, forms["abl_sg_m"], forms["abl_sg_f"], forms["abl_sg_n"]})
insert(t, {{"Vocativo", header=true, color=COLOR_H}, forms["voc_sg_m"], forms["voc_sg_f"], forms["voc_sg_n"]})
insert(t, {{"Plural", colspan=4, header=true, color=COLOR_H}})
insert(t, {{""}, {"Masculino"}, {"Femenino"}, {"Neutro"}, header=true, color=COLOR_H, class="pc"})
insert(t, {{"Nominativo", header=true, color=COLOR_H}, forms["nom_pl_m"], forms["nom_pl_f"], forms["nom_pl_n"]})
insert(t, {{"Genitivo", header=true, color=COLOR_H}, forms["gen_pl_m"], forms["gen_pl_f"], forms["gen_pl_n"]})
insert(t, {{"Dativo", header=true, color=COLOR_H}, forms["dat_pl_m"], forms["dat_pl_f"], forms["dat_pl_n"]})
insert(t, {{"Acusativo", header=true, color=COLOR_H}, forms["acc_pl_m"], forms["acc_pl_f"], forms["acc_pl_n"]})
insert(t, {{"Ablativo", header=true, color=COLOR_H}, forms["abl_pl_m"], forms["abl_pl_f"], forms["abl_pl_n"]})
insert(t, {{"Vocativo", header=true, color=COLOR_H}, forms["voc_pl_m"], forms["voc_pl_f"], forms["voc_pl_n"]})
insert(t, {{args["nota"] or "", colspan=4}})
return renderizar_tabla(
frame,
"'''Declinación de ''"..raiz_m..", "..raiz_f..", "..raiz_n.."'''''  tipo: "..concat(titles, ", "),
t,
ns == 0 and cats or {}
)
end
local EGO, TU, IS, NOS, VOS, EI = 1, 2, 3, 4, 5, 6
local tostr = {"1", "2", "3", "4", "5", "6"}
local PRONOMBRES = {"ego", "tū", "is, ea, id", "nōs", "vōs", "eī, eae, ea"}
local PRONOMBRES_SUBJ = {"ut ego", "ut tū", "ut is, ut ea, ut id", "ut nōs", "ut vōs", "ut eī, ut eae, ut ea"}
local PRONOMBRES_IMP = {"―", "(tū)", "(is, ea, id)", "―", "(vōs)", "(eī, eae, ea)"}
local IMPERSONALES = {"", "", "(id)", "", "", ""}
local function obtener_pronombre(forma, impers)
local conj, p = match(forma, "^(.*)(%d)$")
if not p then
return nil
end
p = tonumber(p)
if impers then
return IMPERSONALES[p]
else
if find(conj, "^subj") then
return PRONOMBRES_SUBJ[p]
end
if find(conj, "^imper") then
return PRONOMBRES_IMP[p]
end
return PRONOMBRES[p]
end
end
local sufijos = {
["1"] = {
inf_act = {"āre","isse"},
inf_pas = {"ārī"},
part_act = {"āns","ūrus"},
part_pas = {"andus","us"},
ger = {"andī","andō","andum"},
sup = {"um","ū"},
ind_pres = {"ō","ās","at","āmus","ātis","ant"},
ind_imp = {"ābam","ābās","ābat","ābāmus","ābātis","ābant"},
ind_perf = {"ī","istī","it","imus","istis","ērunt",
nil,nil,nil,nil,nil,"ēre"},
ind_pluperf = {"eram","erās","erat","erāmus","erātis","erant"},
ind_fut = {"ābō","ābis","ābit","ābimus","ābitis","ābunt"},
ind_fut_perf = {"erō","eris","erit","erimus","eritis","erint"},
ind_fut_sig = {"ō","is","it","imus","itis","int"},
ind_pres_pas = {"or","āris","ātur","āmur","āminī","antur",
nil,"āre"},
ind_imp_pas = {"ābar","ābāris","ābātur","ābāmur","ābāminī","ābantur",
nil,"ābāre"},
ind_fut_pas = {"ābor","āberis","ābitur","ābimur","ābiminī","ābuntur",
nil,"ābere"},
subj_pres = {"em","ēs","et","ēmus","ētis","ent"},
subj_imp = {"ārem","ārēs","āret","ārēmus","ārētis","ārent"},
subj_perf = {"erim","erīs","erit","erīmus","erītis","erint"},
subj_pluperf = {"issem","issēs","isset","issēmus","issētis","issent"},
subj_aor_sig = {"im","īs","īt","īmus","ītis","int"},
subj_pres_pas = {"er","ēris","ētur","ēmur","ēminī","entur",
nil,"ēre"},
subj_imp_pas = {"ārer","ārēris","ārētur","ārēmur","ārēminī","ārentur",
nil,"ārēre"},
imper_pres = {nil,"ā",nil,nil,"āte",nil},
imper_fut = {nil,"ātō","ātō",nil,"ātōte","antō"},
imper_pres_pas = {nil,"āre",nil,nil,"āminī",nil},
imper_fut_pas = {nil,"ātor","ātor",nil,nil,"antor"},
},
["2"] = {
inf_act = {"ēre","isse"},
inf_pas = {"ērī"},
part_act = {"ēns","ūrus"},
part_pas = {"endus","us"},
ger = {"endī","endō","endum"},
sup = {"um","ū"},
ind_pres = {"eō","ēs","et","ēmus","ētis","ent"},
ind_imp = {"ēbam","ēbās","ēbat","ēbāmus","ēbātis","ēbant"},
ind_perf = {"ī","istī","it","imus","istis","ērunt",
nil,nil,nil,nil,nil,"ēre"},
ind_pluperf = {"eram","erās","erat","erāmus","erātis","erant"},
ind_fut = {"ēbō","ēbis","ēbit","ēbimus","ēbitis","ēbunt"},
ind_fut_perf = {"erō","eris","erit","erimus","eritis","erint"},
ind_fut_sig = {"ō","is","it","imus","itis","int"},
ind_pres_pas = {"eor","ēris","ētur","ēmur","ēminī","entur",
nil,"ēre"},
ind_imp_pas = {"ēbar","ēbāris","ēbātur","ēbāmur","ēbāminī","ēbantur",
nil,"ēbāre"},
ind_fut_pas = {"ēbor","ēberis","ēbitur","ēbimur","ēbiminī","ēbuntur",
nil,"ēbere"},
subj_pres = {"eam","eās","eat","eāmus","eātis","eant"},
subj_imp = {"ērem","ērēs","ēret","ērēmus","ērētis","ērent"},
subj_perf = {"erim","erīs","erit","erīmus","erītis","erint"},
subj_pluperf = {"issem","issēs","isset","issēmus","issētis","issent"},
subj_aor_sig = {"im","īs","īt","īmus","ītis","int"},
subj_pres_pas = {"ear","eāris","eātur","eāmur","eāminī","eantur",
nil,"eāre"},
subj_imp_pas = {"ērer","ērēris","ērētur","ērēmur","ērēminī","ērentur",
nil,"ērēre"},
imper_pres = {nil,"ē",nil,nil,"ēte",nil},
imper_fut = {nil,"ētō","ētō",nil,"ētōte","entō"},
imper_pres_pas = {nil,"ēre",nil,nil,"ēminī",nil},
imper_fut_pas = {nil,"ētor","ētor",nil,nil,"entor"},
},
["3"] = { -- 3 (comparar [[capio]] con [[lego]], las raíces con capi- y leg- pero hay que eliminar la doble ii)
inf_act = {"ere","isse"},
inf_pas = {"ī"},
part_act = {"ēns","ūrus"},
part_pas = {"endus","us"},
ger = {"endī","endō","endum"},
sup = {"um","ū"},
ind_pres = {"ō","is","it","imus","itis","unt"},
ind_imp = {"ēbam","ēbās","ēbat","ēbāmus","ēbātis","ēbant"},
ind_perf = {"ī","istī","it","imus","istis","ērunt",
nil,nil,nil,nil,nil,"ēre"},
ind_pluperf = {"eram","erās","erat","erāmus","erātis","erant"},
ind_fut = {"am","ēs","ēt","ēmus","ētis","ent"},
ind_fut_perf = {"erō","eris","erit","erimus","eritis","erint"},
ind_fut_sig = {"ō","is","it","imus","itis","int"},
ind_pres_pas = {"or","eris","itur","imur","iminī","untur",
nil,"ere"},
ind_imp_pas = {"ēbar","ēbāris","ēbātur","ēbāmur","ēbāminī","ēbantur",
nil,"ēbāre"},
ind_fut_pas = {"ar","ēris","ētur","ēmur","ēminī","entur",
nil,"ēre"},
subj_pres = {"am","ās","at","āmus","ātis","ant"},
subj_imp = {"erem","erēs","eret","erēmus","erētis","erent"},
subj_perf = {"erim","erīs","erit","erīmus","erītis","erint"},
subj_pluperf = {"issem","issēs","isset","issēmus","issētis","issent"},
subj_aor_sig = {"im","īs","īt","īmus","ītis","int"},
subj_pres_pas = {"ar","āris","ātur","āmur","āminī","antur",
nil,"āre"},
subj_imp_pas = {"erer","erēris","erētur","erēmur","erēminī","erentur",
nil,"erēre"},
imper_pres = {nil,"e",nil,nil,"ite",nil},
imper_fut = {nil,"itō","itō",nil,"itōte","untō"},
imper_pres_pas = {nil,"ere",nil,nil,"iminī",nil},
imper_fut_pas = {nil,"itor","itor",nil,nil,"untor"},
},
["3/4"] = {
inf_act = {"ere","isse","īre","isse"},
inf_pas = {"ī","īrī"},
part_act = {"ēns","iēns","ūrus"},
part_pas = {"endus","iendus","us"},
ger = {"endī","endō","endum","iendī","iendō","iendum"},
sup = {"um","ū"},
ind_pres = {"ō","is","it","imus","itis","unt",
"iō","īs",nil,"īmus","ītis","iunt"
},
ind_imp = {"ēbam","ēbās","ēbat","ēbāmus","ēbātis","ēbant",
"iēbam","iēbās","iēbat","iēbāmus","iēbātis","iēbant"
},
ind_perf = {"ī","istī","it","imus","istis","ērunt",
nil,nil,nil,nil,nil,"ēre"},
ind_pluperf = {"eram","erās","erat","erāmus","erātis","erant"},
ind_fut = {"am","ēs","ēt","ēmus","ētis","ent",
"iam","iēs","iet","iēmus","iētis","ient"
},
ind_fut_perf = {"erō","eris","erit","erimus","eritis","erint"},
ind_fut_sig = {"ō","is","it","imus","itis","int"},
ind_pres_pas = {"or","eris","itur","imur","iminī","untur",
"ior","ere","ītur","īmur","īminī","iuntur",
nil,"īris",nil,nil,nil,nil,
nil,"īre"
},
ind_imp_pas = {"ēbar","ēbāris","ēbātur","ēbāmur","ēbāminī","ēbantur",
"iēbar","ēbāre","iēbātur","iēbāmur","iēbāminī","iēbantur",
nil,"iēbāris",nil,nil,nil,nil,
nil,"iēbāre"
},
ind_fut_pas = {"ar","ēris","ētur","ēmur","ēminī","entur",
"iar","ēre","iētur","iēmur","iēminī","ientur",
nil,"iēris",nil,nil,nil,nil,
nil,"iēre"
},
subj_pres = {"am","ās","at","āmus","ātis","ant",
"iam","iās","iat","iāmus","iātis","iant",
},
subj_imp = {"erem","erēs","eret","erēmus","erētis","erent",
"īrem","īrēs","īret","īrēmus","īrētis","īrent"
},
subj_perf = {"erim","erīs","erit","erīmus","erītis","erint"},
subj_pluperf = {"issem","issēs","isset","issēmus","issētis","issent"},
subj_aor_sig = {"im","īs","īt","īmus","ītis","int"},
subj_pres_pas = {"ar","āris","ātur","āmur","āminī","antur",
"iar","āre","iātur","iāmur","iāminī","iantur",
nil,"iāris",nil,nil,nil,nil,
nil,"iāre"
},
subj_imp_pas = {"erer","erēris","erētur","erēmur","erēminī","erentur",
"īrer","erēre","īrētur","īrēmur","īrēminī","īrentur",
nil,"īrēris",nil,nil,nil,nil,
nil,"īrēre"
},
imper_pres = {nil,"e",nil,nil,"ite",nil,
nil,"ī",nil,nil,"īte",nil
},
imper_fut = {nil,"itō","itō",nil,"itōte","untō",
nil,"ītō","ītō",nil,"ītōte","iuntō"
},
imper_pres_pas = {nil,"ere",nil,nil,"iminī",nil,
nil,"īre",nil,nil,"īminī",nil
},
imper_fut_pas = {nil,"itor","itor",nil,nil,"untor",
nil,"ītor","ītor",nil,nil,"iuntor"
},
},
["4"] = {
inf_act = {"īre","isse"},
inf_pas = {"īrī"},
part_act = {"iēns","ūrus"},
part_pas = {"iendus","us"},
ger = {"iendī","iendō","iendum"},
sup = {"um","ū"},
ind_pres = {"iō","īs","it","īmus","ītis","iunt"},
ind_imp = {"iēbam","iēbās","iēbat","iēbāmus","iēbātis","iēbant"},
ind_perf = {"ī","istī","it","imus","istis","ērunt",
nil,nil,nil,nil,nil,"ēre"},
ind_pluperf = {"eram","erās","erat","erāmus","erātis","erant"},
ind_fut = {"iam","iēs","iet","iēmus","iētis","ient"},
ind_fut_perf = {"erō","eris","erit","erimus","eritis","erint"},
ind_fut_sig = {"ō","is","it","imus","itis","int"},
ind_pres_pas = {"ior","īris","ītur","īmur","īminī","iuntur",
nil,"īre"},
ind_imp_pas = {"iēbar","iēbāris","iēbātur","iēbāmur","iēbāminī","iēbantur",
nil,"iēbāre"},
ind_fut_pas = {"iar","iēris","iētur","iēmur","iēminī","ientur",
nil,"iēre"},
subj_pres = {"iam","iās","iat","iāmus","iātis","iant"},
subj_imp = {"īrem","īrēs","īret","īrēmus","īrētis","īrent"},
subj_perf = {"erim","erīs","erit","erīmus","erītis","erint"},
subj_pluperf = {"issem","issēs","isset","issēmus","issētis","issent"},
subj_aor_sig = {"im","īs","īt","īmus","ītis","int"},
subj_pres_pas = {"iar","iāris","iātur","iāmur","iāminī","iantur",
nil,"iāre"},
subj_imp_pas = {"īrer","īrēris","īrētur","īrēmur","īrēminī","īrentur",
nil,"īrēre"},
imper_pres = {nil,"ī",nil,nil,"īte",nil},
imper_fut = {nil,"ītō","ītō",nil,"ītōte","iuntō"},
imper_pres_pas = {nil,"īre",nil,nil,"īminī",nil},
imper_fut_pas = {nil,"ītor","ītor",nil,nil,"iuntor"},
}
}
local formas_no_personales = {
inf_act = true,
inf_pas = true,
part_act = true,
part_pas = true,
ger = true,
sup = true,
}
local formas_personales = {
ind_pres = true,
ind_imp = true,
ind_perf = true,
ind_pluperf = true,
ind_fut = true,
ind_fut_perf = true,
ind_fut_sig = true,
ind_pres_pas = true,
ind_imp_pas = true,
ind_fut_pas = true,
subj_pres = true,
subj_imp = true,
subj_perf = true,
subj_pluperf = true,
subj_aor_sig = true,
subj_pres_pas = true,
subj_imp_pas = true,
imper_pres = true,
imper_fut = true,
imper_pres_pas = true,
imper_fut_pas = true,
}
local formas = merge(formas_no_personales, formas_personales)
local verbos_irregulares = {
{"aiō", {"aiō", "aiiō", "aijō", "ajō"}, {
desactivar = {"inf_pas","part_pas","ger","sup","ind_pluperf","ind_fut","ind_fut_perf",
"ind_pres_pas","ind_imp_pas","ind_fut_pas","subj_perf","subj_pluperf","subj_pres_pas",
"subj_imp_pas","imper_fut","imper_pres_pas","imper_fut_pas"
},
conj = "3",
nucleopres = {"ai"},
nucleoperf = {"a"},
nucleosup = {},
nucleosigm = {},
inf_act = {"aiere"},
ind_pres = {nil,nil,nil,{}},
ind_perf = {{},nil,nil,{},{}},
subj_pres = {nil,nil,nil,{},{}},
subj_imp = {{},{},nil,{},{},{}},
imper_pres = {{},{"ai"},{},{},{},{}},
}},
{"cedo", {"cedo"}, {
desactivar = {"inf_act","inf_pas","part_act","part_pas","ger","sup","ind_pluperf","ind_pres","ind_imp","ind_perf",
"ind_fut","ind_fut_perf","ind_pres_pas","ind_imp_pas","ind_fut_pas","subj_pres","subj_imp","subj_perf",
"subj_pluperf","subj_pres_pas","subj_imp_pas","imper_fut","imper_pres_pas","imper_fut_pas"
},
conj = "3",
nucleopres = {},
nucleoperf = {},
nucleosup = {},
nucleosigm = {},
imper_pres = {nil,{"cedo"},nil,nil,{"cette","cedile"},nil},
}},
{"dīcō", {"dīcō"}, {
conj = "3",
nucleopres = {"dīc"},
nucleoperf = {"dīx"},
nucleosup = {"dict"},
nucleosigm = {"dīx"},
desactivar = {},
imper_pres = {nil, {"dīc", "dīce"}},
inf_pas = {"dīcī", "dīcier{L}"},
}},
{"dō", {"dō"}, {
conj = "1",
nucleopres = {"d"},
nucleoperf = {"ded"},
nucleosup = {"dat"},
nucleosigm = {},
desactivar = {},
inf_act = {"dare","dedisse"},
inf_pas = {"darī"},
ind_pres = {nil,nil,nil,{"damus"},{"datis"},nil},
ind_imp = {{"dabam"},{"dabās"},{"dabat"},{"dabāmus"},{"dabātis"},{"dabant"}},
ind_fut = {{"dabō"},{"dabis"},{"dabit"},{"dabimus"},{"dabitis"},{"dabunt"}},
ind_imp_pas = {{"dabar"},{"dabāris","dabāre"},{"dabātur"},{"dabāmur"},{"dabāminī"},{"dabantur"}},
ind_fut_pas = {{"dabor"},{"daberis","dabere"},{"dabitur"},{"dabimur"},{"dabiminī"},{"dabuntur"}},
subj_imp = {{"darem"},{"darēs"},{"daret"},{"darēmus"},{"darētis"},{"darent"}},
subj_imp_pas = {{"darer"},{"darēris","darēre"},{"darētur"},{"darēmur"},{"darēminī"},{"darentur"}},
imper_pres = {nil,nil,nil,nil,{"date"},nil},
imper_fut = {nil,{"datō"},{"datō"},nil,{"datōte"},{"dantō"}},
imper_pres_pas = {nil,{"dare"},nil,nil,{"daminī"},nil},
imper_fut_pas = {nil,{"dator"},{"dator"},nil,nil,{"dator"}},
}},
{"dūcō", {"dūcō"}, {
conj = "3",
nucleopres = {"dūc"},
nucleoperf = {"dūx"},
nucleosup = {"duct"},
nucleosigm = {},
desactivar = {},
imper_pres = {nil, {"dūc", "dūce"}},
}},
{"edō", {"edō", "ëdō"}, {
conj = "3",
nucleopres = {"ed"},
nucleoperf = {"ed"},
nucleosup = {""},
nucleosigm = {},
desactivar = {},
inf_act = {"edere","ēsse"},
part_act = {"edēns","ēsūrus","ēssūrus","ēstūrus"},
part_pas = {"edendus","edundus","ēsus","ēssus","ēstus"},
sup = {"ēsum","ēssum","ēstum","ēsū","ēssū","ēstū"},
ind_pres = {nil,{"edis","ēs"},{"edit","ēst"},nil,{"editis","ēstis"},nil},
ind_pres_pas = {nil,{"ederis","edere","ēssis","ēsse"},{"editur","ēstur"}},
subj_pres = {{"edam","edim"},{"edās","edīs"},{"edat","edit","ēst"},{"edāmus","edīmus"},{"edātis","edītis"},{"edant","edint"}},
subj_imp = {{"ederem","ēssem"},{"ederēs","ēssēs"},{"ederet","ēsset"},{"ederēmus","ēssēmus"},{"ederētis","ēssētis"},{"ederent","ēssent"}},
subj_imp_pas = {{"ederer","ēsser"},{"ederēris","ederēre","ēssēris","ēssēre"},{"ederetur","ēssetur"},{"ederēmur","ēssēmur"},{"ederēminī","ēssēminī"},{"ederentur","ēssentur"}},
imper_pres = {nil,{"ede","ēs"},nil,nil,{"edite","ēste"},nil},
imper_fut = {nil,{"editō","ēstō"},{"editō","ēstō"},nil,{"editōte","ēstōte"},{"eduntō"}},
imper_pres_pas = {nil,{"edere","ēsse"},nil,nil,{"ediminī"},nil},
imper_fut_pas = {nil,{"editor","ēstor"},{"editor","ēstor"},nil,nil,{"eduntor"}},
}},
{"eō", {"eō", "ëō"}, {
conj = "4",
nucleopres = {""},
nucleoperf = {""},
nucleosup = {""},
nucleosigm = {},
desactivar = {"imper_pres_pas"},
inf_act = {"īre","īsse","iisse","īvisse"},
inf_pas = {"īrī","īrier"},
part_act = {"iēns","itūrus"},
part_pas = {"eundum","itum"},
ger = {"eundī","eundō","eundum"},
sup = {"itum","itū"},
ind_pres = {{"eō"},{"īs"},{"it"},{"īmus"},{"ītis"},{"eunt"}},
ind_imp = {{"ībam"},{"ībās"},{"ībat"},{"ībāmus"},{"ībātis"},{"ībant"}},
ind_perf = {{"iī","īvī"},{"īstī","iistī","īvistī"},{"iit","īvit"},{"iimus","īvimus"},{"īstis","iistis","īvistis"},{"iērunt","iēre","īvērunt","īvēre"}},
ind_pluperf = {{"ieram","īveram"},{"ierās","īverās"},{"ierat","īverat"},{"ierāmus","īverāmus"},{"ierātis","īverātis"},{"ierant","īverant"}},
ind_fut = {{"ībō"},{"ībis"},{"ībit"},{"ībimus"},{"ībitis"},{"ībunt"}},
ind_fut_perf = {{"ierō","īverō"},{"ieris","īveris"},{"ierit","īverit"},{"ierimus","īverimus"},{"ieritis","īveritis"},{"ierint","īverint"}},
ind_fut_sig = {nil,nil,nil,nil,nil,nil},
ind_pres_pas = {{},{},{"ītur"},{},{},{}},
ind_imp_pas = {{},{},{"ībātur"},{},{},{}},
ind_fut_pas = {{},{},{"ībitur"},{},{},{}},
subj_pres = {{"eam"},{"eās"},{"eat"},{"eāmus"},{"eātis"},{"eant"}},
subj_imp = {{"īrem"},{"īrēs"},{"īret"},{"īrēmus"},{"īrētis"},{"īrent"}},
subj_perf = {{"ierim","īverim"},{"ierīs","īverīs"},{"ierit","īverit"},{"ierīmus","īverīmus"},{"ierītis","īverītis"},{"ierint","īverint"}},
subj_pluperf = {{"īssem","iissem","īvissem"},{"īssēs","iissēs","īvissēs"},{"īsset","iisset","īvisset"},{"īssēmus","iissēmus","īvissēmus"},{"īssētis","iissētis","īvissētis"},{"īssent","iissent","īvissent"}},
subj_aor_sig = {nil,nil,nil,nil,nil,nil},
subj_pres_pas = {{},{},{"eātur"},{},{},{}},
subj_imp_pas = {{},{},{"īrētur"},{},{},{}},
imper_pres = {nil,nil,nil,nil,nil,nil},
imper_fut = {nil,nil,nil,nil,nil,{"euntō"}},
imper_fut_pas = {nil,{},nil,nil,nil,{}},
}},
{"faciō", {"faciō"}, {
conj = "3",
nucleopres = {"faci"},
nucleoperf = {"fax"},
nucleosup = {"fact"},
nucleosigm = {"fax","faxs","facs"},
desactivar = {},
ind_pres_pas = {{"fīō"},{"fīs"},{"fit"},{"fīmus"},{"fītis"},{"fīunt"}},
ind_imp_pas = {{"fīēbam"},{"fīēbās"},{"fīēbat"},{"fīēbāmus"},{"fīēbātis"},{"fīēbant"}},
ind_fut_pas = {{"fīam"},{"fīēs"},{"fīet"},{"fīēmus"},{"fīētis"},{"fīent"}},
subj_pres_pas = {{"fīam"},{"fīās"},{"fīat"},{"fīāmus"},{"fīātis"},{"fīant"}},
subj_imp_pas = {{"fierem"},{"fierēs"},{"fieret"},{"fierēmus"},{"fierētis"},{"fierent"}},
imper_pres = {nil,{"fac","face"},nil,nil,nil,nil},
imper_pres_pas = {nil,{"fī"},nil,nil,{"fīte"},nil},
imper_fut_pas = {nil,{"fītō"},{"fītō"},nil,{"fītōte"},{"fīuntō"}},
}},
{"ferō", {"ferō"}, {
conj = "3",
nucleopres = {"fer"},
nucleoperf = {"tul"},
nucleosup = {"lāt"},
nucleosigm = {},
desactivar = {},
inf_act = {"ferre", "tulisse", "tetulisse{†}"},
inf_pas = {"ferrī"},
ind_pres = {nil,{"fers"},{"fert"},nil,{"fertis"}},
ind_pres_pas = {nil,{"ferris","ferre"}},
subj_imp = {{"ferrem"},{"ferrēs"},{"ferret"},{"ferrēmus"},{"ferrētis"},{"ferrent"}},
subj_imp_pas = {{"ferrer"},{"ferrēris","ferrēre"},{"ferrētur"},{"ferrēmur"},{"ferrēminī"},{"ferrentur"}},
imper_pres = {nil,{"fer"},nil,nil,{"ferte"},nil},
imper_pres_pas = {nil,{"ferre"},nil,nil,nil,nil},
imper_fut = {nil,{"fertō"},{"fertō"},nil,{"fertōte"},{"feruntō"}},
imper_fut_pas = {nil,{"fertor"},{"fertor"},nil,nil,nil},
}},
{"fīō", {"fīō"}, {
conj = "3",
nucleopres = {"fī"},
nucleoperf = {},
nucleosup = {"fact"},
nucleosigm = {},
semidep = true,
desactivar = {},
ind_pres = {{"fīō"},{"fīs"},{"fit"},{"fīmus"},{"fītis"},{"fīunt"}},
imper_pres = {nil,{"fī"},nil,nil,{"fīte"},nil},
imper_fut = {nil,{"fītō"},{"fītō"},nil,{"fītōte"},{"feruntō"}},
}},
{"inquam", {"inquam"}, {
conj = "3",
nucleopres = {"inqui"},
nucleoperf = {},
nucleosup = {},
nucleosigm = {},
nopasivo = true,
desactivar = {"inf_act","inf_pas","part_pas","ger"},
ind_pres = {{"inquam"}},
}},
{"possum", {"possum"}, {
conj = "3",
nucleopres = {"pot"},
nucleoperf = {"pot"},
nucleosup = {},
nucleosigm = {},
pres = "possō",
desactivar = {"inf_pas","part_pas","ger","sup","ind_pres_pas","ind_imp_pas","ind_fut_pas",
"subj_pres_pas","subj_imp_pas","imper_pres","imper_fut","imper_pres_pas","imper_fut_pas"},
inf_act = {"posse","potesse{†}"},
part_act = {"potēns"},
ind_pres = {{"possum"},{"potes"},{"potest"},{"possumus"},{"potestis"},{"possunt"}},
ind_imp = {{"poteram"},{"poterās"},{"poterat"},{"poterāmus"},{"poterātis"},{"poterant"}},
ind_fut = {{"poterō"},{"poteris","potere"},{"poterit"},{"poterimus"},{"poteritis"},{"poterunt"}},
ind_perf = {{"potuī"},{"potuistī"},{"potuit"},{"potuimus"},{"potuistis"},{"potuērunt","potuēre"}},
ind_pluperf = {{"potueram"},{"potuerās"},{"potuerat"},{"potuerāmus"},{"potuerātis"},{"potuerant"}},
ind_fut_perf = {{"potuerō"},{"potueris"},{"potuerit"},{"potuerimus"},{"potueritis"},{"potuerunt"}},
subj_pres = {{"possem"},{"possēs"},{"possēt"},{"possēmus"},{"possētis"},{"possent"}},
subj_imp = {{"possim"},{"possīs"},{"possit"},{"possīmus"},{"possītis"},{"possint"}},
subj_perf = {{"potuerim"},{"potuerīs"},{"potuerit"},{"potuerīmus"},{"potuerītis"},{"potuerint"}},
subj_pluperf = {{"potuissem"},{"potuissēs"},{"potuisset"},{"potuissēmus"},{"potuissētis"},{"potuissent"}},
}},
{"sum", {"sum"}, {
conj = "3",
nucleopres = {"s"},
nucleoperf = {"fu"},
nucleosup = {},
nucleosigm = {},
pres = "sō",
desactivar = {"inf_pas","part_pas","ger","sup","ind_pres_pas","ind_imp_pas","ind_fut_pas",
"subj_pres_pas","subj_imp_pas","imper_pres_pas","imper_fut_pas"},
inf_act = {"esse"},
part_act = {"futūrus"},
ind_pres = {{"sum"},{"es"},{"est"},{"sumus"},{"estis"},{"sunt"}},
ind_imp = {{"eram"},{"erās"},{"erat"},{"erāmus"},{"erātis"},{"erant"}},
ind_fut = {{"erō"},{"eris","ere"},{"erit"},{"erimus"},{"eritis"},{"erunt"}},
subj_pres = {{"sim","siem","fuam{†}"},{"sīs","siēs","fuās{†}"},{"sit","siet","fuat{†}"},{"sīmus","siēmus","fuāmus{†}"},{"sītis","siētis","fuātis{†}"},{"sint","sient","fuant{†}"}},
subj_imp = {{"essem","forem"},{"essēs","forēs"},{"esset","foret"},{"essēmus","forēmus"},{"essētis","forētis"},{"essent","forent"}},
imper_pres = {nil,{"es"},nil,nil,{"este"},nil},
imper_fut = {nil,{"estō"},{"estō"},nil,{"estōte"},nil},
}},
{"mālō", {"mālō"}, {
conj = "3",
nucleopres = {"māl"},
nucleoperf = {"mālu"},
nucleosup = {},
nucleosigm = {},
desactivar = {"sup","ger","inf_pas","part_pas","ind_pres_pas","ind_imp_pas","ind_fut_pas","subj_pres_pas","subj_imp_pas",
"imper_pres","imper_fut","imper_pres_pas","imper_fut_pas"},
inf_act = {"mālle","māluisse"},
ind_pres = {{"mālō"},{"māvīs"},{"māvult"},{"mālumus"},{"māvultis"},{"mālunt"}},
subj_pres = {{"mālim"},{"mālīs"},{"mālit"},{"mālīmus"},{"mālītis"},{"mālint"}},
subj_imp = {{"māllem"},{"māllēs"},{"māllet"},{"māllēmus"},{"māllētis"},{"māllent"}},
}},
{"nōlō", {"nōlō"}, {
conj = "3",
nucleopres = {"nōl"},
nucleoperf = {"nōlu"},
nucleosup = {},
nucleosigm = {},
desactivar = {"sup","ger","inf_pas","part_pas","ind_pres_pas","ind_imp_pas","ind_fut_pas","subj_pres_pas","subj_imp_pas",
"imper_pres","imper_fut","imper_pres_pas","imper_fut_pas"},
inf_act = {"nōlle","nōluisse"},
ind_pres = {{"nōlō"},{"nōn vīs","nevīs{†}"},{"nōn vult","nōn volt","nevolt{†}"},{"nōlumus"},{"nōn vultis","nōn voltis","nōltis{†}"},{"nōlunt"}},
subj_pres = {{"nōlim"},{"nōlīs"},{"nōlit"},{"nōlīmus"},{"nōlītis"},{"nōlint"}},
subj_imp = {{"nōllem"},{"nōllēs"},{"nōllet"},{"nōllēmus"},{"nōllētis"},{"nōllent"}},
}},
{"volō", {"volō"}, {
conj = "3",
nucleopres = {"vol"},
nucleoperf = {"volu"},
nucleosup = {"volit"},
nucleosigm = {},
desactivar = {"sup","ger","inf_pas","part_pas","ind_pres_pas","ind_imp_pas","ind_fut_pas","subj_pres_pas","subj_imp_pas",
"imper_pres","imper_fut","imper_pres_pas","imper_fut_pas"},
inf_act = {"velle","voluisse"},
ind_pres = {{"volō"},{"vīs"},{"vult","volt{†}"},{"volumus"},{"vultis","voltis{†}"},{"volunt"}},
subj_pres = {{"velim","volim{†}"},{"velīs","volīs{†}"},{"velit","volit{†}"},{"velīmus","volīmus{†}"},{"velītis","volītis{†}"},{"velint","volint{†}"}},
subj_imp = {{"vellem"},{"vellēs"},{"vellet"},{"vellēmus"},{"vellētis"},{"vellent"}},
}},
}
local function combinar_prefijo_nucleosufijo(prefijo, nucleosufijo)
return prefijo..nucleosufijo
end
local function combinar_nucleo_sufijo(nucleo, sufijo, agregar_i)
if agregar_i and (not find(sufijo, "^[iī]")) and (sufijo ~= "e") and (not find(sufijo, "^er")) then
return nucleo.."~i~"..sufijo
end
return nucleo..sufijo
end
local function agregar_forma(conjugado, conjinfo, forma)
conjinfo[forma] = conjinfo[forma] or {}
local sufijos_ = sufijos[conjinfo.conj][forma]
local nucleos
local prefijo
if forma == "sup" then
nucleos = conjinfo.nucleosup
prefijo = conjinfo.prefijosup or conjinfo.prefijo
elseif find(forma, "sig") then
nucleos = conjinfo.nucleosigm
prefijo = conjinfo.prefijosigm or conjinfo.prefijo
elseif find(forma, "perf") then
nucleos = conjinfo.nucleoperf
prefijo = conjinfo.prefijoperf or conjinfo.prefijo
else
nucleos = conjinfo.nucleopres
prefijo = conjinfo.prefijo
end
if formas_no_personales[forma] then
if conjinfo[forma][1] then
if nucleos and #nucleos > 0 then
for _, fm in ipairs(conjinfo[forma]) do
insert_if_not(conjugado[forma], "#"..combinar_prefijo_nucleosufijo(prefijo, fm).."#")
end
end
else
for _, sufijo in ipairs(sufijos_) do
local nucleos_ = nucleos
if forma == "inf_act" and sufijo == "isse" then
nucleos_ = conjinfo.nucleoperf
elseif forma == "part_act" and sufijo == "ūrus" then
nucleos_ = conjinfo.nucleosup
elseif forma == "part_pas" and sufijo == "us" then
nucleos_ = conjinfo.nucleosup
end
local agregar_i = conjinfo.I and nucleos_ == conjinfo.nucleopres
for _,nucleo in ipairs(nucleos_) do
insert_if_not(conjugado[forma], combinar_prefijo_nucleosufijo(prefijo, combinar_nucleo_sufijo(nucleo, sufijo, agregar_i)))
end
end
end
return
end
for i = EGO, EI do
local p = tostr[i]
if conjinfo[forma][i] then
if nucleos and #nucleos > 0 then
for _, fm in ipairs(conjinfo[forma][i]) do
insert_if_not(conjugado[forma..p], "#"..combinar_prefijo_nucleosufijo(prefijo, fm).."#")
end
end
else
local k = i
while sufijos_[k] do
local agregar_i = conjinfo.I and nucleos == conjinfo.nucleopres
for j, n in ipairs(nucleos) do
local x = combinar_prefijo_nucleosufijo(prefijo, combinar_nucleo_sufijo(n, sufijos_[k], agregar_i))
if conjinfo.always_sync_perf and (forma == "ind_perf" or forma == "ind_pluperf" or forma == "ind_fut_perf" or forma == "subj_perf" or forma == "subj_pluperf") then
x = x:gsub("īvī", "iī")
x = x:gsub("īvi", "ī")
x = x:gsub("īve", "ī")
x = x:gsub("īvē", "ē")
end
insert_if_not(conjugado[forma..p], x)
end
k = k + 6
end
end
end
end
local function get_subtype_by_ending(pres, conjinfo, specs)
for _, spec in ipairs(specs) do
local base = extract_base(pres, spec[1])
if base then
for _,s in ipairs(spec[2]) do
if conjinfo[s] == nil then
conjinfo[s] = true
end
end
return base
end
end
error("Unrecognized ending for conjugation " .. conjinfo["conj"])
end
local function detect_v_type_and_subtypes(conjinfo)
local pres = conjinfo["v"]
local conj_arg = conjinfo["conj"]
pres = toNFC(pres)
local base_conj_arg, auto_perf_supine = conj_arg:match("^([124]/?4?)(%+%+?)$")
if base_conj_arg then
if auto_perf_supine == "++" and base_conj_arg ~= "4" then
error("Conjugation types 1++ and 2++ not allowed")
end
conj_arg = base_conj_arg
end
conjinfo.conj = conj_arg
if conj_arg == "1" then
local base = get_subtype_by_ending(pres, conjinfo, {
{"ō", {}},
{"or", {"dep"}},
{"at", {"impers"}},
{"ātur", {"dep", "impers"}},
{"ī", {"nopres"}},
{"it", {"nopres", "impers"}},
})
if not conjinfo["nucleopres"][1] then
conjinfo["nucleopres"][1] = base
end
if auto_perf_supine then
if not conjinfo["nucleoperf"][1] then
conjinfo["nucleoperf"][1] = base .. "āv"
end
if not conjinfo["nucleosup"][1] then
conjinfo["nucleosup"][1] = base .. "āt"
end
end
if conjinfo.sigm then
if not conjinfo["nucleosigm"][1] then
conjinfo["nucleosigm"][1] = base .. "āss"
end
end
elseif conj_arg == "2" then
local base = get_subtype_by_ending(pres, conjinfo, {
{"eō", {}},
{"eor", {"dep"}},
{"et", {"impers"}},
{"ētur", {"dep", "impers"}},
{"ī", {"nopres"}},
{"it", {"nopres", "impers"}},
})
if not conjinfo["nucleopres"][1] then
conjinfo["nucleopres"][1] = base
end
if auto_perf_supine then
if not conjinfo["nucleoperf"][1] then
conjinfo["nucleoperf"][1] = base .. "u"
end
if not conjinfo["nucleosup"][1] then
conjinfo["nucleosup"][1] = base .. "it"
end
end
if conjinfo.sigm then
if not conjinfo["nucleosigm"][1] then
conjinfo["nucleosigm"][1] = base .. "ēss"
end
end
elseif conj_arg == "3" then
local base
if conjinfo.I == false then -- si explícitamente se indicó que no es del tipo -io, hay que excluir sufijos
base = get_subtype_by_ending(pres, conjinfo, {
{"ō", {}},
{"or", {"dep"}},
{"it", {"impers"}},
{"itur", {"dep", "impers"}},
{"ī", {"nopres"}},
})
else
base = get_subtype_by_ending(pres, conjinfo, {
{"iō", {"I"}},
{"ior", {"dep", "I"}},
{"ō", {}},
{"or", {"dep"}},
{"it", {"impers"}},
{"itur", {"dep", "impers"}},
{"ī", {"nopres"}},
})
end
if not conjinfo["nucleopres"][1] then
conjinfo["nucleopres"][1] = base
end
if not conjinfo["nucleoperf"][1] and conjinfo["nopres"] then
conjinfo["nucleoperf"][1] = base
end
assert(conjinfo["nucleoperf"][1], "especifique todos los núcleos para verbos de la tercera conjugación")
assert(conjinfo["nucleosup"][1], "especifique todos los núcleos para verbos de la tercera conjugación")
if conjinfo.sigm then
if not conjinfo["nucleosigm"][1] then
conjinfo["nucleosigm"][1] = base .. "ēss"
end
end
elseif conj_arg == "3/4" then
local base
base = get_subtype_by_ending(pres, conjinfo, {
{"iō", {"I"}},
{"ior", {"dep", "I"}},
})
if not conjinfo["nucleopres"][1] then
conjinfo["nucleopres"][1] = base
end
if not conjinfo["nucleoperf"][1] and conjinfo["nopres"] then
conjinfo["nucleoperf"][1] = base
end
if not conjinfo["nucleoperf"][1] and auto_perf_supine == "++" then
conjinfo["nucleoperf"][1] = base .. "īv"
conjinfo["nucleoperf"][2] = base .. "i"
end
if not conjinfo["nucleoperf"][1] and auto_perf_supine == "+" then
conjinfo["nucleoperf"][1] = base .. "īv"
end
if not conjinfo["nucleosup"][1] and auto_perf_supine then
conjinfo["nucleosup"][1] = base .. "īt"
end
if conjinfo.sigm then
if not conjinfo["nucleosigm"][1] then
conjinfo["nucleosigm"][1] = base .. "īss"
end
end
elseif conj_arg == "4" then
local base = get_subtype_by_ending(pres, conjinfo, {
{"iō", {}},
{"ior", {"dep"}},
{"it", {"impers"}},
{"ītur", {"dep", "impers"}},
{"ī", {"nopres"}},
})
if not conjinfo["nucleopres"][1] then
conjinfo["nucleopres"][1] = base
end
if not conjinfo["nucleoperf"][1] and conjinfo["nopres"] then
conjinfo["nucleoperf"][1] = base
end
if not conjinfo["nucleoperf"][1] and auto_perf_supine == "++" then
conjinfo["nucleoperf"][1] = base .. "īv"
conjinfo["nucleoperf"][2] = base .. "i"
end
if not conjinfo["nucleoperf"][1] and auto_perf_supine == "+" then
conjinfo["nucleoperf"][1] = base .. "īv"
end
if not conjinfo["nucleosup"][1] and auto_perf_supine then
conjinfo["nucleosup"][1] = base .. "īt"
end
if conjinfo.sigm then
if not conjinfo["nucleosigm"][1] then
conjinfo["nucleosigm"][1] = base .. "īss"
end
end
elseif conj_arg == "irreg" then
for _,p in ipairs(verbos_irregulares) do
for _,rx in ipairs(p[2]) do
local pref, verb = match(conjinfo.v, "^(.*)("..rx..")$")
if verb then
conjinfo.v = verb
conjinfo.prefijo = pref
if conjinfo.nucleoperf[1] and conjinfo.nucleoperf[1] ~= "-" then -- [[ecfero]]
conjinfo.prefijoperf = conjinfo.nucleoperf[1]
conjinfo.nucleoperf = {}
end
if conjinfo.nucleosup[1] and conjinfo.nucleosup[1] ~= "-" then
conjinfo.prefijosup = conjinfo.nucleosup[1]
conjinfo.nucleosup = {}
end
if conjinfo.nucleosigm[1] and conjinfo.nucleosigm[1] ~= "-" then
conjinfo.prefijosigm = conjinfo.nucleosigm[1]
conjinfo.nucleosigm = {}
end
conjinfo.irreg = true
conjinfo.conj = p[3].conj
for k,val in pairs(p[3]) do
if not conjinfo[k] or (type(conjinfo[k]) == "table" and not conjinfo[k][1]) then
conjinfo[k] = deep_copy(val)
end
end
return conjinfo
end
end
end
error("Unrecognized conjugation '" .. conj_arg .. "'")
else
error("Unrecognized conjugation '" .. conj_arg .. "'")
end
return conjinfo
end
function export.v(frame)
local title_ = mw.title.getCurrentTitle()
local tit = title_.fullText
local ns = title_.namespace
if ns ~= 0 then
return "Use esta plantilla en el espacio principal."
end
local params = {
[1] = {alias_de = "conj"},
[2] = {alias_de = "pres"},
[3] = {alias_de = "nucleoperf"},
[4] = {alias_de = "nucleosup"},
[5] = {alias_de = "nucleosigm"},
["impers"] = {}, -- pas para formas pasivas solamente
["impersonal"] = {alias_de = "impers"},
["dep"] = {tipo="bool"},
["depon"] = {alias_de="dep"},
["deponente"] = {alias_de="dep"},
["semidep"] = {tipo="bool"},
["semidepon"] = {alias_de="semidep"},
["semideponente"] = {alias_de="semidep"},
["sigm"] = {tipo="bool"},
["nopasivo"] = {tipo="bool"},
["soloperf"] = {tipo="bool"},
["I"] = {tipo="bool"},
["p3inf"] = {tipo="bool"}, -- sin uso
["poet_sync_perf"] = {tipo="bool"}, -- sin uso
["always_sync_perf"] = {tipo="bool"}, -- solo en [[saevio]]
["conj"] = {requerido=true},
["pres"] = {requerido=true},
["nucleopres"] = {lista = true},
["nucleoperf"] = {lista = true},
["nucleosup"] = {lista = true},
["nucleosigm"] = {lista = true},
["núcleopres"] = {alias_de="nucleopres"},
["núcleoperf"] = {alias_de="nucleoperf"},
["núcleosup"] = {alias_de="nucleosup"},
["paradigma"] = {lista = true},
["desactivarnucleos"] = {tipo="bool", por_defecto=true}, -- para [[-o]]
["nota"] = {},
}
local conjugado = {}
for forma,_ in pairs(formas_no_personales) do
params[forma] = {tipo=parsear_arreglo, por_defecto={}}
conjugado[forma] = {}
end
for forma,_ in pairs(formas_personales) do
for i,s in ipairs(tostr) do
params[forma..s] = {tipo=parsear_arreglo, por_defecto={}}
conjugado[forma..s] = {}
if i == 1 then
params[forma] = {alias_de=forma..s}
end
end
end
local parent_frame = frame:getParent()
local args = require("Módulo:parámetros").obtener_parametros(parent_frame.args, params)
assert(not find(tit, " "), "locuciones no soportadas aún")
assert(not (args["dep"] and args["semidep"]), "un verbo no puede ser deponente y semideponente a la vez")
local conjinfo = {
conj = args.conj,
prefijo="",
v=args.pres,
desactivar = {},
dep=args.dep,
semidep=args.semidep,
sigm=args.sigm,
impers=args.impers,
nopasivo=args.nopasivo,
soloperf=args.soloperf,
I=args.I,
p3inf=args.p3inf,
poet_sync_perf=args.poet_sync_perf, -- sin uso
always_sync_perf=args.always_sync_perf,
nucleopres = deep_copy(args.nucleopres),
nucleoperf = deep_copy(args.nucleoperf),
nucleosup = deep_copy(args.nucleosup),
nucleosigm = deep_copy(args.nucleosigm)
}
conjinfo = detect_v_type_and_subtypes(conjinfo)
conjinfo.conj = conjinfo.conj
if conjinfo.impers == true then
conjinfo.impers = "3"
end
-- no puede ir conjinfo acá abajo porque si es un sufijo va a quedar "-" en la raíz, lo que anularía todas las formas conjugadas, tiene que venir directo de args
if args.desactivarnucleos then
if args.nucleopres[1] == "-" then
conjinfo.nucleopres = {}
end
if args.nucleoperf[1] == "-" then
conjinfo.nucleoperf = {}
end
if args.nucleosup[1] == "-" then
conjinfo.nucleosup = {}
end
if args.nucleosigm[1] == "-" then
conjinfo.nucleosigm = {}
end
end
local es_irregular = conjinfo.irreg
for _,d in ipairs(conjinfo.desactivar) do
if formas_no_personales[d] then
args[d] = {"no"}
else
args[d.."2"] = {"no"}
end
end
for forma,_ in pairs(formas) do
agregar_forma(conjugado, conjinfo, forma)
end
local resultante = sobreescribir_formas(conjugado, args)
local mostrar_fut_sig = #resultante["ind_fut_sig1"] > 0
local mostrar_aor_sig = #resultante["subj_aor_sig1"] > 0
local defectivo = comprobar_defectivo(resultante, {"^imper", "_sig"}, tostr)
local defect2
resultante, defect2 = desactivar_formas(resultante,
function (form)
return (conjinfo.nopasivo and form:find("_pas")) or (conjinfo.soloperf and not form:find("perf")) or (conjinfo.impers == "pas" and form:find("_pas[^3]")) or (conjinfo.impers == "pas3" and form:find("_pas[^3]")) or (conjinfo.impers == "pas36" and form:find("_pas[^36]"))
end
)
if defect2 then
defectivo = true
end
-- por ahora innecesario
-- local part_no_adj = {}
-- for _,e in ipairs(resultante.part) do
-- if (find(e, 'PART') or not find(e, 'ADJ')) and not find(e, "†") then
-- insert(part_no_adj, gsub1(e, '%b{}', ''))
-- end
-- end
local tit_pres = f(resultante["ind_pres1"][1] or "―")
local tit_inf = f(resultante["inf_act"][1] or "―")
local tit_perf = f(resultante["ind_perf1"][1] or "―")
local tit_sup = f(resultante["sup"][1] or "―")
resultante = agregar_enlaces(resultante, tit, normalizar_enlace)
local es_impersonal = conjinfo.impers
resultante = formatear_formas(resultante, function (x)
return obtener_pronombre(x, es_impersonal)
end)
local impers = conjinfo.impers
local cs, cs1, cs2, fila_pronombres_ind, fila_pronombres_subj, fila_pronombres_imper, mostrar_imper
if impers == "3" then
fila_pronombres_ind = {"", "(id)", color=COLOR_IND, header=true, class="pc"}
fila_pronombres_subj = {"", "(quod id)", color=COLOR_SUBJ, header=true, class="pc"}
fila_pronombres_imper = {"", "(id)", color=COLOR_IMPER, header=true, class="pc"}
cs = 2
elseif impers == "36" then
error("no soportado actualmente")
cs = 3
else
fila_pronombres_ind = {"", PRONOMBRES[1], PRONOMBRES[2], PRONOMBRES[3], PRONOMBRES[4], PRONOMBRES[5], PRONOMBRES[6], color=COLOR_IND, header=true, class="pc"}
fila_pronombres_subj = {"", PRONOMBRES_SUBJ[1], PRONOMBRES_SUBJ[2], PRONOMBRES_SUBJ[3], PRONOMBRES_SUBJ[4], PRONOMBRES_SUBJ[5], PRONOMBRES_SUBJ[6], color=COLOR_SUBJ, header=true, class="pc"}
fila_pronombres_imper = {"", PRONOMBRES_IMP[1], PRONOMBRES_IMP[2], PRONOMBRES_IMP[3], PRONOMBRES_IMP[4], PRONOMBRES_IMP[5], PRONOMBRES_IMP[6], color=COLOR_IMPER, header=true, class="pc"}
cs = 7
mostrar_imper = true
end
cs1 = cs -- math.floor(cs / 2)
-- cs2 = cs - cs1
local t = {}
insert(t, {{"Formas no personales (verboides)", colspan=cs}, color=COLOR_H, header=true})
if impers == "3" then
insert(t, {{"Infinitivo activo", header=true, color=COLOR_NP}, resultante.inf_act})
insert(t, {{"Infinitivo pasivo", header=true, color=COLOR_NP}, resultante.inf_pas})
insert(t, {{"Participio activo", header=true, color=COLOR_NP}, resultante.part_act})
insert(t, {{"Participio pasivo", header=true, color=COLOR_NP}, resultante.part_pas})
insert(t, {{"Gerundio", header=true, color=COLOR_NP}, resultante.ger})
insert(t, {{"Supino", header=true, color=COLOR_NP}, resultante.sup})
else
resultante.inf_act.colspan = cs1-1
resultante.inf_pas.colspan = cs1-1
resultante.part_act.colspan = cs1-1
resultante.part_pas.colspan = cs1-1
resultante.ger.colspan = cs1-1
resultante.sup.colspan = cs1-1
if not conjinfo.dep then
insert(t, {{"Infinitivo activo", header=true, color=COLOR_NP}, resultante.inf_act})
end
if not conjinfo.semidep then
insert(t, {{"Infinitivo pasivo", header=true, color=COLOR_NP}, resultante.inf_pas})
end
if not conjinfo.dep then
insert(t, {{"Participio activo", header=true, color=COLOR_NP}, resultante.part_act})
end
if not conjinfo.semidep then
insert(t, {{"Participio pasivo", header=true, color=COLOR_NP}, resultante.part_pas})
end
insert(t, {{"Gerundio", header=true, color=COLOR_NP}, resultante.ger})
insert(t, {{"Supino", header=true, color=COLOR_NP}, resultante.sup})
end
local function ic(tiempo)
if impers == "3" then
return resultante[tiempo.."3"]
elseif impers == "36" then
return resultante[tiempo.."3"], resultante[tiempo.."6"]
end
return resultante[tiempo.."1"], resultante[tiempo.."2"], resultante[tiempo.."3"], resultante[tiempo.."4"], resultante[tiempo.."5"], resultante[tiempo.."6"]
end
insert(t, {{"Formas personales", colspan=cs}, color=COLOR_H, header=true})
insert(t, {{"Modo indicativo", colspan=cs}, color=COLOR_IND, header=true})
insert(t, fila_pronombres_ind)
if not conjinfo.dep then
insert(t, {{"Presente", color=COLOR_IND, header=true}, ic("ind_pres")})
insert(t, {{"Pretérito imperfecto", color=COLOR_IND, header=true}, ic("ind_imp")})
insert(t, {{"Futuro", color=COLOR_IND, header=true}, ic("ind_fut")})
end
if not conjinfo.dep and not conjinfo.semidep then
insert(t, {{"Pretérito perfecto", color=COLOR_IND, header=true}, ic("ind_perf")})
insert(t, {{"Pretérito pluscuamperfecto", color=COLOR_IND, header=true}, ic("ind_pluperf")})
insert(t, {{"Futuro perfecto", color=COLOR_IND, header=true}, ic("ind_fut_perf")})
end
if mostrar_fut_sig then
insert(t, {{f("Futuro sigmático{†}"), color=COLOR_IND, header=true}, ic("ind_fut_sig")})
end
if not conjinfo.semidep then
insert(t, {{"Presente pasivo", color=COLOR_IND, header=true}, ic("ind_pres_pas")})
insert(t, {{"Pretérito imperfecto pasivo", color=COLOR_IND, header=true}, ic("ind_imp_pas")})
insert(t, {{"Futuro pasivo", color=COLOR_IND, header=true}, ic("ind_fut_pas")})
end
insert(t, {{"Modo subjuntivo", colspan=cs}, color=COLOR_SUBJ, header=true})
insert(t, fila_pronombres_subj)
if not conjinfo.dep then
insert(t, {{"Presente", color=COLOR_SUBJ, header=true}, ic("subj_pres")})
insert(t, {{"Pretérito imperfecto", color=COLOR_SUBJ, header=true}, ic("subj_imp")})
end
if not conjinfo.dep and not conjinfo.semidep then
insert(t, {{"Pretérito perfecto", color=COLOR_SUBJ, header=true}, ic("subj_perf")})
insert(t, {{"Pretérito pluscuamperfecto", color=COLOR_SUBJ, header=true}, ic("subj_pluperf")})
end
if mostrar_aor_sig then
insert(t, {{f("Aorista sigmático{†}"), color=COLOR_SUBJ, header=true}, ic("subj_aor_sig")})
end
if not conjinfo.semidep then
insert(t, {{"Presente pasivo", color=COLOR_SUBJ, header=true}, ic("subj_pres_pas")})
insert(t, {{"Pretérito imperfecto pasivo", color=COLOR_SUBJ, header=true}, ic("subj_imp_pas")})
end
insert(t, {{"Modo imperativo", colspan=cs}, color=COLOR_IMPER, header=true})
insert(t, fila_pronombres_imper)
if mostrar_imper then
if not conjinfo.dep then
insert(t, {{"Presente", color=COLOR_IMPER, header=true}, ic("imper_pres")})
insert(t, {{"Futuro", color=COLOR_IMPER, header=true}, ic("imper_fut")})
end
if not conjinfo.semidep then
insert(t, {{"Presente pasivo", color=COLOR_IMPER, header=true}, ic("imper_pres_pas")})
insert(t, {{"Futuro pasivo", color=COLOR_IMPER, header=true}, ic("imper_fut_pas")})
end
else
insert(t, {{"Como verbo "..(impers == "3" and "impersonal" or "terciopersonal")..", ''"..tit.."'' CARECE de imperativo", color=COLOR_IMPER, header=true, colspan=cs}})
end
insert(t, {{f("Leyenda: † arcaico, x no normativo, ~■~ cambio ortográfico, #■# irregularidad"), colspan=cs}})
args["nota"] = args["nota"] or ""
if conjinfo.impers == "utc3" then
args["nota"] = args["nota"].." NOTA: se usa también como impersonal, en cuyo caso solo son válidas las conjugaciones de la tercera persona singular."
end
if conjinfo.impers == "umc3" then
args["nota"] = args["nota"].." NOTA: se usa más como impersonal, en cuyo caso solo son válidas las conjugaciones de la tercera persona singular."
end
if conjinfo.impers == "utc36" then
args["nota"] = args["nota"].." NOTA: se usa también como terciopersonal, en cuyo caso solo son válidas las conjugaciones de la tercera persona singular y plural."
end
if conjinfo.impers == "umc36" then
args["nota"] = args["nota"].." NOTA: se usa más como terciopersonal, en cuyo caso solo son válidas las conjugaciones de la tercera persona singular y plural."
end
if conjinfo.impers == "pas" or conjinfo.imeprs == "pas3" then
args["nota"] = args["nota"].." NOTA: impersonal para las formas pasivas"
end
if conjinfo.impers == "pas36" then
args["nota"] = args["nota"].." NOTA: formas pasivas terciopersonales (solamente tercera persona singular y plural)"
end
if conjinfo.soloperf then
args["nota"] = args["nota"].. " NOTA: solo se emplean las formas del perfecto y pluscuamperfecto con valor de presente, imperfecto o futuro"
end
if conjinfo.nopasivo then
args["nota"] = args["nota"].. " NOTA: solo se emplean las formas activas"
end
insert(t, {{args["nota"] and args["nota"] or "", colspan=cs}})
local cats = {}
local subtits = {}
local conj_str
if conjinfo.conj == "1" then
conj_str = "primera conjugación"
elseif conjinfo.conj == "2" then
conj_str = "segunda conjugación"
elseif conjinfo.conj == "3" then
conj_str = "tercera conjugación"
elseif conjinfo.conj == "3/4" then
conj_str = "tercera/cuarta conjugación"
else
conj_str = "cuarta conjugación"
end
insert(cats, "LA:Verbos de la "..conj_str)
insert(subtits, conj_str)
impers = impers or ""
if impers == "3" or find(impers, "^u[tm]c3$") then
insert(subtits, "impersonal")
insert(cats, "LA:Verbos impersonales")
end
if defectivo then
insert(subtits, "defectivo")
insert(cats, "LA:Verbos defectivos")
end
if conjinfo.dep then
insert(subtits, "deponente")
insert(cats, "LA:Verbos deponentes")
end
if conjinfo.semidep then
insert(subtits, "semideponente")
insert(cats, "LA:Verbos semideponentes")
end
if es_irregular then
insert(subtits, "irregular")
insert(cats, "LA:Verbos irregulares")
else
insert(subtits, "regular")
insert(cats, "LA:Verbos regulares")
end
return renderizar_tabla(
frame,
"'''Conjugación de ''"..tit_pres..", "..tit_inf..", "..tit_perf..", "..tit_sup.."'''''  ("..concat(subtits, ", ")..")",
t,
ns == 0 and cats or {})
end
function export.adv(frame)
local title_ = mw.title.getCurrentTitle()
local title = title_.fullText
local ns = title_.namespace
if ns ~= 0 then
return "Use esta plantilla en el espacio principal."
end
local params = {
["n"] = {},
["nota"] = {alias_de = "n"},
["comp"] = {lista = true},
["comparativo"] = {alias_de = "comp"},
["compnota"] = {lista = true},
["sup"] = {lista = true},
["superlativo"] = {alias_de = "sup"},
["supnota"] = {lista = true},
}
local parent_frame = frame:getParent()
local args = require("Módulo:parámetros").obtener_parametros(parent_frame.args, params)
local head = args[1]
local modo = args[2]
local enc
local cats = {}
local cat_pref = "LA:Adverbios"
if modo == "-" then
enc = "sin comparativo ni superlativo"
insert(cats, cat_pref.." incomparables")
return renderizar_encabezado(
frame,
head,
enc,
args["n"],
{},
ns == 0 and cats or {},
normalizar_enlace
)
end
local flex = {comp={},sup={}}
local stem
for _, suff in ipairs{"iter", "nter", "ter", "er", "iē", "ē", "rā", "im", "ō"} do
stem = match(head, "^(.*)" .. suff .. "$")
if stem ~= nil then
local comp_suff, sup_suff = "ius", "issimē"
if suff == "nter" then
stem = stem .. "nt"
end
if suff == "rā" then
comp_suff = "er" .. comp_suff
sup_suff = "imē"
end
insert(flex.comp, stem .. comp_suff)
insert(flex.sup, stem .. sup_suff)
break
end
end
if not stem and not args.comp[1] and not args.sup[1] then
error("Unrecognized adverb type, recognized types are “-ē”, “-er”, “-ter”, “-iter”, “-im”, or “-ō”, “-ra” or specify irregular forms or “-” if incomparable.")
end
local formas, irr = sobreescribir_formas(flex, args)
if args["comp"][1] == "no" then
enc = "sin comparativo"
insert(cats, cat_pref.." sin comparativo")
return renderizar_encabezado(
frame,
head,
enc,
args["n"],
{{"superlativo", formas.sup, args["supnota"]}},
ns == 0 and cats or {},
normalizar_enlace
)
elseif args["sup"][1] == "no" then
enc = "sin superlativo"
insert(cats, cat_pref.." sin superlativo")
return renderizar_encabezado(
frame,
head,
enc,
args["n"],
{{"comparativo", formas.comp, args["compnota"]}},
ns == 0 and cats or {},
normalizar_enlace
)
end
if irr then
enc = f("#irregular#")
insert(cats, cat_pref.." irregulares")
end
return renderizar_encabezado(
frame,
head,
enc,
args["n"],
{{"comparativo", formas.comp, args["compnota"]},
{"superlativo", formas.sup, args["supnota"]}},
ns == 0 and cats or {},
normalizar_enlace
)
end
return export
tcs2fbsxumwwetpiaz6v7qheu0i2i9l
6121432
6121431
2026-07-12T04:52:57Z
Tmagc
158167
6121432
Scribunto
text/plain
-- FLEXIÓN DEL LATÍN
-- Adaptado desde en.wikt por Tmagc
local export = {}
local unpack = unpack or table.unpack
local insert = table.insert
local concat = table.concat
local m_table = require("Módulo:tabla")
local list_to_set = m_table.listToSet
local keys_to_list = m_table.keysToList
local insert_if_not = m_table.insertIfNot
local deep_copy = m_table.deepCopy
local contains = m_table.contains
local append = m_table.append
local merge = m_table.merge
local m_str = require("Módulo:string")
local u = m_str.char
local match = m_str.match
local sub = m_str.sub
local gsub = m_str.gsub
local gsubb = m_str.gsubb
local split = m_str.split
local gsplit = m_str.gsplit
local find = m_str.find
local m_str_avanzado = require("Módulo:string/avanzado")
local toNFD = m_str_avanzado.toNFD
local toNFC = m_str_avanzado.toNFC
local m_flex = require("Módulo:flex")
local f = m_flex.f
local f_links = m_flex.f_links
local parsear_arreglo = m_flex.parsear_arreglo
local separar_palabras = m_flex.separar_palabras
local combinar_copulativa = m_flex.combinar_copulativa
local sobreescribir_formas = m_flex.sobreescribir_formas
local desactivar_formas = m_flex.desactivar_formas
local agregar_enlaces = m_flex.agregar_enlaces
local formatear_formas = m_flex.formatear_formas
local comprobar_defectivo = m_flex.comprobar_defectivo
local renderizar_tabla = m_flex.renderizar_tabla
local renderizar_encabezado = m_flex.renderizar_encabezado
local COLOR_H = m_flex.COLOR_H
local COLOR_NP = m_flex.COLOR_NP
local COLOR_IND = m_flex.COLOR_IND
local COLOR_COND = m_flex.COLOR_COND
local COLOR_SUBJ = m_flex.COLOR_SUBJ
local COLOR_IMPER = m_flex.COLOR_IMPER
local MACRON = u(0x304)
local BREVE = u(0x306)
local DIAER = u(0x308)
local DBREVE = u(0x361)
local ACCENT = "[" .. MACRON .. BREVE .. DIAER .. DBREVE .. "]"
local VOWEL = "[aæeioœuyAÆEIOŒUY]"
local cons_to_vowel = {
["j"] = "i", ["J"] = "I",
["v"] = "u", ["V"] = "U",
}
local function normalizar_enlace(x)
x = toNFD(x)
x = gsub(x, ACCENT, "")
return toNFC(x)
end
local function join(a, b)
a, b = toNFD(a), toNFD(b)
-- If the first part ends in "j" or "v", convert it to "i" or "u" unless
-- the second part begins with a vowel.
if not match(b, "^" .. VOWEL) then
a = gsub(a, "[jvJV]$", cons_to_vowel)
end
return toNFC(a..b)
end
local function add_form(decl, slot, stem, suf)
if type(slot) == "string" then
slot = {slot}
end
for _,slt in ipairs(slot) do
if type(decl[slt]) == "nil" or decl[slt] == "" then
decl[slt] = {}
elseif type(decl[slt]) == "string" then
decl[slt] = {decl[slt]}
end
insert_if_not(decl[slt], join(stem, suf))
end
end
local function remove_forms(decl, forms)
for form,_ in pairs(decl) do
for _,rx in ipairs(forms) do
if form:find(rx) then
forms[form] = {}
break
end
end
end
end
local function merge_forms(forms, forms2, keys)
keys = keys or forms2
for key,arr in pairs(keys) do
if not forms[key] then
forms[key] = {}
end
if type(forms2[key]) == "string" then
insert_if_not(forms[key], forms2[key])
elseif type(forms2[key]) == "table" then
for _,a in ipairs(forms2[key]) do
insert_if_not(forms[key], a)
end
end
end
end
local noun_decl = {}
noun_decl["0"] = function(data, args)
local forms = data.forms
local stem = args[1]
insert_if_not(data.title, "indeclinable")
insert_if_not(data.categories, "LA:Sustantivos indeclinables")
forms["nom_sg"] = stem
forms["gen_sg"] = stem
forms["dat_sg"] = stem
forms["acc_sg"] = stem
forms["abl_sg"] = stem
forms["voc_sg"] = stem
forms["nom_pl"] = stem
forms["gen_pl"] = stem
forms["dat_pl"] = stem
forms["acc_pl"] = stem
forms["abl_pl"] = stem
forms["voc_pl"] = stem
-- with locative
if data.loc then
forms["loc_sg"] = stem
forms["loc_pl"] = stem
end
end
local function alt_gen_pl_in_um(stem, forms, types, subtitles, i_stem)
if types.genplum then
add_form(forms, "gen_pl", stem, (i_stem and "i" or "") .. "um")
elseif types.not_genplum then
-- FIXME: not a contraction.
-- insert_if_not(subtitles, "uncontracted genitive plural")
end
end
noun_decl["1"] = function(data, args)
local forms, types, loc, subtitles = data.forms, data.types, data.loc, data.subtitles
local stem = args[1]
-- normal 1st
local nom_sg = "a"
local gen_loc_sg = "ae"
local dat_sg = "ae"
local acc_sg = "am"
local abl_sg = "ā"
local voc_sg = "a"
local nom_voc_pl = "ae"
local gen_pl = "ārum"
local dat_abl_loc_pl = "īs"
local acc_pl = "ās"
insert_if_not(data.title, "primera declinación")
insert_if_not(data.categories, "LA:Sustantivos de la primera declinación")
-- ām
if types.am then
nom_sg = "ām"
acc_sg = "ām"
abl_sg = {"ām", "ā"}
voc_sg = "ām"
-- all Greek
elseif types.Greek then
insert_if_not(data.title, "griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
--Greek Ma
if types.Ma then
nom_sg = "ās"
acc_sg = "ān"
voc_sg = "ā"
-- Greek Me
elseif types.Me then
nom_sg = "ēs"
acc_sg = "ēn"
abl_sg = "ē"
voc_sg = "ē"
-- Greek
else
nom_sg = "ē"
gen_loc_sg = "ēs"
acc_sg = "ēn"
abl_sg = "ē"
voc_sg = "ē"
end
end
-- ābus
if types.abus then
dat_abl_loc_pl = "ābus"
end
add_form(forms, "nom_sg", stem, nom_sg)
add_form(forms, "gen_sg", stem, gen_loc_sg)
add_form(forms, "dat_sg", stem, dat_sg)
add_form(forms, "acc_sg", stem, acc_sg)
add_form(forms, "abl_sg", stem, abl_sg)
add_form(forms, "voc_sg", stem, voc_sg)
add_form(forms, {"nom_pl", "voc_pl"}, stem, nom_voc_pl)
add_form(forms, "gen_pl", stem, gen_pl)
add_form(forms, {"dat_pl", "abl_pl"}, stem, dat_abl_loc_pl)
add_form(forms, "acc_pl", stem, acc_pl)
-- with locative
if loc then
add_form(forms, "loc_sg", stem, gen_loc_sg)
add_form(forms, "loc_pl", stem, dat_abl_loc_pl)
end
end
noun_decl["2"] = function(data, args)
local forms, types, subtitles, notes = data.forms, data.types, data.subtitles, data.notes
local stem1, stem2 = args[1], args[2]
insert_if_not(data.title, "segunda declinación")
insert_if_not(data.categories, "LA:Sustantivos de la segunda declinación")
-- normal 2nd
forms["nom_sg"] = stem1 .. "us"
forms["gen_sg"] = stem1 .. "ī"
forms["dat_sg"] = stem1 .. "ō"
forms["acc_sg"] = stem1 .. "um"
forms["abl_sg"] = stem1 .. "ō"
forms["voc_sg"] = stem1 .. "e"
forms["nom_pl"] = stem1 .. "ī"
forms["gen_pl"] = stem1 .. "ōrum"
forms["dat_pl"] = stem1 .. "īs"
forms["acc_pl"] = stem1 .. "ōs"
forms["abl_pl"] = stem1 .. "īs"
forms["voc_pl"] = stem1 .. "ī"
-- all neuter
if types.N then
forms["nom_sg"] = stem1 .. "um"
forms["voc_sg"] = stem1 .. "um"
forms["nom_pl"] = stem1 .. "a"
forms["acc_pl"] = stem1 .. "a"
forms["voc_pl"] = stem1 .. "a"
-- neuter ium
if types.ium then
forms["nom_sg"] = stem1 .. "ium"
forms["gen_sg"] = {stem1 .. "iī", stem1 .. "ī{†}"}
forms["dat_sg"] = stem1 .. "iō"
forms["acc_sg"] = stem1 .. "ium"
forms["abl_sg"] = stem1 .. "iō"
forms["voc_sg"] = stem1 .. "ium"
forms["nom_pl"] = stem1 .. "ia"
forms["gen_pl"] = stem1 .. "iōrum"
forms["dat_pl"] = stem1 .. "iīs"
forms["acc_pl"] = stem1 .. "ia"
forms["abl_pl"] = stem1 .. "iīs"
forms["voc_pl"] = stem1 .. "ia"
-- neuter us, plural a
elseif types.a then
forms["nom_sg"] = stem1 .. "us"
forms["acc_sg"] = stem1 .. "us"
forms["voc_sg"] = stem1 .. "us"
forms["nom_pl"] = stem1 .. "a"
forms["acc_pl"] = stem1 .. "a"
forms["voc_pl"] = stem1 .. "a"
-- -vom (aevom, etc.)
elseif types.vom then
forms["nom_sg"] = stem1 .. "om"
forms["acc_sg"] = stem1 .. "om"
forms["voc_sg"] = stem1 .. "om"
-- neuter Greek in -os (cētos)
elseif types.Greek and types.us then
insert_if_not(data.title, "griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = stem1 .. "os"
forms["acc_sg"] = stem1 .. "os"
forms["voc_sg"] = stem1 .. "os"
forms["nom_pl"] = stem1 .. "ē"
forms["gen_pl"] = stem1 .. "ōn"
forms["acc_pl"] = stem1 .. "ē"
forms["voc_pl"] = stem1 .. "ē"
-- neuter Greek
elseif types.Greek then
insert_if_not(data.title, "griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = stem1 .. "on"
forms["acc_sg"] = stem1 .. "on"
forms["voc_sg"] = stem1 .. "on"
-- neuter us
elseif types.us then
forms["nom_sg"] = stem1 .. "us"
forms["acc_sg"] = stem1 .. "us"
forms["voc_sg"] = stem1 .. "us"
forms["nom_pl"] = stem1 .. "ī"
forms["acc_pl"] = stem1 .. "ōs"
forms["voc_pl"] = stem1 .. "ī"
end
-- er
elseif types.er then
forms["nom_sg"] = stem1
forms["gen_sg"] = stem2 .. "ī"
forms["dat_sg"] = stem2 .. "ō"
forms["acc_sg"] = stem2 .. "um"
forms["abl_sg"] = stem2 .. "ō"
forms["voc_sg"] = stem1
forms["nom_pl"] = stem2 .. "ī"
forms["gen_pl"] = stem2 .. "ōrum"
forms["dat_pl"] = stem2 .. "īs"
forms["acc_pl"] = stem2 .. "ōs"
forms["abl_pl"] = stem2 .. "īs"
forms["voc_pl"] = stem2 .. "ī"
-- ius
elseif types.ius then
forms["nom_sg"] = stem1 .. "ius"
forms["gen_sg"] = {stem1 .. "iī", stem1 .. "ī{†}"}
forms["dat_sg"] = stem1 .. "iō"
forms["acc_sg"] = stem1 .. "ium"
forms["abl_sg"] = stem1 .. "iō"
if types.voci then
-- Only for proper names and fīlius, genius
forms["voc_sg"] = stem1 .. "ī"
else
forms["voc_sg"] = stem1 .. "ie"
end
forms["nom_pl"] = stem1 .. "iī"
forms["gen_pl"] = stem1 .. "iōrum"
forms["dat_pl"] = stem1 .. "iīs"
forms["acc_pl"] = stem1 .. "iōs"
forms["abl_pl"] = stem1 .. "iīs"
forms["voc_pl"] = stem1 .. "iī"
-- -vos (servos, etc.)
elseif types.vos then
forms["nom_sg"] = stem1 .. "os"
forms["acc_sg"] = stem1 .. "om"
-- Greek
elseif types.Greek then
insert_if_not(data.title, "griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = stem1 .. "os"
forms["acc_sg"] = stem1 .. "on"
if data.num == "pl" then
forms["nom_pl"] = stem1 .. "oe"
forms["voc_pl"] = stem1 .. "oe"
else
forms["nom_pl"] = {stem1 .. "ī", stem1 .. "oe"}
forms["voc_pl"] = {stem1 .. "ī", stem1 .. "oe"}
end
elseif types.not_Greek then
insert_if_not(data.title, "no griego")
end
-- with -um genitive plural
alt_gen_pl_in_um(stem2, forms, types, subtitles, types.ius or types.ium)
-- with locative
if data.loc then
if types.ius or types.ium then
forms["loc_sg"] = stem2 .. "iī"
forms["loc_pl"] = stem2 .. "iīs"
else
forms["loc_sg"] = stem2 .. "ī"
forms["loc_pl"] = stem2 .. "īs"
end
end
end
local acc_sg_i_stem_subtypes = {
acc_im = {
-- amussis, basis, buris, cucumis, gummis, mephitis, paraphrasis, poesis, ravis, sitis, tussis, (vis) [abl -ī];
-- cannabis, senapis, sinapis [abl -e, -ī]
acc_sg = {"im"},
title = {"accusative singular in ''-im''"},
},
acc_im_in = {
-- cities, rivers, gods, e.g. Bilbilis, Syrtis, Tiberis, Anubis, Osiris [abl -ī];
-- Baetis, Tigris [acc -e, -ī]
acc_sg = {"im", "in"},
title = {"accusative singular in ''-im'' or ''-in''"},
},
acc_im_in_em = {
-- e.g. tigris, river Līris
acc_sg = {"im", "in", "em"},
title = {"accusative singular in ''-im'', ''-in'' or ''-em''"},
},
acc_im_em = {
acc_sg = {"im", "em"},
title = {"accusative singular in ''-im'' or ''-em''"},
},
acc_im_occ_em = {
-- febris, pelvis, puppis, restis, securis, turris [abl -ī, -e]
acc_sg = {"im", "em"},
title = {"accusative singular in ''-im'' or occasionally ''-em''"},
},
acc_em_im = {
-- aqualis, clavis, lens, navis [abl -e, -ī];
-- cutis, restis [abl -e]
acc_sg = {"em", "im"},
title = {"accusative singular in ''-em'' or ''-im''"},
},
}
local abl_sg_i_stem_subtypes = {
abl_i = {
-- amussis, basis, buris, cucumis, gummis, mephitis, paraphrasis, poesis, ravis, sitis, tussis, (vis) [acc -im];
-- cities, rivers, gods, e.g. Bilbilis, Syrtis, Tiberis, Anubis, Osiris [acc -im or -in];
-- canalis "water pipe", months in -is or -er, nouns originally i-stem adjectives such as aedilis, affinis, bipennis, familiaris, sodalis, volucris, etc. [acc -em]
abl_sg = {"ī"},
title = {"ablative singular in ''-ī''"},
},
abl_i_e = {
-- febris, pelvis, puppis, restis, securis, turris [acc -im, -em]
abl_sg = {"ī", "e"},
title = {"ablative singular in ''-ī'' or ''-e''"},
},
abl_e_i = {
-- cannabis, senapis, sinapis [acc -im];
-- Baetis, Tigris [acc -im, -in];
-- aqualis, clavis, lens, navis [acc -em, -im];
-- finis, mugilis, occiput, pugil, rus, supellex, vectis [acc -em]
abl_sg = {"e", "ī"},
title = {"ablative singular in ''-e'' or ''-ī''"},
},
abl_e_occ_i = {
-- amnis, anguis, avis, civis, classis, fustis, ignis, imber, orbis, pars, postis, sors, unguis, vesper [acc -em]
abl_sg = {"e", "ī"},
title = {"ablative singular in ''-e'' or occasionally ''-ī''"},
},
}
local function extract_stem(form, ending)
local base = match(form, "^(.*)" .. ending .. "$")
if not base then
error("Form " .. form .. " should end in -" .. ending)
end
return base
end
local function count_vowels(stem)
return select(2, toNFD(stem):gsub("[aeiouyAEIOUY]", ""))
end
noun_decl["3"] = function(data, args)
local forms, types, subtitles, notes = data.forms, data.types, data.subtitles, data.notes
local stem1, stem2 = args[1], args[2]
-- local function non_i_stem_type()
-- return (count_vowels(stem1) > count_vowels(stem2) and "parisyllabic" or "imparisyllabic") .. " non-i-stem"
-- end
insert_if_not(data.title, "tercera declinación")
insert_if_not(data.categories, "LA:Sustantivos de la tercera declinación")
--normal 3rd
forms["nom_sg"] = stem1
forms["gen_sg"] = stem2 .. "is"
forms["dat_sg"] = stem2 .. "ī"
forms["acc_sg"] = stem2 .. "em"
forms["abl_sg"] = stem2 .. "e"
forms["voc_sg"] = stem1
forms["nom_pl"] = stem2 .. "ēs"
forms["gen_pl"] = stem2 .. "um"
forms["dat_pl"] = stem2 .. "ibus"
forms["acc_pl"] = stem2 .. "ēs"
forms["abl_pl"] = stem2 .. "ibus"
forms["voc_pl"] = stem2 .. "ēs"
local acc_sg_i_stem_subtype = false
local not_acc_sg_i_stem_subtype = false
for subtype, _ in pairs(types) do
if acc_sg_i_stem_subtypes[subtype] then
acc_sg_i_stem_subtype = true
break
end
end
for acc_sg_subtype, _ in pairs(acc_sg_i_stem_subtypes) do
if types["not_" .. acc_sg_subtype] then
not_acc_sg_i_stem_subtype = true
break
end
end
local abl_sg_i_stem_subtype = false
local not_abl_sg_i_stem_subtype = false
for subtype, _ in pairs(types) do
if abl_sg_i_stem_subtypes[subtype] then
abl_sg_i_stem_subtype = true
break
end
end
for abl_sg_subtype, _ in pairs(abl_sg_i_stem_subtypes) do
if types["not_" .. abl_sg_subtype] then
not_abl_sg_i_stem_subtype = true
break
end
end
-- all Greek
if types.Greek then
insert_if_not(data.title, "griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
-- Greek er
if types.er then
stem1 = extract_stem(stem1, "ēr")
forms["nom_sg"] = stem1 .. "ēr"
forms["gen_sg"] = stem1 .. "eris"
forms["dat_sg"] = stem1 .. "erī"
forms["acc_sg"] = {stem1 .. "era", stem1 .. "erem"}
forms["abl_sg"] = stem1 .. "ere"
forms["voc_sg"] = stem1 .. "ēr"
forms["nom_pl"] = stem1 .. "erēs"
forms["gen_pl"] = stem1 .. "erum"
forms["dat_pl"] = stem1 .. "eribus"
forms["acc_pl"] = stem1 .. "erēs"
forms["abl_pl"] = stem1 .. "eribus"
forms["voc_pl"] = stem1 .. "erēs"
-- Greek on
elseif types.on then
stem1 = extract_stem(stem1, "ōn")
forms["nom_sg"] = stem1 .. "ōn"
forms["gen_sg"] = {stem1 .. "ontis", stem1 .. "ontos"}
forms["dat_sg"] = stem1 .. "ontī"
forms["acc_sg"] = stem1 .. "onta"
forms["abl_sg"] = stem1 .. "onte"
forms["voc_sg"] = stem1 .. "ōn"
forms["nom_pl"] = stem1 .. "ontēs"
forms["gen_pl"] = {stem1 .. "ontum", stem1 .. "ontium"}
forms["dat_pl"] = stem1 .. "ontibus"
forms["acc_pl"] = {stem1 .. "ontēs", stem1 .. "ontās"}
forms["abl_pl"] = stem1 .. "ontibus"
forms["voc_pl"] = stem1 .. "ontēs"
-- Greek i-stem
elseif types.I then
forms["gen_sg"] = {stem2 .. "is", stem2 .. "eōs", stem2 .. "ios"}
forms["acc_sg"] = {stem2 .. "im", stem2 .. "in", stem2 .. "em{MED}"}
forms["abl_sg"] = {stem2 .. "ī", stem2 .. "e{MED}"}
forms["voc_sg"] = {stem2 .. "is", stem2 .. "i"}
forms["nom_pl"] = {stem2 .. "ēs", stem2 .. "eis"}
forms["gen_pl"] = {stem2 .. "ium", stem2 .. "eōn"}
forms["acc_pl"] = {stem2 .. "ēs", stem2 .. "eis"}
forms["voc_pl"] = {stem2 .. "ēs", stem2 .. "eis"}
if types.poetic_esi then
forms["dat_pl"] = {stem2 .. "ibus", stem2 .. "esi{L}"}
forms["abl_pl"] = {stem2 .. "ibus", stem2 .. "esi{L}"}
end
-- normal Greek
else
forms["gen_sg"] = stem2 .. "os"
if match(toNFD(stem2), "[yY]" .. ACCENT .. "*$") then
forms["acc_sg"] = stem2 .. "n"
else
forms["acc_sg"] = stem2 .. "a"
end
forms["nom_pl"] = stem2 .. "es"
forms["acc_pl"] = stem2 .. "as"
forms["voc_pl"] = stem2 .. "es"
if match(toNFD(stem1), "[iyIY]" .. ACCENT .. "*s$") then
-- Per Hiley, words in -is and -ys have a poetic vocative
-- without the -s, but otherwise the vocative is the same
-- as the nominative.
forms["voc_sg"] = {stem1, (stem1:gsub("s$", "")).."{L}"}
end
end
elseif types.not_Greek then
insert_if_not(data.title, "no griego")
end
-- polis
if types.polis then
stem1 = extract_stem(stem1, "polis")
insert_if_not(data.title, "parcialmente griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = stem1 .. "polis"
forms["gen_sg"] = stem1 .. "polis"
forms["dat_sg"] = stem1 .. "polī"
forms["acc_sg"] = {stem1 .. "polim", stem1 .. "polin"}
forms["abl_sg"] = stem1 .. "polī"
forms["voc_sg"] = {stem1 .. "polis", stem1 .. "polī"}
end
-- all neuter
if types.N then
forms["acc_sg"] = stem1
-- neuter I stem
if types.I then
-- pure variety
if types.pure then
forms["abl_sg"] = stem2 .. "ī"
forms["nom_pl"] = stem2 .. "ia"
forms["gen_pl"] = stem2 .. "ium"
forms["acc_pl"] = stem2 .. "ia"
forms["voc_pl"] = stem2 .. "ia"
-- non-pure variety (rare)
else
forms["nom_pl"] = stem2 .. "a"
forms["gen_pl"] = {stem2 .. "ium", stem2 .. "um"}
forms["acc_pl"] = stem2 .. "a"
forms["voc_pl"] = stem2 .. "a"
end
-- normal neuter
else
forms["nom_pl"] = stem2 .. "a"
forms["acc_pl"] = stem2 .. "a"
forms["voc_pl"] = stem2 .. "a"
end
-- I stem
elseif types.I or acc_sg_i_stem_subtype or abl_sg_i_stem_subtype then
forms["gen_pl"] = stem2 .. "ium"
-- Per Allen and Greenough, Hiley and others, the acc_pl in -īs
-- applied originally to all i-stem nouns, and was current as an
-- alternative form up through Caesar.
forms["acc_pl"] = {stem2 .. "ēs", stem2 .. "īs"}
-- pure variety
if types.pure then
forms["acc_sg"] = stem2 .. "im"
forms["abl_sg"] = stem2 .. "ī"
forms["nom_pl"] = stem2 .. "īs"
forms["acc_pl"] = stem2 .. "īs"
forms["voc_pl"] = stem2 .. "īs"
end
local num = data.num
for subtype, _ in pairs(types) do
local acc_sg_i_stem_props = acc_sg_i_stem_subtypes[subtype]
if acc_sg_i_stem_props then
forms["acc_sg"] = {}
for _, ending in ipairs(acc_sg_i_stem_props.acc_sg) do
insert_if_not(forms["acc_sg"], stem2 .. ending)
end
-- if num ~= "pl" then
-- for _, t in ipairs(acc_sg_i_stem_props.title) do
-- insert_if_not(subtitles, t)
-- end
-- end
break
end
end
-- FIXME: needs to be done for neuter nouns as well.
for subtype, _ in pairs(types) do
local abl_sg_i_stem_props = abl_sg_i_stem_subtypes[subtype]
if abl_sg_i_stem_props then
forms["abl_sg"] = {}
for _, ending in ipairs(abl_sg_i_stem_props.abl_sg) do
insert_if_not(forms["abl_sg"], stem2 .. ending)
end
-- if num ~= "pl" then
-- for _, t in ipairs(abl_sg_i_stem_props.title) do
-- insert_if_not(subtitles, t)
-- end
-- end
break
end
end
end
-- with locative
if data.loc then
-- As far as I can tell, in general both dative singular and
-- ablative singular could be used for the third-declension locative,
-- with different time periods preferring different forms.
-- http://dcc.dickinson.edu/grammar/latin/3rd-declension-locative-case
-- mentions rūrī along with either Carthāginī or Carthāgine.
-- Wikipedia in https://en.wikipedia.org/wiki/Locative_case#Latin
-- says this:
--
-- In archaic times, the locative singular of third declension nouns
-- was still interchangeable between ablative and dative forms, but in
-- the Augustan Period the use of the ablative form became fixed.
-- Therefore, both forms "rūrī" and "rūre" may be encountered.
--
-- Lewis and Short confirm this.
local loc_sg = forms["dat_sg"]
if type(loc_sg) == "table" then
loc_sg = deep_copy(loc_sg)
else
loc_sg = {loc_sg}
end
local abl_sg = forms["abl_sg"]
if type(abl_sg) == "table" then
for _, form in ipairs(abl_sg) do
insert_if_not(loc_sg, deep_copy(form))
end
else
insert_if_not(loc_sg, abl_sg)
end
forms["loc_sg"] = loc_sg
forms["loc_pl"] = deep_copy(forms["abl_pl"])
--The following is what we used to have, but I simply cannot believe it.
--if types.Greek and not types.s then
-- forms["loc_pl"] = stem2 .. "ēs"
--end
end
end
noun_decl["4"] = function(data, args)
local forms, types, subtitles, notes = data.forms, data.types, data.subtitles, data.notes
local stem = args[1]
insert_if_not(data.title, "cuarta declinación")
insert_if_not(data.categories, "LA:Sustantivos de la cuarta declinación")
-- normal 4th
forms["nom_sg"] = stem .. "us"
forms["gen_sg"] = stem .. "ūs"
forms["dat_sg"] = stem .. "uī"
forms["acc_sg"] = stem .. "um"
forms["abl_sg"] = stem .. "ū"
forms["voc_sg"] = stem .. "us"
forms["nom_pl"] = stem .. "ūs"
forms["gen_pl"] = stem .. "uum"
forms["dat_pl"] = stem .. "ibus"
forms["acc_pl"] = stem .. "ūs"
forms["abl_pl"] = stem .. "ibus"
forms["voc_pl"] = stem .. "ūs"
if types.echo then
for slot in pairs(forms) do
if slot ~= "gen_sg" then
forms[slot] = stem .. "ō"
end
end
add_form(forms, "acc_sg", stem, "ōn")
elseif types.Callisto then
for slot in pairs(forms) do
if slot ~= "gen_sg" then
forms[slot] = stem .. "ō"
end
end
end
-- neuter
if types.N then
forms["nom_sg"] = stem .. "ū̆{?}"
forms["gen_sg"] = {stem .. "ūs{C}", stem .. "ū{S}"}
forms["dat_sg"] = {stem .. "uī{C}", stem .. "ū{S}"}
forms["acc_sg"] = stem .. "ū̆{?}"
forms["voc_sg"] = stem .. "ū̆{?}"
forms["nom_pl"] = stem .. "ua"
forms["acc_pl"] = stem .. "ua"
forms["voc_pl"] = stem .. "ua"
end
-- ubus
if types.ubus then
forms["dat_pl"] = stem .. "ubus"
forms["abl_pl"] = stem .. "ubus"
end
-- with locative
if data.loc then
forms["loc_sg"] = forms["abl_sg"]
forms["loc_pl"] = forms["abl_pl"]
end
end
noun_decl["5"] = function(data, args)
local forms, types = data.forms, data.types
local stem = args[1]
insert_if_not(data.title, "quinta declinación")
insert_if_not(data.categories, "LA:Sustantivos de la quinta declinación")
-- ies
if types.i then
stem = stem .. "i"
end
forms["nom_sg"] = stem .. "ēs"
forms["gen_sg"] = stem .. "eī"
forms["dat_sg"] = stem .. "eī"
forms["acc_sg"] = stem .. "em"
forms["abl_sg"] = stem .. "ē"
forms["voc_sg"] = stem .. "ēs"
forms["nom_pl"] = stem .. "ēs"
forms["gen_pl"] = stem .. "ērum"
forms["dat_pl"] = stem .. "ēbus"
forms["acc_pl"] = stem .. "ēs"
forms["abl_pl"] = stem .. "ēbus"
forms["voc_pl"] = stem .. "ēs"
-- ies
if types.i then
forms["gen_sg"] = stem .. "ēī"
forms["dat_sg"] = stem .. "ēī"
end
--with locative
if data.loc then
forms["loc_sg"] = stem .. "ē"
forms["loc_pl"] = stem .. "ēbus"
end
end
noun_decl["sgpl"] = function(data, args)
local forms = data.forms
local stem1, stem2 = args[1], args[2]
insert_if_not(data.title, "indeclinable")
insert_if_not(data.categories, "LA:Sustantivos indeclinables")
forms["nom_sg"] = stem1
forms["gen_sg"] = stem1
forms["dat_sg"] = stem1
forms["acc_sg"] = stem1
forms["abl_sg"] = stem1
forms["voc_sg"] = stem1
forms["nom_pl"] = stem2
forms["gen_pl"] = stem2
forms["dat_pl"] = stem2
forms["acc_pl"] = stem2
forms["abl_pl"] = stem2
forms["voc_pl"] = stem2
-- with locative
if data.loc then
forms["loc_sg"] = stem1
forms["loc_pl"] = stem2
end
end
noun_decl["indecl"] = function(data, args)
local forms = data.forms
local stem = args[1]
insert_if_not(data.title, "indeclinable")
insert_if_not(data.categories, "LA:Sustantivos indeclinables")
forms["nom_sg"] = stem
forms["gen_sg"] = {}
forms["dat_sg"] = {}
forms["acc_sg"] = stem
forms["abl_sg"] = {}
forms["voc_sg"] = {}
forms["nom_pl"] = {}
forms["gen_pl"] = {}
forms["dat_pl"] = {}
forms["acc_pl"] = {}
forms["abl_pl"] = {}
forms["voc_pl"] = {}
-- with locative (for multiword terms)
if data.loc then
forms["loc_sg"] = {}
forms["loc_pl"] = {}
end
data.num = "sg"
end
noun_decl["irreg"] = function(data, args)
local forms, subtitles, notes = data.forms, data.subtitles, data.notes
local stem = args[1]
insert_if_not(data.title, "irregular")
insert_if_not(data.categories, "LA:Sustantivos irregulares")
forms["nom_sg"] = {}
forms["gen_sg"] = {}
forms["dat_sg"] = {}
forms["acc_sg"] = {}
forms["abl_sg"] = {}
forms["voc_sg"] = {}
forms["nom_pl"] = {}
forms["gen_pl"] = {}
forms["dat_pl"] = {}
forms["acc_pl"] = {}
forms["abl_pl"] = {}
forms["voc_pl"] = {}
if stem == "bōs" then
data.decl = "3"
local stem1, stem2 = "bōs", "bov"
noun_decl["3"](data, {stem1, stem2})
add_form(forms, "abl_sg", stem2, "īd{†}")
add_form(forms, "gen_pl", "bo", "um")
add_form(forms, "gen_pl", stem2, "erum")
add_form(forms, "dat_pl", "", "bōbus")
add_form(forms, "dat_pl", "", "būbus")
add_form(forms, "abl_pl", "", "bōbus")
add_form(forms, "abl_pl", "", "būbus")
elseif stem:match("^[dD]eus$") then
data.decl = "2"
local dD = stem:sub(1, 1)
forms["nom_sg"] = dD .. "eus"
forms["gen_sg"] = dD .. "eī"
forms["dat_sg"] = dD .. "eō"
forms["acc_sg"] = dD .. "eum"
forms["abl_sg"] = dD .. "eō"
forms["voc_sg"] = {dD .. "eus", dD .. "ee"}
if stem == "deus" then
forms["nom_pl"] = {"dī", "diī", "deī"}
forms["gen_pl"] = {"deōrum", "deum"}
forms["dat_pl"] = {"dīs", "diīs", "deīs"}
forms["acc_pl"] = "deōs"
forms["abl_pl"] = {"dīs", "diīs", "deīs"}
forms["voc_pl"] = {"dī", "diī", "deī"}
end
elseif stem == "domus" then
data.decl = "4,2"
insert_if_not(data.title, "cuarta/segunda declinación")
forms["nom_sg"] = "domus"
forms["gen_sg"] = {"domūs", "domī"}
forms["dat_sg"] = {"domuī", "domō", "domū"}
forms["acc_sg"] = "domum"
forms["abl_sg"] = {"domū", "domō"}
forms["voc_sg"] = "domus"
forms["loc_sg"] = "domī"
forms["nom_pl"] = "domūs"
forms["gen_pl"] = {"domuum", "domōrum"}
forms["dat_pl"] = "domibus"
forms["acc_pl"] = {"domūs", "domōs"}
forms["abl_pl"] = "domibus"
forms["voc_pl"] = "domūs"
forms["loc_pl"] = {}
data.loc = true
elseif match(stem, "^[IÏJ]ēs[uū]" .. BREVE .. "?s$") then
local ij = sub(stem, 1, 1)
local uu = match(stem, "[uū]" .. BREVE .. "?")
forms["nom_sg"] = stem
forms["gen_sg"] = ij .. "ēsū"
forms["dat_sg"] = ij .. "ēsū"
forms["acc_sg"] = ij .. "ēs" .. uu .. "m"
forms["abl_sg"] = ij .. "ēsū"
forms["voc_sg"] = ij .. "ēsū"
data.num = "sg"
elseif stem == "Mōsēs" or stem == "Moesēs" or match(stem, "^M[oō]" .. BREVE .. "?[īȳ]sēs$") then
local mos = sub(stem, 1, -3)
forms["nom_sg"] = stem
forms["gen_sg"] = {mos .. "ī", mos .. "ēī", mos .. "is", mos .. "ēn", mos .. "eōs"}
forms["dat_sg"] = mos .. "ī"
forms["acc_sg"] = {mos .. "ēn", mos .. "em"}
forms["abl_sg"] = {mos .. "e", mos .. "ēn", mos .. "ī"}
forms["voc_sg"] = {mos .. "ēs", mos .. "ē"}
data.num = "sg"
elseif stem:match("^[ij]ūgerum$") then
data.decl = "2,3"
local ij = stem:sub(1, 1)
insert_if_not(data.title, "segunda/tercera declinación híbrido")
forms["nom_sg"] = ij .. "ūgerum"
forms["gen_sg"] = ij .. "ūgerī"
forms["dat_sg"] = ij .. "ūgerō"
forms["acc_sg"] = ij .. "ūgerum"
forms["abl_sg"] = ij .. "ūgerō"
forms["voc_sg"] = ij .. "ūgerum"
forms["nom_pl"] = ij .. "ūgera"
forms["gen_pl"] = ij .. "ūgerum"
forms["dat_pl"] = ij .. "ūgeribus"
forms["acc_pl"] = ij .. "ūgera"
forms["abl_pl"] = {ij .. "ūgeribus", ij .. "ūgerīs{†}"}
forms["voc_pl"] = ij .. "ūgera"
elseif stem == "sūs" then
data.decl = "3"
forms["nom_sg"] = "sūs"
forms["gen_sg"] = "suis"
forms["dat_sg"] = "suī"
forms["acc_sg"] = "suem"
forms["abl_sg"] = "sue"
forms["voc_sg"] = "sūs"
forms["nom_pl"] = "suēs"
forms["gen_pl"] = "suum"
forms["dat_pl"] = {"suibus", "sūbus", "subus"}
forms["acc_pl"] = "suēs"
forms["abl_pl"] = {"suibus", "sūbus", "subus"}
forms["voc_pl"] = "suēs"
elseif stem == "ēthos" then
data.decl = "3"
insert_if_not(data.title, "tercera declinación, griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = "ēthos"
forms["gen_sg"] = "ētheos"
forms["acc_sg"] = "ēthos"
forms["voc_sg"] = "ēthos"
forms["nom_pl"] = {"ēthea", "ēthē"}
forms["dat_pl"] = {"ēthesi", "ēthesin"}
forms["acc_pl"] = {"ēthea", "ēthē"}
forms["abl_pl"] = {"ēthesi", "ēthesin"}
forms["voc_pl"] = {"ēthea", "ēthē"}
elseif stem == "Athōs" then
data.decl = "2"
insert_if_not(data.title, "segunda declinación, griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = "Athōs"
forms["gen_sg"] = "Athō"
forms["dat_sg"] = "Athō"
forms["acc_sg"] = {"Athō", "Athōn"}
forms["abl_sg"] = "Athō"
forms["voc_sg"] = "Athōs"
data.num = "sg"
elseif stem:match("^[uv]ēnum$") then
data.decl = "4,2"
local uv = stem:sub(1, 1)
insert_if_not(data.title, "cuarta/segunda declinación, defectivo")
forms["dat_sg"] = {uv .. "ēnuī", uv .. "ēnō"}
forms["acc_sg"] = uv .. "ēnum"
data.num = "sg"
elseif stem:match("^[uv]īs$") then
data.decl = "3"
local uv = stem:sub(1, 1)
insert_if_not(data.title, "defectivo")
forms["nom_sg"] = uv .. "īs"
forms["gen_sg"] = uv .. "īs"
forms["dat_sg"] = uv .. "ī"
forms["acc_sg"] = uv .. "im"
forms["abl_sg"] = uv .. "ī"
forms["voc_sg"] = uv .. "īs"
forms["nom_pl"] = uv .. "īrēs"
forms["gen_pl"] = uv .. "īrium"
forms["dat_pl"] = uv .. "īribus"
forms["acc_pl"] = {uv .. "īrēs", uv .. "īrīs"}
forms["abl_pl"] = uv .. "īribus"
forms["voc_pl"] = uv .. "īrēs"
else
error("Stem " .. stem .. " not recognized.")
end
end
local adj_decl = {}
adj_decl["0+"] = function(data, args)
local forms, categories = data.forms, data.categories
local stem = args[1]
insert_if_not(data.title, "indeclinable")
insert_if_not(categories, "LA:Adjetivos indeclinables")
forms["nom_sg_m"] = stem
forms["nom_pl_m"] = stem
forms["gen_sg_m"] = stem
forms["gen_pl_m"] = stem
forms["dat_sg_m"] = stem
forms["dat_pl_m"] = stem
forms["acc_sg_m"] = stem
forms["acc_pl_m"] = stem
forms["abl_sg_m"] = stem
forms["abl_pl_m"] = stem
forms["voc_sg_m"] = stem
forms["voc_pl_m"] = stem
forms["loc_sg_m"] = stem
forms["loc_pl_m"] = stem
end
adj_decl["1&2+"] = function(data, args)
local forms, types, pos, subtitles, categories = data.forms, data.types, data.pos, data.subtitles, data.categories
local stem = args[1]
insert_if_not(data.title, "primera y segunda declinación")
insert_if_not(categories, "LA:Adjetivos de la primera declinación")
insert_if_not(categories, "LA:Adjetivos de la segunda declinación")
local original
if types.er then
local final2 = stem:sub(-2)
if final2 == "er" then
-- insert_if_not(categories, "LA:Sustantivos de la primera declinación")
-- insert_if_not(categories, "LA:Sustantivos de la segunda declinación")
elseif final2 == "ur" then
-- insert_if_not(categories, "LA:Sustantivos de la primera declinación")
-- insert_if_not(categories, "LA:Sustantivos de la segunda declinación")
else
error("Unrecognized ''-r'' stem (doesn't end in ''-er'' or ''-ur''): " .. stem)
end
stem, original = args[2], stem
end
local us = "us"
local a_sf = "a"
local um = "um"
local ae_gsf = "ae"
local am = "am"
local a_macron = "ā"
local i_pl = stem .. "ī"
if types.greekA or types.greekE then
insert_if_not(data.title, "griego")
insert_if_not(categories, "LA:Sustantivos griegos")
if types.greekA then
us = "os"
um = "on"
am = "ān"
else
us = "os"
a_sf = "ē"
um = "on"
ae_gsf = "ēs"
am = "ēn"
a_macron = "ē"
end
i_pl = {i_pl, stem .. "oe"}
end
forms["nom_sg_m"] = original or (stem .. us)
forms["nom_sg_f"] = stem .. a_sf
forms["nom_sg_n"] = stem .. um
forms["nom_pl_m"] = i_pl
forms["nom_pl_f"] = stem .. "ae"
forms["nom_pl_n"] = stem .. "a"
forms["gen_sg_m"] = stem .. "ī"
forms["gen_sg_f"] = stem .. ae_gsf
forms["gen_sg_n"] = stem .. "ī"
forms["gen_pl_m"] = stem .. "ōrum"
forms["gen_pl_f"] = stem .. "ārum"
forms["gen_pl_n"] = stem .. "ōrum"
forms["dat_sg_m"] = stem .. "ō"
forms["dat_sg_f"] = stem .. "ae"
forms["dat_sg_n"] = stem .. "ō"
forms["dat_pl_m"] = stem .. "īs"
forms["dat_pl_f"] = stem .. "īs"
forms["dat_pl_n"] = stem .. "īs"
forms["acc_sg_m"] = stem .. um
forms["acc_sg_f"] = stem .. am
forms["acc_sg_n"] = stem .. um
forms["acc_pl_m"] = stem .. "ōs"
forms["acc_pl_f"] = stem .. "ās"
forms["acc_pl_n"] = stem .. "a"
forms["abl_sg_m"] = stem .. "ō"
forms["abl_sg_f"] = stem .. a_macron
forms["abl_sg_n"] = stem .. "ō"
forms["abl_pl_m"] = stem .. "īs"
forms["abl_pl_f"] = stem .. "īs"
forms["abl_pl_n"] = stem .. "īs"
forms["voc_sg_m"] = original or (stem .. "e")
forms["voc_sg_f"] = stem .. a_sf
forms["voc_sg_n"] = stem .. um
forms["voc_pl_m"] = i_pl
forms["voc_pl_f"] = stem .. "ae"
forms["voc_pl_n"] = stem .. "a"
if types.ius then
insert_if_not(data.title, "pronominal")
--insert_if_not(subtitles, "with genitive singular in ''-ī̆us'' and dative singular in ''-ī''")
forms["gen_sg_m"] = stem .. "ī̆us"
forms["gen_sg_f"] = stem .. "ī̆us"
forms["gen_sg_n"] = stem .. "ī̆us"
forms["dat_sg_m"] = stem .. "ī"
forms["dat_sg_f"] = stem .. "ī"
forms["dat_sg_n"] = stem .. "ī"
elseif types.not_ius then
insert_if_not(data.title, "no pronominal")
--insert_if_not(subtitles, "with normal genitive and dative singular")
end
if stem == "me" then
forms["voc_sg_m"] = "mī"
end
if types.ic then
--insert_if_not(subtitles, "with genitive singular ending in ''-ius'' and dative singular ending in ''-ic''")
local oc = "oc"
local oc_macron = "ōc"
if stem == "ill" then
oc = "uc"
oc_macron = "ūc"
end
forms["nom_sg_m"] = stem .. "ic"
forms["nom_sg_f"] = stem .. "aec"
forms["nom_sg_n"] = stem .. oc
forms["nom_pl_n"] = stem .. "aec"
forms["gen_sg_m"] = stem .. "uius"
forms["gen_sg_f"] = stem .. "uius"
forms["gen_sg_n"] = stem .. "uius"
forms["dat_sg_m"] = stem .. "uic"
forms["dat_sg_f"] = stem .. "uic"
forms["dat_sg_n"] = stem .. "uic"
forms["acc_sg_m"] = stem .. "unc"
forms["acc_sg_f"] = stem .. "anc"
forms["acc_sg_n"] = stem .. oc
forms["acc_pl_n"] = stem .. "aec"
forms["abl_sg_m"] = stem .. "ōc"
forms["abl_sg_f"] = stem .. "āc"
forms["abl_sg_n"] = stem .. oc_macron
forms["voc_sg_m"] = {}
forms["voc_sg_f"] = {}
forms["voc_sg_n"] = {}
forms["voc_pl_m"] = {}
forms["voc_pl_f"] = {}
forms["voc_pl_n"] = {}
end
if types.distr then
if stem:sub(-1) == "n" then
forms["gen_pl_m"] = {stem .. "um", stem .. "ōrum{R}"}
forms["gen_pl_f"] = {stem .. "um", stem .. "ārum{R}"}
forms["gen_pl_n"] = {stem .. "um", stem .. "ōrum{R}"}
else
error("Unrecognized distributive numeral stem (doesn't end in ''n''): " .. stem)
end
original = stem
stem = args[2]
end
forms["loc_sg_m"] = deep_copy(forms["gen_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["gen_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["gen_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_f"] = deep_copy(forms["abl_pl_f"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
adj_decl["1-1+"] = function(data, args)
local forms, subtitles, categories = data.forms, data.subtitles, data.categories
local stem = args[1]
insert_if_not(data.title, "primera declinación")
insert_if_not(categories, "LA:Adjetivos de la primera declinación")
forms["nom_sg_m"] = stem .. "a"
forms["nom_pl_m"] = stem .. "ae"
forms["nom_pl_n"] = stem .. "a"
forms["gen_sg_m"] = stem .. "ae"
forms["gen_pl_m"] = stem .. "ārum"
forms["dat_sg_m"] = stem .. "ae"
forms["dat_pl_m"] = stem .. "īs"
forms["acc_sg_m"] = stem .. "am"
forms["acc_sg_n"] = stem .. "a"
forms["acc_pl_m"] = stem .. "ās"
forms["acc_pl_n"] = stem .. "a"
forms["abl_sg_m"] = stem .. "ā"
forms["abl_pl_m"] = stem .. "īs"
forms["voc_sg_m"] = stem .. "a"
forms["voc_pl_m"] = stem .. "ae"
forms["voc_pl_n"] = stem .. "a"
forms["loc_sg_m"] = deep_copy(forms["gen_sg_m"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
end
adj_decl["2-2+"] = function(data, args)
local forms, types, pos, subtitles, categories = data.forms, data.types, data.pos, data.subtitles, data.categories
local stem = args[1]
insert_if_not(data.title, "segunda declinación")
insert_if_not(categories, "LA:Adjetivos de la segunda declinación")
local us = "us"
local um = "um"
local i_pl = stem .. "ī"
if types.greek then
insert_if_not(data.title, "griego")
insert_if_not(categories, "LA:Sustantivos griegos")
us = "os"
um = "on"
i_pl = {i_pl, stem .. "oe"}
end
forms["nom_sg_m"] = stem .. us
forms["nom_sg_n"] = stem .. um
forms["nom_pl_m"] = i_pl
forms["nom_pl_n"] = stem .. "a"
forms["gen_sg_m"] = stem .. "ī"
forms["gen_sg_n"] = stem .. "ī"
forms["gen_pl_m"] = stem .. "ōrum"
forms["gen_pl_n"] = stem .. "ōrum"
forms["dat_sg_m"] = stem .. "ō"
forms["dat_sg_n"] = stem .. "ō"
forms["dat_pl_m"] = stem .. "īs"
forms["dat_pl_n"] = stem .. "īs"
forms["acc_sg_m"] = stem .. um
forms["acc_sg_n"] = stem .. um
forms["acc_pl_m"] = stem .. "ōs"
forms["acc_pl_n"] = stem .. "a"
forms["abl_sg_m"] = stem .. "ō"
forms["abl_sg_n"] = stem .. "ō"
forms["abl_pl_m"] = stem .. "īs"
forms["abl_pl_n"] = stem .. "īs"
forms["voc_sg_m"] = stem .. "e"
forms["voc_sg_n"] = stem .. um
forms["voc_pl_m"] = i_pl
forms["voc_pl_n"] = stem .. "a"
forms["loc_sg_m"] = deep_copy(forms["gen_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["gen_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
local function abl_i_e(...)
local function update_slot(forms, slot, f, do_copy)
if not forms[slot] then
return do_copy
elseif do_copy then
f = deep_copy(f)
end
forms[slot] = f
return true
end
function abl_i_e(stem, forms, types)
local f, do_copy
if types["abl_e_i"] then
f = {stem .. "e", stem .. "ī"}
elseif types["abl_i_e"] then
f = {stem .. "ī", stem .. "e"}
else
return
end
do_copy = update_slot(forms, "abl_sg_m", f, do_copy)
do_copy = update_slot(forms, "abl_sg_f", f, do_copy)
-- Neuter doesn't take -e with i-stems.
if not types.I then
update_slot(forms, "abl_sg_n", f, do_copy)
end
end
return abl_i_e(...)
end
adj_decl["3-1+"] = function(data, args)
local forms, types, pos, subtitles, notes, categories = data.forms, data.types, data.pos, data.subtitles, data.notes, data.categories
local stem1, stem2 = args[1], args[2]
-- local singpos = singularize(pos)
insert_if_not(data.title, "tercera declinación, dos terminaciones")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación con dos terminaciones")
forms["nom_sg_m"] = stem1
forms["nom_sg_n"] = stem1
forms["nom_pl_m"] = stem2 .. "ēs"
forms["nom_pl_n"] = stem2 .. "ia"
forms["gen_sg_m"] = stem2 .. "is"
forms["gen_sg_n"] = stem2 .. "is"
forms["gen_pl_m"] = stem2 .. "ium"
forms["gen_pl_n"] = stem2 .. "ium"
forms["dat_sg_m"] = stem2 .. "ī"
forms["dat_sg_n"] = stem2 .. "ī"
forms["dat_pl_m"] = stem2 .. "ibus"
forms["dat_pl_n"] = stem2 .. "ibus"
forms["acc_sg_m"] = stem2 .. "em"
forms["acc_sg_n"] = stem1
forms["acc_pl_m"] = {stem2 .. "īs", stem2 .. "ēs"}
forms["acc_pl_n"] = stem2 .. "ia"
forms["abl_sg_m"] = stem2 .. "ī"
forms["abl_sg_n"] = stem2 .. "ī"
forms["abl_pl_m"] = stem2 .. "ibus"
forms["abl_pl_n"] = stem2 .. "ibus"
abl_i_e(stem2, forms, types)
forms["voc_sg_m"] = stem1
forms["voc_sg_n"] = stem1
forms["voc_pl_m"] = stem2 .. "ēs"
forms["voc_pl_n"] = stem2 .. "ia"
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
if types.par then
forms["nom_pl_n"] = stem2 .. "a"
forms["gen_pl_m"] = stem2 .. "um"
forms["gen_pl_n"] = stem2 .. "um"
forms["abl_sg_m"] = stem2 .. "e"
forms["abl_sg_n"] = stem2 .. "e"
forms["loc_sg_m"] = {stem2 .. "ī", stem2 .. "e"} -- Really?
forms["loc_sg_n"] = {stem2 .. "ī", stem2 .. "e"} -- Why does this happen?
forms["acc_pl_n"] = stem2 .. "a"
forms["voc_pl_n"] = stem2 .. "a"
end
local es_base = stem1:match("^(.-)ēs$")
if es_base and es_base == stem2 then
if types.greek then
forms["nom_sg_n"] = {stem2 .. "ē̆s{?}"}
forms["acc_sg_n"] = {stem2 .. "ē̆s{?}"}
forms["voc_sg_m"] = {stem2 .. "ē̆s{?}"}
forms["voc_sg_n"] = {stem2 .. "ē̆s{?}"}
forms["nom_pl_n"] = {stem2 .. "a{?}", stem2 .. "ia{?}"}
forms["acc_pl_n"] = {stem2 .. "a{?}", stem2 .. "ia{?}"}
forms["voc_pl_n"] = {stem2 .. "a{?}", stem2 .. "ia{?}"}
forms["abl_sg_m"] = {stem2 .. "e{?}", stem2 .. "ī{?}"}
forms["abl_sg_n"] = {stem2 .. "e{?}", stem2 .. "ī{?}"}
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["gen_pl_m"] = {stem2 .. "um{?}", stem2 .. "ium{?}"}
forms["gen_pl_n"] = {stem2 .. "um{?}", stem2 .. "ium{?}"}
insert_if_not(data.title, "griego")
insert_if_not(categories, "LA:Adjetivos griegos")
elseif types.not_greek then
insert_if_not(data.title, "no griego")
end
end
end
adj_decl["3-def+"] = function(data, args)
local forms, types, pos, subtitles, notes, categories = data.forms, data.types, data.pos, data.subtitles, data.notes, data.categories
local stem1, stem2 = args[1], args[2]
-- local singpos = singularize(pos)
insert_if_not(data.title, "tercera declinación, defectivo")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación")
forms["nom_sg_m"] = stem1
forms["nom_sg_n"] = stem1
forms["nom_pl_m"] = stem2 .. "ēs"
forms["nom_pl_n"] = stem2 .. "ia"
forms["gen_sg_m"] = stem2 .. "is"
forms["gen_sg_n"] = stem2 .. "is"
forms["gen_pl_m"] = stem2 .. "ium"
forms["gen_pl_n"] = stem2 .. "ium"
forms["dat_sg_m"] = stem2 .. "ī"
forms["dat_sg_n"] = stem2 .. "ī"
forms["dat_pl_m"] = stem2 .. "ibus"
forms["dat_pl_n"] = stem2 .. "ibus"
forms["acc_sg_m"] = stem2 .. "em"
forms["acc_sg_n"] = stem1
forms["acc_pl_m"] = stem2 .. "ēs"
forms["acc_pl_n"] = stem2 .. "ia"
forms["abl_sg_m"] = stem2 .. "ī"
forms["abl_sg_n"] = stem2 .. "ī"
forms["abl_pl_m"] = stem2 .. "ibus"
forms["abl_pl_n"] = stem2 .. "ibus"
forms["voc_sg_m"] = stem1
forms["voc_sg_n"] = stem1
forms["voc_pl_m"] = stem2 .. "ēs"
forms["voc_pl_n"] = stem2 .. "ia"
if types.tor then
insert_if_not(data.title, "tercera declinación, solo en masculino")
insert_if_not(categories, "LA:Adjetivos solo en masculino")
remove_forms(forms, {"_f$", "_n$"})
forms["nom_sg_m"] = stem1
forms["gen_sg_m"] = stem2 .. "is"
forms["dat_sg_m"] = stem2 .. "ī"
forms["acc_sg_m"] = stem2 .. "em"
forms["abl_sg_m"] = stem2 .. "e"
forms["voc_sg_m"] = stem1
forms["nom_pl_m"] = stem2 .. "ēs"
forms["gen_pl_m"] = stem2 .. "um"
forms["dat_pl_m"] = stem2 .. "ibus"
forms["acc_pl_m"] = stem2 .. "ēs"
forms["abl_pl_m"] = stem2 .. "ibus"
forms["voc_pl_m"] = stem2 .. "ēs"
end
if types.trix then
insert_if_not(data.title, "tercera declinación, solo en femenino o en neutro plural")
insert_if_not(categories, "LA:Adjetivos solo en femenino")
insert_if_not(categories, "LA:Adjetivos solo en neutro")
remove_forms(forms, {"_m$", "sg_n$"})
forms["nom_sg_f"] = stem1
forms["gen_sg_f"] = stem2 .. "is"
forms["dat_sg_f"] = stem2 .. "ī"
forms["acc_sg_f"] = stem2 .. "em"
forms["abl_sg_f"] = {stem2 .. "e", stem2 .. "ī"}
forms["voc_sg_f"] = stem1
forms["nom_pl_f"] = stem2 .. "ēs"
forms["gen_pl_f"] = stem2 .. "ium"
forms["dat_pl_f"] = stem2 .. "ibus"
forms["acc_pl_f"] = stem2 .. "ēs"
forms["abl_pl_f"] = stem2 .. "ibus"
forms["voc_pl_f"] = stem2 .. "ēs"
end
if types.trixf then
insert_if_not(data.title, "tercera declinación, solo en femenino")
insert_if_not(categories, "LA:Adjetivos solo en femenino")
remove_forms(forms, {"_m$","_n$"})
forms["nom_sg_f"] = stem1
forms["gen_sg_f"] = stem2 .. "is"
forms["dat_sg_f"] = stem2 .. "ī"
forms["acc_sg_f"] = stem2 .. "em"
forms["abl_sg_f"] = {stem2 .. "e", stem2 .. "ī"}
forms["voc_sg_f"] = stem1
forms["nom_pl_f"] = stem2 .. "ēs"
forms["gen_pl_f"] = stem2 .. "ium"
forms["dat_pl_f"] = stem2 .. "ibus"
forms["acc_pl_f"] = stem2 .. "ēs"
forms["abl_pl_f"] = stem2 .. "ibus"
forms["voc_pl_f"] = stem2 .. "ēs"
end
if types.idis then
insert_if_not(data.title, "tercera declinación, solo en femenino")
insert_if_not(categories, "LA:Adjetivos solo en femenino")
remove_forms(forms, {"_m$","_n$"})
forms["nom_sg_f"] = stem1
forms["gen_sg_f"] = {stem2 .. "is", stem2 .. "os"}
forms["dat_sg_f"] = stem2 .. "ī"
forms["acc_sg_f"] = {stem2 .. "em", stem2 .. "a"}
forms["abl_sg_f"] = stem2 .. "e"
forms["voc_sg_f"] = stem1
forms["nom_pl_f"] = {stem2 .. "ēs", stem2 .. "es"}
forms["gen_pl_f"] = stem2 .. "um"
forms["dat_pl_f"] = stem2 .. "ibus"
forms["acc_pl_f"] = {stem2 .. "ēs", stem2 .. "as"}
forms["abl_pl_f"] = stem2 .. "ibus"
forms["voc_pl_f"] = {stem2 .. "ēs", stem2 .. "es"}
end
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["abl_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_f"] = deep_copy(forms["abl_pl_f"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
adj_decl["3-C+"] = function(data, args)
local forms, types, pos, categories = data.forms, data.types, data.pos, data.categories
local stem1 = args[1]
local stem2 = stem1 .. "ōr"
insert_if_not(data.title, "tercera declinación, comparativo")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación")
insert_if_not(categories, "LA:Adjetivos comparativos")
forms["nom_sg_m"] = stem1 .. "or"
forms["nom_sg_n"] = stem1 .. "us"
forms["nom_pl_m"] = stem2 .. "ēs"
forms["nom_pl_n"] = stem2 .. "a"
forms["gen_sg_m"] = stem2 .. "is"
forms["gen_sg_n"] = stem2 .. "is"
forms["gen_pl_m"] = stem2 .. "um"
forms["gen_pl_n"] = stem2 .. "um"
forms["dat_sg_m"] = stem2 .. "ī"
forms["dat_sg_n"] = stem2 .. "ī"
forms["dat_pl_m"] = stem2 .. "ibus"
forms["dat_pl_n"] = stem2 .. "ibus"
forms["acc_sg_m"] = stem2 .. "em"
forms["acc_sg_n"] = stem1 .. "us"
forms["acc_pl_m"] = {stem2 .. "ēs", stem2 .. "īs"}
forms["acc_pl_n"] = stem2 .. "a"
forms["abl_sg_m"] = stem2 .. "ī"
forms["abl_sg_n"] = stem2 .. "ī"
forms["abl_pl_m"] = stem2 .. "ibus"
forms["abl_pl_n"] = stem2 .. "ibus"
abl_i_e(stem2, forms, types)
forms["voc_sg_m"] = stem1 .. "or"
forms["voc_sg_n"] = stem1 .. "us"
forms["voc_pl_m"] = stem2 .. "ēs"
forms["voc_pl_n"] = stem2 .. "a"
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
adj_decl["3-P+"] = function(data, args)
local forms, notes = data.forms, data.notes
local stem2 = args[2]
adj_decl["3-1+"](data, args)
insert_if_not(data.title, "tercera declinación, participio")
insert_if_not(data.categories, "LA:Adjetivos de la tercera declinación")
forms["abl_sg_m"] = {stem2 .. "e{PART}", stem2 .. "ī{ADJ}"}
forms["abl_sg_n"] = {stem2 .. "e{PART}", stem2 .. "ī{ADJ}"}
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["acc_pl_m"] = {stem2 .. "ēs", stem2 .. "īs"}
end
adj_decl["3-2+"] = function(data, args)
local forms, types, pos, categories = data.forms, data.types, data.pos, data.categories
local stem = args[1]
-- local singpos = singularize(pos)
insert_if_not(data.title, "tercera declinación, dos terminaciones")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación con dos terminaciones")
forms["nom_sg_m"] = stem .. "is"
forms["nom_sg_n"] = stem .. "e"
forms["nom_pl_m"] = stem .. "ēs"
forms["nom_pl_n"] = stem .. "ia"
forms["gen_sg_m"] = stem .. "is"
forms["gen_sg_n"] = stem .. "is"
forms["gen_pl_m"] = stem .. "ium"
forms["gen_pl_n"] = stem .. "ium"
forms["dat_sg_m"] = stem .. "ī"
forms["dat_sg_n"] = stem .. "ī"
forms["dat_pl_m"] = stem .. "ibus"
forms["dat_pl_n"] = stem .. "ibus"
forms["acc_sg_m"] = stem .. "em"
forms["acc_sg_n"] = stem .. "e"
forms["acc_pl_m"] = {stem .. "īs", stem .. "ēs"}
forms["acc_pl_n"] = stem .. "ia"
forms["abl_sg_m"] = stem .. "ī"
forms["abl_sg_n"] = stem .. "ī"
forms["abl_pl_m"] = stem .. "ibus"
forms["abl_pl_n"] = stem .. "ibus"
-- abl_i_e(stem, forms, types) -- enable once [[Module:la-nominal]] has ben updated
forms["voc_sg_m"] = stem .. "is"
forms["voc_sg_n"] = stem .. "e"
forms["voc_pl_m"] = stem .. "ēs"
forms["voc_pl_n"] = stem .. "ia"
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
adj_decl["3-3+"] = function(data, args)
local forms, types, pos, categories = data.forms, data.types, data.pos, data.categories
local stem1, stem2 = args[1], args[2]
-- local singpos = singularize(pos)
insert_if_not(data.title, "tercera declinación")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación con tres terminaciones")
forms["nom_sg_m"] = stem1
forms["nom_sg_f"] = stem2 .. "is"
forms["nom_sg_n"] = stem2 .. "e"
forms["nom_pl_m"] = stem2 .. "ēs"
forms["nom_pl_f"] = stem2 .. "ēs"
forms["nom_pl_n"] = stem2 .. "ia"
forms["gen_sg_m"] = stem2 .. "is"
forms["gen_sg_f"] = stem2 .. "is"
forms["gen_sg_n"] = stem2 .. "is"
forms["gen_pl_m"] = stem2 .. "ium"
forms["gen_pl_f"] = stem2 .. "ium"
forms["gen_pl_n"] = stem2 .. "ium"
forms["dat_sg_m"] = stem2 .. "ī"
forms["dat_sg_f"] = stem2 .. "ī"
forms["dat_sg_n"] = stem2 .. "ī"
forms["dat_pl_m"] = stem2 .. "ibus"
forms["dat_pl_f"] = stem2 .. "ibus"
forms["dat_pl_n"] = stem2 .. "ibus"
forms["acc_sg_m"] = stem2 .. "em"
forms["acc_sg_f"] = stem2 .. "em"
forms["acc_sg_n"] = stem2 .. "e"
forms["acc_pl_m"] = {stem2 .. "īs", stem2 .. "ēs"}
forms["acc_pl_f"] = {stem2 .. "īs", stem2 .. "ēs"}
forms["acc_pl_n"] = stem2 .. "ia"
forms["abl_sg_m"] = stem2 .. "ī"
forms["abl_sg_f"] = stem2 .. "ī"
forms["abl_sg_n"] = stem2 .. "ī"
forms["abl_pl_m"] = stem2 .. "ibus"
forms["abl_pl_f"] = stem2 .. "ibus"
forms["abl_pl_n"] = stem2 .. "ibus"
-- abl_i_e(stem2, forms, types) -- enable once [[Module:la-nominal]] has ben updated
forms["voc_sg_m"] = stem1
forms["voc_sg_f"] = stem2 .. "is"
forms["voc_sg_n"] = stem2 .. "e"
forms["voc_pl_m"] = stem2 .. "ēs"
forms["voc_pl_f"] = stem2 .. "ēs"
forms["voc_pl_n"] = stem2 .. "ia"
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["abl_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_f"] = deep_copy(forms["abl_pl_f"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
adj_decl["indecl+"] = function(data, args)
local forms, subtitles, categories = data.forms, data.subtitles, data.categories
local stem = args[1]
insert_if_not(data.title, "indeclinable")
insert_if_not(categories, "LA:Adjetivos indeclinables")
forms["nom_sg_m"] = stem
forms["nom_pl_m"] = {}
forms["gen_sg_m"] = {}
forms["gen_pl_m"] = {}
forms["dat_sg_m"] = {}
forms["dat_pl_m"] = {}
forms["acc_sg_m"] = stem
forms["acc_pl_m"] = {}
forms["abl_sg_m"] = {}
forms["abl_pl_m"] = {}
forms["voc_sg_m"] = {}
forms["voc_pl_m"] = {}
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
end
adj_decl["irreg+"] = function(data,args)
local forms, types, pos, notes, categories = data.forms, data.types, data.pos, data.notes, data.categories
local arg1 = args[1]
insert_if_not(data.title, "irregular")
insert_if_not(categories, "LA:Adjetivos irregulares")
if arg1 == "duo" or arg1 == "ambō" then
local stem = sub(arg1, 1, -2)
-- data.title = stem == "amb" and "irregular adjective" or "numeral"
data.num = "pl"
local stem_with_o = stem .. (stem == "amb" and "ō" or "o")
forms["nom_pl_m"] = stem_with_o
forms["nom_pl_f"] = stem .. "ae"
forms["nom_pl_n"] = stem_with_o
forms["gen_pl_m"] = stem .. "ōrum"
forms["gen_pl_f"] = stem .. "ārum"
forms["gen_pl_n"] = stem .. "ōrum"
forms["dat_pl_m"] = stem .. "ōbus"
forms["dat_pl_f"] = stem .. "ābus"
forms["dat_pl_n"] = stem .. "ōbus"
forms["acc_pl_m"] = {stem .. "ōs", stem_with_o}
forms["acc_pl_f"] = stem .. "ās"
forms["acc_pl_n"] = stem_with_o
forms["abl_pl_m"] = stem .. "ōbus"
forms["abl_pl_f"] = stem .. "ābus"
forms["abl_pl_n"] = stem .. "ōbus"
forms["voc_pl_m"] = stem_with_o
forms["voc_pl_f"] = stem .. "ae"
forms["voc_pl_n"] = stem_with_o
if stem == "du" then
forms["gen_pl_m"] = {forms["gen_pl_m"], "duum", "duom{†}"}
forms["gen_pl_n"] = {forms["gen_pl_n"], "duum", "duom{†}"}
end
elseif arg1:sub(-6) == "mīlle" then
insert_if_not(data.title, "numeral semiindeclinable")
local stem = arg1:sub(1, -3)
forms["nom_sg_m"] = stem .. "le"
forms["nom_pl_m"] = {stem .. "ia", stem .. "lia"}
forms["gen_sg_m"] = stem .. "le"
forms["gen_pl_m"] = {stem .. "ium", stem .. "lium"}
forms["dat_sg_m"] = stem .. "le"
forms["dat_pl_m"] = {stem .. "ibus", stem .. "libus"}
forms["acc_sg_m"] = stem .. "le"
forms["acc_pl_m"] = {stem .. "ia", stem .. "lia"}
forms["abl_sg_m"] = stem .. "le"
forms["abl_pl_m"] = {stem .. "ibus", stem .. "libus"}
forms["voc_sg_m"] = stem .. "le"
forms["voc_pl_m"] = {stem .. "ia", stem .. "lia"}
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
elseif arg1 == "ille" or arg1 == "iste" or arg1 == "ipse" or arg1 == "olle" then
local stem = arg1:sub(1, -2)
types.ius = true
adj_decl["1&2+"](data, {stem})
insert_if_not(data.title, "demostrativo") -- .. " " .. singularize(data.pos)
forms["nom_sg_m"] = arg1
if arg1 == "ipse" then
add_form(forms, "nom_sg_n", stem, "ud{MED}")
add_form(forms, "acc_sg_n", stem, "ud{MED}")
else
forms["nom_sg_n"] = stem .. "ud"
forms["acc_sg_n"] = stem .. "ud"
end
forms["voc_sg_m"] = {}
forms["voc_sg_f"] = {}
forms["voc_sg_n"] = {}
forms["voc_pl_m"] = {}
forms["voc_pl_f"] = {}
forms["voc_pl_n"] = {}
elseif arg1 == "illic" or arg1 == "istic" or arg1 == "isthic" then
insert_if_not(data.title, "demostrativo") -- .. " " .. singularize(data.pos)
local stem = arg1:sub(1, -3)
forms["nom_sg_m"] = stem .. "ic"
forms["nom_sg_f"] = stem .. "aec"
forms["nom_sg_n"] = {stem .. "uc", stem .. "ucce", stem .. "oc"}
forms["gen_sg_m"] = stem .. "ī̆usce"
forms["gen_sg_f"] = stem .. "ī̆usce"
forms["gen_sg_n"] = stem .. "ī̆usce"
forms["dat_sg_m"] = stem .. "īc"
forms["dat_sg_f"] = stem .. "īc"
forms["dat_sg_n"] = stem .. "īc"
forms["acc_sg_m"] = stem .. "unc"
forms["acc_sg_f"] = stem .. "anc"
forms["acc_sg_n"] = {stem .. "uc", stem .. "ucce", stem .. "oc"}
forms["abl_sg_m"] = stem .. "ōc"
forms["abl_sg_f"] = stem .. "āc"
forms["abl_sg_n"] = stem .. "ōc"
forms["loc_sg_m"] = deep_copy(forms["gen_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["gen_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["gen_sg_n"])
forms["nom_pl_m"] = stem .. "īsce"
forms["nom_pl_f"] = stem .. "aec"
forms["nom_pl_n"] = stem .. "aec"
forms["gen_pl_m"] = stem .. "ōrunc{?}"
forms["gen_pl_f"] = stem .. "ārunc{?}"
forms["gen_ok_n"] = stem .. "ōrunc{?}"
forms["dat_pl_m"] = stem .. "īsce"
forms["dat_pl_f"] = stem .. "īsce"
forms["dat_pl_n"] = stem .. "īsce"
forms["acc_pl_m"] = stem .. "ōsce"
forms["acc_pl_f"] = stem .. "āsce"
forms["acc_pl_n"] = stem .. "aec"
forms["abl_pl_m"] = stem .. "īsce"
forms["abl_pl_f"] = stem .. "īsce"
forms["abl_pl_n"] = stem .. "īsce"
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_f"] = deep_copy(forms["abl_pl_f"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
elseif arg1 == "hice" then
insert_if_not(data.title, "demostrativo") -- .. " pronoun"
forms["nom_sg_m"] = "hice"
forms["nom_sg_f"] = "haece"
forms["nom_sg_n"] = "hoce"
forms["nom_pl_m"] = "hīce"
forms["nom_pl_f"] = "haece"
forms["nom_pl_n"] = "haece"
forms["gen_sg_m"] = "huiusce"
forms["gen_sg_f"] = "huiusce"
forms["gen_sg_n"] = "huiusce"
forms["gen_pl_m"] = {"hōrunce", "hōrumce"}
forms["gen_pl_f"] = {"hārunce", "hārumce"}
forms["gen_pl_n"] = {"hōrunce", "hōrumce"}
forms["dat_sg_m"] = "huīce"
forms["dat_sg_f"] = "huīce"
forms["dat_sg_n"] = "huīce"
forms["dat_pl_m"] = "hīsce"
forms["dat_pl_f"] = "hīsce"
forms["dat_pl_n"] = "hīsce"
forms["acc_sg_m"] = "hunce"
forms["acc_sg_f"] = "hance"
forms["acc_sg_n"] = "hoce"
forms["acc_pl_m"] = "hōsce"
forms["acc_pl_f"] = "hāsce"
forms["acc_pl_n"] = "haece"
forms["abl_sg_m"] = "hōce"
forms["abl_sg_f"] = "hāce"
forms["abl_sg_n"] = "hōce"
forms["abl_pl_m"] = "hīsce"
forms["abl_pl_f"] = "hīsce"
forms["abl_pl_n"] = "hīsce"
forms["loc_sg_m"] = deep_copy(forms["gen_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["gen_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["gen_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_f"] = deep_copy(forms["abl_pl_f"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
elseif arg1 == "plūs" then
insert_if_not(data.title, "comparativo")
insert_if_not(data.categories, "LA:Sustantivos de la tercera declinación")
insert_if_not(data.categories, "LA:Sustantivos de la tercera declinación con una terminación")
data.note = "Ninguna de las formas en singular se usaron en latín clásico"
forms["nom_sg_n"] = "plūs"
forms["nom_pl_m"] = "plūrēs"
forms["nom_pl_n"] = "plūra"
forms["gen_sg_m"] = "plūris"
forms["gen_sg_n"] = "plūris"
forms["gen_pl_m"] = "plūrium"
forms["gen_pl_n"] = "plūrium"
forms["dat_sg_m"] = "plūrī"
forms["dat_sg_n"] = "plūrī"
forms["dat_pl_m"] = "plūribus"
forms["dat_pl_n"] = "plūribus"
forms["acc_sg_m"] = "plūrem"
forms["acc_sg_f"] = "plūrem"
forms["acc_sg_n"] = "plūs"
forms["acc_pl_m"] = {"plūrēs", "plūrīs"}
forms["acc_pl_n"] = "plūra"
forms["abl_sg_m"] = {"plūrī", "plūre"}
forms["abl_sg_f"] = {"plūrī", "plūre"}
forms["abl_sg_n"] = {"plūrī", "plūre"}
forms["abl_pl_m"] = "plūribus"
forms["abl_pl_n"] = "plūribus"
forms["voc_sg_n"] = "plūs"
forms["voc_pl_m"] = "plūrēs"
forms["voc_pl_n"] = "plūra"
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["abl_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
elseif match(arg1, "^egō̆?$") or arg1 == "nōs" then
insert_if_not(data.title, "pronombre nominativo")
forms["nom_sg_m"] = arg1
forms["nom_pl_m"] = "nōs"
forms["gen_sg_m"] = "meī"
forms["gen_pl_m"] = {"nostrī", "nostrum"}
forms["dat_sg_m"] = "mihī̆"
forms["dat_pl_m"] = "nōbīs"
forms["acc_sg_m"] = {"mē", "mēmē"}
forms["acc_pl_m"] = "nōs"
forms["abl_sg_m"] = {"mē", "mēmē"}
forms["abl_pl_m"] = "nōbīs"
forms["voc_sg_m"] = arg1
forms["voc_pl_m"] = "nōs"
elseif arg1 == "tū" or arg1 == "vōs" then
insert_if_not(data.title, "pronombre nominativo")
forms["nom_sg_m"] = arg1
forms["nom_pl_m"] = "vōs"
forms["gen_sg_m"] = "tuī"
forms["gen_pl_m"] = {"vestrī", "vestrum"}
forms["dat_sg_m"] = "tibī̆"
forms["dat_pl_m"] = "vōbīs"
forms["acc_sg_m"] = {"tē", "tētē"}
forms["acc_pl_m"] = "vōs"
forms["abl_sg_m"] = {"tē", "tētē"}
forms["abl_pl_m"] = "vōbīs"
forms["voc_sg_m"] = arg1
forms["voc_pl_m"] = "vōs"
elseif arg1 == "suī" then
insert_if_not(data.title, "pronombre reflexivo")
forms["nom_sg_m"] = {}
forms["nom_pl_m"] = {}
forms["gen_sg_m"] = arg1
forms["gen_pl_m"] = forms["gen_sg_m"]
forms["dat_sg_m"] = "sibī̆"
forms["dat_pl_m"] = forms["dat_sg_m"]
forms["acc_sg_m"] = {"sē", "sēsē"}
forms["acc_pl_m"] = {"sē", "sēsē"}
forms["abl_sg_m"] = {"sē", "sēsē"}
forms["abl_pl_m"] = {"sē", "sēsē"}
forms["voc_sg_m"] = {}
forms["voc_pl_m"] = {}
elseif arg1 == "is" or arg1 == "īdem" then
insert_if_not(data.title, "pronombre demostrativo")
forms["nom_sg_m"] = "is"
forms["nom_sg_f"] = "ea"
forms["nom_sg_n"] = "id"
forms["nom_pl_m"] = {"iī", "eī", "ī"}
forms["nom_pl_f"] = "eae"
forms["nom_pl_n"] = "ea"
forms["gen_sg_m"] = {"eius", "ejus"}
forms["gen_sg_f"] = {"eius", "ejus"}
forms["gen_sg_n"] = {"eius", "ejus"}
forms["gen_pl_m"] = {"eōrum", "eum"}
forms["gen_pl_f"] = "eārum"
forms["gen_pl_n"] = {"eōrum", "eum"}
forms["dat_sg_m"] = {"eī", "e͡i", "ēī"}
forms["dat_sg_f"] = {"eī", "e͡i", "ēī", "eae"}
forms["dat_sg_n"] = {"eī", "e͡i", "ēī"}
forms["dat_pl_m"] = {"iīs", "eīs", "īs"}
forms["dat_pl_f"] = {"iīs", "eīs", "īs", "eābus"}
forms["dat_pl_n"] = {"iīs", "eīs", "īs"}
forms["acc_sg_m"] = "eum"
forms["acc_sg_f"] = "eam"
forms["acc_sg_n"] = "id"
forms["acc_pl_m"] = "eōs"
forms["acc_pl_f"] = "eās"
forms["acc_pl_n"] = "ea"
forms["abl_sg_m"] = "eō"
forms["abl_sg_f"] = "eā"
forms["abl_sg_n"] = "eō"
forms["abl_pl_m"] = {"iīs", "eīs", "īs"}
forms["abl_pl_f"] = {"iīs", "eīs", "īs"}
forms["abl_pl_n"] = {"iīs", "eīs", "īs"}
if arg1 == "īdem" then
forms["nom_sg_m"] = "ī"
forms["nom_sg_n"] = "i"
forms["acc_sg_n"] = "i"
end
elseif arg1 == "quis" or arg1 == "quī" then
data.note = "La forma ''qua'' es preferida frente a ''quae'' cuando se usa como indefinido"
local id = "id"
if arg1 == "quī" then
insert_if_not(data.title, "determinante relativo/interrogativo")
id = "od"
forms["nom_sg_m"] = {"quī", "quis", "quei{†}"}
forms["nom_sg_f"] = {"quae", "qua"}
forms["acc_sg_f"] = "quam"
forms["abl_sg_m"] = "quō"
forms["abl_sg_f"] = "quā"
forms["abl_sg_n"] = "quō"
else
insert_if_not(data.title, "pronombre relativo/interrogativo")
forms["nom_sg_m"] = {"quis", "quī"}
forms["nom_sg_f"] = {"quae", "qua", "quis{†}"}
forms["acc_sg_f"] = {"quam", "quem{†}"}
forms["abl_sg_m"] = {"quō", "quī"}
forms["abl_sg_f"] = {"quā", "quī"}
forms["abl_sg_n"] = {"quō", "quī"}
end
forms["nom_sg_n"] = "qu"..id
forms["nom_pl_m"] = {"quī", "quei{†}"}
forms["nom_pl_f"] = "quae"
forms["nom_pl_n"] = {"quae", "qua"}
forms["gen_sg_m"] = {"cuius", "quoius{†}"}
forms["gen_sg_f"] = {"cuius", "quoius{†}"}
forms["gen_sg_n"] = {"cuius", "quoius{†}"}
forms["gen_pl_m"] = "quōrum"
forms["gen_pl_f"] = "quārum"
forms["gen_pl_n"] = "quōrum"
forms["dat_sg_m"] = {"cui", "quoi{†}", "quoiei{†}"}
forms["dat_sg_f"] = {"cui", "quoi{†}", "quoiei{†}"}
forms["dat_sg_n"] = {"cui", "quoi{†}", "quoiei{†}"}
forms["dat_pl_m"] = {"quibus", "quīs", "queis{†}"}
forms["dat_pl_f"] = {"quibus", "quīs", "queis{†}"}
forms["dat_pl_n"] = {"quibus", "quīs", "queis{†}"}
forms["acc_sg_m"] = "quem"
forms["acc_sg_n"] = "qu"..id
forms["acc_pl_m"] = "quōs"
forms["acc_pl_f"] = "quās"
forms["acc_pl_n"] = {"quae", "qua"}
forms["abl_pl_m"] = {"quibus", "quīs", "queis{†}"}
forms["abl_pl_f"] = {"quibus", "quīs", "queis{†}"}
forms["abl_pl_n"] = {"quibus", "quīs", "queis{†}"}
elseif arg1 == "aliquī" then
insert_if_not(data.title, "determinante indefinido")
forms["nom_sg_m"] = {"aliquī{DET/ADJ}", "aliquis{PRON/SUST}"}
forms["nom_sg_f"] = {"aliqua", "aliquae{R}"}
forms["nom_sg_n"] = "aliquod"
forms["nom_pl_m"] = "aliquī"
forms["nom_pl_f"] = "aliquae"
forms["nom_pl_n"] = "aliqua"
forms["gen_sg_m"] = {"alicuius", "aliquoius{†}"}
forms["gen_sg_f"] = {"alicuius", "aliquoius{†}"}
forms["gen_sg_n"] = {"alicuius", "aliquoius{†}"}
forms["gen_pl_m"] = "aliquōrum"
forms["gen_pl_f"] = "aliquārum"
forms["gen_pl_n"] = "aliquōrum"
forms["dat_sg_m"] = {"alicui", "aliquoi{†}"}
forms["dat_sg_f"] = {"alicui", "aliquoi{†}"}
forms["dat_sg_n"] = {"alicui", "aliquoi{†}"}
forms["dat_pl_m"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
forms["dat_pl_f"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
forms["dat_pl_n"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
forms["acc_sg_m"] = "aliquem"
forms["acc_sg_f"] = "aliquam"
forms["acc_sg_n"] = "aliquod"
forms["acc_pl_m"] = "aliquōs"
forms["acc_pl_f"] = "aliquās"
forms["acc_pl_n"] = "aliqua"
forms["abl_sg_m"] = "aliquō"
forms["abl_sg_f"] = "aliquā"
forms["abl_sg_n"] = "aliquō"
forms["abl_pl_m"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
forms["abl_pl_f"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
forms["abl_pl_n"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
elseif arg1 == "quisquam" then
insert_if_not(data.title, "determinante indefinido, concordancia en negativo")
data.note = "En latín clásico, era preferidas las formas de ''ūllus'' en lugar de las esta voz para el femenino y el neutro."
forms["nom_sg_m"] = "quisquam"
forms["nom_sg_f"] = {"quaequam", "quisquam{†}"}
forms["nom_sg_n"] = "quodquam"
forms["nom_pl_m"] = "quīquam"
forms["nom_pl_f"] = "quaequam"
forms["nom_pl_n"] = "quaequam"
forms["gen_sg_m"] = "cuiusquam"
forms["gen_sg_f"] = "cuiusquam"
forms["gen_sg_n"] = "cuiusquam"
forms["gen_pl_m"] = "quōrumquam"
forms["gen_pl_f"] = "quārumquam"
forms["gen_pl_n"] = "quōrumquam"
forms["dat_sg_m"] = "cuiquam"
forms["dat_sg_f"] = "cuiquam"
forms["dat_sg_n"] = "cuiquam"
forms["dat_pl_m"] = "quibusquam"
forms["dat_pl_f"] = "quibusquam"
forms["dat_pl_n"] = "quibusquam"
forms["acc_sg_m"] = "quemquam"
forms["acc_sg_f"] = {"quamquam", "quemquam{†}"}
forms["acc_sg_n"] = "quodquam"
forms["acc_pl_m"] = "quōsquam"
forms["acc_pl_f"] = "quāsquam"
forms["acc_pl_n"] = "quaequam"
forms["abl_sg_m"] = {"quōquam", "quīquam{†}"}
forms["abl_sg_f"] = "quāquam"
forms["abl_sg_n"] = "quōquam"
forms["abl_pl_m"] = "quibusquam"
forms["abl_pl_f"] = "quibusquam"
forms["abl_pl_n"] = "quibusquam"
forms["voc_sg_m"] = "quisquam"
forms["voc_sg_f"] = "quaequam"
forms["voc_sg_n"] = "quodquam"
forms["voc_pl_m"] = "quīquam"
forms["voc_pl_f"] = "quaequam"
forms["voc_pl_n"] = "quaequam"
elseif arg1 == "quisquis" then
insert_if_not(data.title, "pronombre relativo/interrogativo")
forms["nom_sg_m"] = "quisquis"
forms["nom_sg_f"] = "quisquis"
forms["nom_sg_n"] = {"quidquid", "quicquid"}
forms["nom_pl_m"] = "quīquī"
forms["nom_pl_f"] = "quaequae"
forms["nom_pl_n"] = "quaequae"
forms["gen_sg_m"] = "cuiuscuius"
forms["gen_sg_f"] = "cuiuscuius"
forms["gen_sg_n"] = "cuiuscuius"
forms["gen_pl_m"] = "quōrumquōrum"
forms["gen_pl_f"] = "quārumquārum"
forms["gen_pl_n"] = "quōrumquōrum"
forms["dat_sg_m"] = "cuicui"
forms["dat_sg_f"] = "cuicui"
forms["dat_sg_n"] = "cuicui"
forms["dat_pl_m"] = {"quibusquibus", "quīsquīs"}
forms["dat_pl_f"] = {"quibusquibus", "quīsquīs"}
forms["dat_pl_n"] = {"quibusquibus", "quīsquīs"}
forms["acc_sg_m"] = "quemquem"
forms["acc_sg_f"] = "quamquam"
forms["acc_sg_n"] = {"quidquid", "quicquid"}
forms["acc_pl_m"] = "quōsquōs"
forms["acc_pl_f"] = "quāsquās"
forms["acc_pl_n"] = "quaequae"
forms["abl_sg_m"] = "quōquō"
forms["abl_sg_f"] = "quāquā"
forms["abl_sg_n"] = "quōquō"
forms["abl_pl_m"] = {"quibusquibus", "quīsquīs"}
forms["abl_pl_f"] = {"quibusquibus", "quīsquīs"}
forms["abl_pl_n"] = {"quibusquibus", "quīsquīs"}
forms["voc_sg_m"] = "quisquis"
forms["voc_sg_f"] = "quisquis"
forms["voc_sg_n"] = {"quidquid", "quicquid"}
forms["voc_pl_m"] = "quīquī"
forms["voc_pl_f"] = "quaequae"
forms["voc_pl_n"] = "quaequae"
elseif arg1 == "ecquis" then
insert_if_not(data.title, "pronombre interrogativo")
forms["nom_sg_m"] = {"ecquis", "ecquī"}
forms["nom_sg_f"] = {"ecqua", "ecquae"}
forms["nom_sg_n"] = "ecquid"
forms["nom_pl_m"] = "ecquī"
forms["nom_pl_f"] = "ecquae"
forms["nom_pl_n"] = {"ecqua", "ecquae"}
forms["gen_sg_m"] = "eccuius"
forms["gen_sg_f"] = "eccuius"
forms["gen_sg_n"] = "eccuius"
forms["dat_sg_m"] = "eccui"
forms["dat_sg_f"] = "eccui"
forms["dat_sg_n"] = "eccui"
forms["acc_sg_m"] = "ecquem"
forms["acc_sg_f"] = "ecquam"
forms["acc_sg_n"] = "ecquod"
forms["acc_pl_m"] = "ecquōs"
forms["acc_pl_f"] = "ecquās"
forms["acc_pl_n"] = {"ecqua", "ecquae"}
forms["abl_sg_m"] = {"ecquō", "ecquī"}
forms["abl_sg_f"] = {"ecquā", "ecquī"}
forms["abl_sg_n"] = {"ecquō", "ecquī"}
elseif arg1 == "quīdam" then
insert_if_not(data.title, "pronombre indefinido")
forms["nom_sg_m"] = "quīdam"
forms["nom_sg_f"] = "quaedam"
forms["nom_sg_n"] = "quiddam"
forms["nom_pl_m"] = {"quīdam", "quēsdam{†}"}
forms["nom_pl_f"] = "quaedam"
forms["nom_pl_n"] = "quaedam"
forms["gen_sg_m"] = {"cuiusdam", "quoiusdam{†}"}
forms["gen_sg_f"] = {"cuiusdam", "quoiusdam{†}"}
forms["gen_sg_n"] = {"cuiusdam", "quoiusdam{†}"}
forms["gen_pl_m"] = {"quōrundam", "quōrumdam"}
forms["gen_pl_f"] = {"quārundam", "quārumdam"}
forms["gen_pl_n"] = {"quōrundam", "quōrumdam"}
forms["dat_sg_m"] = {"cuidam", "quoidam{†}"}
forms["dat_sg_f"] = {"cuidam", "quoidam{†}"}
forms["dat_sg_n"] = {"cuidam", "quoidam{†}"}
forms["dat_pl_m"] = {"quibusdam", "quīsdam{†}"}
forms["dat_pl_f"] = {"quibusdam", "quīsdam{†}"}
forms["dat_pl_n"] = {"quibusdam", "quīsdam{†}"}
forms["acc_sg_m"] = {"quendam", "quemdam"}
forms["acc_sg_f"] = {"quandam", "quamdam"}
forms["acc_sg_n"] = "quiddam"
forms["acc_pl_m"] = {"quōsdam", "quēsdam{†}"}
forms["acc_pl_f"] = "quāsdam"
forms["acc_pl_n"] = "quaedam"
forms["abl_sg_m"] = "quōdam"
forms["abl_sg_f"] = "quādam"
forms["abl_sg_n"] = "quōdam"
forms["abl_pl_m"] = {"quibusdam", "quīsdam{†}"}
forms["abl_pl_f"] = {"quibusdam", "quīsdam{†}"}
forms["abl_pl_n"] = {"quibusdam", "quīsdam{†}"}
elseif arg1 == "nēmō" then
insert_if_not(data.title, "Determinante y pronombre, concordancia en negativo")
forms["nom_sg_m"] = "nēmō"
forms["nom_sg_f"] = "nēmō"
forms["gen_sg_m"] = {"nūllī̆us", "nēminis{R}"}
forms["gen_sg_f"] = {"nūllī̆us", "nēminis{R}"}
forms["dat_sg_m"] = "nēminī"
forms["dat_sg_f"] = "nēminī"
forms["acc_sg_m"] = "nēminem"
forms["acc_sg_f"] = "nēminem"
forms["abl_sg_m"] = {"nūllō", "nēmine{R}"}
forms["abl_sg_f"] = {"nūllā", "nēmine{R}"}
else
error('adjective ' .. arg1 .. ' not recognized')
end
end
local function extract_base(lemma, ending)
if ending:find("(", nil, true) then
return match(lemma, ending)
end
return match(lemma, "^(.*)" .. ending .. "$")
end
local function get_noun_subtype_by_ending(lemma, stem2, decltype, specified_subtypes,
endings_and_subtypes)
for _, ending_and_subtypes in ipairs(endings_and_subtypes) do
local ending = ending_and_subtypes[1]
local subtypes = ending_and_subtypes[2]
local not_this_subtype = false
if (
specified_subtypes.pl and not contains(subtypes, "pl") or
contains(subtypes, "both") and not specified_subtypes.both
) then
-- We now require that plurale tantum terms specify a plural-form lemma.
-- The autodetected subtypes will include 'pl' for such lemmas; if not,
-- we fail this entry. Additionally, if the rule contains 'both', it
-- must be explicitly specified to match.
not_this_subtype = true
else
for _, subtype in ipairs(subtypes) do
-- A subtype is directly canceled by specifying -SUBTYPE.
-- In addition, M or F as a subtype is canceled by N, and
-- vice-versa, but M doesn't cancel F or vice-versa; instead,
-- we simply ignore the conflicting gender specification when
-- constructing the combination of specified and inferred subtypes.
-- The reason for this is that neuters have distinct declensions
-- from masculines and feminines, but masculines and feminines have
-- the same declension, and various nouns in Latin that are
-- normally masculine are exceptionally feminine and vice-versa
-- (nauta, agricola, fraxinus, malus "apple tree", manus, rēs,
-- etc.).
--
-- In addition, sg as a subtype is canceled by pl and vice-versa.
-- It's also possible to specify both, which will override sg but
-- not cancel it (in the sense that it won't prevent the relevant
-- rule from matching). For example, there's a rule specifying that
-- lemmas beginning with a capital letter and ending in -ius take
-- the ius.voci.sg subtypes. Specifying such a lemma with the
-- subtype both will result in the ius.voci.both subtypes, whereas
-- specifying such a lemma with the subtype pl will cause this rule
-- not to match, and it will fall through to a less specific rule
-- that returns just the ius subtype, which will be combined with
-- the explicitly specified pl subtype to produce ius.pl.
if specified_subtypes["-" .. subtype] or
subtype == "N" and (specified_subtypes.M or specified_subtypes.F) or
(subtype == "M" or subtype == "F") and specified_subtypes.N or
subtype == "sg" and specified_subtypes.pl or
subtype == "pl" and specified_subtypes.sg then
not_this_subtype = true
break
end
end
end
if not not_this_subtype then
if type(ending) == "table" then
local lemma_ending = ending[1]
local stem2_ending = ending[2]
local base = extract_base(lemma, lemma_ending)
if base and base .. stem2_ending == stem2 then
return base, stem2, subtypes
end
else
local base = extract_base(lemma, ending)
if base then
return base, stem2, subtypes
end
end
end
end
if decltype then
error("Unrecognized ending for declension-" .. decltype .. " noun: " .. lemma)
end
return lemma, stem2, keys_to_list(specified_subtypes)
end
local patterns = {
{"[mM]a", "%0t"},
{"e", ""},
{"([aoAO])([lr])", "%1" .. MACRON .. "%2"},
{"[eE]l", "%0l"},
{"([mM])en", "%1in"},
{"([tT]ūd)ō", "%1in"},
{"([gG])ō", "%1in"},
{"[ōŌ]", "%1n"},
{"er", "r"},
{"[ēi]s", ""},
{"([āēīōūȳĀĒĪŌŪȲ]n)s", function(v)
return (gsub(toNFD(v), MACRON, "") .. "t")
end},
{"([cC])eps", "%1ipit"},
{"([bp])s", "%1"},
{"us", "or"},
{"s", "t"},
{"ex", "ic"},
{"x", "c"},
}
local function make_stem2(stem)
local n
for _, pattern in ipairs(patterns) do
local key = pattern[1]
stem, n = gsub(stem, key .. "$", pattern[2])
if n > 0 then
-- debug_track("la-utilities/" .. key) REVISAR
return toNFC(stem)
end
end
-- debug_track("la-utilities") REVISAR
return stem
end
local function detect_noun_subtype(lemma, stem2, typ, subtypes)
local base, _
if typ == "1" then
return get_noun_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"ām", {"F", "am"}},
{"ās", {"M", "Greek", "Ma"}},
{"ēs", {"M", "Greek", "Me"}},
{"ē", {"F", "Greek"}},
{"ae", {"F", "pl"}},
{"a", {"F"}},
})
elseif typ == "2" then
local detected_subtypes
lemma, stem2, detected_subtypes = get_noun_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"^(.*r)$", {"M", "er"}},
{"^(.*v)os$", {"M", "vos"}},
{"^(.*v)om$", {"N", "vom"}},
-- If the lemma ends in -os and the user said N or -M, then the
-- following won't apply, and the second (neuter) -os will applly.
{"os", {"M", "Greek"}},
{"os", {"N", "Greek", "us"}},
{"on", {"N", "Greek"}},
-- -ius beginning with a capital letter is assumed a proper name,
-- and takes the voci subtype (vocative in -ī) along with the ius
-- subtype and sg-only. Other nouns in -ius just take the ius
-- subtype. Explicitly specify "sg" so that if .pl is given,
-- this rule won't apply.
{"^(%u.*)ius$", {"M", "ius", "voci", "sg"}},
{"ius", {"M", "ius"}},
{"ium", {"N", "ium"}},
-- If the lemma ends in -us and the user said N or -M, then the
-- following won't apply, and the second (neuter) -us will applly.
{"us", {"M"}},
{"us", {"N", "us"}},
{"um", {"N"}},
{"iī", {"M", "ius", "pl"}},
{"ia", {"N", "ium", "pl"}},
-- If the lemma ends in -ī and the user said N or -M, then the
-- following won't apply, and the second (neuter) -ī will applly.
{"ī", {"M", "pl"}},
{"ī", {"N", "us", "pl"}},
{"oe", {"M", "Greek", "pl"}},
{"a", {"N", "pl"}},
})
stem2 = stem2 or lemma
return lemma, stem2, detected_subtypes
elseif typ == "3" then
if subtypes.pl then
if subtypes.Greek then
base = lemma:match("^(.*)erēs$")
if base then
return base .. "ēr", base .. "er", {"er"}
end
base = lemma:match("^(.*)ontēs$")
if base then
return base .. "ōn", base .. "ont", {"on"}
end
base = lemma:match("^(.*)es$")
if base then
return base, stem2 or base, {}
end
error("Unrecognized ending for declension-3 plural Greek noun: " .. lemma)
end
base = lemma:match("^(.*)ia$")
if base then
return base, stem2 or base, {"N", "I", "pure"}
end
base = lemma:match("^(.*)a$")
if base then
return base, stem2 or base, {"N"}
end
base = lemma:match("^(.*)ēs$")
if base then
return base, stem2 or base, {}
end
error("Unrecognized ending for declension-3 plural noun: " .. lemma)
end
stem2 = stem2 or make_stem2(lemma)
local detected_subtypes
if subtypes.Greek then
base, _, detected_subtypes = get_noun_subtype_by_ending(lemma, stem2, nil, subtypes, {
{{"is", ""}, {"I"}},
{"ēr", {"er"}},
{"ōn", {"on"}},
})
if base then
return lemma, stem2, detected_subtypes
end
return lemma, stem2, {}
end
if not subtypes.N then
base, _, detected_subtypes = get_noun_subtype_by_ending(lemma, stem2, nil, subtypes, {
{{"^(%u.*pol)is$", ""}, {"F", "polis", "sg", "loc"}},
{{"tūdō", "tūdin"}, {"F"}},
{{"tās", "tāt"}, {"F"}},
{{"tūs", "tūt"}, {"F"}},
{{"tiō", "tiōn"}, {"F"}},
{{"siō", "siōn"}, {"F"}},
{{"xiō", "xiōn"}, {"F"}},
{{"gō", "gin"}, {"F"}},
{{"or", "ōr"}, {"M"}},
{{"tr[iī]x", "trīc"}, {"F"}},
{{"is", ""}, {"I"}},
{{"^(%l.*)ēs$", ""}, {"I"}},
})
if base then
return lemma, stem2, detected_subtypes
end
end
base, _, detected_subtypes = get_noun_subtype_by_ending(lemma, stem2, nil, subtypes, {
{{"us", "or"}, {"N"}},
{{"us", "er"}, {"N"}},
{{"ma", "mat"}, {"N"}},
{{"men", "min"}, {"N"}},
{{"^(%u.*)e$", ""}, {"N", "sg"}},
{{"e", ""}, {"N", "I", "pure"}},
{{"al", "āl"}, {"N", "I", "pure"}},
{{"ar", "ār"}, {"N", "I", "pure"}},
})
if base then
return lemma, stem2, detected_subtypes
end
return lemma, stem2, {}
elseif typ == "4" then
if subtypes.echo or subtypes.Callisto then
base = lemma:match("^(.*)ō$")
if not base then
error("Declension-4 noun of subtype .echo or .Callisto should end in -ō: " .. lemma)
end
if subtypes.Callisto then
return base, nil, {"F", "sg"}
else
return base, nil, {"F"}
end
end
return get_noun_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"us", {"M"}},
{"ū̆", {"N"}},
{"ūs", {"M", "pl"}},
{"ua", {"N", "pl"}},
})
elseif typ == "5" then
return get_noun_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"iēs", {"F", "i"}},
{"iēs", {"F", "i", "pl"}},
{"ēs", {"F"}},
{"ēs", {"F", "pl"}},
})
elseif typ == "sgpl" then
return lemma, stem2, {}
elseif typ == "irreg" and lemma == "domus" then
-- [[domus]] auto-sets data.loc = true, but we need to know this
-- before declining the noun so we can propagate it to other segments.
return lemma, nil, {"loc"}
elseif typ == "indecl" or typ == "irreg" and (
lemma == "Deus" or match(lemma, "^[IJ]ēs[uū]s$") or
lemma == "Athōs" or lemma == "vēnum"
) then
-- Indeclinable nouns, and certain irregular nouns, set data.num = "sg",
-- but we need to know this before declining the noun so we can
-- propagate it to other segments.
return get_noun_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"", {"both"}},
{"", {"sg"}},
{"", {"pl"}},
})
elseif typ == "indecl" or typ == "irreg" then
return lemma, nil, {}
else
return nil, nil, {}
end
end
-- Given ENDINGS_AND_SUBTYPES (a list of four-tuples of ENDING, RETTYPE,
-- SUBTYPES, PROCESS_RETVAL), check each ENDING in turn against LEMMA and
-- STEM2. If it matches, return a four-tuple BASE, STEM2, RETTYPE, NEW_SUBTYPES
-- where BASE is normally the remainder of LEMMA minus the ending, STEM2 is
-- as passed in, RETTYPE is as passed in, and NEW_SUBTYPES is the same as
-- SUBTYPES minus any subtypes beginning with a hyphen. If no endings match,
-- throw an error if DECLTYPPE is non-nil, mentioning the DECLTYPE
-- (user-specified declension); but if DECLTYPE is nil, just return the tuple
-- nil, nil, nil, nil.
--
-- In order for a given entry to match, ENDING must match and also the subtypes
-- in SUBTYPES (a list) must not be incompatible with the passed-in
-- user-specified subtypes SPECIFIED_SUBTYPES (a set, i.e. a table where the
-- keys are strings and the value is always true). "Incompatible" means that
-- a given SUBTYPE is specified in either one and -SUBTYPE in the other, or
-- that "pl" is found in SPECIFIED_SUBTYPES and not in SUBTYPES.
--
-- The ending spec in ENDINGS_AND_SUBTYPES is one of the following:
--
-- 1. A simple string, e.g. "tūdō", specifying an ending.
-- 2. A regex that should match the entire lemma (it should be anchored at
-- the beginning with ^ and at the end with $), and contains a single
-- capturing group to match the base.
-- 3. A pair {SIMPLE_STRING_OR_REGEX, STEM2_ENDING} where
-- SIMPLE_STRING_OR_REGEX is one of the previous two possibilities and
-- STEM2_ENDING is a string specifying the corresponding ending that must
-- be present in STEM2. If this form is used, the combination of
-- base + STEM2_ENDING must exactly match STEM2 in order for this entry
-- to be considered a match. An example is {"is", ""}, which will match
-- lemma == "follis", stem2 == "foll", but not lemma == "lapis",
-- stem2 == "lapid".
--
-- If PROCESS_STEM2 is given and the returned STEM2 would be nil, call
-- process_stem2(BASE) to get the STEM2 to return.
local function get_adj_type_and_subtype_by_ending(lemma, stem2, decltype,
specified_subtypes, endings_and_subtypes, process_stem2)
for _, ending_and_subtypes in ipairs(endings_and_subtypes) do
local ending = ending_and_subtypes[1]
local rettype = ending_and_subtypes[2]
local subtypes = ending_and_subtypes[3]
local process_retval = ending_and_subtypes[4]
local not_this_subtype = false
if (
specified_subtypes.pl and not contains(subtypes, "pl") or
contains(subtypes, "both") and not specified_subtypes.both
) then
-- We now require that plurale tantum terms specify a plural-form lemma.
-- The autodetected subtypes will include 'pl' for such lemmas; if not,
-- we fail this entry. Additionally, if the rule contains 'both', it
-- must be explicitly specified to match.
not_this_subtype = true
else
for _, subtype in ipairs(subtypes) do
-- A subtype is directly canceled by specifying -SUBTYPE.
if specified_subtypes["-" .. subtype] then
not_this_subtype = true
break
end
-- A subtype is canceled if the user specified SUBTYPE and
-- -SUBTYPE is given in the to-be-returned subtypes.
local must_not_be_present = subtype:match("^%-(.*)$")
if must_not_be_present and specified_subtypes[must_not_be_present] then
not_this_subtype = true
break
end
end
end
if not not_this_subtype then
local base
if type(ending) == "table" then
local lemma_ending = ending[1]
local stem2_ending = ending[2]
base = extract_base(lemma, lemma_ending)
if base and base .. stem2_ending ~= stem2 then
base = nil
end
else
base = extract_base(lemma, ending)
end
if base then
-- Remove subtypes of the form -SUBTYPE from the subtypes
-- to be returned.
local new_subtypes = {}
for _, subtype in ipairs(subtypes) do
if subtype:sub(1, 1) ~= "-" then
insert(new_subtypes, subtype)
end
end
if process_retval then
base, stem2 = process_retval(base, stem2)
end
if process_stem2 then
stem2 = stem2 or process_stem2(base)
end
return base, stem2, rettype, new_subtypes
end
end
end
if not decltype then
return lemma, stem2, nil, keys_to_list(specified_subtypes)
elseif decltype == "" then
error("Unrecognized ending for adjective: " .. lemma)
else
error("Unrecognized ending for declension-" .. decltype .. " adjective: " .. lemma)
end
end
-- Autodetect the type and subtype of an adjective given all the information
-- specified by the user: lemma, stem2, declension type and specified subtypes.
-- Four values are returned: the lemma base (i.e. the stem of the lemma, as
-- required by the declension functions), the value of stem2 to pass to the
-- declension function, the declension type and the autodetected subtypes.
-- Note that this will not detect a given subtype if -SUBTYPE is specified for
-- any subtype that would be returned, or if SUBTYPE is specified and -SUBTYPE
-- is among the subtypes that would be returned (such subtypes are filtered out
-- of the returned subtypes).
local function detect_adj_type_and_subtype(lemma, stem2, typ, subtypes)
local function base_as_stem2(base, stem2)
return base, base
end
local function constant_base(baseval)
return function(base, stem2)
return baseval, nil
end
end
local function decl12_stem2(base)
return base
end
local function decl3_stem2(base)
return make_stem2(base)
end
local decl12_entries = {
{"us", "1&2+", {}},
{"a", "1&2+", {}},
{"um", "1&2+", {}},
{"ī", "1&2+", {"pl"}},
{"ae", "1&2+", {"pl"}},
{"a", "1&2+", {"pl"}},
-- Nearly all -os adjectives are greekA
{"os", "1&2+", {"greekA", "-greekE"}},
{"os", "1&2+", {"greekE", "-greekA"}},
{"ē", "1&2+", {"greekE", "-greekA"}},
{"on", "1&2+", {"greekA", "-greekE"}},
{"on", "1&2+", {"greekE", "-greekA"}},
{"^(.*er)$", "1&2+", {"er"}},
{"^(.*ur)$", "1&2+", {"er"}},
{"^(h)ic$", "1&2+", {"ic"}},
}
local decl3_entries = {
{"^(.*er)$", "3-3+", {"I"}},
{"^(.*er)$", "3-3+", {}},
{"is", "3-2+", {"I"}},
{"is", "3-2+", {}},
{"e", "3-2+", {"I"}},
{"e", "3-2+", {}},
{"^(.*[ij])or$", "3-C+", {"abl_e_i", "-abl_i_e"}},
{"^(.*[ij])or$", "3-C+", {}},
{"^(min)or$", "3-C+", {"abl_e_i", "-abl_i_e"}},
{"^(min)or$", "3-C+", {}},
{"^(.*trīx)$", "3-def+", {"trix", "abl_i_e", "-abl_e_i"}},
{"^(.*trīx)$", "3-def+", {"trix"}},
{"^(.*tor)$", "3-def+", {"tor", "abl_i_e", "-abl_e_i"}},
{"^(.*tor)$", "3-def+", {"tor"}},
-- Detect -ēs as 3-1 without auto-inferring .pl if .pl
-- not specified. If we don't do this, the later entry for
-- -ēs will auto-infer .pl whenever -ēs is specified (which
-- won't work for adjectives like quadripēs, volucripēs).
-- Essentially, for declension-3 adjectives, we require that
-- .pl is given if the lemma is plural.
--
-- Most 3-1 adjectives are i-stem (e.g. audāx) so we require -I
-- to be given with non-i-stem adjectives. The first entry below
-- will apply when -I isn't given, the second when it is given.
{"^(.*ēs)$", "3-1+", {"I", "abl_i_e", "-abl_e_i"}},
{"^(.*ēs)$", "3-1+", {"I"}},
{"^(.*ēs)$", "3-1+", {"par", "abl_i_e", "-abl_e_i"}},
{"^(.*ēs)$", "3-1+", {"par"}},
{"^(.*[ij])ōrēs$", "3-C+", {"pl"}},
{"^(min)ōrēs$", "3-C+", {"pl"}},
-- If .pl with -ēs, we don't know if the adjective is 3-1, 3-2
-- or 3-3. Since 3-2 is probably the most common, we infer it
-- (as well as the fact that these adjectives *are* in a sense
-- 3-2 since they have a distinct neuter in -(i)a. Note that
-- we have two entries here; the first one will apply unless
-- -I is given, and will infer an i-stem adjective; the second
-- one will apply otherwise (and infer a non-i-stem 3-1 adjective).
{"ēs", "3-2+", {"pl", "I"}, base_as_stem2},
{"ēs", "3-1+", {"pl", "par"}, base_as_stem2},
-- Same for neuters.
{"ia", "3-2+", {"pl", "I"}, base_as_stem2},
{"a", "3-1+", {"pl", "par"}, base_as_stem2},
-- As above for -ēs but for miscellaneous singulars.
{"", "3-1+", {"I", "abl_i_e", "-abl_e_i"}},
{"", "3-1+", {"I"}},
{"", "3-1+", {"par", "abl_i_e", "-abl_e_i"}},
{"", "3-1+", {"par"}},
}
local function get_subtypes_and_endings(typ, f)
local subtypes_and_endings = {}
for _, v in ipairs(decl3_entries) do
if f(v) then
v = deep_copy(v)
v[2] = typ
insert(subtypes_and_endings, v)
end
end
return subtypes_and_endings
end
local function compare(spec)
return spec[2] == typ
end
if typ == "+" then
local base, new_stem2, rettype, new_subtypes = get_adj_type_and_subtype_by_ending(lemma, stem2, nil, subtypes, decl12_entries, decl12_stem2)
if rettype then
return base, new_stem2, rettype, new_subtypes
else
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, decl3_entries, decl3_stem2)
end
elseif typ == "3+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, decl3_entries, decl3_stem2)
elseif typ == "1&2+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, decl12_entries, decl12_stem2)
elseif typ == "1-1+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"a", typ, {}},
{"ae", typ, {"pl"}},
})
elseif typ == "2-2+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"us", typ, {}},
{"um", typ, {}},
{"ī", typ, {"pl"}},
{"a", typ, {"pl"}},
{"os", typ, {"greek"}},
{"on", typ, {"greek"}},
{"oe", typ, {"greek", "pl"}},
})
elseif typ == "3-1+" then
-- Use the specs from `decl3_entries`, but add the two i-stem 3-2+ specs when plural-only, as they're the same when 3-1+.
local subtypes_and_endings = get_subtypes_and_endings(typ, function(spec)
local spec1, spec2 = spec[1], spec[2]
return spec2 == typ or (spec2 == "3-2+" and spec1 == "ēs" or spec1 == "ia")
end)
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, subtypes_and_endings, decl3_stem2)
elseif typ == "3-def+" then
-- Like 3-1+ but defective in gender
local subtypes_and_endings = get_subtypes_and_endings(typ, compare)
insert(subtypes_and_endings, {"", typ, {"I"}})
insert(subtypes_and_endings, {"", typ, {"par"}})
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, subtypes_and_endings, decl3_stem2)
elseif typ == "3-2+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"is", typ, {}},
{"e", typ, {}},
-- Detect -ēs as 3-2 without auto-inferring .pl if .pl
-- not specified. If we don't do this, the later entry for
-- -ēs will auto-infer .pl whenever -ēs is specified (which
-- won't work for adjectives like isoscelēs). Essentially,
-- for declension-3 adjectives, we require that .pl is given
-- if the lemma is plural.
{"ēs", typ, {}},
{"ēs", typ, {"pl"}},
{"ia", typ, {"pl"}},
}, decl3_stem2)
elseif typ == "3-3+" or typ == "3-P+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"ēs", typ, {"pl"}, base_as_stem2},
{"ia", typ, {"pl"}, base_as_stem2},
{"", typ, {}},
}, decl3_stem2)
elseif typ == "3-C+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, get_subtypes_and_endings(typ, compare), decl3_stem2)
elseif typ == "irreg+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"^(duo)$", typ, {"pl"}},
{"^(ambō)$", typ, {"pl"}},
{"^(mīll?ia)$", typ, {"N", "pl"}, constant_base("mīlle")},
-- match ea
{"^(ea)$", typ, {}, constant_base("is")},
-- match id
{"^(id)$", typ, {}, constant_base("is")},
-- match plural eī, iī
{"^([ei]ī)$", typ, {"pl"}, constant_base("is")},
-- match plural ea, eae
{"^(eae?)$", typ, {"pl"}, constant_base("is")},
-- match eadem
{"^(eadem)$", typ, {}, constant_base("īdem")},
-- match īdem, idem
{"^([īi]dem)$", typ, {}, constant_base("īdem")},
-- match plural īdem
{"^(īdem)$", typ, {"pl"}},
-- match plural eadem, eaedem
{"^(eae?dem)$", typ, {"pl"}, constant_base("īdem")},
-- match illa, ipsa, ista; it doesn't matter if we overmatch because
-- we'll get an error as we use the stem itself in the returned base
{"^(i[lps][lst])a$", typ, {}, function(base, stem2) return base .. "e", nil end},
-- match illud, istud; as above, it doesn't matter if we overmatch
{"^(i[ls][lt])ud$", typ, {}, function(base, stem2) return base .. "e", nil end},
-- match ipsum
{"^(ipsum)$", typ, {}, constant_base("ipse")},
-- match plural illī, ipsī, istī; as above, it doesn't matter if we
-- overmatch
{"^(i[lps][lst])ī$", typ, {"pl"}, function(base, stem2) return base .. "e", nil end},
-- match plural illa, illae, ipsa, ipsae, ista, istae; as above, it
-- doesn't matter if we overmatch
{"^(i[lps][lst])ae?$", typ, {"pl"}, function(base, stem2) return base .. "e", nil end},
-- Detect quī as non-plural unless .pl specified.
{"^(quī)$", typ, {}},
-- Otherwise detect quī as plural.
{"^(quī)$", typ, {"pl"}},
-- Same for quae.
{"^(quae)$", typ, {}, constant_base("quī")},
{"^(quae)$", typ, {"pl"}, constant_base("quī")},
{"^(quid)$", typ, {}, constant_base("quis")},
{"^(quod)$", typ, {}, constant_base("quī")},
{"^(qui[cd]quid)$", typ, {}, constant_base("quisquis")},
{"^(quīquī)$", typ, {"pl"}, constant_base("quisquis")},
{"^(quaequae)$", typ, {"pl"}, constant_base("quisquis")},
-- match all remaining lemmas in lemma form
{"", typ, {}},
})
elseif typ == "indecl+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"", typ, {"both"}},
{"", typ, {"sg"}},
{"", typ, {"pl"}},
})
else -- 0+
return lemma, nil, typ, {}
end
end
local noun_lb = {
nom_sg = "sg.",
gen_sg = "sg.",
dat_sg = "sg.",
acc_sg = "sg.",
abl_sg = "sg.",
voc_sg = "sg.",
loc_sg = "sg.",
nom_pl = "pl.",
gen_pl = "pl.",
dat_pl = "pl.",
acc_pl = "pl.",
abl_pl = "pl.",
voc_pl = "pl.",
loc_pl = "pl."
}
function export.sust(frame)
local title_ = mw.title.getCurrentTitle()
local title = title_.fullText
local ns = title_.namespace
if ns ~= 0 then
return "Use esta plantilla en el espacio principal."
end
local params = {
[1] = {requerido=true},
["alt"] = {},
["num"] = {por_defecto = ""},
["núm"] = {alias_de = "num"},
["nota"] = {},
}
for form,_ in pairs(noun_lb) do
params[form] = {lista=true}
end
local parent_frame = frame:getParent()
local args = require("Módulo:parámetros").obtener_parametros(parent_frame.args, params)
local tpalabras = {}
for _,p in ipairs(args) do
p = match(p, "^(.-);") or p
local a, b = match(p, "^(.-)%.(.*)$")
assert(b, "error en especificaciones de palabra")
local r1 = match(a, "^([^/]+)/")
if not r1 then
r1 = a
end
if r1 == "idem" or r1 == "īdem" then -- REVISAR: parche para idem que internamente lo declina como si fuera "i"
insert(tpalabras, "ī")
else
insert(tpalabras, r1)
end
end
local palabras, separadores = separar_palabras(title, concat(tpalabras, "-"))
local L = #palabras
local M = 1
local declinfo
local titles = {}
local cats = {}
local genero
local nosg, nopl = true, true
for _,arg in ipairs(args) do
local formas = {}
for subarg in gsplit(arg, ";") do
local types = {}
local a, b = match(subarg, "^(.-)%.(.*)$")
assert(b, "error en especificaciones de palabra")
local c, d = match(b, "^(.-)%.(.*)$")
if d then
for spec in gsplit(d, "%.") do
spec = gsub(spec, "(.)%-", "%1_")
types[spec] = true
end
end
c = c or b
local r = split(a, "/")
local r1, r2, detected_subtypes = detect_noun_subtype(r[1], r[2], c, types)
for _, subtype in ipairs(detected_subtypes) do
if types["-" .. subtype] then
-- if a "cancel subtype" spec is given, remove the cancel spec
-- and don't apply the subtype
types["-" .. subtype] = nil
elseif (subtype == "M" or subtype == "F" or subtype == "N") and
(types.M or types.F or types.N) then
-- if gender already specified, don't create conflicting gender spec
elseif (subtype == "sg" or subtype == "pl" or subtype == "both") and
(types.sg or types.pl or types.both) then
-- if number restriction already specified, don't create conflicting
-- number restriction spec
else
types[subtype] = true
end
end
if not genero then
if types.M then
genero = "m"
end
if types.N then
genero = "n"
end
if types.F then
genero = "f"
end
end
local es_adj
if not r1 and genero then
local typ
r1, r2, typ, detected_subtypes = detect_adj_type_and_subtype(r[1], r[2], c, types)
if r1 then
c = typ
es_adj = true
end
end
assert(r1, "forma no reconocida: "..r[1])
local cb = es_adj and adj_decl[c] or noun_decl[c]
assert(cb, "Especifique el tipo de sustantivo correcto en el primer parámetro")
local data = {forms={}, types=types, pos="", subtitles="", notes="", categories=cats, title=titles, loc=types.loc, num=args.num}
cb(data, {r1, r2})
if es_adj then
local forms_ = {}
for form,arr in pairs(data.forms) do
local f1, f2 = form:match("^(.*)(_"..genero..")$")
if f1 then
forms_[f1] = arr
end
end
data.forms = forms_
end
if not types.sg then
nopl = false
end
if not types.pl then
nosg = false
end
if types.sg then
for key,_ in pairs(data.forms) do
if key:find("_pl") then
data.forms[key] = {}
end
end
end
if types.pl then
for key,_ in pairs(data.forms) do
if key:find("_sg") then
data.forms[key] = {}
end
end
end
merge_forms(formas, data.forms, noun_lb)
end
if not declinfo then
declinfo = formas
else
declinfo = combinar_copulativa(declinfo, formas, separadores[M])
M = M + 1
end
end
if declinfo["loc_sg"] and #declinfo["loc_sg"] == 0 then
declinfo["loc_sg"] = nil
end
if declinfo["loc_pl"] and #declinfo["loc_pl"] == 0 then
declinfo["loc_pl"] = nil
end
if nosg == false then
nosg = find(args["num"], "p")
end
if nopl == false then
nopl = find(args["num"], "s")
end
local forms = sobreescribir_formas(declinfo, args, false, {})
comprobar_defectivo(forms, {})
forms = desactivar_formas(forms,
function (form)
return (form:find("pl$") and nopl) or (form:find("sg$") and nosg)
end
)
local raiz_nom = f(forms["nom_sg"][1] or forms["nom_pl"][1] or "?")
local raiz_gen = f(forms["gen_sg"][1] or forms["gen_pl"][1] or "?")
forms = agregar_enlaces(forms, title, normalizar_enlace)
forms = formatear_formas(forms, noun_lb)
local t = {}
insert(t, {{""}, {"Singular"}, {"Plural"}, header=true, color=COLOR_H, class="pc"})
insert(t, {{"Nominativo", header=true, color=COLOR_H}, forms["nom_sg"], forms["nom_pl"]})
insert(t, {{"Genitivo", header=true, color=COLOR_H}, forms["gen_sg"], forms["gen_pl"]})
insert(t, {{"Dativo", header=true, color=COLOR_H}, forms["dat_sg"], forms["dat_pl"]})
insert(t, {{"Acusativo", header=true, color=COLOR_H}, forms["acc_sg"], forms["acc_pl"]})
insert(t, {{"Ablativo", header=true, color=COLOR_H}, forms["abl_sg"], forms["abl_pl"]})
insert(t, {{"Vocativo", header=true, color=COLOR_H}, forms["voc_sg"], forms["voc_pl"]})
if (forms["loc_sg"] and forms["loc_sg"][1]) or (forms["loc_pl"] and forms["loc_pl"][1]) then
insert(t, {{"Locativo", header=true, color=COLOR_H}, forms["loc_sg"], forms["loc_pl"]})
end
insert(t, {{args["nota"] or "", colspan=3}})
return renderizar_tabla(
frame,
"'''Declinación de ''"..raiz_nom..", "..raiz_gen.."'''''  tipo: "..concat(titles, ", "),
t,
ns == 0 and cats or {}
)
end
local adj_lb = {
nom_sg_m = "m.",
nom_sg_n = "n.",
nom_sg_f = "f.",
nom_pl_m = "m.",
nom_pl_n = "n.",
nom_pl_f = "f.",
gen_sg_m = "m.",
gen_sg_n = "n.",
gen_sg_f = "f.",
gen_pl_m = "m.",
gen_pl_n = "n.",
gen_pl_f = "f.",
dat_sg_m = "m.",
dat_sg_n = "n.",
dat_sg_f = "f.",
dat_pl_m = "m.",
dat_pl_n = "n.",
dat_pl_f = "f.",
acc_sg_m = "m.",
acc_sg_n = "n.",
acc_sg_f = "f.",
acc_pl_m = "m.",
acc_pl_n = "n.",
acc_pl_f = "f.",
abl_sg_m = "m.",
abl_sg_n = "n.",
abl_sg_f = "f.",
abl_pl_m = "m.",
abl_pl_n = "n.",
abl_pl_f = "f.",
voc_sg_m = "m.",
voc_sg_n = "n.",
voc_sg_f = "f.",
voc_pl_m = "m.",
voc_pl_n = "n.",
voc_pl_f = "f.",
}
function export.adj(frame)
local title_ = mw.title.getCurrentTitle()
local title = title_.fullText
local ns = title_.namespace
if ns ~= 0 then
return "Use esta plantilla en el espacio principal."
end
local params = {
[1] = {requerido=true},
["alt"] = {},
["num"] = {por_defecto = ""},
["núm"] = {alias_de="num"},
["gen"] = {por_defecto="mfn"},
["nota"] = {},
}
for form,_ in pairs(adj_lb) do
params[form] = {lista=true}
end
params["dat_pl"] = {lista=true}
params["abl_pl"] = {lista=true}
params["loc_pl"] = {lista=true}
local parent_frame = frame:getParent()
local args = require("Módulo:parámetros").obtener_parametros(parent_frame.args, params)
if args["dat_pl"][1] then
args["dat_pl_m"] = deep_copy(args["dat_pl"])
args["dat_pl_n"] = deep_copy(args["dat_pl"])
args["dat_pl_f"] = deep_copy(args["dat_pl"])
end
if args["abl_pl"][1] then
args["abl_pl_m"] = deep_copy(args["abl_pl"])
args["abl_pl_n"] = deep_copy(args["abl_pl"])
args["abl_pl_f"] = deep_copy(args["abl_pl"])
end
if args["loc_pl"][1] then
args["loc_pl_m"] = deep_copy(args["loc_pl"])
args["loc_pl_n"] = deep_copy(args["loc_pl"])
args["loc_pl_f"] = deep_copy(args["loc_pl"])
end
args["dat_pl"] = nil
args["abl_pl"] = nil
args["loc_pl"] = nil
assert(not find(title, " "), "locuciones no soportadas aún") -- REVISAR
local tpalabras = {}
for _,p in ipairs(args) do
p = match(p, "^(.-);") or p
local a, b = match(p, "^(.-)%.(.*)$")
assert(b, "error en especificaciones de palabra")
local r1 = match(a, "^([^/]+)/")
if not r1 then
r1 = a
end
if r1 == "idem" or r1 == "īdem" then -- REVISAR: parche para idem que internamente lo declina como si fuera "i"
insert(tpalabras, "ī")
else
insert(tpalabras, r1)
end
end
local palabras, separadores = separar_palabras(title, concat(tpalabras, "-"))
local L = #palabras
local M = 1
local declinfo
local titles = {}
local cats = {}
local nosg, nopl = true, true
for _,arg in ipairs(args) do
local formas = {}
for subarg in gsplit(arg, ";") do
local types = {}
local a, b = match(subarg, "^(.-)%.(.*)$")
a = a or subarg
b = b or "+"
local c, d = match(b, "^(.-)%.(.*)$")
if d then
for spec in gsplit(d, "%.") do
spec = gsub(spec, "(.)%-", "%1_")
types[spec] = true
end
end
c = c or b
local r = split(a, "/")
local r1, r2, typ, detected_subtypes = detect_adj_type_and_subtype(r[1], r[2], c, types)
for _, subtype in ipairs(detected_subtypes) do
if types["-" .. subtype] then
-- if a "cancel subtype" spec is given, remove the cancel spec
-- and don't apply the subtype
types["-" .. subtype] = nil
elseif (subtype == "M" or subtype == "F" or subtype == "N") and
(types.M or types.F or types.N) then
-- if gender already specified, don't create conflicting gender spec
elseif (subtype == "sg" or subtype == "pl" or subtype == "both") and
(types.sg or types.pl or types.both) then
-- if number restriction already specified, don't create conflicting
-- number restriction spec
else
types[subtype] = true
end
end
local cb = adj_decl[typ]
assert(cb, "Especifique el tipo de sustantivo correcto en el primer parámetro")
local data = {forms={}, types=types, pos="", subtitles="", notes="", categories=cats, title=titles, loc=types.loc, num=args.num}
cb(data, {r1, r2})
local formas_ = {} -- necesario crear otro arreglo para no modificar las claves durante la iteración
for form,arr in pairs(data.forms) do
local pref = match(form, "^(.*)_m$")
if pref and not data.forms[pref.."_f"] then
formas_[pref.."_f"] = deep_copy(arr)
end
if pref and not data.forms[pref.."_n"] then
formas_[pref.."_n"] = deep_copy(arr)
end
formas_[form] = arr
end
data.forms = formas_
if not types.sg then
nopl = false
end
if not types.pl then
nosg = false
end
if types.sg then
for key,_ in pairs(data.forms) do
if key:find("_pl") then
data.forms[key] = {}
end
end
end
if types.pl then
for key,_ in pairs(data.forms) do
if key:find("_sg") then
data.forms[key] = {}
end
end
end
merge_forms(formas, data.forms, adj_lb)
end
if not declinfo then
declinfo = formas
else
declinfo = combinar_copulativa(declinfo, formas, separadores[M])
M = M + 1
end
end
if nosg == false then
nosg = find(args["num"], "p")
end
if nopl == false then
nopl = find(args["num"], "s")
end
local m = find(args["gen"], "m")
local fem = find(args["gen"], "f")
local n = find(args["gen"], "n")
local forms = sobreescribir_formas(declinfo, args, false, {}, adj_lb)
comprobar_defectivo(forms)
forms = desactivar_formas(forms,
function (form)
return (form:find("pl") and nopl) or (form:find("sg") and nosg) or (form:find("m$") and not m) or (form:find("f$") and not fem) or (form:find("n$") and not n)
end
)
local raiz_m = f(forms["nom_sg_m"][1] or forms["nom_pl_m"][1] or "?")
local raiz_f = f(forms["nom_sg_f"][1] or forms["nom_pl_f"][1] or "?")
local raiz_n = f(forms["nom_sg_n"][1] or forms["nom_pl_n"][1] or "?")
forms = agregar_enlaces(forms, title, normalizar_enlace)
forms = formatear_formas(forms, adj_lb)
local t = {}
insert(t, {{"Singular", colspan=4}, header=true, color=COLOR_H})
insert(t, {{""}, {"Masculino"}, {"Femenino"}, {"Neutro"}, header=true, color=COLOR_H, class="pc"})
insert(t, {{"Nominativo", header=true, color=COLOR_H}, forms["nom_sg_m"], forms["nom_sg_f"], forms["nom_sg_n"]})
insert(t, {{"Genitivo", header=true, color=COLOR_H}, forms["gen_sg_m"], forms["gen_sg_f"], forms["gen_sg_n"]})
insert(t, {{"Dativo", header=true, color=COLOR_H}, forms["dat_sg_m"], forms["dat_sg_f"], forms["dat_sg_n"]})
insert(t, {{"Acusativo", header=true, color=COLOR_H}, forms["acc_sg_m"], forms["acc_sg_f"], forms["acc_sg_n"]})
insert(t, {{"Ablativo", header=true, color=COLOR_H}, forms["abl_sg_m"], forms["abl_sg_f"], forms["abl_sg_n"]})
insert(t, {{"Vocativo", header=true, color=COLOR_H}, forms["voc_sg_m"], forms["voc_sg_f"], forms["voc_sg_n"]})
insert(t, {{"Plural", colspan=4, header=true, color=COLOR_H}})
insert(t, {{""}, {"Masculino"}, {"Femenino"}, {"Neutro"}, header=true, color=COLOR_H, class="pc"})
insert(t, {{"Nominativo", header=true, color=COLOR_H}, forms["nom_pl_m"], forms["nom_pl_f"], forms["nom_pl_n"]})
insert(t, {{"Genitivo", header=true, color=COLOR_H}, forms["gen_pl_m"], forms["gen_pl_f"], forms["gen_pl_n"]})
insert(t, {{"Dativo", header=true, color=COLOR_H}, forms["dat_pl_m"], forms["dat_pl_f"], forms["dat_pl_n"]})
insert(t, {{"Acusativo", header=true, color=COLOR_H}, forms["acc_pl_m"], forms["acc_pl_f"], forms["acc_pl_n"]})
insert(t, {{"Ablativo", header=true, color=COLOR_H}, forms["abl_pl_m"], forms["abl_pl_f"], forms["abl_pl_n"]})
insert(t, {{"Vocativo", header=true, color=COLOR_H}, forms["voc_pl_m"], forms["voc_pl_f"], forms["voc_pl_n"]})
insert(t, {{args["nota"] or "", colspan=4}})
return renderizar_tabla(
frame,
"'''Declinación de ''"..raiz_m..", "..raiz_f..", "..raiz_n.."'''''  tipo: "..concat(titles, ", "),
t,
ns == 0 and cats or {}
)
end
local EGO, TU, IS, NOS, VOS, EI = 1, 2, 3, 4, 5, 6
local tostr = {"1", "2", "3", "4", "5", "6"}
local PRONOMBRES = {"ego", "tū", "is, ea, id", "nōs", "vōs", "eī, eae, ea"}
local PRONOMBRES_SUBJ = {"ut ego", "ut tū", "ut is, ut ea, ut id", "ut nōs", "ut vōs", "ut eī, ut eae, ut ea"}
local PRONOMBRES_IMP = {"―", "(tū)", "(is, ea, id)", "―", "(vōs)", "(eī, eae, ea)"}
local IMPERSONALES = {"", "", "(id)", "", "", ""}
local function obtener_pronombre(forma, impers)
local conj, p = match(forma, "^(.*)(%d)$")
if not p then
return nil
end
p = tonumber(p)
if impers then
return IMPERSONALES[p]
else
if find(conj, "^subj") then
return PRONOMBRES_SUBJ[p]
end
if find(conj, "^imper") then
return PRONOMBRES_IMP[p]
end
return PRONOMBRES[p]
end
end
local sufijos = {
["1"] = {
inf_act = {"āre","isse"},
inf_pas = {"ārī"},
part_act = {"āns","ūrus"},
part_pas = {"andus","us"},
ger = {"andī","andō","andum"},
sup = {"um","ū"},
ind_pres = {"ō","ās","at","āmus","ātis","ant"},
ind_imp = {"ābam","ābās","ābat","ābāmus","ābātis","ābant"},
ind_perf = {"ī","istī","it","imus","istis","ērunt",
nil,nil,nil,nil,nil,"ēre"},
ind_pluperf = {"eram","erās","erat","erāmus","erātis","erant"},
ind_fut = {"ābō","ābis","ābit","ābimus","ābitis","ābunt"},
ind_fut_perf = {"erō","eris","erit","erimus","eritis","erint"},
ind_fut_sig = {"ō","is","it","imus","itis","int"},
ind_pres_pas = {"or","āris","ātur","āmur","āminī","antur",
nil,"āre"},
ind_imp_pas = {"ābar","ābāris","ābātur","ābāmur","ābāminī","ābantur",
nil,"ābāre"},
ind_fut_pas = {"ābor","āberis","ābitur","ābimur","ābiminī","ābuntur",
nil,"ābere"},
subj_pres = {"em","ēs","et","ēmus","ētis","ent"},
subj_imp = {"ārem","ārēs","āret","ārēmus","ārētis","ārent"},
subj_perf = {"erim","erīs","erit","erīmus","erītis","erint"},
subj_pluperf = {"issem","issēs","isset","issēmus","issētis","issent"},
subj_aor_sig = {"im","īs","īt","īmus","ītis","int"},
subj_pres_pas = {"er","ēris","ētur","ēmur","ēminī","entur",
nil,"ēre"},
subj_imp_pas = {"ārer","ārēris","ārētur","ārēmur","ārēminī","ārentur",
nil,"ārēre"},
imper_pres = {nil,"ā",nil,nil,"āte",nil},
imper_fut = {nil,"ātō","ātō",nil,"ātōte","antō"},
imper_pres_pas = {nil,"āre",nil,nil,"āminī",nil},
imper_fut_pas = {nil,"ātor","ātor",nil,nil,"antor"},
},
["2"] = {
inf_act = {"ēre","isse"},
inf_pas = {"ērī"},
part_act = {"ēns","ūrus"},
part_pas = {"endus","us"},
ger = {"endī","endō","endum"},
sup = {"um","ū"},
ind_pres = {"eō","ēs","et","ēmus","ētis","ent"},
ind_imp = {"ēbam","ēbās","ēbat","ēbāmus","ēbātis","ēbant"},
ind_perf = {"ī","istī","it","imus","istis","ērunt",
nil,nil,nil,nil,nil,"ēre"},
ind_pluperf = {"eram","erās","erat","erāmus","erātis","erant"},
ind_fut = {"ēbō","ēbis","ēbit","ēbimus","ēbitis","ēbunt"},
ind_fut_perf = {"erō","eris","erit","erimus","eritis","erint"},
ind_fut_sig = {"ō","is","it","imus","itis","int"},
ind_pres_pas = {"eor","ēris","ētur","ēmur","ēminī","entur",
nil,"ēre"},
ind_imp_pas = {"ēbar","ēbāris","ēbātur","ēbāmur","ēbāminī","ēbantur",
nil,"ēbāre"},
ind_fut_pas = {"ēbor","ēberis","ēbitur","ēbimur","ēbiminī","ēbuntur",
nil,"ēbere"},
subj_pres = {"eam","eās","eat","eāmus","eātis","eant"},
subj_imp = {"ērem","ērēs","ēret","ērēmus","ērētis","ērent"},
subj_perf = {"erim","erīs","erit","erīmus","erītis","erint"},
subj_pluperf = {"issem","issēs","isset","issēmus","issētis","issent"},
subj_aor_sig = {"im","īs","īt","īmus","ītis","int"},
subj_pres_pas = {"ear","eāris","eātur","eāmur","eāminī","eantur",
nil,"eāre"},
subj_imp_pas = {"ērer","ērēris","ērētur","ērēmur","ērēminī","ērentur",
nil,"ērēre"},
imper_pres = {nil,"ē",nil,nil,"ēte",nil},
imper_fut = {nil,"ētō","ētō",nil,"ētōte","entō"},
imper_pres_pas = {nil,"ēre",nil,nil,"ēminī",nil},
imper_fut_pas = {nil,"ētor","ētor",nil,nil,"entor"},
},
["3"] = { -- 3 (comparar [[capio]] con [[lego]], las raíces con capi- y leg- pero hay que eliminar la doble ii)
inf_act = {"ere","isse"},
inf_pas = {"ī"},
part_act = {"ēns","ūrus"},
part_pas = {"endus","us"},
ger = {"endī","endō","endum"},
sup = {"um","ū"},
ind_pres = {"ō","is","it","imus","itis","unt"},
ind_imp = {"ēbam","ēbās","ēbat","ēbāmus","ēbātis","ēbant"},
ind_perf = {"ī","istī","it","imus","istis","ērunt",
nil,nil,nil,nil,nil,"ēre"},
ind_pluperf = {"eram","erās","erat","erāmus","erātis","erant"},
ind_fut = {"am","ēs","ēt","ēmus","ētis","ent"},
ind_fut_perf = {"erō","eris","erit","erimus","eritis","erint"},
ind_fut_sig = {"ō","is","it","imus","itis","int"},
ind_pres_pas = {"or","eris","itur","imur","iminī","untur",
nil,"ere"},
ind_imp_pas = {"ēbar","ēbāris","ēbātur","ēbāmur","ēbāminī","ēbantur",
nil,"ēbāre"},
ind_fut_pas = {"ar","ēris","ētur","ēmur","ēminī","entur",
nil,"ēre"},
subj_pres = {"am","ās","at","āmus","ātis","ant"},
subj_imp = {"erem","erēs","eret","erēmus","erētis","erent"},
subj_perf = {"erim","erīs","erit","erīmus","erītis","erint"},
subj_pluperf = {"issem","issēs","isset","issēmus","issētis","issent"},
subj_aor_sig = {"im","īs","īt","īmus","ītis","int"},
subj_pres_pas = {"ar","āris","ātur","āmur","āminī","antur",
nil,"āre"},
subj_imp_pas = {"erer","erēris","erētur","erēmur","erēminī","erentur",
nil,"erēre"},
imper_pres = {nil,"e",nil,nil,"ite",nil},
imper_fut = {nil,"itō","itō",nil,"itōte","untō"},
imper_pres_pas = {nil,"ere",nil,nil,"iminī",nil},
imper_fut_pas = {nil,"itor","itor",nil,nil,"untor"},
},
["3/4"] = {
inf_act = {"ere","isse","īre","isse"},
inf_pas = {"ī","īrī"},
part_act = {"ēns","iēns","ūrus"},
part_pas = {"endus","iendus","us"},
ger = {"endī","endō","endum","iendī","iendō","iendum"},
sup = {"um","ū"},
ind_pres = {"ō","is","it","imus","itis","unt",
"iō","īs",nil,"īmus","ītis","iunt"
},
ind_imp = {"ēbam","ēbās","ēbat","ēbāmus","ēbātis","ēbant",
"iēbam","iēbās","iēbat","iēbāmus","iēbātis","iēbant"
},
ind_perf = {"ī","istī","it","imus","istis","ērunt",
nil,nil,nil,nil,nil,"ēre"},
ind_pluperf = {"eram","erās","erat","erāmus","erātis","erant"},
ind_fut = {"am","ēs","ēt","ēmus","ētis","ent",
"iam","iēs","iet","iēmus","iētis","ient"
},
ind_fut_perf = {"erō","eris","erit","erimus","eritis","erint"},
ind_fut_sig = {"ō","is","it","imus","itis","int"},
ind_pres_pas = {"or","eris","itur","imur","iminī","untur",
"ior","ere","ītur","īmur","īminī","iuntur",
nil,"īris",nil,nil,nil,nil,
nil,"īre"
},
ind_imp_pas = {"ēbar","ēbāris","ēbātur","ēbāmur","ēbāminī","ēbantur",
"iēbar","ēbāre","iēbātur","iēbāmur","iēbāminī","iēbantur",
nil,"iēbāris",nil,nil,nil,nil,
nil,"iēbāre"
},
ind_fut_pas = {"ar","ēris","ētur","ēmur","ēminī","entur",
"iar","ēre","iētur","iēmur","iēminī","ientur",
nil,"iēris",nil,nil,nil,nil,
nil,"iēre"
},
subj_pres = {"am","ās","at","āmus","ātis","ant",
"iam","iās","iat","iāmus","iātis","iant",
},
subj_imp = {"erem","erēs","eret","erēmus","erētis","erent",
"īrem","īrēs","īret","īrēmus","īrētis","īrent"
},
subj_perf = {"erim","erīs","erit","erīmus","erītis","erint"},
subj_pluperf = {"issem","issēs","isset","issēmus","issētis","issent"},
subj_aor_sig = {"im","īs","īt","īmus","ītis","int"},
subj_pres_pas = {"ar","āris","ātur","āmur","āminī","antur",
"iar","āre","iātur","iāmur","iāminī","iantur",
nil,"iāris",nil,nil,nil,nil,
nil,"iāre"
},
subj_imp_pas = {"erer","erēris","erētur","erēmur","erēminī","erentur",
"īrer","erēre","īrētur","īrēmur","īrēminī","īrentur",
nil,"īrēris",nil,nil,nil,nil,
nil,"īrēre"
},
imper_pres = {nil,"e",nil,nil,"ite",nil,
nil,"ī",nil,nil,"īte",nil
},
imper_fut = {nil,"itō","itō",nil,"itōte","untō",
nil,"ītō","ītō",nil,"ītōte","iuntō"
},
imper_pres_pas = {nil,"ere",nil,nil,"iminī",nil,
nil,"īre",nil,nil,"īminī",nil
},
imper_fut_pas = {nil,"itor","itor",nil,nil,"untor",
nil,"ītor","ītor",nil,nil,"iuntor"
},
},
["4"] = {
inf_act = {"īre","isse"},
inf_pas = {"īrī"},
part_act = {"iēns","ūrus"},
part_pas = {"iendus","us"},
ger = {"iendī","iendō","iendum"},
sup = {"um","ū"},
ind_pres = {"iō","īs","it","īmus","ītis","iunt"},
ind_imp = {"iēbam","iēbās","iēbat","iēbāmus","iēbātis","iēbant"},
ind_perf = {"ī","istī","it","imus","istis","ērunt",
nil,nil,nil,nil,nil,"ēre"},
ind_pluperf = {"eram","erās","erat","erāmus","erātis","erant"},
ind_fut = {"iam","iēs","iet","iēmus","iētis","ient"},
ind_fut_perf = {"erō","eris","erit","erimus","eritis","erint"},
ind_fut_sig = {"ō","is","it","imus","itis","int"},
ind_pres_pas = {"ior","īris","ītur","īmur","īminī","iuntur",
nil,"īre"},
ind_imp_pas = {"iēbar","iēbāris","iēbātur","iēbāmur","iēbāminī","iēbantur",
nil,"iēbāre"},
ind_fut_pas = {"iar","iēris","iētur","iēmur","iēminī","ientur",
nil,"iēre"},
subj_pres = {"iam","iās","iat","iāmus","iātis","iant"},
subj_imp = {"īrem","īrēs","īret","īrēmus","īrētis","īrent"},
subj_perf = {"erim","erīs","erit","erīmus","erītis","erint"},
subj_pluperf = {"issem","issēs","isset","issēmus","issētis","issent"},
subj_aor_sig = {"im","īs","īt","īmus","ītis","int"},
subj_pres_pas = {"iar","iāris","iātur","iāmur","iāminī","iantur",
nil,"iāre"},
subj_imp_pas = {"īrer","īrēris","īrētur","īrēmur","īrēminī","īrentur",
nil,"īrēre"},
imper_pres = {nil,"ī",nil,nil,"īte",nil},
imper_fut = {nil,"ītō","ītō",nil,"ītōte","iuntō"},
imper_pres_pas = {nil,"īre",nil,nil,"īminī",nil},
imper_fut_pas = {nil,"ītor","ītor",nil,nil,"iuntor"},
}
}
local formas_no_personales = {
inf_act = true,
inf_pas = true,
part_act = true,
part_pas = true,
ger = true,
sup = true,
}
local formas_personales = {
ind_pres = true,
ind_imp = true,
ind_perf = true,
ind_pluperf = true,
ind_fut = true,
ind_fut_perf = true,
ind_fut_sig = true,
ind_pres_pas = true,
ind_imp_pas = true,
ind_fut_pas = true,
subj_pres = true,
subj_imp = true,
subj_perf = true,
subj_pluperf = true,
subj_aor_sig = true,
subj_pres_pas = true,
subj_imp_pas = true,
imper_pres = true,
imper_fut = true,
imper_pres_pas = true,
imper_fut_pas = true,
}
local formas = merge(formas_no_personales, formas_personales)
local verbos_irregulares = {
{"aiō", {"aiō", "aiiō", "aijō", "ajō"}, {
desactivar = {"inf_pas","part_pas","ger","sup","ind_pluperf","ind_fut","ind_fut_perf",
"ind_pres_pas","ind_imp_pas","ind_fut_pas","subj_perf","subj_pluperf","subj_pres_pas",
"subj_imp_pas","imper_fut","imper_pres_pas","imper_fut_pas"
},
conj = "3",
nucleopres = {"ai"},
nucleoperf = {"a"},
nucleosup = {},
nucleosigm = {},
inf_act = {"aiere"},
ind_pres = {nil,nil,nil,{}},
ind_perf = {{},nil,nil,{},{}},
subj_pres = {nil,nil,nil,{},{}},
subj_imp = {{},{},nil,{},{},{}},
imper_pres = {{},{"ai"},{},{},{},{}},
}},
{"cedo", {"cedo"}, {
desactivar = {"inf_act","inf_pas","part_act","part_pas","ger","sup","ind_pluperf","ind_pres","ind_imp","ind_perf",
"ind_fut","ind_fut_perf","ind_pres_pas","ind_imp_pas","ind_fut_pas","subj_pres","subj_imp","subj_perf",
"subj_pluperf","subj_pres_pas","subj_imp_pas","imper_fut","imper_pres_pas","imper_fut_pas"
},
conj = "3",
nucleopres = {},
nucleoperf = {},
nucleosup = {},
nucleosigm = {},
imper_pres = {nil,{"cedo"},nil,nil,{"cette","cedile"},nil},
}},
{"dīcō", {"dīcō"}, {
conj = "3",
nucleopres = {"dīc"},
nucleoperf = {"dīx"},
nucleosup = {"dict"},
nucleosigm = {"dīx"},
desactivar = {},
imper_pres = {nil, {"dīc", "dīce"}},
inf_pas = {"dīcī", "dīcier{L}"},
}},
{"dō", {"dō"}, {
conj = "1",
nucleopres = {"d"},
nucleoperf = {"ded"},
nucleosup = {"dat"},
nucleosigm = {},
desactivar = {},
inf_act = {"dare","dedisse"},
inf_pas = {"darī"},
ind_pres = {nil,nil,nil,{"damus"},{"datis"},nil},
ind_imp = {{"dabam"},{"dabās"},{"dabat"},{"dabāmus"},{"dabātis"},{"dabant"}},
ind_fut = {{"dabō"},{"dabis"},{"dabit"},{"dabimus"},{"dabitis"},{"dabunt"}},
ind_imp_pas = {{"dabar"},{"dabāris","dabāre"},{"dabātur"},{"dabāmur"},{"dabāminī"},{"dabantur"}},
ind_fut_pas = {{"dabor"},{"daberis","dabere"},{"dabitur"},{"dabimur"},{"dabiminī"},{"dabuntur"}},
subj_imp = {{"darem"},{"darēs"},{"daret"},{"darēmus"},{"darētis"},{"darent"}},
subj_imp_pas = {{"darer"},{"darēris","darēre"},{"darētur"},{"darēmur"},{"darēminī"},{"darentur"}},
imper_pres = {nil,nil,nil,nil,{"date"},nil},
imper_fut = {nil,{"datō"},{"datō"},nil,{"datōte"},{"dantō"}},
imper_pres_pas = {nil,{"dare"},nil,nil,{"daminī"},nil},
imper_fut_pas = {nil,{"dator"},{"dator"},nil,nil,{"dator"}},
}},
{"dūcō", {"dūcō"}, {
conj = "3",
nucleopres = {"dūc"},
nucleoperf = {"dūx"},
nucleosup = {"duct"},
nucleosigm = {},
desactivar = {},
imper_pres = {nil, {"dūc", "dūce"}},
}},
{"edō", {"edō", "ëdō"}, {
conj = "3",
nucleopres = {"ed"},
nucleoperf = {"ed"},
nucleosup = {""},
nucleosigm = {},
desactivar = {},
inf_act = {"edere","ēsse"},
part_act = {"edēns","ēsūrus","ēssūrus","ēstūrus"},
part_pas = {"edendus","edundus","ēsus","ēssus","ēstus"},
sup = {"ēsum","ēssum","ēstum","ēsū","ēssū","ēstū"},
ind_pres = {nil,{"edis","ēs"},{"edit","ēst"},nil,{"editis","ēstis"},nil},
ind_pres_pas = {nil,{"ederis","edere","ēssis","ēsse"},{"editur","ēstur"}},
subj_pres = {{"edam","edim"},{"edās","edīs"},{"edat","edit","ēst"},{"edāmus","edīmus"},{"edātis","edītis"},{"edant","edint"}},
subj_imp = {{"ederem","ēssem"},{"ederēs","ēssēs"},{"ederet","ēsset"},{"ederēmus","ēssēmus"},{"ederētis","ēssētis"},{"ederent","ēssent"}},
subj_imp_pas = {{"ederer","ēsser"},{"ederēris","ederēre","ēssēris","ēssēre"},{"ederetur","ēssetur"},{"ederēmur","ēssēmur"},{"ederēminī","ēssēminī"},{"ederentur","ēssentur"}},
imper_pres = {nil,{"ede","ēs"},nil,nil,{"edite","ēste"},nil},
imper_fut = {nil,{"editō","ēstō"},{"editō","ēstō"},nil,{"editōte","ēstōte"},{"eduntō"}},
imper_pres_pas = {nil,{"edere","ēsse"},nil,nil,{"ediminī"},nil},
imper_fut_pas = {nil,{"editor","ēstor"},{"editor","ēstor"},nil,nil,{"eduntor"}},
}},
{"eō", {"eō", "ëō"}, {
conj = "4",
nucleopres = {""},
nucleoperf = {""},
nucleosup = {""},
nucleosigm = {},
desactivar = {"imper_pres_pas"},
inf_act = {"īre","īsse","iisse","īvisse"},
inf_pas = {"īrī","īrier"},
part_act = {"iēns","itūrus"},
part_pas = {"eundum","itum"},
ger = {"eundī","eundō","eundum"},
sup = {"itum","itū"},
ind_pres = {{"eō"},{"īs"},{"it"},{"īmus"},{"ītis"},{"eunt"}},
ind_imp = {{"ībam"},{"ībās"},{"ībat"},{"ībāmus"},{"ībātis"},{"ībant"}},
ind_perf = {{"iī","īvī"},{"īstī","iistī","īvistī"},{"iit","īvit"},{"iimus","īvimus"},{"īstis","iistis","īvistis"},{"iērunt","iēre","īvērunt","īvēre"}},
ind_pluperf = {{"ieram","īveram"},{"ierās","īverās"},{"ierat","īverat"},{"ierāmus","īverāmus"},{"ierātis","īverātis"},{"ierant","īverant"}},
ind_fut = {{"ībō"},{"ībis"},{"ībit"},{"ībimus"},{"ībitis"},{"ībunt"}},
ind_fut_perf = {{"ierō","īverō"},{"ieris","īveris"},{"ierit","īverit"},{"ierimus","īverimus"},{"ieritis","īveritis"},{"ierint","īverint"}},
ind_fut_sig = {nil,nil,nil,nil,nil,nil},
ind_pres_pas = {{},{},{"ītur"},{},{},{}},
ind_imp_pas = {{},{},{"ībātur"},{},{},{}},
ind_fut_pas = {{},{},{"ībitur"},{},{},{}},
subj_pres = {{"eam"},{"eās"},{"eat"},{"eāmus"},{"eātis"},{"eant"}},
subj_imp = {{"īrem"},{"īrēs"},{"īret"},{"īrēmus"},{"īrētis"},{"īrent"}},
subj_perf = {{"ierim","īverim"},{"ierīs","īverīs"},{"ierit","īverit"},{"ierīmus","īverīmus"},{"ierītis","īverītis"},{"ierint","īverint"}},
subj_pluperf = {{"īssem","iissem","īvissem"},{"īssēs","iissēs","īvissēs"},{"īsset","iisset","īvisset"},{"īssēmus","iissēmus","īvissēmus"},{"īssētis","iissētis","īvissētis"},{"īssent","iissent","īvissent"}},
subj_aor_sig = {nil,nil,nil,nil,nil,nil},
subj_pres_pas = {{},{},{"eātur"},{},{},{}},
subj_imp_pas = {{},{},{"īrētur"},{},{},{}},
imper_pres = {nil,nil,nil,nil,nil,nil},
imper_fut = {nil,nil,nil,nil,nil,{"euntō"}},
imper_fut_pas = {nil,{},nil,nil,nil,{}},
}},
{"faciō", {"faciō"}, {
conj = "3",
nucleopres = {"faci"},
nucleoperf = {"fax"},
nucleosup = {"fact"},
nucleosigm = {"fax","faxs","facs"},
desactivar = {},
ind_pres_pas = {{"fīō"},{"fīs"},{"fit"},{"fīmus"},{"fītis"},{"fīunt"}},
ind_imp_pas = {{"fīēbam"},{"fīēbās"},{"fīēbat"},{"fīēbāmus"},{"fīēbātis"},{"fīēbant"}},
ind_fut_pas = {{"fīam"},{"fīēs"},{"fīet"},{"fīēmus"},{"fīētis"},{"fīent"}},
subj_pres_pas = {{"fīam"},{"fīās"},{"fīat"},{"fīāmus"},{"fīātis"},{"fīant"}},
subj_imp_pas = {{"fierem"},{"fierēs"},{"fieret"},{"fierēmus"},{"fierētis"},{"fierent"}},
imper_pres = {nil,{"fac","face"},nil,nil,nil,nil},
imper_pres_pas = {nil,{"fī"},nil,nil,{"fīte"},nil},
imper_fut_pas = {nil,{"fītō"},{"fītō"},nil,{"fītōte"},{"fīuntō"}},
}},
{"ferō", {"ferō"}, {
conj = "3",
nucleopres = {"fer"},
nucleoperf = {"tul", "tetul"},
nucleosup = {"lāt"},
nucleosigm = {},
desactivar = {},
inf_act = {"ferre", "tulisse", "tetulisse{†}"},
inf_pas = {"ferrī"},
ind_pres = {nil,{"fers"},{"fert"},nil,{"fertis"}},
ind_pres_pas = {nil,{"ferris","ferre"}},
subj_imp = {{"ferrem"},{"ferrēs"},{"ferret"},{"ferrēmus"},{"ferrētis"},{"ferrent"}},
subj_imp_pas = {{"ferrer"},{"ferrēris","ferrēre"},{"ferrētur"},{"ferrēmur"},{"ferrēminī"},{"ferrentur"}},
imper_pres = {nil,{"fer"},nil,nil,{"ferte"},nil},
imper_pres_pas = {nil,{"ferre"},nil,nil,nil,nil},
imper_fut = {nil,{"fertō"},{"fertō"},nil,{"fertōte"},{"feruntō"}},
imper_fut_pas = {nil,{"fertor"},{"fertor"},nil,nil,nil},
}},
{"fīō", {"fīō"}, {
conj = "3",
nucleopres = {"fī"},
nucleoperf = {},
nucleosup = {"fact"},
nucleosigm = {},
semidep = true,
desactivar = {},
ind_pres = {{"fīō"},{"fīs"},{"fit"},{"fīmus"},{"fītis"},{"fīunt"}},
imper_pres = {nil,{"fī"},nil,nil,{"fīte"},nil},
imper_fut = {nil,{"fītō"},{"fītō"},nil,{"fītōte"},{"feruntō"}},
}},
{"inquam", {"inquam"}, {
conj = "3",
nucleopres = {"inqui"},
nucleoperf = {},
nucleosup = {},
nucleosigm = {},
nopasivo = true,
desactivar = {"inf_act","inf_pas","part_pas","ger"},
ind_pres = {{"inquam"}},
}},
{"possum", {"possum"}, {
conj = "3",
nucleopres = {"pot"},
nucleoperf = {"pot"},
nucleosup = {},
nucleosigm = {},
pres = "possō",
desactivar = {"inf_pas","part_pas","ger","sup","ind_pres_pas","ind_imp_pas","ind_fut_pas",
"subj_pres_pas","subj_imp_pas","imper_pres","imper_fut","imper_pres_pas","imper_fut_pas"},
inf_act = {"posse","potesse{†}"},
part_act = {"potēns"},
ind_pres = {{"possum"},{"potes"},{"potest"},{"possumus"},{"potestis"},{"possunt"}},
ind_imp = {{"poteram"},{"poterās"},{"poterat"},{"poterāmus"},{"poterātis"},{"poterant"}},
ind_fut = {{"poterō"},{"poteris","potere"},{"poterit"},{"poterimus"},{"poteritis"},{"poterunt"}},
ind_perf = {{"potuī"},{"potuistī"},{"potuit"},{"potuimus"},{"potuistis"},{"potuērunt","potuēre"}},
ind_pluperf = {{"potueram"},{"potuerās"},{"potuerat"},{"potuerāmus"},{"potuerātis"},{"potuerant"}},
ind_fut_perf = {{"potuerō"},{"potueris"},{"potuerit"},{"potuerimus"},{"potueritis"},{"potuerunt"}},
subj_pres = {{"possem"},{"possēs"},{"possēt"},{"possēmus"},{"possētis"},{"possent"}},
subj_imp = {{"possim"},{"possīs"},{"possit"},{"possīmus"},{"possītis"},{"possint"}},
subj_perf = {{"potuerim"},{"potuerīs"},{"potuerit"},{"potuerīmus"},{"potuerītis"},{"potuerint"}},
subj_pluperf = {{"potuissem"},{"potuissēs"},{"potuisset"},{"potuissēmus"},{"potuissētis"},{"potuissent"}},
}},
{"sum", {"sum"}, {
conj = "3",
nucleopres = {"s"},
nucleoperf = {"fu"},
nucleosup = {},
nucleosigm = {},
pres = "sō",
desactivar = {"inf_pas","part_pas","ger","sup","ind_pres_pas","ind_imp_pas","ind_fut_pas",
"subj_pres_pas","subj_imp_pas","imper_pres_pas","imper_fut_pas"},
inf_act = {"esse"},
part_act = {"futūrus"},
ind_pres = {{"sum"},{"es"},{"est"},{"sumus"},{"estis"},{"sunt"}},
ind_imp = {{"eram"},{"erās"},{"erat"},{"erāmus"},{"erātis"},{"erant"}},
ind_fut = {{"erō"},{"eris","ere"},{"erit"},{"erimus"},{"eritis"},{"erunt"}},
subj_pres = {{"sim","siem","fuam{†}"},{"sīs","siēs","fuās{†}"},{"sit","siet","fuat{†}"},{"sīmus","siēmus","fuāmus{†}"},{"sītis","siētis","fuātis{†}"},{"sint","sient","fuant{†}"}},
subj_imp = {{"essem","forem"},{"essēs","forēs"},{"esset","foret"},{"essēmus","forēmus"},{"essētis","forētis"},{"essent","forent"}},
imper_pres = {nil,{"es"},nil,nil,{"este"},nil},
imper_fut = {nil,{"estō"},{"estō"},nil,{"estōte"},nil},
}},
{"mālō", {"mālō"}, {
conj = "3",
nucleopres = {"māl"},
nucleoperf = {"mālu"},
nucleosup = {},
nucleosigm = {},
desactivar = {"sup","ger","inf_pas","part_pas","ind_pres_pas","ind_imp_pas","ind_fut_pas","subj_pres_pas","subj_imp_pas",
"imper_pres","imper_fut","imper_pres_pas","imper_fut_pas"},
inf_act = {"mālle","māluisse"},
ind_pres = {{"mālō"},{"māvīs"},{"māvult"},{"mālumus"},{"māvultis"},{"mālunt"}},
subj_pres = {{"mālim"},{"mālīs"},{"mālit"},{"mālīmus"},{"mālītis"},{"mālint"}},
subj_imp = {{"māllem"},{"māllēs"},{"māllet"},{"māllēmus"},{"māllētis"},{"māllent"}},
}},
{"nōlō", {"nōlō"}, {
conj = "3",
nucleopres = {"nōl"},
nucleoperf = {"nōlu"},
nucleosup = {},
nucleosigm = {},
desactivar = {"sup","ger","inf_pas","part_pas","ind_pres_pas","ind_imp_pas","ind_fut_pas","subj_pres_pas","subj_imp_pas",
"imper_pres","imper_fut","imper_pres_pas","imper_fut_pas"},
inf_act = {"nōlle","nōluisse"},
ind_pres = {{"nōlō"},{"nōn vīs","nevīs{†}"},{"nōn vult","nōn volt","nevolt{†}"},{"nōlumus"},{"nōn vultis","nōn voltis","nōltis{†}"},{"nōlunt"}},
subj_pres = {{"nōlim"},{"nōlīs"},{"nōlit"},{"nōlīmus"},{"nōlītis"},{"nōlint"}},
subj_imp = {{"nōllem"},{"nōllēs"},{"nōllet"},{"nōllēmus"},{"nōllētis"},{"nōllent"}},
}},
{"volō", {"volō"}, {
conj = "3",
nucleopres = {"vol"},
nucleoperf = {"volu"},
nucleosup = {"volit"},
nucleosigm = {},
desactivar = {"sup","ger","inf_pas","part_pas","ind_pres_pas","ind_imp_pas","ind_fut_pas","subj_pres_pas","subj_imp_pas",
"imper_pres","imper_fut","imper_pres_pas","imper_fut_pas"},
inf_act = {"velle","voluisse"},
ind_pres = {{"volō"},{"vīs"},{"vult","volt{†}"},{"volumus"},{"vultis","voltis{†}"},{"volunt"}},
subj_pres = {{"velim","volim{†}"},{"velīs","volīs{†}"},{"velit","volit{†}"},{"velīmus","volīmus{†}"},{"velītis","volītis{†}"},{"velint","volint{†}"}},
subj_imp = {{"vellem"},{"vellēs"},{"vellet"},{"vellēmus"},{"vellētis"},{"vellent"}},
}},
}
local function combinar_prefijo_nucleosufijo(prefijo, nucleosufijo)
return prefijo..nucleosufijo
end
local function combinar_nucleo_sufijo(nucleo, sufijo, agregar_i)
if agregar_i and (not find(sufijo, "^[iī]")) and (sufijo ~= "e") and (not find(sufijo, "^er")) then
return nucleo.."~i~"..sufijo
end
return nucleo..sufijo
end
local function agregar_forma(conjugado, conjinfo, forma)
conjinfo[forma] = conjinfo[forma] or {}
local sufijos_ = sufijos[conjinfo.conj][forma]
local nucleos
local prefijo
if forma == "sup" then
nucleos = conjinfo.nucleosup
prefijo = conjinfo.prefijosup or conjinfo.prefijo
elseif find(forma, "sig") then
nucleos = conjinfo.nucleosigm
prefijo = conjinfo.prefijosigm or conjinfo.prefijo
elseif find(forma, "perf") then
nucleos = conjinfo.nucleoperf
prefijo = conjinfo.prefijoperf or conjinfo.prefijo
else
nucleos = conjinfo.nucleopres
prefijo = conjinfo.prefijo
end
if formas_no_personales[forma] then
if conjinfo[forma][1] then
if nucleos and #nucleos > 0 then
for _, fm in ipairs(conjinfo[forma]) do
insert_if_not(conjugado[forma], "#"..combinar_prefijo_nucleosufijo(prefijo, fm).."#")
end
end
else
for _, sufijo in ipairs(sufijos_) do
local nucleos_ = nucleos
if forma == "inf_act" and sufijo == "isse" then
nucleos_ = conjinfo.nucleoperf
elseif forma == "part_act" and sufijo == "ūrus" then
nucleos_ = conjinfo.nucleosup
elseif forma == "part_pas" and sufijo == "us" then
nucleos_ = conjinfo.nucleosup
end
local agregar_i = conjinfo.I and nucleos_ == conjinfo.nucleopres
for _,nucleo in ipairs(nucleos_) do
insert_if_not(conjugado[forma], combinar_prefijo_nucleosufijo(prefijo, combinar_nucleo_sufijo(nucleo, sufijo, agregar_i)))
end
end
end
return
end
for i = EGO, EI do
local p = tostr[i]
if conjinfo[forma][i] then
if nucleos and #nucleos > 0 then
for _, fm in ipairs(conjinfo[forma][i]) do
insert_if_not(conjugado[forma..p], "#"..combinar_prefijo_nucleosufijo(prefijo, fm).."#")
end
end
else
local k = i
while sufijos_[k] do
local agregar_i = conjinfo.I and nucleos == conjinfo.nucleopres
for j, n in ipairs(nucleos) do
local x = combinar_prefijo_nucleosufijo(prefijo, combinar_nucleo_sufijo(n, sufijos_[k], agregar_i))
if conjinfo.always_sync_perf and (forma == "ind_perf" or forma == "ind_pluperf" or forma == "ind_fut_perf" or forma == "subj_perf" or forma == "subj_pluperf") then
x = x:gsub("īvī", "iī")
x = x:gsub("īvi", "ī")
x = x:gsub("īve", "ī")
x = x:gsub("īvē", "ē")
end
insert_if_not(conjugado[forma..p], x)
end
k = k + 6
end
end
end
end
local function get_subtype_by_ending(pres, conjinfo, specs)
for _, spec in ipairs(specs) do
local base = extract_base(pres, spec[1])
if base then
for _,s in ipairs(spec[2]) do
if conjinfo[s] == nil then
conjinfo[s] = true
end
end
return base
end
end
error("Unrecognized ending for conjugation " .. conjinfo["conj"])
end
local function detect_v_type_and_subtypes(conjinfo)
local pres = conjinfo["v"]
local conj_arg = conjinfo["conj"]
pres = toNFC(pres)
local base_conj_arg, auto_perf_supine = conj_arg:match("^([124]/?4?)(%+%+?)$")
if base_conj_arg then
if auto_perf_supine == "++" and base_conj_arg ~= "4" then
error("Conjugation types 1++ and 2++ not allowed")
end
conj_arg = base_conj_arg
end
conjinfo.conj = conj_arg
if conj_arg == "1" then
local base = get_subtype_by_ending(pres, conjinfo, {
{"ō", {}},
{"or", {"dep"}},
{"at", {"impers"}},
{"ātur", {"dep", "impers"}},
{"ī", {"nopres"}},
{"it", {"nopres", "impers"}},
})
if not conjinfo["nucleopres"][1] then
conjinfo["nucleopres"][1] = base
end
if auto_perf_supine then
if not conjinfo["nucleoperf"][1] then
conjinfo["nucleoperf"][1] = base .. "āv"
end
if not conjinfo["nucleosup"][1] then
conjinfo["nucleosup"][1] = base .. "āt"
end
end
if conjinfo.sigm then
if not conjinfo["nucleosigm"][1] then
conjinfo["nucleosigm"][1] = base .. "āss"
end
end
elseif conj_arg == "2" then
local base = get_subtype_by_ending(pres, conjinfo, {
{"eō", {}},
{"eor", {"dep"}},
{"et", {"impers"}},
{"ētur", {"dep", "impers"}},
{"ī", {"nopres"}},
{"it", {"nopres", "impers"}},
})
if not conjinfo["nucleopres"][1] then
conjinfo["nucleopres"][1] = base
end
if auto_perf_supine then
if not conjinfo["nucleoperf"][1] then
conjinfo["nucleoperf"][1] = base .. "u"
end
if not conjinfo["nucleosup"][1] then
conjinfo["nucleosup"][1] = base .. "it"
end
end
if conjinfo.sigm then
if not conjinfo["nucleosigm"][1] then
conjinfo["nucleosigm"][1] = base .. "ēss"
end
end
elseif conj_arg == "3" then
local base
if conjinfo.I == false then -- si explícitamente se indicó que no es del tipo -io, hay que excluir sufijos
base = get_subtype_by_ending(pres, conjinfo, {
{"ō", {}},
{"or", {"dep"}},
{"it", {"impers"}},
{"itur", {"dep", "impers"}},
{"ī", {"nopres"}},
})
else
base = get_subtype_by_ending(pres, conjinfo, {
{"iō", {"I"}},
{"ior", {"dep", "I"}},
{"ō", {}},
{"or", {"dep"}},
{"it", {"impers"}},
{"itur", {"dep", "impers"}},
{"ī", {"nopres"}},
})
end
if not conjinfo["nucleopres"][1] then
conjinfo["nucleopres"][1] = base
end
if not conjinfo["nucleoperf"][1] and conjinfo["nopres"] then
conjinfo["nucleoperf"][1] = base
end
assert(conjinfo["nucleoperf"][1], "especifique todos los núcleos para verbos de la tercera conjugación")
assert(conjinfo["nucleosup"][1], "especifique todos los núcleos para verbos de la tercera conjugación")
if conjinfo.sigm then
if not conjinfo["nucleosigm"][1] then
conjinfo["nucleosigm"][1] = base .. "ēss"
end
end
elseif conj_arg == "3/4" then
local base
base = get_subtype_by_ending(pres, conjinfo, {
{"iō", {"I"}},
{"ior", {"dep", "I"}},
})
if not conjinfo["nucleopres"][1] then
conjinfo["nucleopres"][1] = base
end
if not conjinfo["nucleoperf"][1] and conjinfo["nopres"] then
conjinfo["nucleoperf"][1] = base
end
if not conjinfo["nucleoperf"][1] and auto_perf_supine == "++" then
conjinfo["nucleoperf"][1] = base .. "īv"
conjinfo["nucleoperf"][2] = base .. "i"
end
if not conjinfo["nucleoperf"][1] and auto_perf_supine == "+" then
conjinfo["nucleoperf"][1] = base .. "īv"
end
if not conjinfo["nucleosup"][1] and auto_perf_supine then
conjinfo["nucleosup"][1] = base .. "īt"
end
if conjinfo.sigm then
if not conjinfo["nucleosigm"][1] then
conjinfo["nucleosigm"][1] = base .. "īss"
end
end
elseif conj_arg == "4" then
local base = get_subtype_by_ending(pres, conjinfo, {
{"iō", {}},
{"ior", {"dep"}},
{"it", {"impers"}},
{"ītur", {"dep", "impers"}},
{"ī", {"nopres"}},
})
if not conjinfo["nucleopres"][1] then
conjinfo["nucleopres"][1] = base
end
if not conjinfo["nucleoperf"][1] and conjinfo["nopres"] then
conjinfo["nucleoperf"][1] = base
end
if not conjinfo["nucleoperf"][1] and auto_perf_supine == "++" then
conjinfo["nucleoperf"][1] = base .. "īv"
conjinfo["nucleoperf"][2] = base .. "i"
end
if not conjinfo["nucleoperf"][1] and auto_perf_supine == "+" then
conjinfo["nucleoperf"][1] = base .. "īv"
end
if not conjinfo["nucleosup"][1] and auto_perf_supine then
conjinfo["nucleosup"][1] = base .. "īt"
end
if conjinfo.sigm then
if not conjinfo["nucleosigm"][1] then
conjinfo["nucleosigm"][1] = base .. "īss"
end
end
elseif conj_arg == "irreg" then
for _,p in ipairs(verbos_irregulares) do
for _,rx in ipairs(p[2]) do
local pref, verb = match(conjinfo.v, "^(.*)("..rx..")$")
if verb then
conjinfo.v = verb
conjinfo.prefijo = pref
if conjinfo.nucleoperf[1] and conjinfo.nucleoperf[1] ~= "-" then -- [[ecfero]]
conjinfo.prefijoperf = conjinfo.nucleoperf[1]
conjinfo.nucleoperf = {}
end
if conjinfo.nucleosup[1] and conjinfo.nucleosup[1] ~= "-" then
conjinfo.prefijosup = conjinfo.nucleosup[1]
conjinfo.nucleosup = {}
end
if conjinfo.nucleosigm[1] and conjinfo.nucleosigm[1] ~= "-" then
conjinfo.prefijosigm = conjinfo.nucleosigm[1]
conjinfo.nucleosigm = {}
end
conjinfo.irreg = true
conjinfo.conj = p[3].conj
for k,val in pairs(p[3]) do
if not conjinfo[k] or (type(conjinfo[k]) == "table" and not conjinfo[k][1]) then
conjinfo[k] = deep_copy(val)
end
end
return conjinfo
end
end
end
error("Unrecognized conjugation '" .. conj_arg .. "'")
else
error("Unrecognized conjugation '" .. conj_arg .. "'")
end
return conjinfo
end
function export.v(frame)
local title_ = mw.title.getCurrentTitle()
local tit = title_.fullText
local ns = title_.namespace
if ns ~= 0 then
return "Use esta plantilla en el espacio principal."
end
local params = {
[1] = {alias_de = "conj"},
[2] = {alias_de = "pres"},
[3] = {alias_de = "nucleoperf"},
[4] = {alias_de = "nucleosup"},
[5] = {alias_de = "nucleosigm"},
["impers"] = {}, -- pas para formas pasivas solamente
["impersonal"] = {alias_de = "impers"},
["dep"] = {tipo="bool"},
["depon"] = {alias_de="dep"},
["deponente"] = {alias_de="dep"},
["semidep"] = {tipo="bool"},
["semidepon"] = {alias_de="semidep"},
["semideponente"] = {alias_de="semidep"},
["sigm"] = {tipo="bool"},
["nopasivo"] = {tipo="bool"},
["soloperf"] = {tipo="bool"},
["I"] = {tipo="bool"},
["p3inf"] = {tipo="bool"}, -- sin uso
["poet_sync_perf"] = {tipo="bool"}, -- sin uso
["always_sync_perf"] = {tipo="bool"}, -- solo en [[saevio]]
["conj"] = {requerido=true},
["pres"] = {requerido=true},
["nucleopres"] = {lista = true},
["nucleoperf"] = {lista = true},
["nucleosup"] = {lista = true},
["nucleosigm"] = {lista = true},
["núcleopres"] = {alias_de="nucleopres"},
["núcleoperf"] = {alias_de="nucleoperf"},
["núcleosup"] = {alias_de="nucleosup"},
["paradigma"] = {lista = true},
["desactivarnucleos"] = {tipo="bool", por_defecto=true}, -- para [[-o]]
["nota"] = {},
}
local conjugado = {}
for forma,_ in pairs(formas_no_personales) do
params[forma] = {tipo=parsear_arreglo, por_defecto={}}
conjugado[forma] = {}
end
for forma,_ in pairs(formas_personales) do
for i,s in ipairs(tostr) do
params[forma..s] = {tipo=parsear_arreglo, por_defecto={}}
conjugado[forma..s] = {}
if i == 1 then
params[forma] = {alias_de=forma..s}
end
end
end
local parent_frame = frame:getParent()
local args = require("Módulo:parámetros").obtener_parametros(parent_frame.args, params)
assert(not find(tit, " "), "locuciones no soportadas aún")
assert(not (args["dep"] and args["semidep"]), "un verbo no puede ser deponente y semideponente a la vez")
local conjinfo = {
conj = args.conj,
prefijo="",
v=args.pres,
desactivar = {},
dep=args.dep,
semidep=args.semidep,
sigm=args.sigm,
impers=args.impers,
nopasivo=args.nopasivo,
soloperf=args.soloperf,
I=args.I,
p3inf=args.p3inf,
poet_sync_perf=args.poet_sync_perf, -- sin uso
always_sync_perf=args.always_sync_perf,
nucleopres = deep_copy(args.nucleopres),
nucleoperf = deep_copy(args.nucleoperf),
nucleosup = deep_copy(args.nucleosup),
nucleosigm = deep_copy(args.nucleosigm)
}
conjinfo = detect_v_type_and_subtypes(conjinfo)
conjinfo.conj = conjinfo.conj
if conjinfo.impers == true then
conjinfo.impers = "3"
end
-- no puede ir conjinfo acá abajo porque si es un sufijo va a quedar "-" en la raíz, lo que anularía todas las formas conjugadas, tiene que venir directo de args
if args.desactivarnucleos then
if args.nucleopres[1] == "-" then
conjinfo.nucleopres = {}
end
if args.nucleoperf[1] == "-" then
conjinfo.nucleoperf = {}
end
if args.nucleosup[1] == "-" then
conjinfo.nucleosup = {}
end
if args.nucleosigm[1] == "-" then
conjinfo.nucleosigm = {}
end
end
local es_irregular = conjinfo.irreg
for _,d in ipairs(conjinfo.desactivar) do
if formas_no_personales[d] then
args[d] = {"no"}
else
args[d.."2"] = {"no"}
end
end
for forma,_ in pairs(formas) do
agregar_forma(conjugado, conjinfo, forma)
end
local resultante = sobreescribir_formas(conjugado, args)
local mostrar_fut_sig = #resultante["ind_fut_sig1"] > 0
local mostrar_aor_sig = #resultante["subj_aor_sig1"] > 0
local defectivo = comprobar_defectivo(resultante, {"^imper", "_sig"}, tostr)
local defect2
resultante, defect2 = desactivar_formas(resultante,
function (form)
return (conjinfo.nopasivo and form:find("_pas")) or (conjinfo.soloperf and not form:find("perf")) or (conjinfo.impers == "pas" and form:find("_pas[^3]")) or (conjinfo.impers == "pas3" and form:find("_pas[^3]")) or (conjinfo.impers == "pas36" and form:find("_pas[^36]"))
end
)
if defect2 then
defectivo = true
end
-- por ahora innecesario
-- local part_no_adj = {}
-- for _,e in ipairs(resultante.part) do
-- if (find(e, 'PART') or not find(e, 'ADJ')) and not find(e, "†") then
-- insert(part_no_adj, gsub1(e, '%b{}', ''))
-- end
-- end
local tit_pres = f(resultante["ind_pres1"][1] or "―")
local tit_inf = f(resultante["inf_act"][1] or "―")
local tit_perf = f(resultante["ind_perf1"][1] or "―")
local tit_sup = f(resultante["sup"][1] or "―")
resultante = agregar_enlaces(resultante, tit, normalizar_enlace)
local es_impersonal = conjinfo.impers
resultante = formatear_formas(resultante, function (x)
return obtener_pronombre(x, es_impersonal)
end)
local impers = conjinfo.impers
local cs, cs1, cs2, fila_pronombres_ind, fila_pronombres_subj, fila_pronombres_imper, mostrar_imper
if impers == "3" then
fila_pronombres_ind = {"", "(id)", color=COLOR_IND, header=true, class="pc"}
fila_pronombres_subj = {"", "(quod id)", color=COLOR_SUBJ, header=true, class="pc"}
fila_pronombres_imper = {"", "(id)", color=COLOR_IMPER, header=true, class="pc"}
cs = 2
elseif impers == "36" then
error("no soportado actualmente")
cs = 3
else
fila_pronombres_ind = {"", PRONOMBRES[1], PRONOMBRES[2], PRONOMBRES[3], PRONOMBRES[4], PRONOMBRES[5], PRONOMBRES[6], color=COLOR_IND, header=true, class="pc"}
fila_pronombres_subj = {"", PRONOMBRES_SUBJ[1], PRONOMBRES_SUBJ[2], PRONOMBRES_SUBJ[3], PRONOMBRES_SUBJ[4], PRONOMBRES_SUBJ[5], PRONOMBRES_SUBJ[6], color=COLOR_SUBJ, header=true, class="pc"}
fila_pronombres_imper = {"", PRONOMBRES_IMP[1], PRONOMBRES_IMP[2], PRONOMBRES_IMP[3], PRONOMBRES_IMP[4], PRONOMBRES_IMP[5], PRONOMBRES_IMP[6], color=COLOR_IMPER, header=true, class="pc"}
cs = 7
mostrar_imper = true
end
cs1 = cs -- math.floor(cs / 2)
-- cs2 = cs - cs1
local t = {}
insert(t, {{"Formas no personales (verboides)", colspan=cs}, color=COLOR_H, header=true})
if impers == "3" then
insert(t, {{"Infinitivo activo", header=true, color=COLOR_NP}, resultante.inf_act})
insert(t, {{"Infinitivo pasivo", header=true, color=COLOR_NP}, resultante.inf_pas})
insert(t, {{"Participio activo", header=true, color=COLOR_NP}, resultante.part_act})
insert(t, {{"Participio pasivo", header=true, color=COLOR_NP}, resultante.part_pas})
insert(t, {{"Gerundio", header=true, color=COLOR_NP}, resultante.ger})
insert(t, {{"Supino", header=true, color=COLOR_NP}, resultante.sup})
else
resultante.inf_act.colspan = cs1-1
resultante.inf_pas.colspan = cs1-1
resultante.part_act.colspan = cs1-1
resultante.part_pas.colspan = cs1-1
resultante.ger.colspan = cs1-1
resultante.sup.colspan = cs1-1
if not conjinfo.dep then
insert(t, {{"Infinitivo activo", header=true, color=COLOR_NP}, resultante.inf_act})
end
if not conjinfo.semidep then
insert(t, {{"Infinitivo pasivo", header=true, color=COLOR_NP}, resultante.inf_pas})
end
if not conjinfo.dep then
insert(t, {{"Participio activo", header=true, color=COLOR_NP}, resultante.part_act})
end
if not conjinfo.semidep then
insert(t, {{"Participio pasivo", header=true, color=COLOR_NP}, resultante.part_pas})
end
insert(t, {{"Gerundio", header=true, color=COLOR_NP}, resultante.ger})
insert(t, {{"Supino", header=true, color=COLOR_NP}, resultante.sup})
end
local function ic(tiempo)
if impers == "3" then
return resultante[tiempo.."3"]
elseif impers == "36" then
return resultante[tiempo.."3"], resultante[tiempo.."6"]
end
return resultante[tiempo.."1"], resultante[tiempo.."2"], resultante[tiempo.."3"], resultante[tiempo.."4"], resultante[tiempo.."5"], resultante[tiempo.."6"]
end
insert(t, {{"Formas personales", colspan=cs}, color=COLOR_H, header=true})
insert(t, {{"Modo indicativo", colspan=cs}, color=COLOR_IND, header=true})
insert(t, fila_pronombres_ind)
if not conjinfo.dep then
insert(t, {{"Presente", color=COLOR_IND, header=true}, ic("ind_pres")})
insert(t, {{"Pretérito imperfecto", color=COLOR_IND, header=true}, ic("ind_imp")})
insert(t, {{"Futuro", color=COLOR_IND, header=true}, ic("ind_fut")})
end
if not conjinfo.dep and not conjinfo.semidep then
insert(t, {{"Pretérito perfecto", color=COLOR_IND, header=true}, ic("ind_perf")})
insert(t, {{"Pretérito pluscuamperfecto", color=COLOR_IND, header=true}, ic("ind_pluperf")})
insert(t, {{"Futuro perfecto", color=COLOR_IND, header=true}, ic("ind_fut_perf")})
end
if mostrar_fut_sig then
insert(t, {{f("Futuro sigmático{†}"), color=COLOR_IND, header=true}, ic("ind_fut_sig")})
end
if not conjinfo.semidep then
insert(t, {{"Presente pasivo", color=COLOR_IND, header=true}, ic("ind_pres_pas")})
insert(t, {{"Pretérito imperfecto pasivo", color=COLOR_IND, header=true}, ic("ind_imp_pas")})
insert(t, {{"Futuro pasivo", color=COLOR_IND, header=true}, ic("ind_fut_pas")})
end
insert(t, {{"Modo subjuntivo", colspan=cs}, color=COLOR_SUBJ, header=true})
insert(t, fila_pronombres_subj)
if not conjinfo.dep then
insert(t, {{"Presente", color=COLOR_SUBJ, header=true}, ic("subj_pres")})
insert(t, {{"Pretérito imperfecto", color=COLOR_SUBJ, header=true}, ic("subj_imp")})
end
if not conjinfo.dep and not conjinfo.semidep then
insert(t, {{"Pretérito perfecto", color=COLOR_SUBJ, header=true}, ic("subj_perf")})
insert(t, {{"Pretérito pluscuamperfecto", color=COLOR_SUBJ, header=true}, ic("subj_pluperf")})
end
if mostrar_aor_sig then
insert(t, {{f("Aorista sigmático{†}"), color=COLOR_SUBJ, header=true}, ic("subj_aor_sig")})
end
if not conjinfo.semidep then
insert(t, {{"Presente pasivo", color=COLOR_SUBJ, header=true}, ic("subj_pres_pas")})
insert(t, {{"Pretérito imperfecto pasivo", color=COLOR_SUBJ, header=true}, ic("subj_imp_pas")})
end
insert(t, {{"Modo imperativo", colspan=cs}, color=COLOR_IMPER, header=true})
insert(t, fila_pronombres_imper)
if mostrar_imper then
if not conjinfo.dep then
insert(t, {{"Presente", color=COLOR_IMPER, header=true}, ic("imper_pres")})
insert(t, {{"Futuro", color=COLOR_IMPER, header=true}, ic("imper_fut")})
end
if not conjinfo.semidep then
insert(t, {{"Presente pasivo", color=COLOR_IMPER, header=true}, ic("imper_pres_pas")})
insert(t, {{"Futuro pasivo", color=COLOR_IMPER, header=true}, ic("imper_fut_pas")})
end
else
insert(t, {{"Como verbo "..(impers == "3" and "impersonal" or "terciopersonal")..", ''"..tit.."'' CARECE de imperativo", color=COLOR_IMPER, header=true, colspan=cs}})
end
insert(t, {{f("Leyenda: † arcaico, x no normativo, ~■~ cambio ortográfico, #■# irregularidad"), colspan=cs}})
args["nota"] = args["nota"] or ""
if conjinfo.impers == "utc3" then
args["nota"] = args["nota"].." NOTA: se usa también como impersonal, en cuyo caso solo son válidas las conjugaciones de la tercera persona singular."
end
if conjinfo.impers == "umc3" then
args["nota"] = args["nota"].." NOTA: se usa más como impersonal, en cuyo caso solo son válidas las conjugaciones de la tercera persona singular."
end
if conjinfo.impers == "utc36" then
args["nota"] = args["nota"].." NOTA: se usa también como terciopersonal, en cuyo caso solo son válidas las conjugaciones de la tercera persona singular y plural."
end
if conjinfo.impers == "umc36" then
args["nota"] = args["nota"].." NOTA: se usa más como terciopersonal, en cuyo caso solo son válidas las conjugaciones de la tercera persona singular y plural."
end
if conjinfo.impers == "pas" or conjinfo.imeprs == "pas3" then
args["nota"] = args["nota"].." NOTA: impersonal para las formas pasivas"
end
if conjinfo.impers == "pas36" then
args["nota"] = args["nota"].." NOTA: formas pasivas terciopersonales (solamente tercera persona singular y plural)"
end
if conjinfo.soloperf then
args["nota"] = args["nota"].. " NOTA: solo se emplean las formas del perfecto y pluscuamperfecto con valor de presente, imperfecto o futuro"
end
if conjinfo.nopasivo then
args["nota"] = args["nota"].. " NOTA: solo se emplean las formas activas"
end
insert(t, {{args["nota"] and args["nota"] or "", colspan=cs}})
local cats = {}
local subtits = {}
local conj_str
if conjinfo.conj == "1" then
conj_str = "primera conjugación"
elseif conjinfo.conj == "2" then
conj_str = "segunda conjugación"
elseif conjinfo.conj == "3" then
conj_str = "tercera conjugación"
elseif conjinfo.conj == "3/4" then
conj_str = "tercera/cuarta conjugación"
else
conj_str = "cuarta conjugación"
end
insert(cats, "LA:Verbos de la "..conj_str)
insert(subtits, conj_str)
impers = impers or ""
if impers == "3" or find(impers, "^u[tm]c3$") then
insert(subtits, "impersonal")
insert(cats, "LA:Verbos impersonales")
end
if defectivo then
insert(subtits, "defectivo")
insert(cats, "LA:Verbos defectivos")
end
if conjinfo.dep then
insert(subtits, "deponente")
insert(cats, "LA:Verbos deponentes")
end
if conjinfo.semidep then
insert(subtits, "semideponente")
insert(cats, "LA:Verbos semideponentes")
end
if es_irregular then
insert(subtits, "irregular")
insert(cats, "LA:Verbos irregulares")
else
insert(subtits, "regular")
insert(cats, "LA:Verbos regulares")
end
return renderizar_tabla(
frame,
"'''Conjugación de ''"..tit_pres..", "..tit_inf..", "..tit_perf..", "..tit_sup.."'''''  ("..concat(subtits, ", ")..")",
t,
ns == 0 and cats or {})
end
function export.adv(frame)
local title_ = mw.title.getCurrentTitle()
local title = title_.fullText
local ns = title_.namespace
if ns ~= 0 then
return "Use esta plantilla en el espacio principal."
end
local params = {
["n"] = {},
["nota"] = {alias_de = "n"},
["comp"] = {lista = true},
["comparativo"] = {alias_de = "comp"},
["compnota"] = {lista = true},
["sup"] = {lista = true},
["superlativo"] = {alias_de = "sup"},
["supnota"] = {lista = true},
}
local parent_frame = frame:getParent()
local args = require("Módulo:parámetros").obtener_parametros(parent_frame.args, params)
local head = args[1]
local modo = args[2]
local enc
local cats = {}
local cat_pref = "LA:Adverbios"
if modo == "-" then
enc = "sin comparativo ni superlativo"
insert(cats, cat_pref.." incomparables")
return renderizar_encabezado(
frame,
head,
enc,
args["n"],
{},
ns == 0 and cats or {},
normalizar_enlace
)
end
local flex = {comp={},sup={}}
local stem
for _, suff in ipairs{"iter", "nter", "ter", "er", "iē", "ē", "rā", "im", "ō"} do
stem = match(head, "^(.*)" .. suff .. "$")
if stem ~= nil then
local comp_suff, sup_suff = "ius", "issimē"
if suff == "nter" then
stem = stem .. "nt"
end
if suff == "rā" then
comp_suff = "er" .. comp_suff
sup_suff = "imē"
end
insert(flex.comp, stem .. comp_suff)
insert(flex.sup, stem .. sup_suff)
break
end
end
if not stem and not args.comp[1] and not args.sup[1] then
error("Unrecognized adverb type, recognized types are “-ē”, “-er”, “-ter”, “-iter”, “-im”, or “-ō”, “-ra” or specify irregular forms or “-” if incomparable.")
end
local formas, irr = sobreescribir_formas(flex, args)
if args["comp"][1] == "no" then
enc = "sin comparativo"
insert(cats, cat_pref.." sin comparativo")
return renderizar_encabezado(
frame,
head,
enc,
args["n"],
{{"superlativo", formas.sup, args["supnota"]}},
ns == 0 and cats or {},
normalizar_enlace
)
elseif args["sup"][1] == "no" then
enc = "sin superlativo"
insert(cats, cat_pref.." sin superlativo")
return renderizar_encabezado(
frame,
head,
enc,
args["n"],
{{"comparativo", formas.comp, args["compnota"]}},
ns == 0 and cats or {},
normalizar_enlace
)
end
if irr then
enc = f("#irregular#")
insert(cats, cat_pref.." irregulares")
end
return renderizar_encabezado(
frame,
head,
enc,
args["n"],
{{"comparativo", formas.comp, args["compnota"]},
{"superlativo", formas.sup, args["supnota"]}},
ns == 0 and cats or {},
normalizar_enlace
)
end
return export
6w59r9oege7mhenfzgtm9hma16rakls
6121433
6121432
2026-07-12T04:53:58Z
Tmagc
158167
6121433
Scribunto
text/plain
-- FLEXIÓN DEL LATÍN
-- Adaptado desde en.wikt por Tmagc
local export = {}
local unpack = unpack or table.unpack
local insert = table.insert
local concat = table.concat
local m_table = require("Módulo:tabla")
local list_to_set = m_table.listToSet
local keys_to_list = m_table.keysToList
local insert_if_not = m_table.insertIfNot
local deep_copy = m_table.deepCopy
local contains = m_table.contains
local append = m_table.append
local merge = m_table.merge
local m_str = require("Módulo:string")
local u = m_str.char
local match = m_str.match
local sub = m_str.sub
local gsub = m_str.gsub
local gsubb = m_str.gsubb
local split = m_str.split
local gsplit = m_str.gsplit
local find = m_str.find
local m_str_avanzado = require("Módulo:string/avanzado")
local toNFD = m_str_avanzado.toNFD
local toNFC = m_str_avanzado.toNFC
local m_flex = require("Módulo:flex")
local f = m_flex.f
local f_links = m_flex.f_links
local parsear_arreglo = m_flex.parsear_arreglo
local separar_palabras = m_flex.separar_palabras
local combinar_copulativa = m_flex.combinar_copulativa
local sobreescribir_formas = m_flex.sobreescribir_formas
local desactivar_formas = m_flex.desactivar_formas
local agregar_enlaces = m_flex.agregar_enlaces
local formatear_formas = m_flex.formatear_formas
local comprobar_defectivo = m_flex.comprobar_defectivo
local renderizar_tabla = m_flex.renderizar_tabla
local renderizar_encabezado = m_flex.renderizar_encabezado
local COLOR_H = m_flex.COLOR_H
local COLOR_NP = m_flex.COLOR_NP
local COLOR_IND = m_flex.COLOR_IND
local COLOR_COND = m_flex.COLOR_COND
local COLOR_SUBJ = m_flex.COLOR_SUBJ
local COLOR_IMPER = m_flex.COLOR_IMPER
local MACRON = u(0x304)
local BREVE = u(0x306)
local DIAER = u(0x308)
local DBREVE = u(0x361)
local ACCENT = "[" .. MACRON .. BREVE .. DIAER .. DBREVE .. "]"
local VOWEL = "[aæeioœuyAÆEIOŒUY]"
local cons_to_vowel = {
["j"] = "i", ["J"] = "I",
["v"] = "u", ["V"] = "U",
}
local function normalizar_enlace(x)
x = toNFD(x)
x = gsub(x, ACCENT, "")
return toNFC(x)
end
local function join(a, b)
a, b = toNFD(a), toNFD(b)
-- If the first part ends in "j" or "v", convert it to "i" or "u" unless
-- the second part begins with a vowel.
if not match(b, "^" .. VOWEL) then
a = gsub(a, "[jvJV]$", cons_to_vowel)
end
return toNFC(a..b)
end
local function add_form(decl, slot, stem, suf)
if type(slot) == "string" then
slot = {slot}
end
for _,slt in ipairs(slot) do
if type(decl[slt]) == "nil" or decl[slt] == "" then
decl[slt] = {}
elseif type(decl[slt]) == "string" then
decl[slt] = {decl[slt]}
end
insert_if_not(decl[slt], join(stem, suf))
end
end
local function remove_forms(decl, forms)
for form,_ in pairs(decl) do
for _,rx in ipairs(forms) do
if form:find(rx) then
forms[form] = {}
break
end
end
end
end
local function merge_forms(forms, forms2, keys)
keys = keys or forms2
for key,arr in pairs(keys) do
if not forms[key] then
forms[key] = {}
end
if type(forms2[key]) == "string" then
insert_if_not(forms[key], forms2[key])
elseif type(forms2[key]) == "table" then
for _,a in ipairs(forms2[key]) do
insert_if_not(forms[key], a)
end
end
end
end
local noun_decl = {}
noun_decl["0"] = function(data, args)
local forms = data.forms
local stem = args[1]
insert_if_not(data.title, "indeclinable")
insert_if_not(data.categories, "LA:Sustantivos indeclinables")
forms["nom_sg"] = stem
forms["gen_sg"] = stem
forms["dat_sg"] = stem
forms["acc_sg"] = stem
forms["abl_sg"] = stem
forms["voc_sg"] = stem
forms["nom_pl"] = stem
forms["gen_pl"] = stem
forms["dat_pl"] = stem
forms["acc_pl"] = stem
forms["abl_pl"] = stem
forms["voc_pl"] = stem
-- with locative
if data.loc then
forms["loc_sg"] = stem
forms["loc_pl"] = stem
end
end
local function alt_gen_pl_in_um(stem, forms, types, subtitles, i_stem)
if types.genplum then
add_form(forms, "gen_pl", stem, (i_stem and "i" or "") .. "um")
elseif types.not_genplum then
-- FIXME: not a contraction.
-- insert_if_not(subtitles, "uncontracted genitive plural")
end
end
noun_decl["1"] = function(data, args)
local forms, types, loc, subtitles = data.forms, data.types, data.loc, data.subtitles
local stem = args[1]
-- normal 1st
local nom_sg = "a"
local gen_loc_sg = "ae"
local dat_sg = "ae"
local acc_sg = "am"
local abl_sg = "ā"
local voc_sg = "a"
local nom_voc_pl = "ae"
local gen_pl = "ārum"
local dat_abl_loc_pl = "īs"
local acc_pl = "ās"
insert_if_not(data.title, "primera declinación")
insert_if_not(data.categories, "LA:Sustantivos de la primera declinación")
-- ām
if types.am then
nom_sg = "ām"
acc_sg = "ām"
abl_sg = {"ām", "ā"}
voc_sg = "ām"
-- all Greek
elseif types.Greek then
insert_if_not(data.title, "griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
--Greek Ma
if types.Ma then
nom_sg = "ās"
acc_sg = "ān"
voc_sg = "ā"
-- Greek Me
elseif types.Me then
nom_sg = "ēs"
acc_sg = "ēn"
abl_sg = "ē"
voc_sg = "ē"
-- Greek
else
nom_sg = "ē"
gen_loc_sg = "ēs"
acc_sg = "ēn"
abl_sg = "ē"
voc_sg = "ē"
end
end
-- ābus
if types.abus then
dat_abl_loc_pl = "ābus"
end
add_form(forms, "nom_sg", stem, nom_sg)
add_form(forms, "gen_sg", stem, gen_loc_sg)
add_form(forms, "dat_sg", stem, dat_sg)
add_form(forms, "acc_sg", stem, acc_sg)
add_form(forms, "abl_sg", stem, abl_sg)
add_form(forms, "voc_sg", stem, voc_sg)
add_form(forms, {"nom_pl", "voc_pl"}, stem, nom_voc_pl)
add_form(forms, "gen_pl", stem, gen_pl)
add_form(forms, {"dat_pl", "abl_pl"}, stem, dat_abl_loc_pl)
add_form(forms, "acc_pl", stem, acc_pl)
-- with locative
if loc then
add_form(forms, "loc_sg", stem, gen_loc_sg)
add_form(forms, "loc_pl", stem, dat_abl_loc_pl)
end
end
noun_decl["2"] = function(data, args)
local forms, types, subtitles, notes = data.forms, data.types, data.subtitles, data.notes
local stem1, stem2 = args[1], args[2]
insert_if_not(data.title, "segunda declinación")
insert_if_not(data.categories, "LA:Sustantivos de la segunda declinación")
-- normal 2nd
forms["nom_sg"] = stem1 .. "us"
forms["gen_sg"] = stem1 .. "ī"
forms["dat_sg"] = stem1 .. "ō"
forms["acc_sg"] = stem1 .. "um"
forms["abl_sg"] = stem1 .. "ō"
forms["voc_sg"] = stem1 .. "e"
forms["nom_pl"] = stem1 .. "ī"
forms["gen_pl"] = stem1 .. "ōrum"
forms["dat_pl"] = stem1 .. "īs"
forms["acc_pl"] = stem1 .. "ōs"
forms["abl_pl"] = stem1 .. "īs"
forms["voc_pl"] = stem1 .. "ī"
-- all neuter
if types.N then
forms["nom_sg"] = stem1 .. "um"
forms["voc_sg"] = stem1 .. "um"
forms["nom_pl"] = stem1 .. "a"
forms["acc_pl"] = stem1 .. "a"
forms["voc_pl"] = stem1 .. "a"
-- neuter ium
if types.ium then
forms["nom_sg"] = stem1 .. "ium"
forms["gen_sg"] = {stem1 .. "iī", stem1 .. "ī{†}"}
forms["dat_sg"] = stem1 .. "iō"
forms["acc_sg"] = stem1 .. "ium"
forms["abl_sg"] = stem1 .. "iō"
forms["voc_sg"] = stem1 .. "ium"
forms["nom_pl"] = stem1 .. "ia"
forms["gen_pl"] = stem1 .. "iōrum"
forms["dat_pl"] = stem1 .. "iīs"
forms["acc_pl"] = stem1 .. "ia"
forms["abl_pl"] = stem1 .. "iīs"
forms["voc_pl"] = stem1 .. "ia"
-- neuter us, plural a
elseif types.a then
forms["nom_sg"] = stem1 .. "us"
forms["acc_sg"] = stem1 .. "us"
forms["voc_sg"] = stem1 .. "us"
forms["nom_pl"] = stem1 .. "a"
forms["acc_pl"] = stem1 .. "a"
forms["voc_pl"] = stem1 .. "a"
-- -vom (aevom, etc.)
elseif types.vom then
forms["nom_sg"] = stem1 .. "om"
forms["acc_sg"] = stem1 .. "om"
forms["voc_sg"] = stem1 .. "om"
-- neuter Greek in -os (cētos)
elseif types.Greek and types.us then
insert_if_not(data.title, "griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = stem1 .. "os"
forms["acc_sg"] = stem1 .. "os"
forms["voc_sg"] = stem1 .. "os"
forms["nom_pl"] = stem1 .. "ē"
forms["gen_pl"] = stem1 .. "ōn"
forms["acc_pl"] = stem1 .. "ē"
forms["voc_pl"] = stem1 .. "ē"
-- neuter Greek
elseif types.Greek then
insert_if_not(data.title, "griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = stem1 .. "on"
forms["acc_sg"] = stem1 .. "on"
forms["voc_sg"] = stem1 .. "on"
-- neuter us
elseif types.us then
forms["nom_sg"] = stem1 .. "us"
forms["acc_sg"] = stem1 .. "us"
forms["voc_sg"] = stem1 .. "us"
forms["nom_pl"] = stem1 .. "ī"
forms["acc_pl"] = stem1 .. "ōs"
forms["voc_pl"] = stem1 .. "ī"
end
-- er
elseif types.er then
forms["nom_sg"] = stem1
forms["gen_sg"] = stem2 .. "ī"
forms["dat_sg"] = stem2 .. "ō"
forms["acc_sg"] = stem2 .. "um"
forms["abl_sg"] = stem2 .. "ō"
forms["voc_sg"] = stem1
forms["nom_pl"] = stem2 .. "ī"
forms["gen_pl"] = stem2 .. "ōrum"
forms["dat_pl"] = stem2 .. "īs"
forms["acc_pl"] = stem2 .. "ōs"
forms["abl_pl"] = stem2 .. "īs"
forms["voc_pl"] = stem2 .. "ī"
-- ius
elseif types.ius then
forms["nom_sg"] = stem1 .. "ius"
forms["gen_sg"] = {stem1 .. "iī", stem1 .. "ī{†}"}
forms["dat_sg"] = stem1 .. "iō"
forms["acc_sg"] = stem1 .. "ium"
forms["abl_sg"] = stem1 .. "iō"
if types.voci then
-- Only for proper names and fīlius, genius
forms["voc_sg"] = stem1 .. "ī"
else
forms["voc_sg"] = stem1 .. "ie"
end
forms["nom_pl"] = stem1 .. "iī"
forms["gen_pl"] = stem1 .. "iōrum"
forms["dat_pl"] = stem1 .. "iīs"
forms["acc_pl"] = stem1 .. "iōs"
forms["abl_pl"] = stem1 .. "iīs"
forms["voc_pl"] = stem1 .. "iī"
-- -vos (servos, etc.)
elseif types.vos then
forms["nom_sg"] = stem1 .. "os"
forms["acc_sg"] = stem1 .. "om"
-- Greek
elseif types.Greek then
insert_if_not(data.title, "griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = stem1 .. "os"
forms["acc_sg"] = stem1 .. "on"
if data.num == "pl" then
forms["nom_pl"] = stem1 .. "oe"
forms["voc_pl"] = stem1 .. "oe"
else
forms["nom_pl"] = {stem1 .. "ī", stem1 .. "oe"}
forms["voc_pl"] = {stem1 .. "ī", stem1 .. "oe"}
end
elseif types.not_Greek then
insert_if_not(data.title, "no griego")
end
-- with -um genitive plural
alt_gen_pl_in_um(stem2, forms, types, subtitles, types.ius or types.ium)
-- with locative
if data.loc then
if types.ius or types.ium then
forms["loc_sg"] = stem2 .. "iī"
forms["loc_pl"] = stem2 .. "iīs"
else
forms["loc_sg"] = stem2 .. "ī"
forms["loc_pl"] = stem2 .. "īs"
end
end
end
local acc_sg_i_stem_subtypes = {
acc_im = {
-- amussis, basis, buris, cucumis, gummis, mephitis, paraphrasis, poesis, ravis, sitis, tussis, (vis) [abl -ī];
-- cannabis, senapis, sinapis [abl -e, -ī]
acc_sg = {"im"},
title = {"accusative singular in ''-im''"},
},
acc_im_in = {
-- cities, rivers, gods, e.g. Bilbilis, Syrtis, Tiberis, Anubis, Osiris [abl -ī];
-- Baetis, Tigris [acc -e, -ī]
acc_sg = {"im", "in"},
title = {"accusative singular in ''-im'' or ''-in''"},
},
acc_im_in_em = {
-- e.g. tigris, river Līris
acc_sg = {"im", "in", "em"},
title = {"accusative singular in ''-im'', ''-in'' or ''-em''"},
},
acc_im_em = {
acc_sg = {"im", "em"},
title = {"accusative singular in ''-im'' or ''-em''"},
},
acc_im_occ_em = {
-- febris, pelvis, puppis, restis, securis, turris [abl -ī, -e]
acc_sg = {"im", "em"},
title = {"accusative singular in ''-im'' or occasionally ''-em''"},
},
acc_em_im = {
-- aqualis, clavis, lens, navis [abl -e, -ī];
-- cutis, restis [abl -e]
acc_sg = {"em", "im"},
title = {"accusative singular in ''-em'' or ''-im''"},
},
}
local abl_sg_i_stem_subtypes = {
abl_i = {
-- amussis, basis, buris, cucumis, gummis, mephitis, paraphrasis, poesis, ravis, sitis, tussis, (vis) [acc -im];
-- cities, rivers, gods, e.g. Bilbilis, Syrtis, Tiberis, Anubis, Osiris [acc -im or -in];
-- canalis "water pipe", months in -is or -er, nouns originally i-stem adjectives such as aedilis, affinis, bipennis, familiaris, sodalis, volucris, etc. [acc -em]
abl_sg = {"ī"},
title = {"ablative singular in ''-ī''"},
},
abl_i_e = {
-- febris, pelvis, puppis, restis, securis, turris [acc -im, -em]
abl_sg = {"ī", "e"},
title = {"ablative singular in ''-ī'' or ''-e''"},
},
abl_e_i = {
-- cannabis, senapis, sinapis [acc -im];
-- Baetis, Tigris [acc -im, -in];
-- aqualis, clavis, lens, navis [acc -em, -im];
-- finis, mugilis, occiput, pugil, rus, supellex, vectis [acc -em]
abl_sg = {"e", "ī"},
title = {"ablative singular in ''-e'' or ''-ī''"},
},
abl_e_occ_i = {
-- amnis, anguis, avis, civis, classis, fustis, ignis, imber, orbis, pars, postis, sors, unguis, vesper [acc -em]
abl_sg = {"e", "ī"},
title = {"ablative singular in ''-e'' or occasionally ''-ī''"},
},
}
local function extract_stem(form, ending)
local base = match(form, "^(.*)" .. ending .. "$")
if not base then
error("Form " .. form .. " should end in -" .. ending)
end
return base
end
local function count_vowels(stem)
return select(2, toNFD(stem):gsub("[aeiouyAEIOUY]", ""))
end
noun_decl["3"] = function(data, args)
local forms, types, subtitles, notes = data.forms, data.types, data.subtitles, data.notes
local stem1, stem2 = args[1], args[2]
-- local function non_i_stem_type()
-- return (count_vowels(stem1) > count_vowels(stem2) and "parisyllabic" or "imparisyllabic") .. " non-i-stem"
-- end
insert_if_not(data.title, "tercera declinación")
insert_if_not(data.categories, "LA:Sustantivos de la tercera declinación")
--normal 3rd
forms["nom_sg"] = stem1
forms["gen_sg"] = stem2 .. "is"
forms["dat_sg"] = stem2 .. "ī"
forms["acc_sg"] = stem2 .. "em"
forms["abl_sg"] = stem2 .. "e"
forms["voc_sg"] = stem1
forms["nom_pl"] = stem2 .. "ēs"
forms["gen_pl"] = stem2 .. "um"
forms["dat_pl"] = stem2 .. "ibus"
forms["acc_pl"] = stem2 .. "ēs"
forms["abl_pl"] = stem2 .. "ibus"
forms["voc_pl"] = stem2 .. "ēs"
local acc_sg_i_stem_subtype = false
local not_acc_sg_i_stem_subtype = false
for subtype, _ in pairs(types) do
if acc_sg_i_stem_subtypes[subtype] then
acc_sg_i_stem_subtype = true
break
end
end
for acc_sg_subtype, _ in pairs(acc_sg_i_stem_subtypes) do
if types["not_" .. acc_sg_subtype] then
not_acc_sg_i_stem_subtype = true
break
end
end
local abl_sg_i_stem_subtype = false
local not_abl_sg_i_stem_subtype = false
for subtype, _ in pairs(types) do
if abl_sg_i_stem_subtypes[subtype] then
abl_sg_i_stem_subtype = true
break
end
end
for abl_sg_subtype, _ in pairs(abl_sg_i_stem_subtypes) do
if types["not_" .. abl_sg_subtype] then
not_abl_sg_i_stem_subtype = true
break
end
end
-- all Greek
if types.Greek then
insert_if_not(data.title, "griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
-- Greek er
if types.er then
stem1 = extract_stem(stem1, "ēr")
forms["nom_sg"] = stem1 .. "ēr"
forms["gen_sg"] = stem1 .. "eris"
forms["dat_sg"] = stem1 .. "erī"
forms["acc_sg"] = {stem1 .. "era", stem1 .. "erem"}
forms["abl_sg"] = stem1 .. "ere"
forms["voc_sg"] = stem1 .. "ēr"
forms["nom_pl"] = stem1 .. "erēs"
forms["gen_pl"] = stem1 .. "erum"
forms["dat_pl"] = stem1 .. "eribus"
forms["acc_pl"] = stem1 .. "erēs"
forms["abl_pl"] = stem1 .. "eribus"
forms["voc_pl"] = stem1 .. "erēs"
-- Greek on
elseif types.on then
stem1 = extract_stem(stem1, "ōn")
forms["nom_sg"] = stem1 .. "ōn"
forms["gen_sg"] = {stem1 .. "ontis", stem1 .. "ontos"}
forms["dat_sg"] = stem1 .. "ontī"
forms["acc_sg"] = stem1 .. "onta"
forms["abl_sg"] = stem1 .. "onte"
forms["voc_sg"] = stem1 .. "ōn"
forms["nom_pl"] = stem1 .. "ontēs"
forms["gen_pl"] = {stem1 .. "ontum", stem1 .. "ontium"}
forms["dat_pl"] = stem1 .. "ontibus"
forms["acc_pl"] = {stem1 .. "ontēs", stem1 .. "ontās"}
forms["abl_pl"] = stem1 .. "ontibus"
forms["voc_pl"] = stem1 .. "ontēs"
-- Greek i-stem
elseif types.I then
forms["gen_sg"] = {stem2 .. "is", stem2 .. "eōs", stem2 .. "ios"}
forms["acc_sg"] = {stem2 .. "im", stem2 .. "in", stem2 .. "em{MED}"}
forms["abl_sg"] = {stem2 .. "ī", stem2 .. "e{MED}"}
forms["voc_sg"] = {stem2 .. "is", stem2 .. "i"}
forms["nom_pl"] = {stem2 .. "ēs", stem2 .. "eis"}
forms["gen_pl"] = {stem2 .. "ium", stem2 .. "eōn"}
forms["acc_pl"] = {stem2 .. "ēs", stem2 .. "eis"}
forms["voc_pl"] = {stem2 .. "ēs", stem2 .. "eis"}
if types.poetic_esi then
forms["dat_pl"] = {stem2 .. "ibus", stem2 .. "esi{L}"}
forms["abl_pl"] = {stem2 .. "ibus", stem2 .. "esi{L}"}
end
-- normal Greek
else
forms["gen_sg"] = stem2 .. "os"
if match(toNFD(stem2), "[yY]" .. ACCENT .. "*$") then
forms["acc_sg"] = stem2 .. "n"
else
forms["acc_sg"] = stem2 .. "a"
end
forms["nom_pl"] = stem2 .. "es"
forms["acc_pl"] = stem2 .. "as"
forms["voc_pl"] = stem2 .. "es"
if match(toNFD(stem1), "[iyIY]" .. ACCENT .. "*s$") then
-- Per Hiley, words in -is and -ys have a poetic vocative
-- without the -s, but otherwise the vocative is the same
-- as the nominative.
forms["voc_sg"] = {stem1, (stem1:gsub("s$", "")).."{L}"}
end
end
elseif types.not_Greek then
insert_if_not(data.title, "no griego")
end
-- polis
if types.polis then
stem1 = extract_stem(stem1, "polis")
insert_if_not(data.title, "parcialmente griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = stem1 .. "polis"
forms["gen_sg"] = stem1 .. "polis"
forms["dat_sg"] = stem1 .. "polī"
forms["acc_sg"] = {stem1 .. "polim", stem1 .. "polin"}
forms["abl_sg"] = stem1 .. "polī"
forms["voc_sg"] = {stem1 .. "polis", stem1 .. "polī"}
end
-- all neuter
if types.N then
forms["acc_sg"] = stem1
-- neuter I stem
if types.I then
-- pure variety
if types.pure then
forms["abl_sg"] = stem2 .. "ī"
forms["nom_pl"] = stem2 .. "ia"
forms["gen_pl"] = stem2 .. "ium"
forms["acc_pl"] = stem2 .. "ia"
forms["voc_pl"] = stem2 .. "ia"
-- non-pure variety (rare)
else
forms["nom_pl"] = stem2 .. "a"
forms["gen_pl"] = {stem2 .. "ium", stem2 .. "um"}
forms["acc_pl"] = stem2 .. "a"
forms["voc_pl"] = stem2 .. "a"
end
-- normal neuter
else
forms["nom_pl"] = stem2 .. "a"
forms["acc_pl"] = stem2 .. "a"
forms["voc_pl"] = stem2 .. "a"
end
-- I stem
elseif types.I or acc_sg_i_stem_subtype or abl_sg_i_stem_subtype then
forms["gen_pl"] = stem2 .. "ium"
-- Per Allen and Greenough, Hiley and others, the acc_pl in -īs
-- applied originally to all i-stem nouns, and was current as an
-- alternative form up through Caesar.
forms["acc_pl"] = {stem2 .. "ēs", stem2 .. "īs"}
-- pure variety
if types.pure then
forms["acc_sg"] = stem2 .. "im"
forms["abl_sg"] = stem2 .. "ī"
forms["nom_pl"] = stem2 .. "īs"
forms["acc_pl"] = stem2 .. "īs"
forms["voc_pl"] = stem2 .. "īs"
end
local num = data.num
for subtype, _ in pairs(types) do
local acc_sg_i_stem_props = acc_sg_i_stem_subtypes[subtype]
if acc_sg_i_stem_props then
forms["acc_sg"] = {}
for _, ending in ipairs(acc_sg_i_stem_props.acc_sg) do
insert_if_not(forms["acc_sg"], stem2 .. ending)
end
-- if num ~= "pl" then
-- for _, t in ipairs(acc_sg_i_stem_props.title) do
-- insert_if_not(subtitles, t)
-- end
-- end
break
end
end
-- FIXME: needs to be done for neuter nouns as well.
for subtype, _ in pairs(types) do
local abl_sg_i_stem_props = abl_sg_i_stem_subtypes[subtype]
if abl_sg_i_stem_props then
forms["abl_sg"] = {}
for _, ending in ipairs(abl_sg_i_stem_props.abl_sg) do
insert_if_not(forms["abl_sg"], stem2 .. ending)
end
-- if num ~= "pl" then
-- for _, t in ipairs(abl_sg_i_stem_props.title) do
-- insert_if_not(subtitles, t)
-- end
-- end
break
end
end
end
-- with locative
if data.loc then
-- As far as I can tell, in general both dative singular and
-- ablative singular could be used for the third-declension locative,
-- with different time periods preferring different forms.
-- http://dcc.dickinson.edu/grammar/latin/3rd-declension-locative-case
-- mentions rūrī along with either Carthāginī or Carthāgine.
-- Wikipedia in https://en.wikipedia.org/wiki/Locative_case#Latin
-- says this:
--
-- In archaic times, the locative singular of third declension nouns
-- was still interchangeable between ablative and dative forms, but in
-- the Augustan Period the use of the ablative form became fixed.
-- Therefore, both forms "rūrī" and "rūre" may be encountered.
--
-- Lewis and Short confirm this.
local loc_sg = forms["dat_sg"]
if type(loc_sg) == "table" then
loc_sg = deep_copy(loc_sg)
else
loc_sg = {loc_sg}
end
local abl_sg = forms["abl_sg"]
if type(abl_sg) == "table" then
for _, form in ipairs(abl_sg) do
insert_if_not(loc_sg, deep_copy(form))
end
else
insert_if_not(loc_sg, abl_sg)
end
forms["loc_sg"] = loc_sg
forms["loc_pl"] = deep_copy(forms["abl_pl"])
--The following is what we used to have, but I simply cannot believe it.
--if types.Greek and not types.s then
-- forms["loc_pl"] = stem2 .. "ēs"
--end
end
end
noun_decl["4"] = function(data, args)
local forms, types, subtitles, notes = data.forms, data.types, data.subtitles, data.notes
local stem = args[1]
insert_if_not(data.title, "cuarta declinación")
insert_if_not(data.categories, "LA:Sustantivos de la cuarta declinación")
-- normal 4th
forms["nom_sg"] = stem .. "us"
forms["gen_sg"] = stem .. "ūs"
forms["dat_sg"] = stem .. "uī"
forms["acc_sg"] = stem .. "um"
forms["abl_sg"] = stem .. "ū"
forms["voc_sg"] = stem .. "us"
forms["nom_pl"] = stem .. "ūs"
forms["gen_pl"] = stem .. "uum"
forms["dat_pl"] = stem .. "ibus"
forms["acc_pl"] = stem .. "ūs"
forms["abl_pl"] = stem .. "ibus"
forms["voc_pl"] = stem .. "ūs"
if types.echo then
for slot in pairs(forms) do
if slot ~= "gen_sg" then
forms[slot] = stem .. "ō"
end
end
add_form(forms, "acc_sg", stem, "ōn")
elseif types.Callisto then
for slot in pairs(forms) do
if slot ~= "gen_sg" then
forms[slot] = stem .. "ō"
end
end
end
-- neuter
if types.N then
forms["nom_sg"] = stem .. "ū̆{?}"
forms["gen_sg"] = {stem .. "ūs{C}", stem .. "ū{S}"}
forms["dat_sg"] = {stem .. "uī{C}", stem .. "ū{S}"}
forms["acc_sg"] = stem .. "ū̆{?}"
forms["voc_sg"] = stem .. "ū̆{?}"
forms["nom_pl"] = stem .. "ua"
forms["acc_pl"] = stem .. "ua"
forms["voc_pl"] = stem .. "ua"
end
-- ubus
if types.ubus then
forms["dat_pl"] = stem .. "ubus"
forms["abl_pl"] = stem .. "ubus"
end
-- with locative
if data.loc then
forms["loc_sg"] = forms["abl_sg"]
forms["loc_pl"] = forms["abl_pl"]
end
end
noun_decl["5"] = function(data, args)
local forms, types = data.forms, data.types
local stem = args[1]
insert_if_not(data.title, "quinta declinación")
insert_if_not(data.categories, "LA:Sustantivos de la quinta declinación")
-- ies
if types.i then
stem = stem .. "i"
end
forms["nom_sg"] = stem .. "ēs"
forms["gen_sg"] = stem .. "eī"
forms["dat_sg"] = stem .. "eī"
forms["acc_sg"] = stem .. "em"
forms["abl_sg"] = stem .. "ē"
forms["voc_sg"] = stem .. "ēs"
forms["nom_pl"] = stem .. "ēs"
forms["gen_pl"] = stem .. "ērum"
forms["dat_pl"] = stem .. "ēbus"
forms["acc_pl"] = stem .. "ēs"
forms["abl_pl"] = stem .. "ēbus"
forms["voc_pl"] = stem .. "ēs"
-- ies
if types.i then
forms["gen_sg"] = stem .. "ēī"
forms["dat_sg"] = stem .. "ēī"
end
--with locative
if data.loc then
forms["loc_sg"] = stem .. "ē"
forms["loc_pl"] = stem .. "ēbus"
end
end
noun_decl["sgpl"] = function(data, args)
local forms = data.forms
local stem1, stem2 = args[1], args[2]
insert_if_not(data.title, "indeclinable")
insert_if_not(data.categories, "LA:Sustantivos indeclinables")
forms["nom_sg"] = stem1
forms["gen_sg"] = stem1
forms["dat_sg"] = stem1
forms["acc_sg"] = stem1
forms["abl_sg"] = stem1
forms["voc_sg"] = stem1
forms["nom_pl"] = stem2
forms["gen_pl"] = stem2
forms["dat_pl"] = stem2
forms["acc_pl"] = stem2
forms["abl_pl"] = stem2
forms["voc_pl"] = stem2
-- with locative
if data.loc then
forms["loc_sg"] = stem1
forms["loc_pl"] = stem2
end
end
noun_decl["indecl"] = function(data, args)
local forms = data.forms
local stem = args[1]
insert_if_not(data.title, "indeclinable")
insert_if_not(data.categories, "LA:Sustantivos indeclinables")
forms["nom_sg"] = stem
forms["gen_sg"] = {}
forms["dat_sg"] = {}
forms["acc_sg"] = stem
forms["abl_sg"] = {}
forms["voc_sg"] = {}
forms["nom_pl"] = {}
forms["gen_pl"] = {}
forms["dat_pl"] = {}
forms["acc_pl"] = {}
forms["abl_pl"] = {}
forms["voc_pl"] = {}
-- with locative (for multiword terms)
if data.loc then
forms["loc_sg"] = {}
forms["loc_pl"] = {}
end
data.num = "sg"
end
noun_decl["irreg"] = function(data, args)
local forms, subtitles, notes = data.forms, data.subtitles, data.notes
local stem = args[1]
insert_if_not(data.title, "irregular")
insert_if_not(data.categories, "LA:Sustantivos irregulares")
forms["nom_sg"] = {}
forms["gen_sg"] = {}
forms["dat_sg"] = {}
forms["acc_sg"] = {}
forms["abl_sg"] = {}
forms["voc_sg"] = {}
forms["nom_pl"] = {}
forms["gen_pl"] = {}
forms["dat_pl"] = {}
forms["acc_pl"] = {}
forms["abl_pl"] = {}
forms["voc_pl"] = {}
if stem == "bōs" then
data.decl = "3"
local stem1, stem2 = "bōs", "bov"
noun_decl["3"](data, {stem1, stem2})
add_form(forms, "abl_sg", stem2, "īd{†}")
add_form(forms, "gen_pl", "bo", "um")
add_form(forms, "gen_pl", stem2, "erum")
add_form(forms, "dat_pl", "", "bōbus")
add_form(forms, "dat_pl", "", "būbus")
add_form(forms, "abl_pl", "", "bōbus")
add_form(forms, "abl_pl", "", "būbus")
elseif stem:match("^[dD]eus$") then
data.decl = "2"
local dD = stem:sub(1, 1)
forms["nom_sg"] = dD .. "eus"
forms["gen_sg"] = dD .. "eī"
forms["dat_sg"] = dD .. "eō"
forms["acc_sg"] = dD .. "eum"
forms["abl_sg"] = dD .. "eō"
forms["voc_sg"] = {dD .. "eus", dD .. "ee"}
if stem == "deus" then
forms["nom_pl"] = {"dī", "diī", "deī"}
forms["gen_pl"] = {"deōrum", "deum"}
forms["dat_pl"] = {"dīs", "diīs", "deīs"}
forms["acc_pl"] = "deōs"
forms["abl_pl"] = {"dīs", "diīs", "deīs"}
forms["voc_pl"] = {"dī", "diī", "deī"}
end
elseif stem == "domus" then
data.decl = "4,2"
insert_if_not(data.title, "cuarta/segunda declinación")
forms["nom_sg"] = "domus"
forms["gen_sg"] = {"domūs", "domī"}
forms["dat_sg"] = {"domuī", "domō", "domū"}
forms["acc_sg"] = "domum"
forms["abl_sg"] = {"domū", "domō"}
forms["voc_sg"] = "domus"
forms["loc_sg"] = "domī"
forms["nom_pl"] = "domūs"
forms["gen_pl"] = {"domuum", "domōrum"}
forms["dat_pl"] = "domibus"
forms["acc_pl"] = {"domūs", "domōs"}
forms["abl_pl"] = "domibus"
forms["voc_pl"] = "domūs"
forms["loc_pl"] = {}
data.loc = true
elseif match(stem, "^[IÏJ]ēs[uū]" .. BREVE .. "?s$") then
local ij = sub(stem, 1, 1)
local uu = match(stem, "[uū]" .. BREVE .. "?")
forms["nom_sg"] = stem
forms["gen_sg"] = ij .. "ēsū"
forms["dat_sg"] = ij .. "ēsū"
forms["acc_sg"] = ij .. "ēs" .. uu .. "m"
forms["abl_sg"] = ij .. "ēsū"
forms["voc_sg"] = ij .. "ēsū"
data.num = "sg"
elseif stem == "Mōsēs" or stem == "Moesēs" or match(stem, "^M[oō]" .. BREVE .. "?[īȳ]sēs$") then
local mos = sub(stem, 1, -3)
forms["nom_sg"] = stem
forms["gen_sg"] = {mos .. "ī", mos .. "ēī", mos .. "is", mos .. "ēn", mos .. "eōs"}
forms["dat_sg"] = mos .. "ī"
forms["acc_sg"] = {mos .. "ēn", mos .. "em"}
forms["abl_sg"] = {mos .. "e", mos .. "ēn", mos .. "ī"}
forms["voc_sg"] = {mos .. "ēs", mos .. "ē"}
data.num = "sg"
elseif stem:match("^[ij]ūgerum$") then
data.decl = "2,3"
local ij = stem:sub(1, 1)
insert_if_not(data.title, "segunda/tercera declinación híbrido")
forms["nom_sg"] = ij .. "ūgerum"
forms["gen_sg"] = ij .. "ūgerī"
forms["dat_sg"] = ij .. "ūgerō"
forms["acc_sg"] = ij .. "ūgerum"
forms["abl_sg"] = ij .. "ūgerō"
forms["voc_sg"] = ij .. "ūgerum"
forms["nom_pl"] = ij .. "ūgera"
forms["gen_pl"] = ij .. "ūgerum"
forms["dat_pl"] = ij .. "ūgeribus"
forms["acc_pl"] = ij .. "ūgera"
forms["abl_pl"] = {ij .. "ūgeribus", ij .. "ūgerīs{†}"}
forms["voc_pl"] = ij .. "ūgera"
elseif stem == "sūs" then
data.decl = "3"
forms["nom_sg"] = "sūs"
forms["gen_sg"] = "suis"
forms["dat_sg"] = "suī"
forms["acc_sg"] = "suem"
forms["abl_sg"] = "sue"
forms["voc_sg"] = "sūs"
forms["nom_pl"] = "suēs"
forms["gen_pl"] = "suum"
forms["dat_pl"] = {"suibus", "sūbus", "subus"}
forms["acc_pl"] = "suēs"
forms["abl_pl"] = {"suibus", "sūbus", "subus"}
forms["voc_pl"] = "suēs"
elseif stem == "ēthos" then
data.decl = "3"
insert_if_not(data.title, "tercera declinación, griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = "ēthos"
forms["gen_sg"] = "ētheos"
forms["acc_sg"] = "ēthos"
forms["voc_sg"] = "ēthos"
forms["nom_pl"] = {"ēthea", "ēthē"}
forms["dat_pl"] = {"ēthesi", "ēthesin"}
forms["acc_pl"] = {"ēthea", "ēthē"}
forms["abl_pl"] = {"ēthesi", "ēthesin"}
forms["voc_pl"] = {"ēthea", "ēthē"}
elseif stem == "Athōs" then
data.decl = "2"
insert_if_not(data.title, "segunda declinación, griego")
insert_if_not(data.categories, "LA:Sustantivos griegos")
forms["nom_sg"] = "Athōs"
forms["gen_sg"] = "Athō"
forms["dat_sg"] = "Athō"
forms["acc_sg"] = {"Athō", "Athōn"}
forms["abl_sg"] = "Athō"
forms["voc_sg"] = "Athōs"
data.num = "sg"
elseif stem:match("^[uv]ēnum$") then
data.decl = "4,2"
local uv = stem:sub(1, 1)
insert_if_not(data.title, "cuarta/segunda declinación, defectivo")
forms["dat_sg"] = {uv .. "ēnuī", uv .. "ēnō"}
forms["acc_sg"] = uv .. "ēnum"
data.num = "sg"
elseif stem:match("^[uv]īs$") then
data.decl = "3"
local uv = stem:sub(1, 1)
insert_if_not(data.title, "defectivo")
forms["nom_sg"] = uv .. "īs"
forms["gen_sg"] = uv .. "īs"
forms["dat_sg"] = uv .. "ī"
forms["acc_sg"] = uv .. "im"
forms["abl_sg"] = uv .. "ī"
forms["voc_sg"] = uv .. "īs"
forms["nom_pl"] = uv .. "īrēs"
forms["gen_pl"] = uv .. "īrium"
forms["dat_pl"] = uv .. "īribus"
forms["acc_pl"] = {uv .. "īrēs", uv .. "īrīs"}
forms["abl_pl"] = uv .. "īribus"
forms["voc_pl"] = uv .. "īrēs"
else
error("Stem " .. stem .. " not recognized.")
end
end
local adj_decl = {}
adj_decl["0+"] = function(data, args)
local forms, categories = data.forms, data.categories
local stem = args[1]
insert_if_not(data.title, "indeclinable")
insert_if_not(categories, "LA:Adjetivos indeclinables")
forms["nom_sg_m"] = stem
forms["nom_pl_m"] = stem
forms["gen_sg_m"] = stem
forms["gen_pl_m"] = stem
forms["dat_sg_m"] = stem
forms["dat_pl_m"] = stem
forms["acc_sg_m"] = stem
forms["acc_pl_m"] = stem
forms["abl_sg_m"] = stem
forms["abl_pl_m"] = stem
forms["voc_sg_m"] = stem
forms["voc_pl_m"] = stem
forms["loc_sg_m"] = stem
forms["loc_pl_m"] = stem
end
adj_decl["1&2+"] = function(data, args)
local forms, types, pos, subtitles, categories = data.forms, data.types, data.pos, data.subtitles, data.categories
local stem = args[1]
insert_if_not(data.title, "primera y segunda declinación")
insert_if_not(categories, "LA:Adjetivos de la primera declinación")
insert_if_not(categories, "LA:Adjetivos de la segunda declinación")
local original
if types.er then
local final2 = stem:sub(-2)
if final2 == "er" then
-- insert_if_not(categories, "LA:Sustantivos de la primera declinación")
-- insert_if_not(categories, "LA:Sustantivos de la segunda declinación")
elseif final2 == "ur" then
-- insert_if_not(categories, "LA:Sustantivos de la primera declinación")
-- insert_if_not(categories, "LA:Sustantivos de la segunda declinación")
else
error("Unrecognized ''-r'' stem (doesn't end in ''-er'' or ''-ur''): " .. stem)
end
stem, original = args[2], stem
end
local us = "us"
local a_sf = "a"
local um = "um"
local ae_gsf = "ae"
local am = "am"
local a_macron = "ā"
local i_pl = stem .. "ī"
if types.greekA or types.greekE then
insert_if_not(data.title, "griego")
insert_if_not(categories, "LA:Sustantivos griegos")
if types.greekA then
us = "os"
um = "on"
am = "ān"
else
us = "os"
a_sf = "ē"
um = "on"
ae_gsf = "ēs"
am = "ēn"
a_macron = "ē"
end
i_pl = {i_pl, stem .. "oe"}
end
forms["nom_sg_m"] = original or (stem .. us)
forms["nom_sg_f"] = stem .. a_sf
forms["nom_sg_n"] = stem .. um
forms["nom_pl_m"] = i_pl
forms["nom_pl_f"] = stem .. "ae"
forms["nom_pl_n"] = stem .. "a"
forms["gen_sg_m"] = stem .. "ī"
forms["gen_sg_f"] = stem .. ae_gsf
forms["gen_sg_n"] = stem .. "ī"
forms["gen_pl_m"] = stem .. "ōrum"
forms["gen_pl_f"] = stem .. "ārum"
forms["gen_pl_n"] = stem .. "ōrum"
forms["dat_sg_m"] = stem .. "ō"
forms["dat_sg_f"] = stem .. "ae"
forms["dat_sg_n"] = stem .. "ō"
forms["dat_pl_m"] = stem .. "īs"
forms["dat_pl_f"] = stem .. "īs"
forms["dat_pl_n"] = stem .. "īs"
forms["acc_sg_m"] = stem .. um
forms["acc_sg_f"] = stem .. am
forms["acc_sg_n"] = stem .. um
forms["acc_pl_m"] = stem .. "ōs"
forms["acc_pl_f"] = stem .. "ās"
forms["acc_pl_n"] = stem .. "a"
forms["abl_sg_m"] = stem .. "ō"
forms["abl_sg_f"] = stem .. a_macron
forms["abl_sg_n"] = stem .. "ō"
forms["abl_pl_m"] = stem .. "īs"
forms["abl_pl_f"] = stem .. "īs"
forms["abl_pl_n"] = stem .. "īs"
forms["voc_sg_m"] = original or (stem .. "e")
forms["voc_sg_f"] = stem .. a_sf
forms["voc_sg_n"] = stem .. um
forms["voc_pl_m"] = i_pl
forms["voc_pl_f"] = stem .. "ae"
forms["voc_pl_n"] = stem .. "a"
if types.ius then
insert_if_not(data.title, "pronominal")
--insert_if_not(subtitles, "with genitive singular in ''-ī̆us'' and dative singular in ''-ī''")
forms["gen_sg_m"] = stem .. "ī̆us"
forms["gen_sg_f"] = stem .. "ī̆us"
forms["gen_sg_n"] = stem .. "ī̆us"
forms["dat_sg_m"] = stem .. "ī"
forms["dat_sg_f"] = stem .. "ī"
forms["dat_sg_n"] = stem .. "ī"
elseif types.not_ius then
insert_if_not(data.title, "no pronominal")
--insert_if_not(subtitles, "with normal genitive and dative singular")
end
if stem == "me" then
forms["voc_sg_m"] = "mī"
end
if types.ic then
--insert_if_not(subtitles, "with genitive singular ending in ''-ius'' and dative singular ending in ''-ic''")
local oc = "oc"
local oc_macron = "ōc"
if stem == "ill" then
oc = "uc"
oc_macron = "ūc"
end
forms["nom_sg_m"] = stem .. "ic"
forms["nom_sg_f"] = stem .. "aec"
forms["nom_sg_n"] = stem .. oc
forms["nom_pl_n"] = stem .. "aec"
forms["gen_sg_m"] = stem .. "uius"
forms["gen_sg_f"] = stem .. "uius"
forms["gen_sg_n"] = stem .. "uius"
forms["dat_sg_m"] = stem .. "uic"
forms["dat_sg_f"] = stem .. "uic"
forms["dat_sg_n"] = stem .. "uic"
forms["acc_sg_m"] = stem .. "unc"
forms["acc_sg_f"] = stem .. "anc"
forms["acc_sg_n"] = stem .. oc
forms["acc_pl_n"] = stem .. "aec"
forms["abl_sg_m"] = stem .. "ōc"
forms["abl_sg_f"] = stem .. "āc"
forms["abl_sg_n"] = stem .. oc_macron
forms["voc_sg_m"] = {}
forms["voc_sg_f"] = {}
forms["voc_sg_n"] = {}
forms["voc_pl_m"] = {}
forms["voc_pl_f"] = {}
forms["voc_pl_n"] = {}
end
if types.distr then
if stem:sub(-1) == "n" then
forms["gen_pl_m"] = {stem .. "um", stem .. "ōrum{R}"}
forms["gen_pl_f"] = {stem .. "um", stem .. "ārum{R}"}
forms["gen_pl_n"] = {stem .. "um", stem .. "ōrum{R}"}
else
error("Unrecognized distributive numeral stem (doesn't end in ''n''): " .. stem)
end
original = stem
stem = args[2]
end
forms["loc_sg_m"] = deep_copy(forms["gen_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["gen_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["gen_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_f"] = deep_copy(forms["abl_pl_f"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
adj_decl["1-1+"] = function(data, args)
local forms, subtitles, categories = data.forms, data.subtitles, data.categories
local stem = args[1]
insert_if_not(data.title, "primera declinación")
insert_if_not(categories, "LA:Adjetivos de la primera declinación")
forms["nom_sg_m"] = stem .. "a"
forms["nom_pl_m"] = stem .. "ae"
forms["nom_pl_n"] = stem .. "a"
forms["gen_sg_m"] = stem .. "ae"
forms["gen_pl_m"] = stem .. "ārum"
forms["dat_sg_m"] = stem .. "ae"
forms["dat_pl_m"] = stem .. "īs"
forms["acc_sg_m"] = stem .. "am"
forms["acc_sg_n"] = stem .. "a"
forms["acc_pl_m"] = stem .. "ās"
forms["acc_pl_n"] = stem .. "a"
forms["abl_sg_m"] = stem .. "ā"
forms["abl_pl_m"] = stem .. "īs"
forms["voc_sg_m"] = stem .. "a"
forms["voc_pl_m"] = stem .. "ae"
forms["voc_pl_n"] = stem .. "a"
forms["loc_sg_m"] = deep_copy(forms["gen_sg_m"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
end
adj_decl["2-2+"] = function(data, args)
local forms, types, pos, subtitles, categories = data.forms, data.types, data.pos, data.subtitles, data.categories
local stem = args[1]
insert_if_not(data.title, "segunda declinación")
insert_if_not(categories, "LA:Adjetivos de la segunda declinación")
local us = "us"
local um = "um"
local i_pl = stem .. "ī"
if types.greek then
insert_if_not(data.title, "griego")
insert_if_not(categories, "LA:Sustantivos griegos")
us = "os"
um = "on"
i_pl = {i_pl, stem .. "oe"}
end
forms["nom_sg_m"] = stem .. us
forms["nom_sg_n"] = stem .. um
forms["nom_pl_m"] = i_pl
forms["nom_pl_n"] = stem .. "a"
forms["gen_sg_m"] = stem .. "ī"
forms["gen_sg_n"] = stem .. "ī"
forms["gen_pl_m"] = stem .. "ōrum"
forms["gen_pl_n"] = stem .. "ōrum"
forms["dat_sg_m"] = stem .. "ō"
forms["dat_sg_n"] = stem .. "ō"
forms["dat_pl_m"] = stem .. "īs"
forms["dat_pl_n"] = stem .. "īs"
forms["acc_sg_m"] = stem .. um
forms["acc_sg_n"] = stem .. um
forms["acc_pl_m"] = stem .. "ōs"
forms["acc_pl_n"] = stem .. "a"
forms["abl_sg_m"] = stem .. "ō"
forms["abl_sg_n"] = stem .. "ō"
forms["abl_pl_m"] = stem .. "īs"
forms["abl_pl_n"] = stem .. "īs"
forms["voc_sg_m"] = stem .. "e"
forms["voc_sg_n"] = stem .. um
forms["voc_pl_m"] = i_pl
forms["voc_pl_n"] = stem .. "a"
forms["loc_sg_m"] = deep_copy(forms["gen_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["gen_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
local function abl_i_e(...)
local function update_slot(forms, slot, f, do_copy)
if not forms[slot] then
return do_copy
elseif do_copy then
f = deep_copy(f)
end
forms[slot] = f
return true
end
function abl_i_e(stem, forms, types)
local f, do_copy
if types["abl_e_i"] then
f = {stem .. "e", stem .. "ī"}
elseif types["abl_i_e"] then
f = {stem .. "ī", stem .. "e"}
else
return
end
do_copy = update_slot(forms, "abl_sg_m", f, do_copy)
do_copy = update_slot(forms, "abl_sg_f", f, do_copy)
-- Neuter doesn't take -e with i-stems.
if not types.I then
update_slot(forms, "abl_sg_n", f, do_copy)
end
end
return abl_i_e(...)
end
adj_decl["3-1+"] = function(data, args)
local forms, types, pos, subtitles, notes, categories = data.forms, data.types, data.pos, data.subtitles, data.notes, data.categories
local stem1, stem2 = args[1], args[2]
-- local singpos = singularize(pos)
insert_if_not(data.title, "tercera declinación, dos terminaciones")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación con dos terminaciones")
forms["nom_sg_m"] = stem1
forms["nom_sg_n"] = stem1
forms["nom_pl_m"] = stem2 .. "ēs"
forms["nom_pl_n"] = stem2 .. "ia"
forms["gen_sg_m"] = stem2 .. "is"
forms["gen_sg_n"] = stem2 .. "is"
forms["gen_pl_m"] = stem2 .. "ium"
forms["gen_pl_n"] = stem2 .. "ium"
forms["dat_sg_m"] = stem2 .. "ī"
forms["dat_sg_n"] = stem2 .. "ī"
forms["dat_pl_m"] = stem2 .. "ibus"
forms["dat_pl_n"] = stem2 .. "ibus"
forms["acc_sg_m"] = stem2 .. "em"
forms["acc_sg_n"] = stem1
forms["acc_pl_m"] = {stem2 .. "īs", stem2 .. "ēs"}
forms["acc_pl_n"] = stem2 .. "ia"
forms["abl_sg_m"] = stem2 .. "ī"
forms["abl_sg_n"] = stem2 .. "ī"
forms["abl_pl_m"] = stem2 .. "ibus"
forms["abl_pl_n"] = stem2 .. "ibus"
abl_i_e(stem2, forms, types)
forms["voc_sg_m"] = stem1
forms["voc_sg_n"] = stem1
forms["voc_pl_m"] = stem2 .. "ēs"
forms["voc_pl_n"] = stem2 .. "ia"
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
if types.par then
forms["nom_pl_n"] = stem2 .. "a"
forms["gen_pl_m"] = stem2 .. "um"
forms["gen_pl_n"] = stem2 .. "um"
forms["abl_sg_m"] = stem2 .. "e"
forms["abl_sg_n"] = stem2 .. "e"
forms["loc_sg_m"] = {stem2 .. "ī", stem2 .. "e"} -- Really?
forms["loc_sg_n"] = {stem2 .. "ī", stem2 .. "e"} -- Why does this happen?
forms["acc_pl_n"] = stem2 .. "a"
forms["voc_pl_n"] = stem2 .. "a"
end
local es_base = stem1:match("^(.-)ēs$")
if es_base and es_base == stem2 then
if types.greek then
forms["nom_sg_n"] = {stem2 .. "ē̆s{?}"}
forms["acc_sg_n"] = {stem2 .. "ē̆s{?}"}
forms["voc_sg_m"] = {stem2 .. "ē̆s{?}"}
forms["voc_sg_n"] = {stem2 .. "ē̆s{?}"}
forms["nom_pl_n"] = {stem2 .. "a{?}", stem2 .. "ia{?}"}
forms["acc_pl_n"] = {stem2 .. "a{?}", stem2 .. "ia{?}"}
forms["voc_pl_n"] = {stem2 .. "a{?}", stem2 .. "ia{?}"}
forms["abl_sg_m"] = {stem2 .. "e{?}", stem2 .. "ī{?}"}
forms["abl_sg_n"] = {stem2 .. "e{?}", stem2 .. "ī{?}"}
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["gen_pl_m"] = {stem2 .. "um{?}", stem2 .. "ium{?}"}
forms["gen_pl_n"] = {stem2 .. "um{?}", stem2 .. "ium{?}"}
insert_if_not(data.title, "griego")
insert_if_not(categories, "LA:Adjetivos griegos")
elseif types.not_greek then
insert_if_not(data.title, "no griego")
end
end
end
adj_decl["3-def+"] = function(data, args)
local forms, types, pos, subtitles, notes, categories = data.forms, data.types, data.pos, data.subtitles, data.notes, data.categories
local stem1, stem2 = args[1], args[2]
-- local singpos = singularize(pos)
insert_if_not(data.title, "tercera declinación, defectivo")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación")
forms["nom_sg_m"] = stem1
forms["nom_sg_n"] = stem1
forms["nom_pl_m"] = stem2 .. "ēs"
forms["nom_pl_n"] = stem2 .. "ia"
forms["gen_sg_m"] = stem2 .. "is"
forms["gen_sg_n"] = stem2 .. "is"
forms["gen_pl_m"] = stem2 .. "ium"
forms["gen_pl_n"] = stem2 .. "ium"
forms["dat_sg_m"] = stem2 .. "ī"
forms["dat_sg_n"] = stem2 .. "ī"
forms["dat_pl_m"] = stem2 .. "ibus"
forms["dat_pl_n"] = stem2 .. "ibus"
forms["acc_sg_m"] = stem2 .. "em"
forms["acc_sg_n"] = stem1
forms["acc_pl_m"] = stem2 .. "ēs"
forms["acc_pl_n"] = stem2 .. "ia"
forms["abl_sg_m"] = stem2 .. "ī"
forms["abl_sg_n"] = stem2 .. "ī"
forms["abl_pl_m"] = stem2 .. "ibus"
forms["abl_pl_n"] = stem2 .. "ibus"
forms["voc_sg_m"] = stem1
forms["voc_sg_n"] = stem1
forms["voc_pl_m"] = stem2 .. "ēs"
forms["voc_pl_n"] = stem2 .. "ia"
if types.tor then
insert_if_not(data.title, "tercera declinación, solo en masculino")
insert_if_not(categories, "LA:Adjetivos solo en masculino")
remove_forms(forms, {"_f$", "_n$"})
forms["nom_sg_m"] = stem1
forms["gen_sg_m"] = stem2 .. "is"
forms["dat_sg_m"] = stem2 .. "ī"
forms["acc_sg_m"] = stem2 .. "em"
forms["abl_sg_m"] = stem2 .. "e"
forms["voc_sg_m"] = stem1
forms["nom_pl_m"] = stem2 .. "ēs"
forms["gen_pl_m"] = stem2 .. "um"
forms["dat_pl_m"] = stem2 .. "ibus"
forms["acc_pl_m"] = stem2 .. "ēs"
forms["abl_pl_m"] = stem2 .. "ibus"
forms["voc_pl_m"] = stem2 .. "ēs"
end
if types.trix then
insert_if_not(data.title, "tercera declinación, solo en femenino o en neutro plural")
insert_if_not(categories, "LA:Adjetivos solo en femenino")
insert_if_not(categories, "LA:Adjetivos solo en neutro")
remove_forms(forms, {"_m$", "sg_n$"})
forms["nom_sg_f"] = stem1
forms["gen_sg_f"] = stem2 .. "is"
forms["dat_sg_f"] = stem2 .. "ī"
forms["acc_sg_f"] = stem2 .. "em"
forms["abl_sg_f"] = {stem2 .. "e", stem2 .. "ī"}
forms["voc_sg_f"] = stem1
forms["nom_pl_f"] = stem2 .. "ēs"
forms["gen_pl_f"] = stem2 .. "ium"
forms["dat_pl_f"] = stem2 .. "ibus"
forms["acc_pl_f"] = stem2 .. "ēs"
forms["abl_pl_f"] = stem2 .. "ibus"
forms["voc_pl_f"] = stem2 .. "ēs"
end
if types.trixf then
insert_if_not(data.title, "tercera declinación, solo en femenino")
insert_if_not(categories, "LA:Adjetivos solo en femenino")
remove_forms(forms, {"_m$","_n$"})
forms["nom_sg_f"] = stem1
forms["gen_sg_f"] = stem2 .. "is"
forms["dat_sg_f"] = stem2 .. "ī"
forms["acc_sg_f"] = stem2 .. "em"
forms["abl_sg_f"] = {stem2 .. "e", stem2 .. "ī"}
forms["voc_sg_f"] = stem1
forms["nom_pl_f"] = stem2 .. "ēs"
forms["gen_pl_f"] = stem2 .. "ium"
forms["dat_pl_f"] = stem2 .. "ibus"
forms["acc_pl_f"] = stem2 .. "ēs"
forms["abl_pl_f"] = stem2 .. "ibus"
forms["voc_pl_f"] = stem2 .. "ēs"
end
if types.idis then
insert_if_not(data.title, "tercera declinación, solo en femenino")
insert_if_not(categories, "LA:Adjetivos solo en femenino")
remove_forms(forms, {"_m$","_n$"})
forms["nom_sg_f"] = stem1
forms["gen_sg_f"] = {stem2 .. "is", stem2 .. "os"}
forms["dat_sg_f"] = stem2 .. "ī"
forms["acc_sg_f"] = {stem2 .. "em", stem2 .. "a"}
forms["abl_sg_f"] = stem2 .. "e"
forms["voc_sg_f"] = stem1
forms["nom_pl_f"] = {stem2 .. "ēs", stem2 .. "es"}
forms["gen_pl_f"] = stem2 .. "um"
forms["dat_pl_f"] = stem2 .. "ibus"
forms["acc_pl_f"] = {stem2 .. "ēs", stem2 .. "as"}
forms["abl_pl_f"] = stem2 .. "ibus"
forms["voc_pl_f"] = {stem2 .. "ēs", stem2 .. "es"}
end
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["abl_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_f"] = deep_copy(forms["abl_pl_f"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
adj_decl["3-C+"] = function(data, args)
local forms, types, pos, categories = data.forms, data.types, data.pos, data.categories
local stem1 = args[1]
local stem2 = stem1 .. "ōr"
insert_if_not(data.title, "tercera declinación, comparativo")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación")
insert_if_not(categories, "LA:Adjetivos comparativos")
forms["nom_sg_m"] = stem1 .. "or"
forms["nom_sg_n"] = stem1 .. "us"
forms["nom_pl_m"] = stem2 .. "ēs"
forms["nom_pl_n"] = stem2 .. "a"
forms["gen_sg_m"] = stem2 .. "is"
forms["gen_sg_n"] = stem2 .. "is"
forms["gen_pl_m"] = stem2 .. "um"
forms["gen_pl_n"] = stem2 .. "um"
forms["dat_sg_m"] = stem2 .. "ī"
forms["dat_sg_n"] = stem2 .. "ī"
forms["dat_pl_m"] = stem2 .. "ibus"
forms["dat_pl_n"] = stem2 .. "ibus"
forms["acc_sg_m"] = stem2 .. "em"
forms["acc_sg_n"] = stem1 .. "us"
forms["acc_pl_m"] = {stem2 .. "ēs", stem2 .. "īs"}
forms["acc_pl_n"] = stem2 .. "a"
forms["abl_sg_m"] = stem2 .. "ī"
forms["abl_sg_n"] = stem2 .. "ī"
forms["abl_pl_m"] = stem2 .. "ibus"
forms["abl_pl_n"] = stem2 .. "ibus"
abl_i_e(stem2, forms, types)
forms["voc_sg_m"] = stem1 .. "or"
forms["voc_sg_n"] = stem1 .. "us"
forms["voc_pl_m"] = stem2 .. "ēs"
forms["voc_pl_n"] = stem2 .. "a"
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
adj_decl["3-P+"] = function(data, args)
local forms, notes = data.forms, data.notes
local stem2 = args[2]
adj_decl["3-1+"](data, args)
insert_if_not(data.title, "tercera declinación, participio")
insert_if_not(data.categories, "LA:Adjetivos de la tercera declinación")
forms["abl_sg_m"] = {stem2 .. "e{PART}", stem2 .. "ī{ADJ}"}
forms["abl_sg_n"] = {stem2 .. "e{PART}", stem2 .. "ī{ADJ}"}
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["acc_pl_m"] = {stem2 .. "ēs", stem2 .. "īs"}
end
adj_decl["3-2+"] = function(data, args)
local forms, types, pos, categories = data.forms, data.types, data.pos, data.categories
local stem = args[1]
-- local singpos = singularize(pos)
insert_if_not(data.title, "tercera declinación, dos terminaciones")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación con dos terminaciones")
forms["nom_sg_m"] = stem .. "is"
forms["nom_sg_n"] = stem .. "e"
forms["nom_pl_m"] = stem .. "ēs"
forms["nom_pl_n"] = stem .. "ia"
forms["gen_sg_m"] = stem .. "is"
forms["gen_sg_n"] = stem .. "is"
forms["gen_pl_m"] = stem .. "ium"
forms["gen_pl_n"] = stem .. "ium"
forms["dat_sg_m"] = stem .. "ī"
forms["dat_sg_n"] = stem .. "ī"
forms["dat_pl_m"] = stem .. "ibus"
forms["dat_pl_n"] = stem .. "ibus"
forms["acc_sg_m"] = stem .. "em"
forms["acc_sg_n"] = stem .. "e"
forms["acc_pl_m"] = {stem .. "īs", stem .. "ēs"}
forms["acc_pl_n"] = stem .. "ia"
forms["abl_sg_m"] = stem .. "ī"
forms["abl_sg_n"] = stem .. "ī"
forms["abl_pl_m"] = stem .. "ibus"
forms["abl_pl_n"] = stem .. "ibus"
-- abl_i_e(stem, forms, types) -- enable once [[Module:la-nominal]] has ben updated
forms["voc_sg_m"] = stem .. "is"
forms["voc_sg_n"] = stem .. "e"
forms["voc_pl_m"] = stem .. "ēs"
forms["voc_pl_n"] = stem .. "ia"
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
adj_decl["3-3+"] = function(data, args)
local forms, types, pos, categories = data.forms, data.types, data.pos, data.categories
local stem1, stem2 = args[1], args[2]
-- local singpos = singularize(pos)
insert_if_not(data.title, "tercera declinación")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación")
insert_if_not(categories, "LA:Adjetivos de la tercera declinación con tres terminaciones")
forms["nom_sg_m"] = stem1
forms["nom_sg_f"] = stem2 .. "is"
forms["nom_sg_n"] = stem2 .. "e"
forms["nom_pl_m"] = stem2 .. "ēs"
forms["nom_pl_f"] = stem2 .. "ēs"
forms["nom_pl_n"] = stem2 .. "ia"
forms["gen_sg_m"] = stem2 .. "is"
forms["gen_sg_f"] = stem2 .. "is"
forms["gen_sg_n"] = stem2 .. "is"
forms["gen_pl_m"] = stem2 .. "ium"
forms["gen_pl_f"] = stem2 .. "ium"
forms["gen_pl_n"] = stem2 .. "ium"
forms["dat_sg_m"] = stem2 .. "ī"
forms["dat_sg_f"] = stem2 .. "ī"
forms["dat_sg_n"] = stem2 .. "ī"
forms["dat_pl_m"] = stem2 .. "ibus"
forms["dat_pl_f"] = stem2 .. "ibus"
forms["dat_pl_n"] = stem2 .. "ibus"
forms["acc_sg_m"] = stem2 .. "em"
forms["acc_sg_f"] = stem2 .. "em"
forms["acc_sg_n"] = stem2 .. "e"
forms["acc_pl_m"] = {stem2 .. "īs", stem2 .. "ēs"}
forms["acc_pl_f"] = {stem2 .. "īs", stem2 .. "ēs"}
forms["acc_pl_n"] = stem2 .. "ia"
forms["abl_sg_m"] = stem2 .. "ī"
forms["abl_sg_f"] = stem2 .. "ī"
forms["abl_sg_n"] = stem2 .. "ī"
forms["abl_pl_m"] = stem2 .. "ibus"
forms["abl_pl_f"] = stem2 .. "ibus"
forms["abl_pl_n"] = stem2 .. "ibus"
-- abl_i_e(stem2, forms, types) -- enable once [[Module:la-nominal]] has ben updated
forms["voc_sg_m"] = stem1
forms["voc_sg_f"] = stem2 .. "is"
forms["voc_sg_n"] = stem2 .. "e"
forms["voc_pl_m"] = stem2 .. "ēs"
forms["voc_pl_f"] = stem2 .. "ēs"
forms["voc_pl_n"] = stem2 .. "ia"
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["abl_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_f"] = deep_copy(forms["abl_pl_f"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
end
adj_decl["indecl+"] = function(data, args)
local forms, subtitles, categories = data.forms, data.subtitles, data.categories
local stem = args[1]
insert_if_not(data.title, "indeclinable")
insert_if_not(categories, "LA:Adjetivos indeclinables")
forms["nom_sg_m"] = stem
forms["nom_pl_m"] = {}
forms["gen_sg_m"] = {}
forms["gen_pl_m"] = {}
forms["dat_sg_m"] = {}
forms["dat_pl_m"] = {}
forms["acc_sg_m"] = stem
forms["acc_pl_m"] = {}
forms["abl_sg_m"] = {}
forms["abl_pl_m"] = {}
forms["voc_sg_m"] = {}
forms["voc_pl_m"] = {}
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
end
adj_decl["irreg+"] = function(data,args)
local forms, types, pos, notes, categories = data.forms, data.types, data.pos, data.notes, data.categories
local arg1 = args[1]
insert_if_not(data.title, "irregular")
insert_if_not(categories, "LA:Adjetivos irregulares")
if arg1 == "duo" or arg1 == "ambō" then
local stem = sub(arg1, 1, -2)
-- data.title = stem == "amb" and "irregular adjective" or "numeral"
data.num = "pl"
local stem_with_o = stem .. (stem == "amb" and "ō" or "o")
forms["nom_pl_m"] = stem_with_o
forms["nom_pl_f"] = stem .. "ae"
forms["nom_pl_n"] = stem_with_o
forms["gen_pl_m"] = stem .. "ōrum"
forms["gen_pl_f"] = stem .. "ārum"
forms["gen_pl_n"] = stem .. "ōrum"
forms["dat_pl_m"] = stem .. "ōbus"
forms["dat_pl_f"] = stem .. "ābus"
forms["dat_pl_n"] = stem .. "ōbus"
forms["acc_pl_m"] = {stem .. "ōs", stem_with_o}
forms["acc_pl_f"] = stem .. "ās"
forms["acc_pl_n"] = stem_with_o
forms["abl_pl_m"] = stem .. "ōbus"
forms["abl_pl_f"] = stem .. "ābus"
forms["abl_pl_n"] = stem .. "ōbus"
forms["voc_pl_m"] = stem_with_o
forms["voc_pl_f"] = stem .. "ae"
forms["voc_pl_n"] = stem_with_o
if stem == "du" then
forms["gen_pl_m"] = {forms["gen_pl_m"], "duum", "duom{†}"}
forms["gen_pl_n"] = {forms["gen_pl_n"], "duum", "duom{†}"}
end
elseif arg1:sub(-6) == "mīlle" then
insert_if_not(data.title, "numeral semiindeclinable")
local stem = arg1:sub(1, -3)
forms["nom_sg_m"] = stem .. "le"
forms["nom_pl_m"] = {stem .. "ia", stem .. "lia"}
forms["gen_sg_m"] = stem .. "le"
forms["gen_pl_m"] = {stem .. "ium", stem .. "lium"}
forms["dat_sg_m"] = stem .. "le"
forms["dat_pl_m"] = {stem .. "ibus", stem .. "libus"}
forms["acc_sg_m"] = stem .. "le"
forms["acc_pl_m"] = {stem .. "ia", stem .. "lia"}
forms["abl_sg_m"] = stem .. "le"
forms["abl_pl_m"] = {stem .. "ibus", stem .. "libus"}
forms["voc_sg_m"] = stem .. "le"
forms["voc_pl_m"] = {stem .. "ia", stem .. "lia"}
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
elseif arg1 == "ille" or arg1 == "iste" or arg1 == "ipse" or arg1 == "olle" then
local stem = arg1:sub(1, -2)
types.ius = true
adj_decl["1&2+"](data, {stem})
insert_if_not(data.title, "demostrativo") -- .. " " .. singularize(data.pos)
forms["nom_sg_m"] = arg1
if arg1 == "ipse" then
add_form(forms, "nom_sg_n", stem, "ud{MED}")
add_form(forms, "acc_sg_n", stem, "ud{MED}")
else
forms["nom_sg_n"] = stem .. "ud"
forms["acc_sg_n"] = stem .. "ud"
end
forms["voc_sg_m"] = {}
forms["voc_sg_f"] = {}
forms["voc_sg_n"] = {}
forms["voc_pl_m"] = {}
forms["voc_pl_f"] = {}
forms["voc_pl_n"] = {}
elseif arg1 == "illic" or arg1 == "istic" or arg1 == "isthic" then
insert_if_not(data.title, "demostrativo") -- .. " " .. singularize(data.pos)
local stem = arg1:sub(1, -3)
forms["nom_sg_m"] = stem .. "ic"
forms["nom_sg_f"] = stem .. "aec"
forms["nom_sg_n"] = {stem .. "uc", stem .. "ucce", stem .. "oc"}
forms["gen_sg_m"] = stem .. "ī̆usce"
forms["gen_sg_f"] = stem .. "ī̆usce"
forms["gen_sg_n"] = stem .. "ī̆usce"
forms["dat_sg_m"] = stem .. "īc"
forms["dat_sg_f"] = stem .. "īc"
forms["dat_sg_n"] = stem .. "īc"
forms["acc_sg_m"] = stem .. "unc"
forms["acc_sg_f"] = stem .. "anc"
forms["acc_sg_n"] = {stem .. "uc", stem .. "ucce", stem .. "oc"}
forms["abl_sg_m"] = stem .. "ōc"
forms["abl_sg_f"] = stem .. "āc"
forms["abl_sg_n"] = stem .. "ōc"
forms["loc_sg_m"] = deep_copy(forms["gen_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["gen_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["gen_sg_n"])
forms["nom_pl_m"] = stem .. "īsce"
forms["nom_pl_f"] = stem .. "aec"
forms["nom_pl_n"] = stem .. "aec"
forms["gen_pl_m"] = stem .. "ōrunc{?}"
forms["gen_pl_f"] = stem .. "ārunc{?}"
forms["gen_ok_n"] = stem .. "ōrunc{?}"
forms["dat_pl_m"] = stem .. "īsce"
forms["dat_pl_f"] = stem .. "īsce"
forms["dat_pl_n"] = stem .. "īsce"
forms["acc_pl_m"] = stem .. "ōsce"
forms["acc_pl_f"] = stem .. "āsce"
forms["acc_pl_n"] = stem .. "aec"
forms["abl_pl_m"] = stem .. "īsce"
forms["abl_pl_f"] = stem .. "īsce"
forms["abl_pl_n"] = stem .. "īsce"
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_f"] = deep_copy(forms["abl_pl_f"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
elseif arg1 == "hice" then
insert_if_not(data.title, "demostrativo") -- .. " pronoun"
forms["nom_sg_m"] = "hice"
forms["nom_sg_f"] = "haece"
forms["nom_sg_n"] = "hoce"
forms["nom_pl_m"] = "hīce"
forms["nom_pl_f"] = "haece"
forms["nom_pl_n"] = "haece"
forms["gen_sg_m"] = "huiusce"
forms["gen_sg_f"] = "huiusce"
forms["gen_sg_n"] = "huiusce"
forms["gen_pl_m"] = {"hōrunce", "hōrumce"}
forms["gen_pl_f"] = {"hārunce", "hārumce"}
forms["gen_pl_n"] = {"hōrunce", "hōrumce"}
forms["dat_sg_m"] = "huīce"
forms["dat_sg_f"] = "huīce"
forms["dat_sg_n"] = "huīce"
forms["dat_pl_m"] = "hīsce"
forms["dat_pl_f"] = "hīsce"
forms["dat_pl_n"] = "hīsce"
forms["acc_sg_m"] = "hunce"
forms["acc_sg_f"] = "hance"
forms["acc_sg_n"] = "hoce"
forms["acc_pl_m"] = "hōsce"
forms["acc_pl_f"] = "hāsce"
forms["acc_pl_n"] = "haece"
forms["abl_sg_m"] = "hōce"
forms["abl_sg_f"] = "hāce"
forms["abl_sg_n"] = "hōce"
forms["abl_pl_m"] = "hīsce"
forms["abl_pl_f"] = "hīsce"
forms["abl_pl_n"] = "hīsce"
forms["loc_sg_m"] = deep_copy(forms["gen_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["gen_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["gen_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_f"] = deep_copy(forms["abl_pl_f"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
elseif arg1 == "plūs" then
insert_if_not(data.title, "comparativo")
insert_if_not(data.categories, "LA:Sustantivos de la tercera declinación")
insert_if_not(data.categories, "LA:Sustantivos de la tercera declinación con una terminación")
data.note = "Ninguna de las formas en singular se usaron en latín clásico"
forms["nom_sg_n"] = "plūs"
forms["nom_pl_m"] = "plūrēs"
forms["nom_pl_n"] = "plūra"
forms["gen_sg_m"] = "plūris"
forms["gen_sg_n"] = "plūris"
forms["gen_pl_m"] = "plūrium"
forms["gen_pl_n"] = "plūrium"
forms["dat_sg_m"] = "plūrī"
forms["dat_sg_n"] = "plūrī"
forms["dat_pl_m"] = "plūribus"
forms["dat_pl_n"] = "plūribus"
forms["acc_sg_m"] = "plūrem"
forms["acc_sg_f"] = "plūrem"
forms["acc_sg_n"] = "plūs"
forms["acc_pl_m"] = {"plūrēs", "plūrīs"}
forms["acc_pl_n"] = "plūra"
forms["abl_sg_m"] = {"plūrī", "plūre"}
forms["abl_sg_f"] = {"plūrī", "plūre"}
forms["abl_sg_n"] = {"plūrī", "plūre"}
forms["abl_pl_m"] = "plūribus"
forms["abl_pl_n"] = "plūribus"
forms["voc_sg_n"] = "plūs"
forms["voc_pl_m"] = "plūrēs"
forms["voc_pl_n"] = "plūra"
forms["loc_sg_m"] = deep_copy(forms["abl_sg_m"])
forms["loc_sg_f"] = deep_copy(forms["abl_sg_f"])
forms["loc_sg_n"] = deep_copy(forms["abl_sg_n"])
forms["loc_pl_m"] = deep_copy(forms["abl_pl_m"])
forms["loc_pl_n"] = deep_copy(forms["abl_pl_n"])
elseif match(arg1, "^egō̆?$") or arg1 == "nōs" then
insert_if_not(data.title, "pronombre nominativo")
forms["nom_sg_m"] = arg1
forms["nom_pl_m"] = "nōs"
forms["gen_sg_m"] = "meī"
forms["gen_pl_m"] = {"nostrī", "nostrum"}
forms["dat_sg_m"] = "mihī̆"
forms["dat_pl_m"] = "nōbīs"
forms["acc_sg_m"] = {"mē", "mēmē"}
forms["acc_pl_m"] = "nōs"
forms["abl_sg_m"] = {"mē", "mēmē"}
forms["abl_pl_m"] = "nōbīs"
forms["voc_sg_m"] = arg1
forms["voc_pl_m"] = "nōs"
elseif arg1 == "tū" or arg1 == "vōs" then
insert_if_not(data.title, "pronombre nominativo")
forms["nom_sg_m"] = arg1
forms["nom_pl_m"] = "vōs"
forms["gen_sg_m"] = "tuī"
forms["gen_pl_m"] = {"vestrī", "vestrum"}
forms["dat_sg_m"] = "tibī̆"
forms["dat_pl_m"] = "vōbīs"
forms["acc_sg_m"] = {"tē", "tētē"}
forms["acc_pl_m"] = "vōs"
forms["abl_sg_m"] = {"tē", "tētē"}
forms["abl_pl_m"] = "vōbīs"
forms["voc_sg_m"] = arg1
forms["voc_pl_m"] = "vōs"
elseif arg1 == "suī" then
insert_if_not(data.title, "pronombre reflexivo")
forms["nom_sg_m"] = {}
forms["nom_pl_m"] = {}
forms["gen_sg_m"] = arg1
forms["gen_pl_m"] = forms["gen_sg_m"]
forms["dat_sg_m"] = "sibī̆"
forms["dat_pl_m"] = forms["dat_sg_m"]
forms["acc_sg_m"] = {"sē", "sēsē"}
forms["acc_pl_m"] = {"sē", "sēsē"}
forms["abl_sg_m"] = {"sē", "sēsē"}
forms["abl_pl_m"] = {"sē", "sēsē"}
forms["voc_sg_m"] = {}
forms["voc_pl_m"] = {}
elseif arg1 == "is" or arg1 == "īdem" then
insert_if_not(data.title, "pronombre demostrativo")
forms["nom_sg_m"] = "is"
forms["nom_sg_f"] = "ea"
forms["nom_sg_n"] = "id"
forms["nom_pl_m"] = {"iī", "eī", "ī"}
forms["nom_pl_f"] = "eae"
forms["nom_pl_n"] = "ea"
forms["gen_sg_m"] = {"eius", "ejus"}
forms["gen_sg_f"] = {"eius", "ejus"}
forms["gen_sg_n"] = {"eius", "ejus"}
forms["gen_pl_m"] = {"eōrum", "eum"}
forms["gen_pl_f"] = "eārum"
forms["gen_pl_n"] = {"eōrum", "eum"}
forms["dat_sg_m"] = {"eī", "e͡i", "ēī"}
forms["dat_sg_f"] = {"eī", "e͡i", "ēī", "eae"}
forms["dat_sg_n"] = {"eī", "e͡i", "ēī"}
forms["dat_pl_m"] = {"iīs", "eīs", "īs"}
forms["dat_pl_f"] = {"iīs", "eīs", "īs", "eābus"}
forms["dat_pl_n"] = {"iīs", "eīs", "īs"}
forms["acc_sg_m"] = "eum"
forms["acc_sg_f"] = "eam"
forms["acc_sg_n"] = "id"
forms["acc_pl_m"] = "eōs"
forms["acc_pl_f"] = "eās"
forms["acc_pl_n"] = "ea"
forms["abl_sg_m"] = "eō"
forms["abl_sg_f"] = "eā"
forms["abl_sg_n"] = "eō"
forms["abl_pl_m"] = {"iīs", "eīs", "īs"}
forms["abl_pl_f"] = {"iīs", "eīs", "īs"}
forms["abl_pl_n"] = {"iīs", "eīs", "īs"}
if arg1 == "īdem" then
forms["nom_sg_m"] = "ī"
forms["nom_sg_n"] = "i"
forms["acc_sg_n"] = "i"
end
elseif arg1 == "quis" or arg1 == "quī" then
data.note = "La forma ''qua'' es preferida frente a ''quae'' cuando se usa como indefinido"
local id = "id"
if arg1 == "quī" then
insert_if_not(data.title, "determinante relativo/interrogativo")
id = "od"
forms["nom_sg_m"] = {"quī", "quis", "quei{†}"}
forms["nom_sg_f"] = {"quae", "qua"}
forms["acc_sg_f"] = "quam"
forms["abl_sg_m"] = "quō"
forms["abl_sg_f"] = "quā"
forms["abl_sg_n"] = "quō"
else
insert_if_not(data.title, "pronombre relativo/interrogativo")
forms["nom_sg_m"] = {"quis", "quī"}
forms["nom_sg_f"] = {"quae", "qua", "quis{†}"}
forms["acc_sg_f"] = {"quam", "quem{†}"}
forms["abl_sg_m"] = {"quō", "quī"}
forms["abl_sg_f"] = {"quā", "quī"}
forms["abl_sg_n"] = {"quō", "quī"}
end
forms["nom_sg_n"] = "qu"..id
forms["nom_pl_m"] = {"quī", "quei{†}"}
forms["nom_pl_f"] = "quae"
forms["nom_pl_n"] = {"quae", "qua"}
forms["gen_sg_m"] = {"cuius", "quoius{†}"}
forms["gen_sg_f"] = {"cuius", "quoius{†}"}
forms["gen_sg_n"] = {"cuius", "quoius{†}"}
forms["gen_pl_m"] = "quōrum"
forms["gen_pl_f"] = "quārum"
forms["gen_pl_n"] = "quōrum"
forms["dat_sg_m"] = {"cui", "quoi{†}", "quoiei{†}"}
forms["dat_sg_f"] = {"cui", "quoi{†}", "quoiei{†}"}
forms["dat_sg_n"] = {"cui", "quoi{†}", "quoiei{†}"}
forms["dat_pl_m"] = {"quibus", "quīs", "queis{†}"}
forms["dat_pl_f"] = {"quibus", "quīs", "queis{†}"}
forms["dat_pl_n"] = {"quibus", "quīs", "queis{†}"}
forms["acc_sg_m"] = "quem"
forms["acc_sg_n"] = "qu"..id
forms["acc_pl_m"] = "quōs"
forms["acc_pl_f"] = "quās"
forms["acc_pl_n"] = {"quae", "qua"}
forms["abl_pl_m"] = {"quibus", "quīs", "queis{†}"}
forms["abl_pl_f"] = {"quibus", "quīs", "queis{†}"}
forms["abl_pl_n"] = {"quibus", "quīs", "queis{†}"}
elseif arg1 == "aliquī" then
insert_if_not(data.title, "determinante indefinido")
forms["nom_sg_m"] = {"aliquī{DET/ADJ}", "aliquis{PRON/SUST}"}
forms["nom_sg_f"] = {"aliqua", "aliquae{R}"}
forms["nom_sg_n"] = "aliquod"
forms["nom_pl_m"] = "aliquī"
forms["nom_pl_f"] = "aliquae"
forms["nom_pl_n"] = "aliqua"
forms["gen_sg_m"] = {"alicuius", "aliquoius{†}"}
forms["gen_sg_f"] = {"alicuius", "aliquoius{†}"}
forms["gen_sg_n"] = {"alicuius", "aliquoius{†}"}
forms["gen_pl_m"] = "aliquōrum"
forms["gen_pl_f"] = "aliquārum"
forms["gen_pl_n"] = "aliquōrum"
forms["dat_sg_m"] = {"alicui", "aliquoi{†}"}
forms["dat_sg_f"] = {"alicui", "aliquoi{†}"}
forms["dat_sg_n"] = {"alicui", "aliquoi{†}"}
forms["dat_pl_m"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
forms["dat_pl_f"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
forms["dat_pl_n"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
forms["acc_sg_m"] = "aliquem"
forms["acc_sg_f"] = "aliquam"
forms["acc_sg_n"] = "aliquod"
forms["acc_pl_m"] = "aliquōs"
forms["acc_pl_f"] = "aliquās"
forms["acc_pl_n"] = "aliqua"
forms["abl_sg_m"] = "aliquō"
forms["abl_sg_f"] = "aliquā"
forms["abl_sg_n"] = "aliquō"
forms["abl_pl_m"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
forms["abl_pl_f"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
forms["abl_pl_n"] = {"aliquīs", "aliquibus", "aliqueis{†}"}
elseif arg1 == "quisquam" then
insert_if_not(data.title, "determinante indefinido, concordancia en negativo")
data.note = "En latín clásico, era preferidas las formas de ''ūllus'' en lugar de las esta voz para el femenino y el neutro."
forms["nom_sg_m"] = "quisquam"
forms["nom_sg_f"] = {"quaequam", "quisquam{†}"}
forms["nom_sg_n"] = "quodquam"
forms["nom_pl_m"] = "quīquam"
forms["nom_pl_f"] = "quaequam"
forms["nom_pl_n"] = "quaequam"
forms["gen_sg_m"] = "cuiusquam"
forms["gen_sg_f"] = "cuiusquam"
forms["gen_sg_n"] = "cuiusquam"
forms["gen_pl_m"] = "quōrumquam"
forms["gen_pl_f"] = "quārumquam"
forms["gen_pl_n"] = "quōrumquam"
forms["dat_sg_m"] = "cuiquam"
forms["dat_sg_f"] = "cuiquam"
forms["dat_sg_n"] = "cuiquam"
forms["dat_pl_m"] = "quibusquam"
forms["dat_pl_f"] = "quibusquam"
forms["dat_pl_n"] = "quibusquam"
forms["acc_sg_m"] = "quemquam"
forms["acc_sg_f"] = {"quamquam", "quemquam{†}"}
forms["acc_sg_n"] = "quodquam"
forms["acc_pl_m"] = "quōsquam"
forms["acc_pl_f"] = "quāsquam"
forms["acc_pl_n"] = "quaequam"
forms["abl_sg_m"] = {"quōquam", "quīquam{†}"}
forms["abl_sg_f"] = "quāquam"
forms["abl_sg_n"] = "quōquam"
forms["abl_pl_m"] = "quibusquam"
forms["abl_pl_f"] = "quibusquam"
forms["abl_pl_n"] = "quibusquam"
forms["voc_sg_m"] = "quisquam"
forms["voc_sg_f"] = "quaequam"
forms["voc_sg_n"] = "quodquam"
forms["voc_pl_m"] = "quīquam"
forms["voc_pl_f"] = "quaequam"
forms["voc_pl_n"] = "quaequam"
elseif arg1 == "quisquis" then
insert_if_not(data.title, "pronombre relativo/interrogativo")
forms["nom_sg_m"] = "quisquis"
forms["nom_sg_f"] = "quisquis"
forms["nom_sg_n"] = {"quidquid", "quicquid"}
forms["nom_pl_m"] = "quīquī"
forms["nom_pl_f"] = "quaequae"
forms["nom_pl_n"] = "quaequae"
forms["gen_sg_m"] = "cuiuscuius"
forms["gen_sg_f"] = "cuiuscuius"
forms["gen_sg_n"] = "cuiuscuius"
forms["gen_pl_m"] = "quōrumquōrum"
forms["gen_pl_f"] = "quārumquārum"
forms["gen_pl_n"] = "quōrumquōrum"
forms["dat_sg_m"] = "cuicui"
forms["dat_sg_f"] = "cuicui"
forms["dat_sg_n"] = "cuicui"
forms["dat_pl_m"] = {"quibusquibus", "quīsquīs"}
forms["dat_pl_f"] = {"quibusquibus", "quīsquīs"}
forms["dat_pl_n"] = {"quibusquibus", "quīsquīs"}
forms["acc_sg_m"] = "quemquem"
forms["acc_sg_f"] = "quamquam"
forms["acc_sg_n"] = {"quidquid", "quicquid"}
forms["acc_pl_m"] = "quōsquōs"
forms["acc_pl_f"] = "quāsquās"
forms["acc_pl_n"] = "quaequae"
forms["abl_sg_m"] = "quōquō"
forms["abl_sg_f"] = "quāquā"
forms["abl_sg_n"] = "quōquō"
forms["abl_pl_m"] = {"quibusquibus", "quīsquīs"}
forms["abl_pl_f"] = {"quibusquibus", "quīsquīs"}
forms["abl_pl_n"] = {"quibusquibus", "quīsquīs"}
forms["voc_sg_m"] = "quisquis"
forms["voc_sg_f"] = "quisquis"
forms["voc_sg_n"] = {"quidquid", "quicquid"}
forms["voc_pl_m"] = "quīquī"
forms["voc_pl_f"] = "quaequae"
forms["voc_pl_n"] = "quaequae"
elseif arg1 == "ecquis" then
insert_if_not(data.title, "pronombre interrogativo")
forms["nom_sg_m"] = {"ecquis", "ecquī"}
forms["nom_sg_f"] = {"ecqua", "ecquae"}
forms["nom_sg_n"] = "ecquid"
forms["nom_pl_m"] = "ecquī"
forms["nom_pl_f"] = "ecquae"
forms["nom_pl_n"] = {"ecqua", "ecquae"}
forms["gen_sg_m"] = "eccuius"
forms["gen_sg_f"] = "eccuius"
forms["gen_sg_n"] = "eccuius"
forms["dat_sg_m"] = "eccui"
forms["dat_sg_f"] = "eccui"
forms["dat_sg_n"] = "eccui"
forms["acc_sg_m"] = "ecquem"
forms["acc_sg_f"] = "ecquam"
forms["acc_sg_n"] = "ecquod"
forms["acc_pl_m"] = "ecquōs"
forms["acc_pl_f"] = "ecquās"
forms["acc_pl_n"] = {"ecqua", "ecquae"}
forms["abl_sg_m"] = {"ecquō", "ecquī"}
forms["abl_sg_f"] = {"ecquā", "ecquī"}
forms["abl_sg_n"] = {"ecquō", "ecquī"}
elseif arg1 == "quīdam" then
insert_if_not(data.title, "pronombre indefinido")
forms["nom_sg_m"] = "quīdam"
forms["nom_sg_f"] = "quaedam"
forms["nom_sg_n"] = "quiddam"
forms["nom_pl_m"] = {"quīdam", "quēsdam{†}"}
forms["nom_pl_f"] = "quaedam"
forms["nom_pl_n"] = "quaedam"
forms["gen_sg_m"] = {"cuiusdam", "quoiusdam{†}"}
forms["gen_sg_f"] = {"cuiusdam", "quoiusdam{†}"}
forms["gen_sg_n"] = {"cuiusdam", "quoiusdam{†}"}
forms["gen_pl_m"] = {"quōrundam", "quōrumdam"}
forms["gen_pl_f"] = {"quārundam", "quārumdam"}
forms["gen_pl_n"] = {"quōrundam", "quōrumdam"}
forms["dat_sg_m"] = {"cuidam", "quoidam{†}"}
forms["dat_sg_f"] = {"cuidam", "quoidam{†}"}
forms["dat_sg_n"] = {"cuidam", "quoidam{†}"}
forms["dat_pl_m"] = {"quibusdam", "quīsdam{†}"}
forms["dat_pl_f"] = {"quibusdam", "quīsdam{†}"}
forms["dat_pl_n"] = {"quibusdam", "quīsdam{†}"}
forms["acc_sg_m"] = {"quendam", "quemdam"}
forms["acc_sg_f"] = {"quandam", "quamdam"}
forms["acc_sg_n"] = "quiddam"
forms["acc_pl_m"] = {"quōsdam", "quēsdam{†}"}
forms["acc_pl_f"] = "quāsdam"
forms["acc_pl_n"] = "quaedam"
forms["abl_sg_m"] = "quōdam"
forms["abl_sg_f"] = "quādam"
forms["abl_sg_n"] = "quōdam"
forms["abl_pl_m"] = {"quibusdam", "quīsdam{†}"}
forms["abl_pl_f"] = {"quibusdam", "quīsdam{†}"}
forms["abl_pl_n"] = {"quibusdam", "quīsdam{†}"}
elseif arg1 == "nēmō" then
insert_if_not(data.title, "Determinante y pronombre, concordancia en negativo")
forms["nom_sg_m"] = "nēmō"
forms["nom_sg_f"] = "nēmō"
forms["gen_sg_m"] = {"nūllī̆us", "nēminis{R}"}
forms["gen_sg_f"] = {"nūllī̆us", "nēminis{R}"}
forms["dat_sg_m"] = "nēminī"
forms["dat_sg_f"] = "nēminī"
forms["acc_sg_m"] = "nēminem"
forms["acc_sg_f"] = "nēminem"
forms["abl_sg_m"] = {"nūllō", "nēmine{R}"}
forms["abl_sg_f"] = {"nūllā", "nēmine{R}"}
else
error('adjective ' .. arg1 .. ' not recognized')
end
end
local function extract_base(lemma, ending)
if ending:find("(", nil, true) then
return match(lemma, ending)
end
return match(lemma, "^(.*)" .. ending .. "$")
end
local function get_noun_subtype_by_ending(lemma, stem2, decltype, specified_subtypes,
endings_and_subtypes)
for _, ending_and_subtypes in ipairs(endings_and_subtypes) do
local ending = ending_and_subtypes[1]
local subtypes = ending_and_subtypes[2]
local not_this_subtype = false
if (
specified_subtypes.pl and not contains(subtypes, "pl") or
contains(subtypes, "both") and not specified_subtypes.both
) then
-- We now require that plurale tantum terms specify a plural-form lemma.
-- The autodetected subtypes will include 'pl' for such lemmas; if not,
-- we fail this entry. Additionally, if the rule contains 'both', it
-- must be explicitly specified to match.
not_this_subtype = true
else
for _, subtype in ipairs(subtypes) do
-- A subtype is directly canceled by specifying -SUBTYPE.
-- In addition, M or F as a subtype is canceled by N, and
-- vice-versa, but M doesn't cancel F or vice-versa; instead,
-- we simply ignore the conflicting gender specification when
-- constructing the combination of specified and inferred subtypes.
-- The reason for this is that neuters have distinct declensions
-- from masculines and feminines, but masculines and feminines have
-- the same declension, and various nouns in Latin that are
-- normally masculine are exceptionally feminine and vice-versa
-- (nauta, agricola, fraxinus, malus "apple tree", manus, rēs,
-- etc.).
--
-- In addition, sg as a subtype is canceled by pl and vice-versa.
-- It's also possible to specify both, which will override sg but
-- not cancel it (in the sense that it won't prevent the relevant
-- rule from matching). For example, there's a rule specifying that
-- lemmas beginning with a capital letter and ending in -ius take
-- the ius.voci.sg subtypes. Specifying such a lemma with the
-- subtype both will result in the ius.voci.both subtypes, whereas
-- specifying such a lemma with the subtype pl will cause this rule
-- not to match, and it will fall through to a less specific rule
-- that returns just the ius subtype, which will be combined with
-- the explicitly specified pl subtype to produce ius.pl.
if specified_subtypes["-" .. subtype] or
subtype == "N" and (specified_subtypes.M or specified_subtypes.F) or
(subtype == "M" or subtype == "F") and specified_subtypes.N or
subtype == "sg" and specified_subtypes.pl or
subtype == "pl" and specified_subtypes.sg then
not_this_subtype = true
break
end
end
end
if not not_this_subtype then
if type(ending) == "table" then
local lemma_ending = ending[1]
local stem2_ending = ending[2]
local base = extract_base(lemma, lemma_ending)
if base and base .. stem2_ending == stem2 then
return base, stem2, subtypes
end
else
local base = extract_base(lemma, ending)
if base then
return base, stem2, subtypes
end
end
end
end
if decltype then
error("Unrecognized ending for declension-" .. decltype .. " noun: " .. lemma)
end
return lemma, stem2, keys_to_list(specified_subtypes)
end
local patterns = {
{"[mM]a", "%0t"},
{"e", ""},
{"([aoAO])([lr])", "%1" .. MACRON .. "%2"},
{"[eE]l", "%0l"},
{"([mM])en", "%1in"},
{"([tT]ūd)ō", "%1in"},
{"([gG])ō", "%1in"},
{"[ōŌ]", "%1n"},
{"er", "r"},
{"[ēi]s", ""},
{"([āēīōūȳĀĒĪŌŪȲ]n)s", function(v)
return (gsub(toNFD(v), MACRON, "") .. "t")
end},
{"([cC])eps", "%1ipit"},
{"([bp])s", "%1"},
{"us", "or"},
{"s", "t"},
{"ex", "ic"},
{"x", "c"},
}
local function make_stem2(stem)
local n
for _, pattern in ipairs(patterns) do
local key = pattern[1]
stem, n = gsub(stem, key .. "$", pattern[2])
if n > 0 then
-- debug_track("la-utilities/" .. key) REVISAR
return toNFC(stem)
end
end
-- debug_track("la-utilities") REVISAR
return stem
end
local function detect_noun_subtype(lemma, stem2, typ, subtypes)
local base, _
if typ == "1" then
return get_noun_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"ām", {"F", "am"}},
{"ās", {"M", "Greek", "Ma"}},
{"ēs", {"M", "Greek", "Me"}},
{"ē", {"F", "Greek"}},
{"ae", {"F", "pl"}},
{"a", {"F"}},
})
elseif typ == "2" then
local detected_subtypes
lemma, stem2, detected_subtypes = get_noun_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"^(.*r)$", {"M", "er"}},
{"^(.*v)os$", {"M", "vos"}},
{"^(.*v)om$", {"N", "vom"}},
-- If the lemma ends in -os and the user said N or -M, then the
-- following won't apply, and the second (neuter) -os will applly.
{"os", {"M", "Greek"}},
{"os", {"N", "Greek", "us"}},
{"on", {"N", "Greek"}},
-- -ius beginning with a capital letter is assumed a proper name,
-- and takes the voci subtype (vocative in -ī) along with the ius
-- subtype and sg-only. Other nouns in -ius just take the ius
-- subtype. Explicitly specify "sg" so that if .pl is given,
-- this rule won't apply.
{"^(%u.*)ius$", {"M", "ius", "voci", "sg"}},
{"ius", {"M", "ius"}},
{"ium", {"N", "ium"}},
-- If the lemma ends in -us and the user said N or -M, then the
-- following won't apply, and the second (neuter) -us will applly.
{"us", {"M"}},
{"us", {"N", "us"}},
{"um", {"N"}},
{"iī", {"M", "ius", "pl"}},
{"ia", {"N", "ium", "pl"}},
-- If the lemma ends in -ī and the user said N or -M, then the
-- following won't apply, and the second (neuter) -ī will applly.
{"ī", {"M", "pl"}},
{"ī", {"N", "us", "pl"}},
{"oe", {"M", "Greek", "pl"}},
{"a", {"N", "pl"}},
})
stem2 = stem2 or lemma
return lemma, stem2, detected_subtypes
elseif typ == "3" then
if subtypes.pl then
if subtypes.Greek then
base = lemma:match("^(.*)erēs$")
if base then
return base .. "ēr", base .. "er", {"er"}
end
base = lemma:match("^(.*)ontēs$")
if base then
return base .. "ōn", base .. "ont", {"on"}
end
base = lemma:match("^(.*)es$")
if base then
return base, stem2 or base, {}
end
error("Unrecognized ending for declension-3 plural Greek noun: " .. lemma)
end
base = lemma:match("^(.*)ia$")
if base then
return base, stem2 or base, {"N", "I", "pure"}
end
base = lemma:match("^(.*)a$")
if base then
return base, stem2 or base, {"N"}
end
base = lemma:match("^(.*)ēs$")
if base then
return base, stem2 or base, {}
end
error("Unrecognized ending for declension-3 plural noun: " .. lemma)
end
stem2 = stem2 or make_stem2(lemma)
local detected_subtypes
if subtypes.Greek then
base, _, detected_subtypes = get_noun_subtype_by_ending(lemma, stem2, nil, subtypes, {
{{"is", ""}, {"I"}},
{"ēr", {"er"}},
{"ōn", {"on"}},
})
if base then
return lemma, stem2, detected_subtypes
end
return lemma, stem2, {}
end
if not subtypes.N then
base, _, detected_subtypes = get_noun_subtype_by_ending(lemma, stem2, nil, subtypes, {
{{"^(%u.*pol)is$", ""}, {"F", "polis", "sg", "loc"}},
{{"tūdō", "tūdin"}, {"F"}},
{{"tās", "tāt"}, {"F"}},
{{"tūs", "tūt"}, {"F"}},
{{"tiō", "tiōn"}, {"F"}},
{{"siō", "siōn"}, {"F"}},
{{"xiō", "xiōn"}, {"F"}},
{{"gō", "gin"}, {"F"}},
{{"or", "ōr"}, {"M"}},
{{"tr[iī]x", "trīc"}, {"F"}},
{{"is", ""}, {"I"}},
{{"^(%l.*)ēs$", ""}, {"I"}},
})
if base then
return lemma, stem2, detected_subtypes
end
end
base, _, detected_subtypes = get_noun_subtype_by_ending(lemma, stem2, nil, subtypes, {
{{"us", "or"}, {"N"}},
{{"us", "er"}, {"N"}},
{{"ma", "mat"}, {"N"}},
{{"men", "min"}, {"N"}},
{{"^(%u.*)e$", ""}, {"N", "sg"}},
{{"e", ""}, {"N", "I", "pure"}},
{{"al", "āl"}, {"N", "I", "pure"}},
{{"ar", "ār"}, {"N", "I", "pure"}},
})
if base then
return lemma, stem2, detected_subtypes
end
return lemma, stem2, {}
elseif typ == "4" then
if subtypes.echo or subtypes.Callisto then
base = lemma:match("^(.*)ō$")
if not base then
error("Declension-4 noun of subtype .echo or .Callisto should end in -ō: " .. lemma)
end
if subtypes.Callisto then
return base, nil, {"F", "sg"}
else
return base, nil, {"F"}
end
end
return get_noun_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"us", {"M"}},
{"ū̆", {"N"}},
{"ūs", {"M", "pl"}},
{"ua", {"N", "pl"}},
})
elseif typ == "5" then
return get_noun_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"iēs", {"F", "i"}},
{"iēs", {"F", "i", "pl"}},
{"ēs", {"F"}},
{"ēs", {"F", "pl"}},
})
elseif typ == "sgpl" then
return lemma, stem2, {}
elseif typ == "irreg" and lemma == "domus" then
-- [[domus]] auto-sets data.loc = true, but we need to know this
-- before declining the noun so we can propagate it to other segments.
return lemma, nil, {"loc"}
elseif typ == "indecl" or typ == "irreg" and (
lemma == "Deus" or match(lemma, "^[IJ]ēs[uū]s$") or
lemma == "Athōs" or lemma == "vēnum"
) then
-- Indeclinable nouns, and certain irregular nouns, set data.num = "sg",
-- but we need to know this before declining the noun so we can
-- propagate it to other segments.
return get_noun_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"", {"both"}},
{"", {"sg"}},
{"", {"pl"}},
})
elseif typ == "indecl" or typ == "irreg" then
return lemma, nil, {}
else
return nil, nil, {}
end
end
-- Given ENDINGS_AND_SUBTYPES (a list of four-tuples of ENDING, RETTYPE,
-- SUBTYPES, PROCESS_RETVAL), check each ENDING in turn against LEMMA and
-- STEM2. If it matches, return a four-tuple BASE, STEM2, RETTYPE, NEW_SUBTYPES
-- where BASE is normally the remainder of LEMMA minus the ending, STEM2 is
-- as passed in, RETTYPE is as passed in, and NEW_SUBTYPES is the same as
-- SUBTYPES minus any subtypes beginning with a hyphen. If no endings match,
-- throw an error if DECLTYPPE is non-nil, mentioning the DECLTYPE
-- (user-specified declension); but if DECLTYPE is nil, just return the tuple
-- nil, nil, nil, nil.
--
-- In order for a given entry to match, ENDING must match and also the subtypes
-- in SUBTYPES (a list) must not be incompatible with the passed-in
-- user-specified subtypes SPECIFIED_SUBTYPES (a set, i.e. a table where the
-- keys are strings and the value is always true). "Incompatible" means that
-- a given SUBTYPE is specified in either one and -SUBTYPE in the other, or
-- that "pl" is found in SPECIFIED_SUBTYPES and not in SUBTYPES.
--
-- The ending spec in ENDINGS_AND_SUBTYPES is one of the following:
--
-- 1. A simple string, e.g. "tūdō", specifying an ending.
-- 2. A regex that should match the entire lemma (it should be anchored at
-- the beginning with ^ and at the end with $), and contains a single
-- capturing group to match the base.
-- 3. A pair {SIMPLE_STRING_OR_REGEX, STEM2_ENDING} where
-- SIMPLE_STRING_OR_REGEX is one of the previous two possibilities and
-- STEM2_ENDING is a string specifying the corresponding ending that must
-- be present in STEM2. If this form is used, the combination of
-- base + STEM2_ENDING must exactly match STEM2 in order for this entry
-- to be considered a match. An example is {"is", ""}, which will match
-- lemma == "follis", stem2 == "foll", but not lemma == "lapis",
-- stem2 == "lapid".
--
-- If PROCESS_STEM2 is given and the returned STEM2 would be nil, call
-- process_stem2(BASE) to get the STEM2 to return.
local function get_adj_type_and_subtype_by_ending(lemma, stem2, decltype,
specified_subtypes, endings_and_subtypes, process_stem2)
for _, ending_and_subtypes in ipairs(endings_and_subtypes) do
local ending = ending_and_subtypes[1]
local rettype = ending_and_subtypes[2]
local subtypes = ending_and_subtypes[3]
local process_retval = ending_and_subtypes[4]
local not_this_subtype = false
if (
specified_subtypes.pl and not contains(subtypes, "pl") or
contains(subtypes, "both") and not specified_subtypes.both
) then
-- We now require that plurale tantum terms specify a plural-form lemma.
-- The autodetected subtypes will include 'pl' for such lemmas; if not,
-- we fail this entry. Additionally, if the rule contains 'both', it
-- must be explicitly specified to match.
not_this_subtype = true
else
for _, subtype in ipairs(subtypes) do
-- A subtype is directly canceled by specifying -SUBTYPE.
if specified_subtypes["-" .. subtype] then
not_this_subtype = true
break
end
-- A subtype is canceled if the user specified SUBTYPE and
-- -SUBTYPE is given in the to-be-returned subtypes.
local must_not_be_present = subtype:match("^%-(.*)$")
if must_not_be_present and specified_subtypes[must_not_be_present] then
not_this_subtype = true
break
end
end
end
if not not_this_subtype then
local base
if type(ending) == "table" then
local lemma_ending = ending[1]
local stem2_ending = ending[2]
base = extract_base(lemma, lemma_ending)
if base and base .. stem2_ending ~= stem2 then
base = nil
end
else
base = extract_base(lemma, ending)
end
if base then
-- Remove subtypes of the form -SUBTYPE from the subtypes
-- to be returned.
local new_subtypes = {}
for _, subtype in ipairs(subtypes) do
if subtype:sub(1, 1) ~= "-" then
insert(new_subtypes, subtype)
end
end
if process_retval then
base, stem2 = process_retval(base, stem2)
end
if process_stem2 then
stem2 = stem2 or process_stem2(base)
end
return base, stem2, rettype, new_subtypes
end
end
end
if not decltype then
return lemma, stem2, nil, keys_to_list(specified_subtypes)
elseif decltype == "" then
error("Unrecognized ending for adjective: " .. lemma)
else
error("Unrecognized ending for declension-" .. decltype .. " adjective: " .. lemma)
end
end
-- Autodetect the type and subtype of an adjective given all the information
-- specified by the user: lemma, stem2, declension type and specified subtypes.
-- Four values are returned: the lemma base (i.e. the stem of the lemma, as
-- required by the declension functions), the value of stem2 to pass to the
-- declension function, the declension type and the autodetected subtypes.
-- Note that this will not detect a given subtype if -SUBTYPE is specified for
-- any subtype that would be returned, or if SUBTYPE is specified and -SUBTYPE
-- is among the subtypes that would be returned (such subtypes are filtered out
-- of the returned subtypes).
local function detect_adj_type_and_subtype(lemma, stem2, typ, subtypes)
local function base_as_stem2(base, stem2)
return base, base
end
local function constant_base(baseval)
return function(base, stem2)
return baseval, nil
end
end
local function decl12_stem2(base)
return base
end
local function decl3_stem2(base)
return make_stem2(base)
end
local decl12_entries = {
{"us", "1&2+", {}},
{"a", "1&2+", {}},
{"um", "1&2+", {}},
{"ī", "1&2+", {"pl"}},
{"ae", "1&2+", {"pl"}},
{"a", "1&2+", {"pl"}},
-- Nearly all -os adjectives are greekA
{"os", "1&2+", {"greekA", "-greekE"}},
{"os", "1&2+", {"greekE", "-greekA"}},
{"ē", "1&2+", {"greekE", "-greekA"}},
{"on", "1&2+", {"greekA", "-greekE"}},
{"on", "1&2+", {"greekE", "-greekA"}},
{"^(.*er)$", "1&2+", {"er"}},
{"^(.*ur)$", "1&2+", {"er"}},
{"^(h)ic$", "1&2+", {"ic"}},
}
local decl3_entries = {
{"^(.*er)$", "3-3+", {"I"}},
{"^(.*er)$", "3-3+", {}},
{"is", "3-2+", {"I"}},
{"is", "3-2+", {}},
{"e", "3-2+", {"I"}},
{"e", "3-2+", {}},
{"^(.*[ij])or$", "3-C+", {"abl_e_i", "-abl_i_e"}},
{"^(.*[ij])or$", "3-C+", {}},
{"^(min)or$", "3-C+", {"abl_e_i", "-abl_i_e"}},
{"^(min)or$", "3-C+", {}},
{"^(.*trīx)$", "3-def+", {"trix", "abl_i_e", "-abl_e_i"}},
{"^(.*trīx)$", "3-def+", {"trix"}},
{"^(.*tor)$", "3-def+", {"tor", "abl_i_e", "-abl_e_i"}},
{"^(.*tor)$", "3-def+", {"tor"}},
-- Detect -ēs as 3-1 without auto-inferring .pl if .pl
-- not specified. If we don't do this, the later entry for
-- -ēs will auto-infer .pl whenever -ēs is specified (which
-- won't work for adjectives like quadripēs, volucripēs).
-- Essentially, for declension-3 adjectives, we require that
-- .pl is given if the lemma is plural.
--
-- Most 3-1 adjectives are i-stem (e.g. audāx) so we require -I
-- to be given with non-i-stem adjectives. The first entry below
-- will apply when -I isn't given, the second when it is given.
{"^(.*ēs)$", "3-1+", {"I", "abl_i_e", "-abl_e_i"}},
{"^(.*ēs)$", "3-1+", {"I"}},
{"^(.*ēs)$", "3-1+", {"par", "abl_i_e", "-abl_e_i"}},
{"^(.*ēs)$", "3-1+", {"par"}},
{"^(.*[ij])ōrēs$", "3-C+", {"pl"}},
{"^(min)ōrēs$", "3-C+", {"pl"}},
-- If .pl with -ēs, we don't know if the adjective is 3-1, 3-2
-- or 3-3. Since 3-2 is probably the most common, we infer it
-- (as well as the fact that these adjectives *are* in a sense
-- 3-2 since they have a distinct neuter in -(i)a. Note that
-- we have two entries here; the first one will apply unless
-- -I is given, and will infer an i-stem adjective; the second
-- one will apply otherwise (and infer a non-i-stem 3-1 adjective).
{"ēs", "3-2+", {"pl", "I"}, base_as_stem2},
{"ēs", "3-1+", {"pl", "par"}, base_as_stem2},
-- Same for neuters.
{"ia", "3-2+", {"pl", "I"}, base_as_stem2},
{"a", "3-1+", {"pl", "par"}, base_as_stem2},
-- As above for -ēs but for miscellaneous singulars.
{"", "3-1+", {"I", "abl_i_e", "-abl_e_i"}},
{"", "3-1+", {"I"}},
{"", "3-1+", {"par", "abl_i_e", "-abl_e_i"}},
{"", "3-1+", {"par"}},
}
local function get_subtypes_and_endings(typ, f)
local subtypes_and_endings = {}
for _, v in ipairs(decl3_entries) do
if f(v) then
v = deep_copy(v)
v[2] = typ
insert(subtypes_and_endings, v)
end
end
return subtypes_and_endings
end
local function compare(spec)
return spec[2] == typ
end
if typ == "+" then
local base, new_stem2, rettype, new_subtypes = get_adj_type_and_subtype_by_ending(lemma, stem2, nil, subtypes, decl12_entries, decl12_stem2)
if rettype then
return base, new_stem2, rettype, new_subtypes
else
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, decl3_entries, decl3_stem2)
end
elseif typ == "3+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, decl3_entries, decl3_stem2)
elseif typ == "1&2+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, decl12_entries, decl12_stem2)
elseif typ == "1-1+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"a", typ, {}},
{"ae", typ, {"pl"}},
})
elseif typ == "2-2+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"us", typ, {}},
{"um", typ, {}},
{"ī", typ, {"pl"}},
{"a", typ, {"pl"}},
{"os", typ, {"greek"}},
{"on", typ, {"greek"}},
{"oe", typ, {"greek", "pl"}},
})
elseif typ == "3-1+" then
-- Use the specs from `decl3_entries`, but add the two i-stem 3-2+ specs when plural-only, as they're the same when 3-1+.
local subtypes_and_endings = get_subtypes_and_endings(typ, function(spec)
local spec1, spec2 = spec[1], spec[2]
return spec2 == typ or (spec2 == "3-2+" and spec1 == "ēs" or spec1 == "ia")
end)
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, subtypes_and_endings, decl3_stem2)
elseif typ == "3-def+" then
-- Like 3-1+ but defective in gender
local subtypes_and_endings = get_subtypes_and_endings(typ, compare)
insert(subtypes_and_endings, {"", typ, {"I"}})
insert(subtypes_and_endings, {"", typ, {"par"}})
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, subtypes_and_endings, decl3_stem2)
elseif typ == "3-2+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"is", typ, {}},
{"e", typ, {}},
-- Detect -ēs as 3-2 without auto-inferring .pl if .pl
-- not specified. If we don't do this, the later entry for
-- -ēs will auto-infer .pl whenever -ēs is specified (which
-- won't work for adjectives like isoscelēs). Essentially,
-- for declension-3 adjectives, we require that .pl is given
-- if the lemma is plural.
{"ēs", typ, {}},
{"ēs", typ, {"pl"}},
{"ia", typ, {"pl"}},
}, decl3_stem2)
elseif typ == "3-3+" or typ == "3-P+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"ēs", typ, {"pl"}, base_as_stem2},
{"ia", typ, {"pl"}, base_as_stem2},
{"", typ, {}},
}, decl3_stem2)
elseif typ == "3-C+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, get_subtypes_and_endings(typ, compare), decl3_stem2)
elseif typ == "irreg+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"^(duo)$", typ, {"pl"}},
{"^(ambō)$", typ, {"pl"}},
{"^(mīll?ia)$", typ, {"N", "pl"}, constant_base("mīlle")},
-- match ea
{"^(ea)$", typ, {}, constant_base("is")},
-- match id
{"^(id)$", typ, {}, constant_base("is")},
-- match plural eī, iī
{"^([ei]ī)$", typ, {"pl"}, constant_base("is")},
-- match plural ea, eae
{"^(eae?)$", typ, {"pl"}, constant_base("is")},
-- match eadem
{"^(eadem)$", typ, {}, constant_base("īdem")},
-- match īdem, idem
{"^([īi]dem)$", typ, {}, constant_base("īdem")},
-- match plural īdem
{"^(īdem)$", typ, {"pl"}},
-- match plural eadem, eaedem
{"^(eae?dem)$", typ, {"pl"}, constant_base("īdem")},
-- match illa, ipsa, ista; it doesn't matter if we overmatch because
-- we'll get an error as we use the stem itself in the returned base
{"^(i[lps][lst])a$", typ, {}, function(base, stem2) return base .. "e", nil end},
-- match illud, istud; as above, it doesn't matter if we overmatch
{"^(i[ls][lt])ud$", typ, {}, function(base, stem2) return base .. "e", nil end},
-- match ipsum
{"^(ipsum)$", typ, {}, constant_base("ipse")},
-- match plural illī, ipsī, istī; as above, it doesn't matter if we
-- overmatch
{"^(i[lps][lst])ī$", typ, {"pl"}, function(base, stem2) return base .. "e", nil end},
-- match plural illa, illae, ipsa, ipsae, ista, istae; as above, it
-- doesn't matter if we overmatch
{"^(i[lps][lst])ae?$", typ, {"pl"}, function(base, stem2) return base .. "e", nil end},
-- Detect quī as non-plural unless .pl specified.
{"^(quī)$", typ, {}},
-- Otherwise detect quī as plural.
{"^(quī)$", typ, {"pl"}},
-- Same for quae.
{"^(quae)$", typ, {}, constant_base("quī")},
{"^(quae)$", typ, {"pl"}, constant_base("quī")},
{"^(quid)$", typ, {}, constant_base("quis")},
{"^(quod)$", typ, {}, constant_base("quī")},
{"^(qui[cd]quid)$", typ, {}, constant_base("quisquis")},
{"^(quīquī)$", typ, {"pl"}, constant_base("quisquis")},
{"^(quaequae)$", typ, {"pl"}, constant_base("quisquis")},
-- match all remaining lemmas in lemma form
{"", typ, {}},
})
elseif typ == "indecl+" then
return get_adj_type_and_subtype_by_ending(lemma, stem2, typ, subtypes, {
{"", typ, {"both"}},
{"", typ, {"sg"}},
{"", typ, {"pl"}},
})
else -- 0+
return lemma, nil, typ, {}
end
end
local noun_lb = {
nom_sg = "sg.",
gen_sg = "sg.",
dat_sg = "sg.",
acc_sg = "sg.",
abl_sg = "sg.",
voc_sg = "sg.",
loc_sg = "sg.",
nom_pl = "pl.",
gen_pl = "pl.",
dat_pl = "pl.",
acc_pl = "pl.",
abl_pl = "pl.",
voc_pl = "pl.",
loc_pl = "pl."
}
function export.sust(frame)
local title_ = mw.title.getCurrentTitle()
local title = title_.fullText
local ns = title_.namespace
if ns ~= 0 then
return "Use esta plantilla en el espacio principal."
end
local params = {
[1] = {requerido=true},
["alt"] = {},
["num"] = {por_defecto = ""},
["núm"] = {alias_de = "num"},
["nota"] = {},
}
for form,_ in pairs(noun_lb) do
params[form] = {lista=true}
end
local parent_frame = frame:getParent()
local args = require("Módulo:parámetros").obtener_parametros(parent_frame.args, params)
local tpalabras = {}
for _,p in ipairs(args) do
p = match(p, "^(.-);") or p
local a, b = match(p, "^(.-)%.(.*)$")
assert(b, "error en especificaciones de palabra")
local r1 = match(a, "^([^/]+)/")
if not r1 then
r1 = a
end
if r1 == "idem" or r1 == "īdem" then -- REVISAR: parche para idem que internamente lo declina como si fuera "i"
insert(tpalabras, "ī")
else
insert(tpalabras, r1)
end
end
local palabras, separadores = separar_palabras(title, concat(tpalabras, "-"))
local L = #palabras
local M = 1
local declinfo
local titles = {}
local cats = {}
local genero
local nosg, nopl = true, true
for _,arg in ipairs(args) do
local formas = {}
for subarg in gsplit(arg, ";") do
local types = {}
local a, b = match(subarg, "^(.-)%.(.*)$")
assert(b, "error en especificaciones de palabra")
local c, d = match(b, "^(.-)%.(.*)$")
if d then
for spec in gsplit(d, "%.") do
spec = gsub(spec, "(.)%-", "%1_")
types[spec] = true
end
end
c = c or b
local r = split(a, "/")
local r1, r2, detected_subtypes = detect_noun_subtype(r[1], r[2], c, types)
for _, subtype in ipairs(detected_subtypes) do
if types["-" .. subtype] then
-- if a "cancel subtype" spec is given, remove the cancel spec
-- and don't apply the subtype
types["-" .. subtype] = nil
elseif (subtype == "M" or subtype == "F" or subtype == "N") and
(types.M or types.F or types.N) then
-- if gender already specified, don't create conflicting gender spec
elseif (subtype == "sg" or subtype == "pl" or subtype == "both") and
(types.sg or types.pl or types.both) then
-- if number restriction already specified, don't create conflicting
-- number restriction spec
else
types[subtype] = true
end
end
if not genero then
if types.M then
genero = "m"
end
if types.N then
genero = "n"
end
if types.F then
genero = "f"
end
end
local es_adj
if not r1 and genero then
local typ
r1, r2, typ, detected_subtypes = detect_adj_type_and_subtype(r[1], r[2], c, types)
if r1 then
c = typ
es_adj = true
end
end
assert(r1, "forma no reconocida: "..r[1])
local cb = es_adj and adj_decl[c] or noun_decl[c]
assert(cb, "Especifique el tipo de sustantivo correcto en el primer parámetro")
local data = {forms={}, types=types, pos="", subtitles="", notes="", categories=cats, title=titles, loc=types.loc, num=args.num}
cb(data, {r1, r2})
if es_adj then
local forms_ = {}
for form,arr in pairs(data.forms) do
local f1, f2 = form:match("^(.*)(_"..genero..")$")
if f1 then
forms_[f1] = arr
end
end
data.forms = forms_
end
if not types.sg then
nopl = false
end
if not types.pl then
nosg = false
end
if types.sg then
for key,_ in pairs(data.forms) do
if key:find("_pl") then
data.forms[key] = {}
end
end
end
if types.pl then
for key,_ in pairs(data.forms) do
if key:find("_sg") then
data.forms[key] = {}
end
end
end
merge_forms(formas, data.forms, noun_lb)
end
if not declinfo then
declinfo = formas
else
declinfo = combinar_copulativa(declinfo, formas, separadores[M])
M = M + 1
end
end
if declinfo["loc_sg"] and #declinfo["loc_sg"] == 0 then
declinfo["loc_sg"] = nil
end
if declinfo["loc_pl"] and #declinfo["loc_pl"] == 0 then
declinfo["loc_pl"] = nil
end
if nosg == false then
nosg = find(args["num"], "p")
end
if nopl == false then
nopl = find(args["num"], "s")
end
local forms = sobreescribir_formas(declinfo, args, false, {})
comprobar_defectivo(forms, {})
forms = desactivar_formas(forms,
function (form)
return (form:find("pl$") and nopl) or (form:find("sg$") and nosg)
end
)
local raiz_nom = f(forms["nom_sg"][1] or forms["nom_pl"][1] or "?")
local raiz_gen = f(forms["gen_sg"][1] or forms["gen_pl"][1] or "?")
forms = agregar_enlaces(forms, title, normalizar_enlace)
forms = formatear_formas(forms, noun_lb)
local t = {}
insert(t, {{""}, {"Singular"}, {"Plural"}, header=true, color=COLOR_H, class="pc"})
insert(t, {{"Nominativo", header=true, color=COLOR_H}, forms["nom_sg"], forms["nom_pl"]})
insert(t, {{"Genitivo", header=true, color=COLOR_H}, forms["gen_sg"], forms["gen_pl"]})
insert(t, {{"Dativo", header=true, color=COLOR_H}, forms["dat_sg"], forms["dat_pl"]})
insert(t, {{"Acusativo", header=true, color=COLOR_H}, forms["acc_sg"], forms["acc_pl"]})
insert(t, {{"Ablativo", header=true, color=COLOR_H}, forms["abl_sg"], forms["abl_pl"]})
insert(t, {{"Vocativo", header=true, color=COLOR_H}, forms["voc_sg"], forms["voc_pl"]})
if (forms["loc_sg"] and forms["loc_sg"][1]) or (forms["loc_pl"] and forms["loc_pl"][1]) then
insert(t, {{"Locativo", header=true, color=COLOR_H}, forms["loc_sg"], forms["loc_pl"]})
end
insert(t, {{args["nota"] or "", colspan=3}})
return renderizar_tabla(
frame,
"'''Declinación de ''"..raiz_nom..", "..raiz_gen.."'''''  tipo: "..concat(titles, ", "),
t,
ns == 0 and cats or {}
)
end
local adj_lb = {
nom_sg_m = "m.",
nom_sg_n = "n.",
nom_sg_f = "f.",
nom_pl_m = "m.",
nom_pl_n = "n.",
nom_pl_f = "f.",
gen_sg_m = "m.",
gen_sg_n = "n.",
gen_sg_f = "f.",
gen_pl_m = "m.",
gen_pl_n = "n.",
gen_pl_f = "f.",
dat_sg_m = "m.",
dat_sg_n = "n.",
dat_sg_f = "f.",
dat_pl_m = "m.",
dat_pl_n = "n.",
dat_pl_f = "f.",
acc_sg_m = "m.",
acc_sg_n = "n.",
acc_sg_f = "f.",
acc_pl_m = "m.",
acc_pl_n = "n.",
acc_pl_f = "f.",
abl_sg_m = "m.",
abl_sg_n = "n.",
abl_sg_f = "f.",
abl_pl_m = "m.",
abl_pl_n = "n.",
abl_pl_f = "f.",
voc_sg_m = "m.",
voc_sg_n = "n.",
voc_sg_f = "f.",
voc_pl_m = "m.",
voc_pl_n = "n.",
voc_pl_f = "f.",
}
function export.adj(frame)
local title_ = mw.title.getCurrentTitle()
local title = title_.fullText
local ns = title_.namespace
if ns ~= 0 then
return "Use esta plantilla en el espacio principal."
end
local params = {
[1] = {requerido=true},
["alt"] = {},
["num"] = {por_defecto = ""},
["núm"] = {alias_de="num"},
["gen"] = {por_defecto="mfn"},
["nota"] = {},
}
for form,_ in pairs(adj_lb) do
params[form] = {lista=true}
end
params["dat_pl"] = {lista=true}
params["abl_pl"] = {lista=true}
params["loc_pl"] = {lista=true}
local parent_frame = frame:getParent()
local args = require("Módulo:parámetros").obtener_parametros(parent_frame.args, params)
if args["dat_pl"][1] then
args["dat_pl_m"] = deep_copy(args["dat_pl"])
args["dat_pl_n"] = deep_copy(args["dat_pl"])
args["dat_pl_f"] = deep_copy(args["dat_pl"])
end
if args["abl_pl"][1] then
args["abl_pl_m"] = deep_copy(args["abl_pl"])
args["abl_pl_n"] = deep_copy(args["abl_pl"])
args["abl_pl_f"] = deep_copy(args["abl_pl"])
end
if args["loc_pl"][1] then
args["loc_pl_m"] = deep_copy(args["loc_pl"])
args["loc_pl_n"] = deep_copy(args["loc_pl"])
args["loc_pl_f"] = deep_copy(args["loc_pl"])
end
args["dat_pl"] = nil
args["abl_pl"] = nil
args["loc_pl"] = nil
assert(not find(title, " "), "locuciones no soportadas aún") -- REVISAR
local tpalabras = {}
for _,p in ipairs(args) do
p = match(p, "^(.-);") or p
local a, b = match(p, "^(.-)%.(.*)$")
assert(b, "error en especificaciones de palabra")
local r1 = match(a, "^([^/]+)/")
if not r1 then
r1 = a
end
if r1 == "idem" or r1 == "īdem" then -- REVISAR: parche para idem que internamente lo declina como si fuera "i"
insert(tpalabras, "ī")
else
insert(tpalabras, r1)
end
end
local palabras, separadores = separar_palabras(title, concat(tpalabras, "-"))
local L = #palabras
local M = 1
local declinfo
local titles = {}
local cats = {}
local nosg, nopl = true, true
for _,arg in ipairs(args) do
local formas = {}
for subarg in gsplit(arg, ";") do
local types = {}
local a, b = match(subarg, "^(.-)%.(.*)$")
a = a or subarg
b = b or "+"
local c, d = match(b, "^(.-)%.(.*)$")
if d then
for spec in gsplit(d, "%.") do
spec = gsub(spec, "(.)%-", "%1_")
types[spec] = true
end
end
c = c or b
local r = split(a, "/")
local r1, r2, typ, detected_subtypes = detect_adj_type_and_subtype(r[1], r[2], c, types)
for _, subtype in ipairs(detected_subtypes) do
if types["-" .. subtype] then
-- if a "cancel subtype" spec is given, remove the cancel spec
-- and don't apply the subtype
types["-" .. subtype] = nil
elseif (subtype == "M" or subtype == "F" or subtype == "N") and
(types.M or types.F or types.N) then
-- if gender already specified, don't create conflicting gender spec
elseif (subtype == "sg" or subtype == "pl" or subtype == "both") and
(types.sg or types.pl or types.both) then
-- if number restriction already specified, don't create conflicting
-- number restriction spec
else
types[subtype] = true
end
end
local cb = adj_decl[typ]
assert(cb, "Especifique el tipo de sustantivo correcto en el primer parámetro")
local data = {forms={}, types=types, pos="", subtitles="", notes="", categories=cats, title=titles, loc=types.loc, num=args.num}
cb(data, {r1, r2})
local formas_ = {} -- necesario crear otro arreglo para no modificar las claves durante la iteración
for form,arr in pairs(data.forms) do
local pref = match(form, "^(.*)_m$")
if pref and not data.forms[pref.."_f"] then
formas_[pref.."_f"] = deep_copy(arr)
end
if pref and not data.forms[pref.."_n"] then
formas_[pref.."_n"] = deep_copy(arr)
end
formas_[form] = arr
end
data.forms = formas_
if not types.sg then
nopl = false
end
if not types.pl then
nosg = false
end
if types.sg then
for key,_ in pairs(data.forms) do
if key:find("_pl") then
data.forms[key] = {}
end
end
end
if types.pl then
for key,_ in pairs(data.forms) do
if key:find("_sg") then
data.forms[key] = {}
end
end
end
merge_forms(formas, data.forms, adj_lb)
end
if not declinfo then
declinfo = formas
else
declinfo = combinar_copulativa(declinfo, formas, separadores[M])
M = M + 1
end
end
if nosg == false then
nosg = find(args["num"], "p")
end
if nopl == false then
nopl = find(args["num"], "s")
end
local m = find(args["gen"], "m")
local fem = find(args["gen"], "f")
local n = find(args["gen"], "n")
local forms = sobreescribir_formas(declinfo, args, false, {}, adj_lb)
comprobar_defectivo(forms)
forms = desactivar_formas(forms,
function (form)
return (form:find("pl") and nopl) or (form:find("sg") and nosg) or (form:find("m$") and not m) or (form:find("f$") and not fem) or (form:find("n$") and not n)
end
)
local raiz_m = f(forms["nom_sg_m"][1] or forms["nom_pl_m"][1] or "?")
local raiz_f = f(forms["nom_sg_f"][1] or forms["nom_pl_f"][1] or "?")
local raiz_n = f(forms["nom_sg_n"][1] or forms["nom_pl_n"][1] or "?")
forms = agregar_enlaces(forms, title, normalizar_enlace)
forms = formatear_formas(forms, adj_lb)
local t = {}
insert(t, {{"Singular", colspan=4}, header=true, color=COLOR_H})
insert(t, {{""}, {"Masculino"}, {"Femenino"}, {"Neutro"}, header=true, color=COLOR_H, class="pc"})
insert(t, {{"Nominativo", header=true, color=COLOR_H}, forms["nom_sg_m"], forms["nom_sg_f"], forms["nom_sg_n"]})
insert(t, {{"Genitivo", header=true, color=COLOR_H}, forms["gen_sg_m"], forms["gen_sg_f"], forms["gen_sg_n"]})
insert(t, {{"Dativo", header=true, color=COLOR_H}, forms["dat_sg_m"], forms["dat_sg_f"], forms["dat_sg_n"]})
insert(t, {{"Acusativo", header=true, color=COLOR_H}, forms["acc_sg_m"], forms["acc_sg_f"], forms["acc_sg_n"]})
insert(t, {{"Ablativo", header=true, color=COLOR_H}, forms["abl_sg_m"], forms["abl_sg_f"], forms["abl_sg_n"]})
insert(t, {{"Vocativo", header=true, color=COLOR_H}, forms["voc_sg_m"], forms["voc_sg_f"], forms["voc_sg_n"]})
insert(t, {{"Plural", colspan=4, header=true, color=COLOR_H}})
insert(t, {{""}, {"Masculino"}, {"Femenino"}, {"Neutro"}, header=true, color=COLOR_H, class="pc"})
insert(t, {{"Nominativo", header=true, color=COLOR_H}, forms["nom_pl_m"], forms["nom_pl_f"], forms["nom_pl_n"]})
insert(t, {{"Genitivo", header=true, color=COLOR_H}, forms["gen_pl_m"], forms["gen_pl_f"], forms["gen_pl_n"]})
insert(t, {{"Dativo", header=true, color=COLOR_H}, forms["dat_pl_m"], forms["dat_pl_f"], forms["dat_pl_n"]})
insert(t, {{"Acusativo", header=true, color=COLOR_H}, forms["acc_pl_m"], forms["acc_pl_f"], forms["acc_pl_n"]})
insert(t, {{"Ablativo", header=true, color=COLOR_H}, forms["abl_pl_m"], forms["abl_pl_f"], forms["abl_pl_n"]})
insert(t, {{"Vocativo", header=true, color=COLOR_H}, forms["voc_pl_m"], forms["voc_pl_f"], forms["voc_pl_n"]})
insert(t, {{args["nota"] or "", colspan=4}})
return renderizar_tabla(
frame,
"'''Declinación de ''"..raiz_m..", "..raiz_f..", "..raiz_n.."'''''  tipo: "..concat(titles, ", "),
t,
ns == 0 and cats or {}
)
end
local EGO, TU, IS, NOS, VOS, EI = 1, 2, 3, 4, 5, 6
local tostr = {"1", "2", "3", "4", "5", "6"}
local PRONOMBRES = {"ego", "tū", "is, ea, id", "nōs", "vōs", "eī, eae, ea"}
local PRONOMBRES_SUBJ = {"ut ego", "ut tū", "ut is, ut ea, ut id", "ut nōs", "ut vōs", "ut eī, ut eae, ut ea"}
local PRONOMBRES_IMP = {"―", "(tū)", "(is, ea, id)", "―", "(vōs)", "(eī, eae, ea)"}
local IMPERSONALES = {"", "", "(id)", "", "", ""}
local function obtener_pronombre(forma, impers)
local conj, p = match(forma, "^(.*)(%d)$")
if not p then
return nil
end
p = tonumber(p)
if impers then
return IMPERSONALES[p]
else
if find(conj, "^subj") then
return PRONOMBRES_SUBJ[p]
end
if find(conj, "^imper") then
return PRONOMBRES_IMP[p]
end
return PRONOMBRES[p]
end
end
local sufijos = {
["1"] = {
inf_act = {"āre","isse"},
inf_pas = {"ārī"},
part_act = {"āns","ūrus"},
part_pas = {"andus","us"},
ger = {"andī","andō","andum"},
sup = {"um","ū"},
ind_pres = {"ō","ās","at","āmus","ātis","ant"},
ind_imp = {"ābam","ābās","ābat","ābāmus","ābātis","ābant"},
ind_perf = {"ī","istī","it","imus","istis","ērunt",
nil,nil,nil,nil,nil,"ēre"},
ind_pluperf = {"eram","erās","erat","erāmus","erātis","erant"},
ind_fut = {"ābō","ābis","ābit","ābimus","ābitis","ābunt"},
ind_fut_perf = {"erō","eris","erit","erimus","eritis","erint"},
ind_fut_sig = {"ō","is","it","imus","itis","int"},
ind_pres_pas = {"or","āris","ātur","āmur","āminī","antur",
nil,"āre"},
ind_imp_pas = {"ābar","ābāris","ābātur","ābāmur","ābāminī","ābantur",
nil,"ābāre"},
ind_fut_pas = {"ābor","āberis","ābitur","ābimur","ābiminī","ābuntur",
nil,"ābere"},
subj_pres = {"em","ēs","et","ēmus","ētis","ent"},
subj_imp = {"ārem","ārēs","āret","ārēmus","ārētis","ārent"},
subj_perf = {"erim","erīs","erit","erīmus","erītis","erint"},
subj_pluperf = {"issem","issēs","isset","issēmus","issētis","issent"},
subj_aor_sig = {"im","īs","īt","īmus","ītis","int"},
subj_pres_pas = {"er","ēris","ētur","ēmur","ēminī","entur",
nil,"ēre"},
subj_imp_pas = {"ārer","ārēris","ārētur","ārēmur","ārēminī","ārentur",
nil,"ārēre"},
imper_pres = {nil,"ā",nil,nil,"āte",nil},
imper_fut = {nil,"ātō","ātō",nil,"ātōte","antō"},
imper_pres_pas = {nil,"āre",nil,nil,"āminī",nil},
imper_fut_pas = {nil,"ātor","ātor",nil,nil,"antor"},
},
["2"] = {
inf_act = {"ēre","isse"},
inf_pas = {"ērī"},
part_act = {"ēns","ūrus"},
part_pas = {"endus","us"},
ger = {"endī","endō","endum"},
sup = {"um","ū"},
ind_pres = {"eō","ēs","et","ēmus","ētis","ent"},
ind_imp = {"ēbam","ēbās","ēbat","ēbāmus","ēbātis","ēbant"},
ind_perf = {"ī","istī","it","imus","istis","ērunt",
nil,nil,nil,nil,nil,"ēre"},
ind_pluperf = {"eram","erās","erat","erāmus","erātis","erant"},
ind_fut = {"ēbō","ēbis","ēbit","ēbimus","ēbitis","ēbunt"},
ind_fut_perf = {"erō","eris","erit","erimus","eritis","erint"},
ind_fut_sig = {"ō","is","it","imus","itis","int"},
ind_pres_pas = {"eor","ēris","ētur","ēmur","ēminī","entur",
nil,"ēre"},
ind_imp_pas = {"ēbar","ēbāris","ēbātur","ēbāmur","ēbāminī","ēbantur",
nil,"ēbāre"},
ind_fut_pas = {"ēbor","ēberis","ēbitur","ēbimur","ēbiminī","ēbuntur",
nil,"ēbere"},
subj_pres = {"eam","eās","eat","eāmus","eātis","eant"},
subj_imp = {"ērem","ērēs","ēret","ērēmus","ērētis","ērent"},
subj_perf = {"erim","erīs","erit","erīmus","erītis","erint"},
subj_pluperf = {"issem","issēs","isset","issēmus","issētis","issent"},
subj_aor_sig = {"im","īs","īt","īmus","ītis","int"},
subj_pres_pas = {"ear","eāris","eātur","eāmur","eāminī","eantur",
nil,"eāre"},
subj_imp_pas = {"ērer","ērēris","ērētur","ērēmur","ērēminī","ērentur",
nil,"ērēre"},
imper_pres = {nil,"ē",nil,nil,"ēte",nil},
imper_fut = {nil,"ētō","ētō",nil,"ētōte","entō"},
imper_pres_pas = {nil,"ēre",nil,nil,"ēminī",nil},
imper_fut_pas = {nil,"ētor","ētor",nil,nil,"entor"},
},
["3"] = { -- 3 (comparar [[capio]] con [[lego]], las raíces con capi- y leg- pero hay que eliminar la doble ii)
inf_act = {"ere","isse"},
inf_pas = {"ī"},
part_act = {"ēns","ūrus"},
part_pas = {"endus","us"},
ger = {"endī","endō","endum"},
sup = {"um","ū"},
ind_pres = {"ō","is","it","imus","itis","unt"},
ind_imp = {"ēbam","ēbās","ēbat","ēbāmus","ēbātis","ēbant"},
ind_perf = {"ī","istī","it","imus","istis","ērunt",
nil,nil,nil,nil,nil,"ēre"},
ind_pluperf = {"eram","erās","erat","erāmus","erātis","erant"},
ind_fut = {"am","ēs","ēt","ēmus","ētis","ent"},
ind_fut_perf = {"erō","eris","erit","erimus","eritis","erint"},
ind_fut_sig = {"ō","is","it","imus","itis","int"},
ind_pres_pas = {"or","eris","itur","imur","iminī","untur",
nil,"ere"},
ind_imp_pas = {"ēbar","ēbāris","ēbātur","ēbāmur","ēbāminī","ēbantur",
nil,"ēbāre"},
ind_fut_pas = {"ar","ēris","ētur","ēmur","ēminī","entur",
nil,"ēre"},
subj_pres = {"am","ās","at","āmus","ātis","ant"},
subj_imp = {"erem","erēs","eret","erēmus","erētis","erent"},
subj_perf = {"erim","erīs","erit","erīmus","erītis","erint"},
subj_pluperf = {"issem","issēs","isset","issēmus","issētis","issent"},
subj_aor_sig = {"im","īs","īt","īmus","ītis","int"},
subj_pres_pas = {"ar","āris","ātur","āmur","āminī","antur",
nil,"āre"},
subj_imp_pas = {"erer","erēris","erētur","erēmur","erēminī","erentur",
nil,"erēre"},
imper_pres = {nil,"e",nil,nil,"ite",nil},
imper_fut = {nil,"itō","itō",nil,"itōte","untō"},
imper_pres_pas = {nil,"ere",nil,nil,"iminī",nil},
imper_fut_pas = {nil,"itor","itor",nil,nil,"untor"},
},
["3/4"] = {
inf_act = {"ere","isse","īre","isse"},
inf_pas = {"ī","īrī"},
part_act = {"ēns","iēns","ūrus"},
part_pas = {"endus","iendus","us"},
ger = {"endī","endō","endum","iendī","iendō","iendum"},
sup = {"um","ū"},
ind_pres = {"ō","is","it","imus","itis","unt",
"iō","īs",nil,"īmus","ītis","iunt"
},
ind_imp = {"ēbam","ēbās","ēbat","ēbāmus","ēbātis","ēbant",
"iēbam","iēbās","iēbat","iēbāmus","iēbātis","iēbant"
},
ind_perf = {"ī","istī","it","imus","istis","ērunt",
nil,nil,nil,nil,nil,"ēre"},
ind_pluperf = {"eram","erās","erat","erāmus","erātis","erant"},
ind_fut = {"am","ēs","ēt","ēmus","ētis","ent",
"iam","iēs","iet","iēmus","iētis","ient"
},
ind_fut_perf = {"erō","eris","erit","erimus","eritis","erint"},
ind_fut_sig = {"ō","is","it","imus","itis","int"},
ind_pres_pas = {"or","eris","itur","imur","iminī","untur",
"ior","ere","ītur","īmur","īminī","iuntur",
nil,"īris",nil,nil,nil,nil,
nil,"īre"
},
ind_imp_pas = {"ēbar","ēbāris","ēbātur","ēbāmur","ēbāminī","ēbantur",
"iēbar","ēbāre","iēbātur","iēbāmur","iēbāminī","iēbantur",
nil,"iēbāris",nil,nil,nil,nil,
nil,"iēbāre"
},
ind_fut_pas = {"ar","ēris","ētur","ēmur","ēminī","entur",
"iar","ēre","iētur","iēmur","iēminī","ientur",
nil,"iēris",nil,nil,nil,nil,
nil,"iēre"
},
subj_pres = {"am","ās","at","āmus","ātis","ant",
"iam","iās","iat","iāmus","iātis","iant",
},
subj_imp = {"erem","erēs","eret","erēmus","erētis","erent",
"īrem","īrēs","īret","īrēmus","īrētis","īrent"
},
subj_perf = {"erim","erīs","erit","erīmus","erītis","erint"},
subj_pluperf = {"issem","issēs","isset","issēmus","issētis","issent"},
subj_aor_sig = {"im","īs","īt","īmus","ītis","int"},
subj_pres_pas = {"ar","āris","ātur","āmur","āminī","antur",
"iar","āre","iātur","iāmur","iāminī","iantur",
nil,"iāris",nil,nil,nil,nil,
nil,"iāre"
},
subj_imp_pas = {"erer","erēris","erētur","erēmur","erēminī","erentur",
"īrer","erēre","īrētur","īrēmur","īrēminī","īrentur",
nil,"īrēris",nil,nil,nil,nil,
nil,"īrēre"
},
imper_pres = {nil,"e",nil,nil,"ite",nil,
nil,"ī",nil,nil,"īte",nil
},
imper_fut = {nil,"itō","itō",nil,"itōte","untō",
nil,"ītō","ītō",nil,"ītōte","iuntō"
},
imper_pres_pas = {nil,"ere",nil,nil,"iminī",nil,
nil,"īre",nil,nil,"īminī",nil
},
imper_fut_pas = {nil,"itor","itor",nil,nil,"untor",
nil,"ītor","ītor",nil,nil,"iuntor"
},
},
["4"] = {
inf_act = {"īre","isse"},
inf_pas = {"īrī"},
part_act = {"iēns","ūrus"},
part_pas = {"iendus","us"},
ger = {"iendī","iendō","iendum"},
sup = {"um","ū"},
ind_pres = {"iō","īs","it","īmus","ītis","iunt"},
ind_imp = {"iēbam","iēbās","iēbat","iēbāmus","iēbātis","iēbant"},
ind_perf = {"ī","istī","it","imus","istis","ērunt",
nil,nil,nil,nil,nil,"ēre"},
ind_pluperf = {"eram","erās","erat","erāmus","erātis","erant"},
ind_fut = {"iam","iēs","iet","iēmus","iētis","ient"},
ind_fut_perf = {"erō","eris","erit","erimus","eritis","erint"},
ind_fut_sig = {"ō","is","it","imus","itis","int"},
ind_pres_pas = {"ior","īris","ītur","īmur","īminī","iuntur",
nil,"īre"},
ind_imp_pas = {"iēbar","iēbāris","iēbātur","iēbāmur","iēbāminī","iēbantur",
nil,"iēbāre"},
ind_fut_pas = {"iar","iēris","iētur","iēmur","iēminī","ientur",
nil,"iēre"},
subj_pres = {"iam","iās","iat","iāmus","iātis","iant"},
subj_imp = {"īrem","īrēs","īret","īrēmus","īrētis","īrent"},
subj_perf = {"erim","erīs","erit","erīmus","erītis","erint"},
subj_pluperf = {"issem","issēs","isset","issēmus","issētis","issent"},
subj_aor_sig = {"im","īs","īt","īmus","ītis","int"},
subj_pres_pas = {"iar","iāris","iātur","iāmur","iāminī","iantur",
nil,"iāre"},
subj_imp_pas = {"īrer","īrēris","īrētur","īrēmur","īrēminī","īrentur",
nil,"īrēre"},
imper_pres = {nil,"ī",nil,nil,"īte",nil},
imper_fut = {nil,"ītō","ītō",nil,"ītōte","iuntō"},
imper_pres_pas = {nil,"īre",nil,nil,"īminī",nil},
imper_fut_pas = {nil,"ītor","ītor",nil,nil,"iuntor"},
}
}
local formas_no_personales = {
inf_act = true,
inf_pas = true,
part_act = true,
part_pas = true,
ger = true,
sup = true,
}
local formas_personales = {
ind_pres = true,
ind_imp = true,
ind_perf = true,
ind_pluperf = true,
ind_fut = true,
ind_fut_perf = true,
ind_fut_sig = true,
ind_pres_pas = true,
ind_imp_pas = true,
ind_fut_pas = true,
subj_pres = true,
subj_imp = true,
subj_perf = true,
subj_pluperf = true,
subj_aor_sig = true,
subj_pres_pas = true,
subj_imp_pas = true,
imper_pres = true,
imper_fut = true,
imper_pres_pas = true,
imper_fut_pas = true,
}
local formas = merge(formas_no_personales, formas_personales)
local verbos_irregulares = {
{"aiō", {"aiō", "aiiō", "aijō", "ajō"}, {
desactivar = {"inf_pas","part_pas","ger","sup","ind_pluperf","ind_fut","ind_fut_perf",
"ind_pres_pas","ind_imp_pas","ind_fut_pas","subj_perf","subj_pluperf","subj_pres_pas",
"subj_imp_pas","imper_fut","imper_pres_pas","imper_fut_pas"
},
conj = "3",
nucleopres = {"ai"},
nucleoperf = {"a"},
nucleosup = {},
nucleosigm = {},
inf_act = {"aiere"},
ind_pres = {nil,nil,nil,{}},
ind_perf = {{},nil,nil,{},{}},
subj_pres = {nil,nil,nil,{},{}},
subj_imp = {{},{},nil,{},{},{}},
imper_pres = {{},{"ai"},{},{},{},{}},
}},
{"cedo", {"cedo"}, {
desactivar = {"inf_act","inf_pas","part_act","part_pas","ger","sup","ind_pluperf","ind_pres","ind_imp","ind_perf",
"ind_fut","ind_fut_perf","ind_pres_pas","ind_imp_pas","ind_fut_pas","subj_pres","subj_imp","subj_perf",
"subj_pluperf","subj_pres_pas","subj_imp_pas","imper_fut","imper_pres_pas","imper_fut_pas"
},
conj = "3",
nucleopres = {},
nucleoperf = {},
nucleosup = {},
nucleosigm = {},
imper_pres = {nil,{"cedo"},nil,nil,{"cette","cedile"},nil},
}},
{"dīcō", {"dīcō"}, {
conj = "3",
nucleopres = {"dīc"},
nucleoperf = {"dīx"},
nucleosup = {"dict"},
nucleosigm = {"dīx"},
desactivar = {},
imper_pres = {nil, {"dīc", "dīce"}},
inf_pas = {"dīcī", "dīcier{L}"},
}},
{"dō", {"dō"}, {
conj = "1",
nucleopres = {"d"},
nucleoperf = {"ded"},
nucleosup = {"dat"},
nucleosigm = {},
desactivar = {},
inf_act = {"dare","dedisse"},
inf_pas = {"darī"},
ind_pres = {nil,nil,nil,{"damus"},{"datis"},nil},
ind_imp = {{"dabam"},{"dabās"},{"dabat"},{"dabāmus"},{"dabātis"},{"dabant"}},
ind_fut = {{"dabō"},{"dabis"},{"dabit"},{"dabimus"},{"dabitis"},{"dabunt"}},
ind_imp_pas = {{"dabar"},{"dabāris","dabāre"},{"dabātur"},{"dabāmur"},{"dabāminī"},{"dabantur"}},
ind_fut_pas = {{"dabor"},{"daberis","dabere"},{"dabitur"},{"dabimur"},{"dabiminī"},{"dabuntur"}},
subj_imp = {{"darem"},{"darēs"},{"daret"},{"darēmus"},{"darētis"},{"darent"}},
subj_imp_pas = {{"darer"},{"darēris","darēre"},{"darētur"},{"darēmur"},{"darēminī"},{"darentur"}},
imper_pres = {nil,nil,nil,nil,{"date"},nil},
imper_fut = {nil,{"datō"},{"datō"},nil,{"datōte"},{"dantō"}},
imper_pres_pas = {nil,{"dare"},nil,nil,{"daminī"},nil},
imper_fut_pas = {nil,{"dator"},{"dator"},nil,nil,{"dator"}},
}},
{"dūcō", {"dūcō"}, {
conj = "3",
nucleopres = {"dūc"},
nucleoperf = {"dūx"},
nucleosup = {"duct"},
nucleosigm = {},
desactivar = {},
imper_pres = {nil, {"dūc", "dūce"}},
}},
{"edō", {"edō", "ëdō"}, {
conj = "3",
nucleopres = {"ed"},
nucleoperf = {"ed"},
nucleosup = {""},
nucleosigm = {},
desactivar = {},
inf_act = {"edere","ēsse"},
part_act = {"edēns","ēsūrus","ēssūrus","ēstūrus"},
part_pas = {"edendus","edundus","ēsus","ēssus","ēstus"},
sup = {"ēsum","ēssum","ēstum","ēsū","ēssū","ēstū"},
ind_pres = {nil,{"edis","ēs"},{"edit","ēst"},nil,{"editis","ēstis"},nil},
ind_pres_pas = {nil,{"ederis","edere","ēssis","ēsse"},{"editur","ēstur"}},
subj_pres = {{"edam","edim"},{"edās","edīs"},{"edat","edit","ēst"},{"edāmus","edīmus"},{"edātis","edītis"},{"edant","edint"}},
subj_imp = {{"ederem","ēssem"},{"ederēs","ēssēs"},{"ederet","ēsset"},{"ederēmus","ēssēmus"},{"ederētis","ēssētis"},{"ederent","ēssent"}},
subj_imp_pas = {{"ederer","ēsser"},{"ederēris","ederēre","ēssēris","ēssēre"},{"ederetur","ēssetur"},{"ederēmur","ēssēmur"},{"ederēminī","ēssēminī"},{"ederentur","ēssentur"}},
imper_pres = {nil,{"ede","ēs"},nil,nil,{"edite","ēste"},nil},
imper_fut = {nil,{"editō","ēstō"},{"editō","ēstō"},nil,{"editōte","ēstōte"},{"eduntō"}},
imper_pres_pas = {nil,{"edere","ēsse"},nil,nil,{"ediminī"},nil},
imper_fut_pas = {nil,{"editor","ēstor"},{"editor","ēstor"},nil,nil,{"eduntor"}},
}},
{"eō", {"eō", "ëō"}, {
conj = "4",
nucleopres = {""},
nucleoperf = {""},
nucleosup = {""},
nucleosigm = {},
desactivar = {"imper_pres_pas"},
inf_act = {"īre","īsse","iisse","īvisse"},
inf_pas = {"īrī","īrier"},
part_act = {"iēns","itūrus"},
part_pas = {"eundum","itum"},
ger = {"eundī","eundō","eundum"},
sup = {"itum","itū"},
ind_pres = {{"eō"},{"īs"},{"it"},{"īmus"},{"ītis"},{"eunt"}},
ind_imp = {{"ībam"},{"ībās"},{"ībat"},{"ībāmus"},{"ībātis"},{"ībant"}},
ind_perf = {{"iī","īvī"},{"īstī","iistī","īvistī"},{"iit","īvit"},{"iimus","īvimus"},{"īstis","iistis","īvistis"},{"iērunt","iēre","īvērunt","īvēre"}},
ind_pluperf = {{"ieram","īveram"},{"ierās","īverās"},{"ierat","īverat"},{"ierāmus","īverāmus"},{"ierātis","īverātis"},{"ierant","īverant"}},
ind_fut = {{"ībō"},{"ībis"},{"ībit"},{"ībimus"},{"ībitis"},{"ībunt"}},
ind_fut_perf = {{"ierō","īverō"},{"ieris","īveris"},{"ierit","īverit"},{"ierimus","īverimus"},{"ieritis","īveritis"},{"ierint","īverint"}},
ind_fut_sig = {nil,nil,nil,nil,nil,nil},
ind_pres_pas = {{},{},{"ītur"},{},{},{}},
ind_imp_pas = {{},{},{"ībātur"},{},{},{}},
ind_fut_pas = {{},{},{"ībitur"},{},{},{}},
subj_pres = {{"eam"},{"eās"},{"eat"},{"eāmus"},{"eātis"},{"eant"}},
subj_imp = {{"īrem"},{"īrēs"},{"īret"},{"īrēmus"},{"īrētis"},{"īrent"}},
subj_perf = {{"ierim","īverim"},{"ierīs","īverīs"},{"ierit","īverit"},{"ierīmus","īverīmus"},{"ierītis","īverītis"},{"ierint","īverint"}},
subj_pluperf = {{"īssem","iissem","īvissem"},{"īssēs","iissēs","īvissēs"},{"īsset","iisset","īvisset"},{"īssēmus","iissēmus","īvissēmus"},{"īssētis","iissētis","īvissētis"},{"īssent","iissent","īvissent"}},
subj_aor_sig = {nil,nil,nil,nil,nil,nil},
subj_pres_pas = {{},{},{"eātur"},{},{},{}},
subj_imp_pas = {{},{},{"īrētur"},{},{},{}},
imper_pres = {nil,nil,nil,nil,nil,nil},
imper_fut = {nil,nil,nil,nil,nil,{"euntō"}},
imper_fut_pas = {nil,{},nil,nil,nil,{}},
}},
{"faciō", {"faciō"}, {
conj = "3",
nucleopres = {"faci"},
nucleoperf = {"fax"},
nucleosup = {"fact"},
nucleosigm = {"fax","faxs","facs"},
desactivar = {},
ind_pres_pas = {{"fīō"},{"fīs"},{"fit"},{"fīmus"},{"fītis"},{"fīunt"}},
ind_imp_pas = {{"fīēbam"},{"fīēbās"},{"fīēbat"},{"fīēbāmus"},{"fīēbātis"},{"fīēbant"}},
ind_fut_pas = {{"fīam"},{"fīēs"},{"fīet"},{"fīēmus"},{"fīētis"},{"fīent"}},
subj_pres_pas = {{"fīam"},{"fīās"},{"fīat"},{"fīāmus"},{"fīātis"},{"fīant"}},
subj_imp_pas = {{"fierem"},{"fierēs"},{"fieret"},{"fierēmus"},{"fierētis"},{"fierent"}},
imper_pres = {nil,{"fac","face"},nil,nil,nil,nil},
imper_pres_pas = {nil,{"fī"},nil,nil,{"fīte"},nil},
imper_fut_pas = {nil,{"fītō"},{"fītō"},nil,{"fītōte"},{"fīuntō"}},
}},
{"ferō", {"ferō"}, {
conj = "3",
nucleopres = {"fer"},
nucleoperf = {"tul", "tetul{†}"},
nucleosup = {"lāt"},
nucleosigm = {},
desactivar = {},
inf_act = {"ferre", "tulisse", "tetulisse{†}"},
inf_pas = {"ferrī"},
ind_pres = {nil,{"fers"},{"fert"},nil,{"fertis"}},
ind_pres_pas = {nil,{"ferris","ferre"}},
subj_imp = {{"ferrem"},{"ferrēs"},{"ferret"},{"ferrēmus"},{"ferrētis"},{"ferrent"}},
subj_imp_pas = {{"ferrer"},{"ferrēris","ferrēre"},{"ferrētur"},{"ferrēmur"},{"ferrēminī"},{"ferrentur"}},
imper_pres = {nil,{"fer"},nil,nil,{"ferte"},nil},
imper_pres_pas = {nil,{"ferre"},nil,nil,nil,nil},
imper_fut = {nil,{"fertō"},{"fertō"},nil,{"fertōte"},{"feruntō"}},
imper_fut_pas = {nil,{"fertor"},{"fertor"},nil,nil,nil},
}},
{"fīō", {"fīō"}, {
conj = "3",
nucleopres = {"fī"},
nucleoperf = {},
nucleosup = {"fact"},
nucleosigm = {},
semidep = true,
desactivar = {},
ind_pres = {{"fīō"},{"fīs"},{"fit"},{"fīmus"},{"fītis"},{"fīunt"}},
imper_pres = {nil,{"fī"},nil,nil,{"fīte"},nil},
imper_fut = {nil,{"fītō"},{"fītō"},nil,{"fītōte"},{"feruntō"}},
}},
{"inquam", {"inquam"}, {
conj = "3",
nucleopres = {"inqui"},
nucleoperf = {},
nucleosup = {},
nucleosigm = {},
nopasivo = true,
desactivar = {"inf_act","inf_pas","part_pas","ger"},
ind_pres = {{"inquam"}},
}},
{"possum", {"possum"}, {
conj = "3",
nucleopres = {"pot"},
nucleoperf = {"pot"},
nucleosup = {},
nucleosigm = {},
pres = "possō",
desactivar = {"inf_pas","part_pas","ger","sup","ind_pres_pas","ind_imp_pas","ind_fut_pas",
"subj_pres_pas","subj_imp_pas","imper_pres","imper_fut","imper_pres_pas","imper_fut_pas"},
inf_act = {"posse","potesse{†}"},
part_act = {"potēns"},
ind_pres = {{"possum"},{"potes"},{"potest"},{"possumus"},{"potestis"},{"possunt"}},
ind_imp = {{"poteram"},{"poterās"},{"poterat"},{"poterāmus"},{"poterātis"},{"poterant"}},
ind_fut = {{"poterō"},{"poteris","potere"},{"poterit"},{"poterimus"},{"poteritis"},{"poterunt"}},
ind_perf = {{"potuī"},{"potuistī"},{"potuit"},{"potuimus"},{"potuistis"},{"potuērunt","potuēre"}},
ind_pluperf = {{"potueram"},{"potuerās"},{"potuerat"},{"potuerāmus"},{"potuerātis"},{"potuerant"}},
ind_fut_perf = {{"potuerō"},{"potueris"},{"potuerit"},{"potuerimus"},{"potueritis"},{"potuerunt"}},
subj_pres = {{"possem"},{"possēs"},{"possēt"},{"possēmus"},{"possētis"},{"possent"}},
subj_imp = {{"possim"},{"possīs"},{"possit"},{"possīmus"},{"possītis"},{"possint"}},
subj_perf = {{"potuerim"},{"potuerīs"},{"potuerit"},{"potuerīmus"},{"potuerītis"},{"potuerint"}},
subj_pluperf = {{"potuissem"},{"potuissēs"},{"potuisset"},{"potuissēmus"},{"potuissētis"},{"potuissent"}},
}},
{"sum", {"sum"}, {
conj = "3",
nucleopres = {"s"},
nucleoperf = {"fu"},
nucleosup = {},
nucleosigm = {},
pres = "sō",
desactivar = {"inf_pas","part_pas","ger","sup","ind_pres_pas","ind_imp_pas","ind_fut_pas",
"subj_pres_pas","subj_imp_pas","imper_pres_pas","imper_fut_pas"},
inf_act = {"esse"},
part_act = {"futūrus"},
ind_pres = {{"sum"},{"es"},{"est"},{"sumus"},{"estis"},{"sunt"}},
ind_imp = {{"eram"},{"erās"},{"erat"},{"erāmus"},{"erātis"},{"erant"}},
ind_fut = {{"erō"},{"eris","ere"},{"erit"},{"erimus"},{"eritis"},{"erunt"}},
subj_pres = {{"sim","siem","fuam{†}"},{"sīs","siēs","fuās{†}"},{"sit","siet","fuat{†}"},{"sīmus","siēmus","fuāmus{†}"},{"sītis","siētis","fuātis{†}"},{"sint","sient","fuant{†}"}},
subj_imp = {{"essem","forem"},{"essēs","forēs"},{"esset","foret"},{"essēmus","forēmus"},{"essētis","forētis"},{"essent","forent"}},
imper_pres = {nil,{"es"},nil,nil,{"este"},nil},
imper_fut = {nil,{"estō"},{"estō"},nil,{"estōte"},nil},
}},
{"mālō", {"mālō"}, {
conj = "3",
nucleopres = {"māl"},
nucleoperf = {"mālu"},
nucleosup = {},
nucleosigm = {},
desactivar = {"sup","ger","inf_pas","part_pas","ind_pres_pas","ind_imp_pas","ind_fut_pas","subj_pres_pas","subj_imp_pas",
"imper_pres","imper_fut","imper_pres_pas","imper_fut_pas"},
inf_act = {"mālle","māluisse"},
ind_pres = {{"mālō"},{"māvīs"},{"māvult"},{"mālumus"},{"māvultis"},{"mālunt"}},
subj_pres = {{"mālim"},{"mālīs"},{"mālit"},{"mālīmus"},{"mālītis"},{"mālint"}},
subj_imp = {{"māllem"},{"māllēs"},{"māllet"},{"māllēmus"},{"māllētis"},{"māllent"}},
}},
{"nōlō", {"nōlō"}, {
conj = "3",
nucleopres = {"nōl"},
nucleoperf = {"nōlu"},
nucleosup = {},
nucleosigm = {},
desactivar = {"sup","ger","inf_pas","part_pas","ind_pres_pas","ind_imp_pas","ind_fut_pas","subj_pres_pas","subj_imp_pas",
"imper_pres","imper_fut","imper_pres_pas","imper_fut_pas"},
inf_act = {"nōlle","nōluisse"},
ind_pres = {{"nōlō"},{"nōn vīs","nevīs{†}"},{"nōn vult","nōn volt","nevolt{†}"},{"nōlumus"},{"nōn vultis","nōn voltis","nōltis{†}"},{"nōlunt"}},
subj_pres = {{"nōlim"},{"nōlīs"},{"nōlit"},{"nōlīmus"},{"nōlītis"},{"nōlint"}},
subj_imp = {{"nōllem"},{"nōllēs"},{"nōllet"},{"nōllēmus"},{"nōllētis"},{"nōllent"}},
}},
{"volō", {"volō"}, {
conj = "3",
nucleopres = {"vol"},
nucleoperf = {"volu"},
nucleosup = {"volit"},
nucleosigm = {},
desactivar = {"sup","ger","inf_pas","part_pas","ind_pres_pas","ind_imp_pas","ind_fut_pas","subj_pres_pas","subj_imp_pas",
"imper_pres","imper_fut","imper_pres_pas","imper_fut_pas"},
inf_act = {"velle","voluisse"},
ind_pres = {{"volō"},{"vīs"},{"vult","volt{†}"},{"volumus"},{"vultis","voltis{†}"},{"volunt"}},
subj_pres = {{"velim","volim{†}"},{"velīs","volīs{†}"},{"velit","volit{†}"},{"velīmus","volīmus{†}"},{"velītis","volītis{†}"},{"velint","volint{†}"}},
subj_imp = {{"vellem"},{"vellēs"},{"vellet"},{"vellēmus"},{"vellētis"},{"vellent"}},
}},
}
local function combinar_prefijo_nucleosufijo(prefijo, nucleosufijo)
return prefijo..nucleosufijo
end
local function combinar_nucleo_sufijo(nucleo, sufijo, agregar_i)
if agregar_i and (not find(sufijo, "^[iī]")) and (sufijo ~= "e") and (not find(sufijo, "^er")) then
return nucleo.."~i~"..sufijo
end
return nucleo..sufijo
end
local function agregar_forma(conjugado, conjinfo, forma)
conjinfo[forma] = conjinfo[forma] or {}
local sufijos_ = sufijos[conjinfo.conj][forma]
local nucleos
local prefijo
if forma == "sup" then
nucleos = conjinfo.nucleosup
prefijo = conjinfo.prefijosup or conjinfo.prefijo
elseif find(forma, "sig") then
nucleos = conjinfo.nucleosigm
prefijo = conjinfo.prefijosigm or conjinfo.prefijo
elseif find(forma, "perf") then
nucleos = conjinfo.nucleoperf
prefijo = conjinfo.prefijoperf or conjinfo.prefijo
else
nucleos = conjinfo.nucleopres
prefijo = conjinfo.prefijo
end
if formas_no_personales[forma] then
if conjinfo[forma][1] then
if nucleos and #nucleos > 0 then
for _, fm in ipairs(conjinfo[forma]) do
insert_if_not(conjugado[forma], "#"..combinar_prefijo_nucleosufijo(prefijo, fm).."#")
end
end
else
for _, sufijo in ipairs(sufijos_) do
local nucleos_ = nucleos
if forma == "inf_act" and sufijo == "isse" then
nucleos_ = conjinfo.nucleoperf
elseif forma == "part_act" and sufijo == "ūrus" then
nucleos_ = conjinfo.nucleosup
elseif forma == "part_pas" and sufijo == "us" then
nucleos_ = conjinfo.nucleosup
end
local agregar_i = conjinfo.I and nucleos_ == conjinfo.nucleopres
for _,nucleo in ipairs(nucleos_) do
insert_if_not(conjugado[forma], combinar_prefijo_nucleosufijo(prefijo, combinar_nucleo_sufijo(nucleo, sufijo, agregar_i)))
end
end
end
return
end
for i = EGO, EI do
local p = tostr[i]
if conjinfo[forma][i] then
if nucleos and #nucleos > 0 then
for _, fm in ipairs(conjinfo[forma][i]) do
insert_if_not(conjugado[forma..p], "#"..combinar_prefijo_nucleosufijo(prefijo, fm).."#")
end
end
else
local k = i
while sufijos_[k] do
local agregar_i = conjinfo.I and nucleos == conjinfo.nucleopres
for j, n in ipairs(nucleos) do
local x = combinar_prefijo_nucleosufijo(prefijo, combinar_nucleo_sufijo(n, sufijos_[k], agregar_i))
if conjinfo.always_sync_perf and (forma == "ind_perf" or forma == "ind_pluperf" or forma == "ind_fut_perf" or forma == "subj_perf" or forma == "subj_pluperf") then
x = x:gsub("īvī", "iī")
x = x:gsub("īvi", "ī")
x = x:gsub("īve", "ī")
x = x:gsub("īvē", "ē")
end
insert_if_not(conjugado[forma..p], x)
end
k = k + 6
end
end
end
end
local function get_subtype_by_ending(pres, conjinfo, specs)
for _, spec in ipairs(specs) do
local base = extract_base(pres, spec[1])
if base then
for _,s in ipairs(spec[2]) do
if conjinfo[s] == nil then
conjinfo[s] = true
end
end
return base
end
end
error("Unrecognized ending for conjugation " .. conjinfo["conj"])
end
local function detect_v_type_and_subtypes(conjinfo)
local pres = conjinfo["v"]
local conj_arg = conjinfo["conj"]
pres = toNFC(pres)
local base_conj_arg, auto_perf_supine = conj_arg:match("^([124]/?4?)(%+%+?)$")
if base_conj_arg then
if auto_perf_supine == "++" and base_conj_arg ~= "4" then
error("Conjugation types 1++ and 2++ not allowed")
end
conj_arg = base_conj_arg
end
conjinfo.conj = conj_arg
if conj_arg == "1" then
local base = get_subtype_by_ending(pres, conjinfo, {
{"ō", {}},
{"or", {"dep"}},
{"at", {"impers"}},
{"ātur", {"dep", "impers"}},
{"ī", {"nopres"}},
{"it", {"nopres", "impers"}},
})
if not conjinfo["nucleopres"][1] then
conjinfo["nucleopres"][1] = base
end
if auto_perf_supine then
if not conjinfo["nucleoperf"][1] then
conjinfo["nucleoperf"][1] = base .. "āv"
end
if not conjinfo["nucleosup"][1] then
conjinfo["nucleosup"][1] = base .. "āt"
end
end
if conjinfo.sigm then
if not conjinfo["nucleosigm"][1] then
conjinfo["nucleosigm"][1] = base .. "āss"
end
end
elseif conj_arg == "2" then
local base = get_subtype_by_ending(pres, conjinfo, {
{"eō", {}},
{"eor", {"dep"}},
{"et", {"impers"}},
{"ētur", {"dep", "impers"}},
{"ī", {"nopres"}},
{"it", {"nopres", "impers"}},
})
if not conjinfo["nucleopres"][1] then
conjinfo["nucleopres"][1] = base
end
if auto_perf_supine then
if not conjinfo["nucleoperf"][1] then
conjinfo["nucleoperf"][1] = base .. "u"
end
if not conjinfo["nucleosup"][1] then
conjinfo["nucleosup"][1] = base .. "it"
end
end
if conjinfo.sigm then
if not conjinfo["nucleosigm"][1] then
conjinfo["nucleosigm"][1] = base .. "ēss"
end
end
elseif conj_arg == "3" then
local base
if conjinfo.I == false then -- si explícitamente se indicó que no es del tipo -io, hay que excluir sufijos
base = get_subtype_by_ending(pres, conjinfo, {
{"ō", {}},
{"or", {"dep"}},
{"it", {"impers"}},
{"itur", {"dep", "impers"}},
{"ī", {"nopres"}},
})
else
base = get_subtype_by_ending(pres, conjinfo, {
{"iō", {"I"}},
{"ior", {"dep", "I"}},
{"ō", {}},
{"or", {"dep"}},
{"it", {"impers"}},
{"itur", {"dep", "impers"}},
{"ī", {"nopres"}},
})
end
if not conjinfo["nucleopres"][1] then
conjinfo["nucleopres"][1] = base
end
if not conjinfo["nucleoperf"][1] and conjinfo["nopres"] then
conjinfo["nucleoperf"][1] = base
end
assert(conjinfo["nucleoperf"][1], "especifique todos los núcleos para verbos de la tercera conjugación")
assert(conjinfo["nucleosup"][1], "especifique todos los núcleos para verbos de la tercera conjugación")
if conjinfo.sigm then
if not conjinfo["nucleosigm"][1] then
conjinfo["nucleosigm"][1] = base .. "ēss"
end
end
elseif conj_arg == "3/4" then
local base
base = get_subtype_by_ending(pres, conjinfo, {
{"iō", {"I"}},
{"ior", {"dep", "I"}},
})
if not conjinfo["nucleopres"][1] then
conjinfo["nucleopres"][1] = base
end
if not conjinfo["nucleoperf"][1] and conjinfo["nopres"] then
conjinfo["nucleoperf"][1] = base
end
if not conjinfo["nucleoperf"][1] and auto_perf_supine == "++" then
conjinfo["nucleoperf"][1] = base .. "īv"
conjinfo["nucleoperf"][2] = base .. "i"
end
if not conjinfo["nucleoperf"][1] and auto_perf_supine == "+" then
conjinfo["nucleoperf"][1] = base .. "īv"
end
if not conjinfo["nucleosup"][1] and auto_perf_supine then
conjinfo["nucleosup"][1] = base .. "īt"
end
if conjinfo.sigm then
if not conjinfo["nucleosigm"][1] then
conjinfo["nucleosigm"][1] = base .. "īss"
end
end
elseif conj_arg == "4" then
local base = get_subtype_by_ending(pres, conjinfo, {
{"iō", {}},
{"ior", {"dep"}},
{"it", {"impers"}},
{"ītur", {"dep", "impers"}},
{"ī", {"nopres"}},
})
if not conjinfo["nucleopres"][1] then
conjinfo["nucleopres"][1] = base
end
if not conjinfo["nucleoperf"][1] and conjinfo["nopres"] then
conjinfo["nucleoperf"][1] = base
end
if not conjinfo["nucleoperf"][1] and auto_perf_supine == "++" then
conjinfo["nucleoperf"][1] = base .. "īv"
conjinfo["nucleoperf"][2] = base .. "i"
end
if not conjinfo["nucleoperf"][1] and auto_perf_supine == "+" then
conjinfo["nucleoperf"][1] = base .. "īv"
end
if not conjinfo["nucleosup"][1] and auto_perf_supine then
conjinfo["nucleosup"][1] = base .. "īt"
end
if conjinfo.sigm then
if not conjinfo["nucleosigm"][1] then
conjinfo["nucleosigm"][1] = base .. "īss"
end
end
elseif conj_arg == "irreg" then
for _,p in ipairs(verbos_irregulares) do
for _,rx in ipairs(p[2]) do
local pref, verb = match(conjinfo.v, "^(.*)("..rx..")$")
if verb then
conjinfo.v = verb
conjinfo.prefijo = pref
if conjinfo.nucleoperf[1] and conjinfo.nucleoperf[1] ~= "-" then -- [[ecfero]]
conjinfo.prefijoperf = conjinfo.nucleoperf[1]
conjinfo.nucleoperf = {}
end
if conjinfo.nucleosup[1] and conjinfo.nucleosup[1] ~= "-" then
conjinfo.prefijosup = conjinfo.nucleosup[1]
conjinfo.nucleosup = {}
end
if conjinfo.nucleosigm[1] and conjinfo.nucleosigm[1] ~= "-" then
conjinfo.prefijosigm = conjinfo.nucleosigm[1]
conjinfo.nucleosigm = {}
end
conjinfo.irreg = true
conjinfo.conj = p[3].conj
for k,val in pairs(p[3]) do
if not conjinfo[k] or (type(conjinfo[k]) == "table" and not conjinfo[k][1]) then
conjinfo[k] = deep_copy(val)
end
end
return conjinfo
end
end
end
error("Unrecognized conjugation '" .. conj_arg .. "'")
else
error("Unrecognized conjugation '" .. conj_arg .. "'")
end
return conjinfo
end
function export.v(frame)
local title_ = mw.title.getCurrentTitle()
local tit = title_.fullText
local ns = title_.namespace
if ns ~= 0 then
return "Use esta plantilla en el espacio principal."
end
local params = {
[1] = {alias_de = "conj"},
[2] = {alias_de = "pres"},
[3] = {alias_de = "nucleoperf"},
[4] = {alias_de = "nucleosup"},
[5] = {alias_de = "nucleosigm"},
["impers"] = {}, -- pas para formas pasivas solamente
["impersonal"] = {alias_de = "impers"},
["dep"] = {tipo="bool"},
["depon"] = {alias_de="dep"},
["deponente"] = {alias_de="dep"},
["semidep"] = {tipo="bool"},
["semidepon"] = {alias_de="semidep"},
["semideponente"] = {alias_de="semidep"},
["sigm"] = {tipo="bool"},
["nopasivo"] = {tipo="bool"},
["soloperf"] = {tipo="bool"},
["I"] = {tipo="bool"},
["p3inf"] = {tipo="bool"}, -- sin uso
["poet_sync_perf"] = {tipo="bool"}, -- sin uso
["always_sync_perf"] = {tipo="bool"}, -- solo en [[saevio]]
["conj"] = {requerido=true},
["pres"] = {requerido=true},
["nucleopres"] = {lista = true},
["nucleoperf"] = {lista = true},
["nucleosup"] = {lista = true},
["nucleosigm"] = {lista = true},
["núcleopres"] = {alias_de="nucleopres"},
["núcleoperf"] = {alias_de="nucleoperf"},
["núcleosup"] = {alias_de="nucleosup"},
["paradigma"] = {lista = true},
["desactivarnucleos"] = {tipo="bool", por_defecto=true}, -- para [[-o]]
["nota"] = {},
}
local conjugado = {}
for forma,_ in pairs(formas_no_personales) do
params[forma] = {tipo=parsear_arreglo, por_defecto={}}
conjugado[forma] = {}
end
for forma,_ in pairs(formas_personales) do
for i,s in ipairs(tostr) do
params[forma..s] = {tipo=parsear_arreglo, por_defecto={}}
conjugado[forma..s] = {}
if i == 1 then
params[forma] = {alias_de=forma..s}
end
end
end
local parent_frame = frame:getParent()
local args = require("Módulo:parámetros").obtener_parametros(parent_frame.args, params)
assert(not find(tit, " "), "locuciones no soportadas aún")
assert(not (args["dep"] and args["semidep"]), "un verbo no puede ser deponente y semideponente a la vez")
local conjinfo = {
conj = args.conj,
prefijo="",
v=args.pres,
desactivar = {},
dep=args.dep,
semidep=args.semidep,
sigm=args.sigm,
impers=args.impers,
nopasivo=args.nopasivo,
soloperf=args.soloperf,
I=args.I,
p3inf=args.p3inf,
poet_sync_perf=args.poet_sync_perf, -- sin uso
always_sync_perf=args.always_sync_perf,
nucleopres = deep_copy(args.nucleopres),
nucleoperf = deep_copy(args.nucleoperf),
nucleosup = deep_copy(args.nucleosup),
nucleosigm = deep_copy(args.nucleosigm)
}
conjinfo = detect_v_type_and_subtypes(conjinfo)
conjinfo.conj = conjinfo.conj
if conjinfo.impers == true then
conjinfo.impers = "3"
end
-- no puede ir conjinfo acá abajo porque si es un sufijo va a quedar "-" en la raíz, lo que anularía todas las formas conjugadas, tiene que venir directo de args
if args.desactivarnucleos then
if args.nucleopres[1] == "-" then
conjinfo.nucleopres = {}
end
if args.nucleoperf[1] == "-" then
conjinfo.nucleoperf = {}
end
if args.nucleosup[1] == "-" then
conjinfo.nucleosup = {}
end
if args.nucleosigm[1] == "-" then
conjinfo.nucleosigm = {}
end
end
local es_irregular = conjinfo.irreg
for _,d in ipairs(conjinfo.desactivar) do
if formas_no_personales[d] then
args[d] = {"no"}
else
args[d.."2"] = {"no"}
end
end
for forma,_ in pairs(formas) do
agregar_forma(conjugado, conjinfo, forma)
end
local resultante = sobreescribir_formas(conjugado, args)
local mostrar_fut_sig = #resultante["ind_fut_sig1"] > 0
local mostrar_aor_sig = #resultante["subj_aor_sig1"] > 0
local defectivo = comprobar_defectivo(resultante, {"^imper", "_sig"}, tostr)
local defect2
resultante, defect2 = desactivar_formas(resultante,
function (form)
return (conjinfo.nopasivo and form:find("_pas")) or (conjinfo.soloperf and not form:find("perf")) or (conjinfo.impers == "pas" and form:find("_pas[^3]")) or (conjinfo.impers == "pas3" and form:find("_pas[^3]")) or (conjinfo.impers == "pas36" and form:find("_pas[^36]"))
end
)
if defect2 then
defectivo = true
end
-- por ahora innecesario
-- local part_no_adj = {}
-- for _,e in ipairs(resultante.part) do
-- if (find(e, 'PART') or not find(e, 'ADJ')) and not find(e, "†") then
-- insert(part_no_adj, gsub1(e, '%b{}', ''))
-- end
-- end
local tit_pres = f(resultante["ind_pres1"][1] or "―")
local tit_inf = f(resultante["inf_act"][1] or "―")
local tit_perf = f(resultante["ind_perf1"][1] or "―")
local tit_sup = f(resultante["sup"][1] or "―")
resultante = agregar_enlaces(resultante, tit, normalizar_enlace)
local es_impersonal = conjinfo.impers
resultante = formatear_formas(resultante, function (x)
return obtener_pronombre(x, es_impersonal)
end)
local impers = conjinfo.impers
local cs, cs1, cs2, fila_pronombres_ind, fila_pronombres_subj, fila_pronombres_imper, mostrar_imper
if impers == "3" then
fila_pronombres_ind = {"", "(id)", color=COLOR_IND, header=true, class="pc"}
fila_pronombres_subj = {"", "(quod id)", color=COLOR_SUBJ, header=true, class="pc"}
fila_pronombres_imper = {"", "(id)", color=COLOR_IMPER, header=true, class="pc"}
cs = 2
elseif impers == "36" then
error("no soportado actualmente")
cs = 3
else
fila_pronombres_ind = {"", PRONOMBRES[1], PRONOMBRES[2], PRONOMBRES[3], PRONOMBRES[4], PRONOMBRES[5], PRONOMBRES[6], color=COLOR_IND, header=true, class="pc"}
fila_pronombres_subj = {"", PRONOMBRES_SUBJ[1], PRONOMBRES_SUBJ[2], PRONOMBRES_SUBJ[3], PRONOMBRES_SUBJ[4], PRONOMBRES_SUBJ[5], PRONOMBRES_SUBJ[6], color=COLOR_SUBJ, header=true, class="pc"}
fila_pronombres_imper = {"", PRONOMBRES_IMP[1], PRONOMBRES_IMP[2], PRONOMBRES_IMP[3], PRONOMBRES_IMP[4], PRONOMBRES_IMP[5], PRONOMBRES_IMP[6], color=COLOR_IMPER, header=true, class="pc"}
cs = 7
mostrar_imper = true
end
cs1 = cs -- math.floor(cs / 2)
-- cs2 = cs - cs1
local t = {}
insert(t, {{"Formas no personales (verboides)", colspan=cs}, color=COLOR_H, header=true})
if impers == "3" then
insert(t, {{"Infinitivo activo", header=true, color=COLOR_NP}, resultante.inf_act})
insert(t, {{"Infinitivo pasivo", header=true, color=COLOR_NP}, resultante.inf_pas})
insert(t, {{"Participio activo", header=true, color=COLOR_NP}, resultante.part_act})
insert(t, {{"Participio pasivo", header=true, color=COLOR_NP}, resultante.part_pas})
insert(t, {{"Gerundio", header=true, color=COLOR_NP}, resultante.ger})
insert(t, {{"Supino", header=true, color=COLOR_NP}, resultante.sup})
else
resultante.inf_act.colspan = cs1-1
resultante.inf_pas.colspan = cs1-1
resultante.part_act.colspan = cs1-1
resultante.part_pas.colspan = cs1-1
resultante.ger.colspan = cs1-1
resultante.sup.colspan = cs1-1
if not conjinfo.dep then
insert(t, {{"Infinitivo activo", header=true, color=COLOR_NP}, resultante.inf_act})
end
if not conjinfo.semidep then
insert(t, {{"Infinitivo pasivo", header=true, color=COLOR_NP}, resultante.inf_pas})
end
if not conjinfo.dep then
insert(t, {{"Participio activo", header=true, color=COLOR_NP}, resultante.part_act})
end
if not conjinfo.semidep then
insert(t, {{"Participio pasivo", header=true, color=COLOR_NP}, resultante.part_pas})
end
insert(t, {{"Gerundio", header=true, color=COLOR_NP}, resultante.ger})
insert(t, {{"Supino", header=true, color=COLOR_NP}, resultante.sup})
end
local function ic(tiempo)
if impers == "3" then
return resultante[tiempo.."3"]
elseif impers == "36" then
return resultante[tiempo.."3"], resultante[tiempo.."6"]
end
return resultante[tiempo.."1"], resultante[tiempo.."2"], resultante[tiempo.."3"], resultante[tiempo.."4"], resultante[tiempo.."5"], resultante[tiempo.."6"]
end
insert(t, {{"Formas personales", colspan=cs}, color=COLOR_H, header=true})
insert(t, {{"Modo indicativo", colspan=cs}, color=COLOR_IND, header=true})
insert(t, fila_pronombres_ind)
if not conjinfo.dep then
insert(t, {{"Presente", color=COLOR_IND, header=true}, ic("ind_pres")})
insert(t, {{"Pretérito imperfecto", color=COLOR_IND, header=true}, ic("ind_imp")})
insert(t, {{"Futuro", color=COLOR_IND, header=true}, ic("ind_fut")})
end
if not conjinfo.dep and not conjinfo.semidep then
insert(t, {{"Pretérito perfecto", color=COLOR_IND, header=true}, ic("ind_perf")})
insert(t, {{"Pretérito pluscuamperfecto", color=COLOR_IND, header=true}, ic("ind_pluperf")})
insert(t, {{"Futuro perfecto", color=COLOR_IND, header=true}, ic("ind_fut_perf")})
end
if mostrar_fut_sig then
insert(t, {{f("Futuro sigmático{†}"), color=COLOR_IND, header=true}, ic("ind_fut_sig")})
end
if not conjinfo.semidep then
insert(t, {{"Presente pasivo", color=COLOR_IND, header=true}, ic("ind_pres_pas")})
insert(t, {{"Pretérito imperfecto pasivo", color=COLOR_IND, header=true}, ic("ind_imp_pas")})
insert(t, {{"Futuro pasivo", color=COLOR_IND, header=true}, ic("ind_fut_pas")})
end
insert(t, {{"Modo subjuntivo", colspan=cs}, color=COLOR_SUBJ, header=true})
insert(t, fila_pronombres_subj)
if not conjinfo.dep then
insert(t, {{"Presente", color=COLOR_SUBJ, header=true}, ic("subj_pres")})
insert(t, {{"Pretérito imperfecto", color=COLOR_SUBJ, header=true}, ic("subj_imp")})
end
if not conjinfo.dep and not conjinfo.semidep then
insert(t, {{"Pretérito perfecto", color=COLOR_SUBJ, header=true}, ic("subj_perf")})
insert(t, {{"Pretérito pluscuamperfecto", color=COLOR_SUBJ, header=true}, ic("subj_pluperf")})
end
if mostrar_aor_sig then
insert(t, {{f("Aorista sigmático{†}"), color=COLOR_SUBJ, header=true}, ic("subj_aor_sig")})
end
if not conjinfo.semidep then
insert(t, {{"Presente pasivo", color=COLOR_SUBJ, header=true}, ic("subj_pres_pas")})
insert(t, {{"Pretérito imperfecto pasivo", color=COLOR_SUBJ, header=true}, ic("subj_imp_pas")})
end
insert(t, {{"Modo imperativo", colspan=cs}, color=COLOR_IMPER, header=true})
insert(t, fila_pronombres_imper)
if mostrar_imper then
if not conjinfo.dep then
insert(t, {{"Presente", color=COLOR_IMPER, header=true}, ic("imper_pres")})
insert(t, {{"Futuro", color=COLOR_IMPER, header=true}, ic("imper_fut")})
end
if not conjinfo.semidep then
insert(t, {{"Presente pasivo", color=COLOR_IMPER, header=true}, ic("imper_pres_pas")})
insert(t, {{"Futuro pasivo", color=COLOR_IMPER, header=true}, ic("imper_fut_pas")})
end
else
insert(t, {{"Como verbo "..(impers == "3" and "impersonal" or "terciopersonal")..", ''"..tit.."'' CARECE de imperativo", color=COLOR_IMPER, header=true, colspan=cs}})
end
insert(t, {{f("Leyenda: † arcaico, x no normativo, ~■~ cambio ortográfico, #■# irregularidad"), colspan=cs}})
args["nota"] = args["nota"] or ""
if conjinfo.impers == "utc3" then
args["nota"] = args["nota"].." NOTA: se usa también como impersonal, en cuyo caso solo son válidas las conjugaciones de la tercera persona singular."
end
if conjinfo.impers == "umc3" then
args["nota"] = args["nota"].." NOTA: se usa más como impersonal, en cuyo caso solo son válidas las conjugaciones de la tercera persona singular."
end
if conjinfo.impers == "utc36" then
args["nota"] = args["nota"].." NOTA: se usa también como terciopersonal, en cuyo caso solo son válidas las conjugaciones de la tercera persona singular y plural."
end
if conjinfo.impers == "umc36" then
args["nota"] = args["nota"].." NOTA: se usa más como terciopersonal, en cuyo caso solo son válidas las conjugaciones de la tercera persona singular y plural."
end
if conjinfo.impers == "pas" or conjinfo.imeprs == "pas3" then
args["nota"] = args["nota"].." NOTA: impersonal para las formas pasivas"
end
if conjinfo.impers == "pas36" then
args["nota"] = args["nota"].." NOTA: formas pasivas terciopersonales (solamente tercera persona singular y plural)"
end
if conjinfo.soloperf then
args["nota"] = args["nota"].. " NOTA: solo se emplean las formas del perfecto y pluscuamperfecto con valor de presente, imperfecto o futuro"
end
if conjinfo.nopasivo then
args["nota"] = args["nota"].. " NOTA: solo se emplean las formas activas"
end
insert(t, {{args["nota"] and args["nota"] or "", colspan=cs}})
local cats = {}
local subtits = {}
local conj_str
if conjinfo.conj == "1" then
conj_str = "primera conjugación"
elseif conjinfo.conj == "2" then
conj_str = "segunda conjugación"
elseif conjinfo.conj == "3" then
conj_str = "tercera conjugación"
elseif conjinfo.conj == "3/4" then
conj_str = "tercera/cuarta conjugación"
else
conj_str = "cuarta conjugación"
end
insert(cats, "LA:Verbos de la "..conj_str)
insert(subtits, conj_str)
impers = impers or ""
if impers == "3" or find(impers, "^u[tm]c3$") then
insert(subtits, "impersonal")
insert(cats, "LA:Verbos impersonales")
end
if defectivo then
insert(subtits, "defectivo")
insert(cats, "LA:Verbos defectivos")
end
if conjinfo.dep then
insert(subtits, "deponente")
insert(cats, "LA:Verbos deponentes")
end
if conjinfo.semidep then
insert(subtits, "semideponente")
insert(cats, "LA:Verbos semideponentes")
end
if es_irregular then
insert(subtits, "irregular")
insert(cats, "LA:Verbos irregulares")
else
insert(subtits, "regular")
insert(cats, "LA:Verbos regulares")
end
return renderizar_tabla(
frame,
"'''Conjugación de ''"..tit_pres..", "..tit_inf..", "..tit_perf..", "..tit_sup.."'''''  ("..concat(subtits, ", ")..")",
t,
ns == 0 and cats or {})
end
function export.adv(frame)
local title_ = mw.title.getCurrentTitle()
local title = title_.fullText
local ns = title_.namespace
if ns ~= 0 then
return "Use esta plantilla en el espacio principal."
end
local params = {
["n"] = {},
["nota"] = {alias_de = "n"},
["comp"] = {lista = true},
["comparativo"] = {alias_de = "comp"},
["compnota"] = {lista = true},
["sup"] = {lista = true},
["superlativo"] = {alias_de = "sup"},
["supnota"] = {lista = true},
}
local parent_frame = frame:getParent()
local args = require("Módulo:parámetros").obtener_parametros(parent_frame.args, params)
local head = args[1]
local modo = args[2]
local enc
local cats = {}
local cat_pref = "LA:Adverbios"
if modo == "-" then
enc = "sin comparativo ni superlativo"
insert(cats, cat_pref.." incomparables")
return renderizar_encabezado(
frame,
head,
enc,
args["n"],
{},
ns == 0 and cats or {},
normalizar_enlace
)
end
local flex = {comp={},sup={}}
local stem
for _, suff in ipairs{"iter", "nter", "ter", "er", "iē", "ē", "rā", "im", "ō"} do
stem = match(head, "^(.*)" .. suff .. "$")
if stem ~= nil then
local comp_suff, sup_suff = "ius", "issimē"
if suff == "nter" then
stem = stem .. "nt"
end
if suff == "rā" then
comp_suff = "er" .. comp_suff
sup_suff = "imē"
end
insert(flex.comp, stem .. comp_suff)
insert(flex.sup, stem .. sup_suff)
break
end
end
if not stem and not args.comp[1] and not args.sup[1] then
error("Unrecognized adverb type, recognized types are “-ē”, “-er”, “-ter”, “-iter”, “-im”, or “-ō”, “-ra” or specify irregular forms or “-” if incomparable.")
end
local formas, irr = sobreescribir_formas(flex, args)
if args["comp"][1] == "no" then
enc = "sin comparativo"
insert(cats, cat_pref.." sin comparativo")
return renderizar_encabezado(
frame,
head,
enc,
args["n"],
{{"superlativo", formas.sup, args["supnota"]}},
ns == 0 and cats or {},
normalizar_enlace
)
elseif args["sup"][1] == "no" then
enc = "sin superlativo"
insert(cats, cat_pref.." sin superlativo")
return renderizar_encabezado(
frame,
head,
enc,
args["n"],
{{"comparativo", formas.comp, args["compnota"]}},
ns == 0 and cats or {},
normalizar_enlace
)
end
if irr then
enc = f("#irregular#")
insert(cats, cat_pref.." irregulares")
end
return renderizar_encabezado(
frame,
head,
enc,
args["n"],
{{"comparativo", formas.comp, args["compnota"]},
{"superlativo", formas.sup, args["supnota"]}},
ns == 0 and cats or {},
normalizar_enlace
)
end
return export
3d2bkhmp7rtpm2ljvzttssdpie9vs1v
érem
0
1065187
6121397
2026-07-11T13:41:41Z
Jemily1
121719
creo esta forma verbal en catalán
6121397
wikitext
text/x-wiki
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|1p|imp|ind|pron=nosaltres}}.
== Referencias y notas ==
<references />
fxyneykpew6ltxa5rky45rn5ca0qgzc
éreu
0
1065188
6121398
2026-07-11T13:42:57Z
Jemily1
121719
creo esta forma verbal en catalán
6121398
wikitext
text/x-wiki
= {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|2p|imp|ind|pron=vosaltres, vós}}.
== Referencias y notas ==
<references />
g8zyed3b6mltnd1s9bfbu76xefjpzdi
6121401
6121398
2026-07-11T13:50:57Z
Jemily1
121719
corrijo esta entrada
6121401
wikitext
text/x-wiki
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|2p|imp|ind|pron=vosaltres, vós}}.
== Referencias y notas ==
<references />
s1zuo3i20uiuwdr6t4vzvodjuw2uklh
fores
0
1065189
6121402
2026-07-11T13:55:37Z
Jemily1
121719
creo esta forma verbal en catalán
6121402
wikitext
text/x-wiki
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|2s|ind|ind|pron=tu}}.
;2: {{f.v|leng=ca|ser|2s|cond|pron=tu}}.
== Referencias y notas ==
<references />
3402vmvp5lglik7i4tndd5ia9x8plh3
fórem
0
1065190
6121404
2026-07-11T14:04:00Z
Jemily1
121719
creo esta forma verbal en catalán
6121404
wikitext
text/x-wiki
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|1p|ind|ind|pron=nosaltres}}.
;2: {{f.v|leng=ca|ser|1p|cond|pron=nosaltres}}.
== Referencias y notas ==
<references />
o35gj2clndqxe75t7lqus404m3vyszn
fóreu
0
1065191
6121405
2026-07-11T14:06:19Z
Jemily1
121719
creo esta forma verbal en catalán
6121405
wikitext
text/x-wiki
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|2p|ind|ind|pron=vosaltres, vós}}.
;2: {{f.v|leng=ca|ser|2p|cond|pron=vosaltres, vós}}.
== Referencias y notas ==
<references />
kufrrh5xoyq7dza2let4pet54vtypud
foren
0
1065192
6121406
2026-07-11T14:07:52Z
Jemily1
121719
creo esta forma verbal en catalán
6121406
wikitext
text/x-wiki
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|3p|ind|ind|pron=ells, elles, vostès}}.
;2: {{f.v|leng=ca|ser|3p|cond|pron=ells, elles, vostès}}.
== Referencias y notas ==
<references />
ge0t9ly9l8ya27gjdfnheebn92cr49n
seràs
0
1065194
6121410
2026-07-11T15:10:32Z
Jemily1
121719
creo esta forma verbal en catalán
6121410
wikitext
text/x-wiki
{{desambiguación|seras|serás}}
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|2s|fut|ind|pron=tu}}.
== Referencias y notas ==
<references />
13au4wa679acjgl5vf5p0367rtyhegt
serà
0
1065195
6121413
2026-07-11T15:14:24Z
Jemily1
121719
añado esta forma verbal en catalán
6121413
wikitext
text/x-wiki
{{desambiguación|sera|será}}
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|3s|fut|ind|pron=ell, ella, vosté}}.
== Referencias y notas ==
<references />
sumzno4nte6z2awxzmw8a6ktkue18yx
serem
0
1065196
6121414
2026-07-11T15:16:34Z
Jemily1
121719
añado esta forma verbal en catalán
6121414
wikitext
text/x-wiki
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|1p|fut|ind|pron=nosaltres}}.
== Referencias y notas ==
<references />
qh51na3p4dprx2frjljyfbbiec5gvu7
sereu
0
1065197
6121415
2026-07-11T15:17:46Z
Jemily1
121719
añado esta forma verbal en catalán
6121415
wikitext
text/x-wiki
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|2p|fut|ind|pron=vosaltres, vós}}.
== Referencias y notas ==
<references />
5urz32muc668y5oxq9kpx04rqgicl1f
seran
0
1065198
6121416
2026-07-11T15:19:04Z
Jemily1
121719
añado esta forma verbal en catalán
6121416
wikitext
text/x-wiki
{{desambiguación|serán}}
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|3p|fut|ind|pron=ells, elles, vostès}}.
== Referencias y notas ==
<references />
mw74bpyim6rx6mto8bpuyohsqsl5mht
seríem
0
1065199
6121421
2026-07-11T17:07:02Z
Jemily1
121719
añado esta forma verbal en catalán
6121421
wikitext
text/x-wiki
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|1p|cond|pron=nosaltres}}.
== Referencias y notas ==
<references />
a839mltq77mdgrr5kja0eiat6qboins
seríeu
0
1065200
6121422
2026-07-11T17:10:24Z
Jemily1
121719
añado esta forma verbal en catalán
6121422
wikitext
text/x-wiki
== {{lengua|ca}} ==
{{pron-graf|leng=ca}}
=== Forma flexiva ===
==== Forma verbal ====
;1: {{f.v|leng=ca|ser|2p|cond|pron=vosaltres, vós}}.
== Referencias y notas ==
<references />
95znmcmm9f53dnvc8lyq83il0wzd4pt
kóochakʼ
0
1065201
6121425
2026-07-12T01:53:06Z
26agcp
138617
Página creada con «== {{lengua|yua}} == {{pron-graf|leng=yua|g=kóochak'|v=kóochaʼ|v2=kóochekʼ|v3=kóocheʼ}} === Etimología === {{etimología|leng=yua}}. ==== {{verbo|yua|intransitivo}} ==== ;1: {{plm|patear}}.<ref>{{DUMY|p=127|cita=kóochak'}}</ref> ==== Conjugación ==== {{yua.v|a}} ==== Véase también ==== * {{l|yua|kóochakʼt}} == Referencias y notas == <references />»
6121425
wikitext
text/x-wiki
== {{lengua|yua}} ==
{{pron-graf|leng=yua|g=kóochak'|v=kóochaʼ|v2=kóochekʼ|v3=kóocheʼ}}
=== Etimología ===
{{etimología|leng=yua}}.
==== {{verbo|yua|intransitivo}} ====
;1: {{plm|patear}}.<ref>{{DUMY|p=127|cita=kóochak'}}</ref>
==== Conjugación ====
{{yua.v|a}}
==== Véase también ====
* {{l|yua|kóochakʼt}}
== Referencias y notas ==
<references />
4sabkiim7zsew5nwywuv5xc1fu72aiu
kóochakʼt
0
1065202
6121426
2026-07-12T01:55:38Z
26agcp
138617
Página creada con «== {{lengua|yua}} == {{pron-graf|leng=yua|g=kóochak't|v=kóochaʼat|v2=kóochekʼt|v3=kóocheʼet}} === Etimología === {{etimología|leng=yua|sufijo|kóochakʼ|t}}. ==== {{verbo|yua|transitivo}} ==== ;1: {{plm|patear}}.<ref>{{DUMY|p=127|cita=kóochak't.ik}}</ref> ==== Conjugación ==== {{yua.v|t1}} ==== Véase también ==== * {{l|yua|kóochakʼ}} == Referencias y notas == <references />»
6121426
wikitext
text/x-wiki
== {{lengua|yua}} ==
{{pron-graf|leng=yua|g=kóochak't|v=kóochaʼat|v2=kóochekʼt|v3=kóocheʼet}}
=== Etimología ===
{{etimología|leng=yua|sufijo|kóochakʼ|t}}.
==== {{verbo|yua|transitivo}} ====
;1: {{plm|patear}}.<ref>{{DUMY|p=127|cita=kóochak't.ik}}</ref>
==== Conjugación ====
{{yua.v|t1}}
==== Véase también ====
* {{l|yua|kóochakʼ}}
== Referencias y notas ==
<references />
jczb6vhckgcj2zj3fovocx09mqqog4y
Categoría:YUA:Rimas:akʼt
14
1065203
6121427
2026-07-12T01:56:20Z
26agcp
138617
Página creada con «{{auto cat}}»
6121427
wikitext
text/x-wiki
{{auto cat}}
eomzlm5v4j7ond1phrju7cnue91g5qx
elato
0
1065204
6121430
2026-07-12T04:41:00Z
Tmagc
158167
Página creada con «{{desambiguación|}} == {{lengua|es}} == {{pron-graf}} === Etimología === {{etimología|la|elatus|alt=elātus}}, participio de {{l+|la|effero|alt=efferre|glosa=levantar}}. ==== {{adjetivo|es}} ==== {{es.adj}} ;1: {{plm|altivo}}, [[presuntuoso]], [[soberbio]].<ref>{{DLE1925}}</ref> {{uso|anticuado}} == Referencias y notas == <references />»
6121430
wikitext
text/x-wiki
{{desambiguación|}}
== {{lengua|es}} ==
{{pron-graf}}
=== Etimología ===
{{etimología|la|elatus|alt=elātus}}, participio de {{l+|la|effero|alt=efferre|glosa=levantar}}.
==== {{adjetivo|es}} ====
{{es.adj}}
;1: {{plm|altivo}}, [[presuntuoso]], [[soberbio]].<ref>{{DLE1925}}</ref>
{{uso|anticuado}}
== Referencias y notas ==
<references />
dib7pgatl7ip13z0rixty9ckr7cop6a