Modül belgelemesi [Düzenle] [Tazele]

Bu modül şu şablonlarda kullanılmaktadır:


local m_baglantilar = require("Modül:bağlantılar")
local m_utilities = require("Modül:araçlar")

local lang = require("Modül:diller").getirKodaGore("it")

local export = {}

-- Functions that do the actual inflecting by creating the forms of a basic term.
local inflections = {}

-- Main entry point
function export.itconj(frame)
	local args = frame:getParent().args
	
	-- Create the forms
	local data = {forms = {}, categories = {}, refl = false}
	
	data.forms.aux = {mw.text.trim(args[2] or "essere")}
	
	if data.forms.aux and (data.forms.aux[1] == "avere or essere" or data.forms.aux[1] == "essere or avere") then
			data.forms.aux = {"avere", "essere"}
	end
	
	-- Find what type of verb is it (hard-coded in the template).
	-- Generate standard conjugated forms for each type of verb,
	local infl_type = frame:getParent().args["type"]
	
	if not infl_type then
		data.forms.infinitive = {args["inf"]}; if data.forms.infinitive[1] == "" then data.forms.infinitive = nil end
	elseif inflections[infl_type] then
		inflections[infl_type](args, data)
	else
		error("Verb type " .. infl_type .. " not supported.")
	end
	
	-- Get overridden forms
	process_overrides(args, data)
	
	-- Correct forms that are used in more than one person
	if not data.forms.pres_subj_1sg or #data.forms.pres_subj_1sg == 0 then data.forms.pres_subj_1sg = mw.clone(data.forms.pres_subj_123sg) end
	if not data.forms.pres_subj_2sg or #data.forms.pres_subj_2sg == 0 then data.forms.pres_subj_2sg = mw.clone(data.forms.pres_subj_123sg) end
	if not data.forms.pres_subj_3sg or #data.forms.pres_subj_3sg == 0 then data.forms.pres_subj_3sg = mw.clone(data.forms.pres_subj_123sg) end
	
	if not data.forms.impf_subj_1sg or #data.forms.impf_subj_1sg == 0 then data.forms.impf_subj_1sg = mw.clone(data.forms.impf_subj_12sg) end
	if not data.forms.impf_subj_2sg or #data.forms.impf_subj_2sg == 0 then data.forms.impf_subj_2sg = mw.clone(data.forms.impf_subj_12sg) end
	
	-- Add reflexive pronouns
	if data.refl then
		add_reflexive_pronouns(args, data)
	end
	
	return make_table(data) .. m_utilities.format_categories(data.categories, lang)
end

-- Replaces terms with overridden ones that are given as additional named parameters.
function process_overrides(args, data)
	-- Each term in current is overridden by one in override, if it exists.
	local function override(current, override)
		current = current or {}
		local ret = {}
		
		local i = 1
		
		-- First see if any of the existing items in current have an override specified.
		while current[i] do
			if override[i] and override[i] ~= "" then
				if override[i] ~= "''" and override[i] ~= "-" then
					table.insert(ret, override[i])
				elseif override[i] == "''" then
					table.insert(data.categories, "it-conj with quotes in override")
				end
			else
				table.insert(ret, current[i])
			end
			
			i = i + 1
		end
		
		-- We've reached the end of current.
		-- Look in the override list to see if there are any extra forms to add on to the end.
		while override[i] do
			if override[i] and override[i] ~= "" and override[i] ~= "''" and override[i] ~= "-" then
				table.insert(ret, override[i])
			elseif override[i] == "''" then
				table.insert(data.categories, "it-conj with quotes in override")
			end
			
			i = i + 1
		end
		
		return ret
	end
	
	-- Mark terms with any additional statement as irregular.
	for k,v in pairs(args) do
		if k ~= 1 and k ~= 2 and k ~= "type" and mw.text.trim(v) ~= '' then
			table.insert(data.categories, 'İtalyanca düzensiz eylemler')
			break
		end
	end
	
	-- Mark terms with irregular past participles
	if args['pastp'] and args['pastp'] ~= '' and not data.refl  then
		table.insert(data.categories, 'İtalyanca düzensiz geçmiş zaman ortaçlı eylemler')
	end

	-- Non-finite forms
	data.forms.infinitive = override(data.forms.infinitive, {args["inf"]})
	data.forms.gerund = override(data.forms.gerund, {args["ger"], args["ger2"]})
	data.forms.pres_ptc = override(data.forms.pres_ptc, {args["presp"], args["presp2"]})
	data.forms.past_ptc = override(data.forms.past_ptc, {args["pastp"], args["pastp2"], args["pastp3"], args["pastp4"]})
	
	-- Present
	data.forms.pres_indc_1sg = override(data.forms.pres_indc_1sg, {args["pres1s"], args["pres1s2"]})
	data.forms.pres_indc_2sg = override(data.forms.pres_indc_2sg, {args["pres2s"], args["pres2s2"]})
	data.forms.pres_indc_3sg = override(data.forms.pres_indc_3sg, {args["pres3s"], args["pres3s2"]})
	data.forms.pres_indc_1pl = override(data.forms.pres_indc_1pl, {args["pres1p"], args["pres1p2"]})
	data.forms.pres_indc_2pl = override(data.forms.pres_indc_2pl, {args["pres2p"], args["pres2p2"]})
	data.forms.pres_indc_3pl = override(data.forms.pres_indc_3pl, {args["pres3p"], args["pres3p2"]})
	
	-- Imperfect
	data.forms.impf_indc_1sg = override(data.forms.impf_indc_1sg, {args["imperf1s"], args["imperf1s2"]})
	data.forms.impf_indc_2sg = override(data.forms.impf_indc_2sg, {args["imperf2s"], args["imperf2s2"]})
	data.forms.impf_indc_3sg = override(data.forms.impf_indc_3sg, {args["imperf3s"], args["imperf3s2"]})
	data.forms.impf_indc_1pl = override(data.forms.impf_indc_1pl, {args["imperf1p"], args["imperf1p2"]})
	data.forms.impf_indc_2pl = override(data.forms.impf_indc_2pl, {args["imperf2p"], args["imperf2p2"]})
	data.forms.impf_indc_3pl = override(data.forms.impf_indc_3pl, {args["imperf3p"], args["imperf3p2"]})
	
	-- Past historic
	data.forms.phis_indc_1sg = override(data.forms.phis_indc_1sg, {args["prem1s"], args["prem1s2"], args["prem1s3"]})
	data.forms.phis_indc_2sg = override(data.forms.phis_indc_2sg, {args["prem2s"], args["prem2s2"]})
	data.forms.phis_indc_3sg = override(data.forms.phis_indc_3sg, {args["prem3s"], args["prem3s2"], args["prem3s3"]})
	data.forms.phis_indc_1pl = override(data.forms.phis_indc_1pl, {args["prem1p"], args["prem1p2"]})
	data.forms.phis_indc_2pl = override(data.forms.phis_indc_2pl, {args["prem2p"], args["prem2p2"]})
	data.forms.phis_indc_3pl = override(data.forms.phis_indc_3pl, {args["prem3p"], args["prem3p2"], args["prem3p3"]})
	
	-- Future
	data.forms.futr_indc_1sg = override(data.forms.futr_indc_1sg, {args["fut1s"], args["fut1s2"]})
	data.forms.futr_indc_2sg = override(data.forms.futr_indc_2sg, {args["fut2s"], args["fut2s2"]})
	data.forms.futr_indc_3sg = override(data.forms.futr_indc_3sg, {args["fut3s"], args["fut3s2"]})
	data.forms.futr_indc_1pl = override(data.forms.futr_indc_1pl, {args["fut1p"], args["fut1p2"]})
	data.forms.futr_indc_2pl = override(data.forms.futr_indc_2pl, {args["fut2p"], args["fut2p2"]})
	data.forms.futr_indc_3pl = override(data.forms.futr_indc_3pl, {args["fut3p"], args["fut3p2"]})
	
	-- Conditional
	data.forms.cond_1sg = override(data.forms.cond_1sg, {args["cond1s"], args["cond1s2"]})
	data.forms.cond_2sg = override(data.forms.cond_2sg, {args["cond2s"], args["cond2s2"]})
	data.forms.cond_3sg = override(data.forms.cond_3sg, {args["cond3s"], args["cond3s2"]})
	data.forms.cond_1pl = override(data.forms.cond_1pl, {args["cond1p"], args["cond1p2"]})
	data.forms.cond_2pl = override(data.forms.cond_2pl, {args["cond2p"], args["cond2p2"]})
	data.forms.cond_3pl = override(data.forms.cond_3pl, {args["cond3p"], args["cond3p2"]})
	
	-- Present subjunctive
	data.forms.pres_subj_123sg = override(data.forms.pres_subj_123sg, {args["sub123s"], args["sub123s2"]})
	data.forms.pres_subj_3sg = override(data.forms.pres_subj_3sg, {args["sub3s"], args["sub3s2"]})
	data.forms.pres_subj_1pl = override(data.forms.pres_subj_1pl, {args["sub1p"], args["sub1p2"]})
	data.forms.pres_subj_2pl = override(data.forms.pres_subj_2pl, {args["sub2p"], args["sub2p2"]})
	data.forms.pres_subj_3pl = override(data.forms.pres_subj_3pl, {args["sub3p"], args["sub3p2"]})
	
	-- Imperfect subjunctive
	data.forms.impf_subj_12sg = override(data.forms.impf_subj_12sg, {args["impsub12s"], args["impsub12s2"]})
	data.forms.impf_subj_3sg = override(data.forms.impf_subj_3sg, {args["impsub3s"], args["impsub3s2"]})
	data.forms.impf_subj_1pl = override(data.forms.impf_subj_1pl, {args["impsub1p"], args["impsub1p2"]})
	data.forms.impf_subj_2pl = override(data.forms.impf_subj_2pl, {args["impsub2p"], args["impsub2p2"]})
	data.forms.impf_subj_3pl = override(data.forms.impf_subj_3pl, {args["impsub3p"], args["impsub3p2"]})
	
	-- Imperative
	data.forms.impr_2sg = override(data.forms.impr_2sg, {args["imp2s"], args["imp2s2"], args["imp2s3"], args["imp2s4"]})
	data.forms.impr_3sg = override(data.forms.impr_3sg, {args["imp3s"], args["imp3s2"]})
	data.forms.impr_1pl = override(data.forms.impr_1pl, {args["imp1p"], args["imp1p2"]})
	data.forms.impr_2pl = override(data.forms.impr_2pl, {args["imp2p"], args["imp2p2"]})
	data.forms.impr_3pl = override(data.forms.impr_3pl, {args["imp3p"], args["imp3p2"]})
end

-- Adds reflexive pronouns to the appropriate forms
function add_reflexive_pronouns(args, data)
	-- Gather pronoun parameters
	local pronouns = {}
	
	pronouns["1sg"] = args["mi"] or ""; if pronouns["1sg"] == "" then pronouns["1sg"] = "mi" end
	pronouns["2sg"] = args["ti"] or ""; if pronouns["2sg"] == "" then pronouns["2sg"] = "ti" end
	pronouns["3sg"] = args["si"] or ""; if pronouns["3sg"] == "" then pronouns["3sg"] = "si" end
	pronouns["1pl"] = args["ci"] or ""; if pronouns["1pl"] == "" then pronouns["1pl"] = "ci" end
	pronouns["2pl"] = args["vi"] or ""; if pronouns["2pl"] == "" then pronouns["2pl"] = "vi" end
	pronouns["3pl"] = pronouns["3sg"]
	
	-- Go over all the forms in the list
	for key, subforms in pairs(data.forms) do
		-- Extract the person/number from the last 3 characters of the key
		local person = key:sub(-3)
		
		-- Skip these three, as they already had pronouns added earlier
		if pronouns[person] and key ~= "impr_2sg" and key ~= "impr_1pl" and key ~= "impr_2pl" then
			-- Go through each of the alternative subforms and add the pronoun
			for key2, subform in ipairs(subforms) do
				data.forms[key][key2] = pronouns[person] .. " [[" .. subform .. "]]"
			end
		end
	end
end


-- Inflection functions

inflections["are"] = function(args, data)
	local stem = args[1]
	
	data.forms.infinitive = {stem .. "are"}
	data.forms.gerund = {stem .. "ando"}
	data.forms.pres_ptc = {stem .. "ante"}
	data.forms.past_ptc = {stem .. "ato"}
	
	data.forms.pres_indc_1sg = {stem .. "o"}
	data.forms.pres_indc_2sg = {stem .. "i"}
	data.forms.pres_indc_3sg = {stem .. "a"}
	data.forms.pres_indc_1pl = {stem .. "iamo"}
	data.forms.pres_indc_2pl = {stem .. "ate"}
	data.forms.pres_indc_3pl = {stem .. "ano"}
	
	data.forms.impf_indc_1sg = {stem .. "avo"}
	data.forms.impf_indc_2sg = {stem .. "avi"}
	data.forms.impf_indc_3sg = {stem .. "ava"}
	data.forms.impf_indc_1pl = {stem .. "avamo"}
	data.forms.impf_indc_2pl = {stem .. "avate"}
	data.forms.impf_indc_3pl = {stem .. "avano"}
	
	data.forms.phis_indc_1sg = {stem .. "ai"}
	data.forms.phis_indc_2sg = {stem .. "asti"}
	data.forms.phis_indc_3sg = {stem .. "ò"}
	data.forms.phis_indc_1pl = {stem .. "ammo"}
	data.forms.phis_indc_2pl = {stem .. "aste"}
	data.forms.phis_indc_3pl = {stem .. "arono"}
	
	data.forms.futr_indc_1sg = {stem .. "erò"}
	data.forms.futr_indc_2sg = {stem .. "erai"}
	data.forms.futr_indc_3sg = {stem .. "erà"}
	data.forms.futr_indc_1pl = {stem .. "eremo"}
	data.forms.futr_indc_2pl = {stem .. "erete"}
	data.forms.futr_indc_3pl = {stem .. "eranno"}
	
	data.forms.cond_1sg = {stem .. "erei"}
	data.forms.cond_2sg = {stem .. "eresti"}
	data.forms.cond_3sg = {stem .. "erebbe"}
	data.forms.cond_1pl = {stem .. "eremmo"}
	data.forms.cond_2pl = {stem .. "ereste"}
	data.forms.cond_3pl = {stem .. "erebbero"}
	
	data.forms.pres_subj_123sg = {stem .. "i"}
	data.forms.pres_subj_3sg = nil
	data.forms.pres_subj_1pl = {stem .. "iamo"}
	data.forms.pres_subj_2pl = {stem .. "iate"}
	data.forms.pres_subj_3pl = {stem .. "ino"}
	
	data.forms.impf_subj_12sg = {stem .. "assi"}
	data.forms.impf_subj_3sg = {stem .. "asse"}
	data.forms.impf_subj_1pl = {stem .. "assimo"}
	data.forms.impf_subj_2pl = {stem .. "aste"}
	data.forms.impf_subj_3pl = {stem .. "assero"}
	
	data.forms.impr_2sg = {stem .. "a", "non [[" .. stem .. "are]]"}
	data.forms.impr_3sg = {stem .. "i"}
	data.forms.impr_1pl = {stem .. "iamo"}
	data.forms.impr_2pl = {stem .. "ate"}
	data.forms.impr_3pl = {stem .. "ino"}
end

inflections["arsi"] = function(args, data)
	inflections["are"](args, data)
	
	local stem = args[1]
	data.refl = true
	
	data.forms.infinitive = {stem .. "arsi"}
	data.forms.gerund = {stem .. "andosi"}
	data.forms.pres_ptc = {stem .. "antesi"}
	table.insert(data.forms.past_ptc, stem .. "atosi")
	if args["inf"] and mw.ustring.match(args["inf"], "ne$") then
		data.forms.impr_2sg = {stem .. "atene", "non te ne [[" .. stem .. "are]]", "non [[" .. stem .. "artene]]"}
	elseif args["inf"] and mw.ustring.match(args["inf"], "la$") then
		data.forms.impr_2sg = {stem .. "atela", "non te la [[" .. stem .. "are]]", "non [[" .. stem .. "artela]]"}
	else
		data.forms.impr_2sg = {stem .. "ati", "non ti [[" .. stem .. "are]]", "non [[" .. stem .. "arti]]"}
	end	
	data.forms.impr_1pl = {stem .. "iamoci"}
	data.forms.impr_2pl = {stem .. "atevi"}
end

inflections["care"] = function(args, data)
	local stem = args[1]
	
	data.forms.infinitive = {stem .. "are"}
	data.forms.gerund = {stem .. "ando"}
	data.forms.pres_ptc = {stem .. "ante"}
	data.forms.past_ptc = {stem .. "ato"}
	
	data.forms.pres_indc_1sg = {stem .. "o"}
	data.forms.pres_indc_2sg = {stem .. "hi"}
	data.forms.pres_indc_3sg = {stem .. "a"}
	data.forms.pres_indc_1pl = {stem .. "hiamo"}
	data.forms.pres_indc_2pl = {stem .. "ate"}
	data.forms.pres_indc_3pl = {stem .. "ano"}
	
	data.forms.impf_indc_1sg = {stem .. "avo"}
	data.forms.impf_indc_2sg = {stem .. "avi"}
	data.forms.impf_indc_3sg = {stem .. "ava"}
	data.forms.impf_indc_1pl = {stem .. "avamo"}
	data.forms.impf_indc_2pl = {stem .. "avate"}
	data.forms.impf_indc_3pl = {stem .. "avano"}
	
	data.forms.phis_indc_1sg = {stem .. "ai"}
	data.forms.phis_indc_2sg = {stem .. "asti"}
	data.forms.phis_indc_3sg = {stem .. "ò"}
	data.forms.phis_indc_1pl = {stem .. "ammo"}
	data.forms.phis_indc_2pl = {stem .. "aste"}
	data.forms.phis_indc_3pl = {stem .. "arono"}
	
	data.forms.futr_indc_1sg = {stem .. "herò"}
	data.forms.futr_indc_2sg = {stem .. "herai"}
	data.forms.futr_indc_3sg = {stem .. "herà"}
	data.forms.futr_indc_1pl = {stem .. "heremo"}
	data.forms.futr_indc_2pl = {stem .. "herete"}
	data.forms.futr_indc_3pl = {stem .. "heranno"}
	
	data.forms.cond_1sg = {stem .. "herei"}
	data.forms.cond_2sg = {stem .. "heresti"}
	data.forms.cond_3sg = {stem .. "herebbe"}
	data.forms.cond_1pl = {stem .. "heremmo"}
	data.forms.cond_2pl = {stem .. "hereste"}
	data.forms.cond_3pl = {stem .. "herebbero"}
	
	data.forms.pres_subj_123sg = {stem .. "hi"}
	data.forms.pres_subj_3sg = nil
	data.forms.pres_subj_1pl = {stem .. "hiamo"}
	data.forms.pres_subj_2pl = {stem .. "hiate"}
	data.forms.pres_subj_3pl = {stem .. "hino"}
	
	data.forms.impf_subj_12sg = {stem .. "assi"}
	data.forms.impf_subj_3sg = {stem .. "asse"}
	data.forms.impf_subj_1pl = {stem .. "assimo"}
	data.forms.impf_subj_2pl = {stem .. "aste"}
	data.forms.impf_subj_3pl = {stem .. "assero"}
	
	data.forms.impr_2sg = {stem .. "a", "non [[" .. stem .. "are]]"}
	data.forms.impr_3sg = {stem .. "hi"}
	data.forms.impr_1pl = {stem .. "hiamo"}
	data.forms.impr_2pl = {stem .. "ate"}
	data.forms.impr_3pl = {stem .. "hino"}
end

inflections["carsi"] = function(args, data)
	inflections["care"](args, data)
	
	local stem = args[1]
	data.refl = true
	
	data.forms.infinitive = {stem .. "arsi"}
	data.forms.gerund = {stem .. "andosi"}
	data.forms.pres_ptc = {stem .. "antesi"}
	table.insert(data.forms.past_ptc, stem .. "atosi")
	if args["inf"] and mw.ustring.match(args["inf"], "ne$") then
		data.forms.impr_2sg = {stem .. "atene", "non te ne [[" .. stem .. "are]]", "non [[" .. stem .. "artene]]"}
	elseif args["inf"] and mw.ustring.match(args["inf"], "la$") then
		data.forms.impr_2sg = {stem .. "atela", "non te la [[" .. stem .. "are]]", "non [[" .. stem .. "artela]]"}
	else
		data.forms.impr_2sg = {stem .. "ati", "non ti [[" .. stem .. "are]]", "non [[" .. stem .. "arti]]"}
	end	
	data.forms.impr_1pl = {stem .. "hiamoci"}
	data.forms.impr_2pl = {stem .. "atevi"}
end

inflections["iare"] = function(args, data)
	local stem = args[1]
	
	data.forms.infinitive = {stem .. "are"}
	data.forms.gerund = {stem .. "ando"}
	data.forms.pres_ptc = {stem .. "ante"}
	data.forms.past_ptc = {stem .. "ato"}
	
	data.forms.pres_indc_1sg = {stem .. "o"}
	data.forms.pres_indc_2sg = {stem}
	data.forms.pres_indc_3sg = {stem .. "a"}
	data.forms.pres_indc_1pl = {stem .. "amo"}
	data.forms.pres_indc_2pl = {stem .. "ate"}
	data.forms.pres_indc_3pl = {stem .. "ano"}
	
	data.forms.impf_indc_1sg = {stem .. "avo"}
	data.forms.impf_indc_2sg = {stem .. "avi"}
	data.forms.impf_indc_3sg = {stem .. "ava"}
	data.forms.impf_indc_1pl = {stem .. "avamo"}
	data.forms.impf_indc_2pl = {stem .. "avate"}
	data.forms.impf_indc_3pl = {stem .. "avano"}
	
	data.forms.phis_indc_1sg = {stem .. "ai"}
	data.forms.phis_indc_2sg = {stem .. "asti"}
	data.forms.phis_indc_3sg = {stem .. "ò"}
	data.forms.phis_indc_1pl = {stem .. "ammo"}
	data.forms.phis_indc_2pl = {stem .. "aste"}
	data.forms.phis_indc_3pl = {stem .. "arono"}
	
	data.forms.futr_indc_1sg = {stem .. "erò"}
	data.forms.futr_indc_2sg = {stem .. "erai"}
	data.forms.futr_indc_3sg = {stem .. "erà"}
	data.forms.futr_indc_1pl = {stem .. "eremo"}
	data.forms.futr_indc_2pl = {stem .. "erete"}
	data.forms.futr_indc_3pl = {stem .. "eranno"}
	
	data.forms.cond_1sg = {stem .. "erei"}
	data.forms.cond_2sg = {stem .. "eresti"}
	data.forms.cond_3sg = {stem .. "erebbe"}
	data.forms.cond_1pl = {stem .. "eremmo"}
	data.forms.cond_2pl = {stem .. "ereste"}
	data.forms.cond_3pl = {stem .. "erebbero"}
	
	data.forms.pres_subj_123sg = {stem}
	data.forms.pres_subj_3sg = nil
	data.forms.pres_subj_1pl = {stem .. "amo"}
	data.forms.pres_subj_2pl = {stem .. "ate"}
	data.forms.pres_subj_3pl = {stem .. "no"}
	
	data.forms.impf_subj_12sg = {stem .. "assi"}
	data.forms.impf_subj_3sg = {stem .. "asse"}
	data.forms.impf_subj_1pl = {stem .. "assimo"}
	data.forms.impf_subj_2pl = {stem .. "aste"}
	data.forms.impf_subj_3pl = {stem .. "assero"}
	
	data.forms.impr_2sg = {stem .. "a", "non [[" .. stem .. "are]]"}
	data.forms.impr_3sg = {stem}
	data.forms.impr_1pl = {stem .. "amo"}
	data.forms.impr_2pl = {stem .. "ate"}
	data.forms.impr_3pl = {stem .. "no"}
end

inflections["iarsi"] = function(args, data)
	inflections["iare"](args, data)
	
	local stem = args[1]
	data.refl = true
	
	data.forms.infinitive = {stem .. "arsi"}
	data.forms.gerund = {stem .. "andosi"}
	data.forms.pres_ptc = {stem .. "antesi"}
	table.insert(data.forms.past_ptc, stem .. "atosi")
	if args["inf"] and mw.ustring.match(args["inf"], "ne$") then
		data.forms.impr_2sg = {stem .. "atene", "non te ne [[" .. stem .. "are]]", "non [[" .. stem .. "artene]]"}
	elseif args["inf"] and mw.ustring.match(args["inf"], "la$") then
		data.forms.impr_2sg = {stem .. "atela", "non te la [[" .. stem .. "are]]", "non [[" .. stem .. "artela]]"}
	else
		data.forms.impr_2sg = {stem .. "ati", "non ti [[" .. stem .. "are]]", "non [[" .. stem .. "arti]]"}
	end	
	data.forms.impr_1pl = {stem .. "amoci"}
	data.forms.impr_2pl = {stem .. "atevi"}
end

inflections["ciare"] = function(args, data)
	local stem = args[1]
	
	data.forms.infinitive = {stem .. "iare"}
	data.forms.gerund = {stem .. "iando"}
	data.forms.pres_ptc = {stem .. "iante"}
	data.forms.past_ptc = {stem .. "iato"}
	
	data.forms.pres_indc_1sg = {stem .. "io"}
	data.forms.pres_indc_2sg = {stem .. "i"}
	data.forms.pres_indc_3sg = {stem .. "ia"}
	data.forms.pres_indc_1pl = {stem .. "iamo"}
	data.forms.pres_indc_2pl = {stem .. "iate"}
	data.forms.pres_indc_3pl = {stem .. "iano"}
	
	data.forms.impf_indc_1sg = {stem .. "iavo"}
	data.forms.impf_indc_2sg = {stem .. "iavi"}
	data.forms.impf_indc_3sg = {stem .. "iava"}
	data.forms.impf_indc_1pl = {stem .. "iavamo"}
	data.forms.impf_indc_2pl = {stem .. "iavate"}
	data.forms.impf_indc_3pl = {stem .. "iavano"}
	
	data.forms.phis_indc_1sg = {stem .. "iai"}
	data.forms.phis_indc_2sg = {stem .. "iasti"}
	data.forms.phis_indc_3sg = {stem .. "iò"}
	data.forms.phis_indc_1pl = {stem .. "iammo"}
	data.forms.phis_indc_2pl = {stem .. "iaste"}
	data.forms.phis_indc_3pl = {stem .. "iarono"}
	
	data.forms.futr_indc_1sg = {stem .. "erò"}
	data.forms.futr_indc_2sg = {stem .. "erai"}
	data.forms.futr_indc_3sg = {stem .. "erà"}
	data.forms.futr_indc_1pl = {stem .. "eremo"}
	data.forms.futr_indc_2pl = {stem .. "erete"}
	data.forms.futr_indc_3pl = {stem .. "eranno"} 
	
	data.forms.cond_1sg = {stem .. "erei"}
	data.forms.cond_2sg = {stem .. "eresti"}
	data.forms.cond_3sg = {stem .. "erebbe"}
	data.forms.cond_1pl = {stem .. "eremmo"}
	data.forms.cond_2pl = {stem .. "ereste"}
	data.forms.cond_3pl = {stem .. "erebbero"}
	
	data.forms.pres_subj_123sg = {stem .. "i"}
	data.forms.pres_subj_3sg = nil
	data.forms.pres_subj_1pl = {stem .. "iamo"}
	data.forms.pres_subj_2pl = {stem .. "iate"}
	data.forms.pres_subj_3pl = {stem .. "ino"}
	
	data.forms.impf_subj_12sg = {stem .. "iassi"}
	data.forms.impf_subj_3sg = {stem .. "iasse"}
	data.forms.impf_subj_1pl = {stem .. "iassimo"}
	data.forms.impf_subj_2pl = {stem .. "iaste"}
	data.forms.impf_subj_3pl = {stem .. "iassero"}
	
	data.forms.impr_2sg = {stem .. "ia", "non [[" .. stem .. "iare]]"}
	data.forms.impr_3sg = {stem .. "i"}
	data.forms.impr_1pl = {stem .. "iamo"}
	data.forms.impr_2pl = {stem .. "iate"}
	data.forms.impr_3pl = {stem .. "ino"}
end

inflections["ciarsi"] = function(args, data)
	inflections["ciare"](args, data)
	
	local stem = args[1]
	data.refl = true
	
	data.forms.infinitive = {stem .. "iarsi"}
	data.forms.gerund = {stem .. "iandosi"}
	data.forms.pres_ptc = {stem .. "iantesi"}
	table.insert(data.forms.past_ptc, stem .. "iatosi")
	if args["inf"] and mw.ustring.match(args["inf"], "ne$") then
		data.forms.impr_2sg = {stem .. "iatene", "non te ne [[" .. stem .. "iare]]", "non [[" .. stem .. "iartene]]"}
	elseif args["inf"] and mw.ustring.match(args["inf"], "la$") then
		data.forms.impr_2sg = {stem .. "iatela", "non te la [[" .. stem .. "iare]]", "non [[" .. stem .. "iartela]]"}
	else
		data.forms.impr_2sg = {stem .. "iati", "non ti [[" .. stem .. "iare]]", "non [[" .. stem .. "iarti]]"}
	end	
	data.forms.impr_1pl = {stem .. "iamoci"}
	data.forms.impr_2pl = {stem .. "iatevi"}
end

inflections["ere"] = function(args, data)
	local stem = args[1]
	
	data.forms.infinitive = {stem .. "ere"}
	data.forms.gerund = {stem .. "endo"}
	data.forms.pres_ptc = {stem .. "ente"}
	data.forms.past_ptc = {stem .. "uto"}
	
	data.forms.pres_indc_1sg = {stem .. "o"}
	data.forms.pres_indc_2sg = {stem .. "i"}
	data.forms.pres_indc_3sg = {stem .. "e"}
	data.forms.pres_indc_1pl = {stem .. "iamo"}
	data.forms.pres_indc_2pl = {stem .. "ete"}
	data.forms.pres_indc_3pl = {stem .. "ono"}
	
	data.forms.impf_indc_1sg = {stem .. "evo"}
	data.forms.impf_indc_2sg = {stem .. "evi"}
	data.forms.impf_indc_3sg = {stem .. "eva"}
	data.forms.impf_indc_1pl = {stem .. "evamo"}
	data.forms.impf_indc_2pl = {stem .. "evate"}
	data.forms.impf_indc_3pl = {stem .. "evano"}
	
	data.forms.phis_indc_1sg = {stem .. "ei"}
	data.forms.phis_indc_2sg = {stem .. "esti"}
	data.forms.phis_indc_3sg = {stem .. "ette", stem .. "é"}
	data.forms.phis_indc_1pl = {stem .. "emmo"}
	data.forms.phis_indc_2pl = {stem .. "este"}
	data.forms.phis_indc_3pl = {stem .. "ettero", stem .. "erono"}
	
	data.forms.futr_indc_1sg = {stem .. "erò"}
	data.forms.futr_indc_2sg = {stem .. "erai"}
	data.forms.futr_indc_3sg = {stem .. "erà"}
	data.forms.futr_indc_1pl = {stem .. "eremo"}
	data.forms.futr_indc_2pl = {stem .. "erete"}
	data.forms.futr_indc_3pl = {stem .. "eranno"}
	
	data.forms.cond_1sg = {stem .. "erei"}
	data.forms.cond_2sg = {stem .. "eresti"}
	data.forms.cond_3sg = {stem .. "erebbe"}
	data.forms.cond_1pl = {stem .. "eremmo"}
	data.forms.cond_2pl = {stem .. "ereste"}
	data.forms.cond_3pl = {stem .. "erebbero"}
	
	data.forms.pres_subj_123sg = {stem .. "a"}
	data.forms.pres_subj_3sg = nil
	data.forms.pres_subj_1pl = {stem .. "iamo"}
	data.forms.pres_subj_2pl = {stem .. "iate"}
	data.forms.pres_subj_3pl = {stem .. "ano"}
	
	data.forms.impf_subj_12sg = {stem .. "essi"}
	data.forms.impf_subj_3sg = {stem .. "esse"}
	data.forms.impf_subj_1pl = {stem .. "essimo"}
	data.forms.impf_subj_2pl = {stem .. "este"}
	data.forms.impf_subj_3pl = {stem .. "essero"}
	
	if mw.ustring.match(stem, "a$") then
		data.forms.impr_2sg = {stem .. "i", "non [[" .. stem .. "rre]]"}
	elseif args["inf"] and mw.ustring.match(args["inf"], "orre$") then
		data.forms.impr_2sg = {stem .. "i", "non [[" .. args["inf"] .. "]]"}
	else
		data.forms.impr_2sg = {stem .. "i", "non [[" .. stem .. "ere]]"}
	end	
	
	data.forms.impr_3sg = {stem .. "a"}
	data.forms.impr_1pl = {stem .. "iamo"}
	data.forms.impr_2pl = {stem .. "ete"}
	data.forms.impr_3pl = {stem .. "ano"}
end

inflections["ersi"] = function(args, data)
	inflections["ere"](args, data)
	
	local stem = args[1]
	local stem2 = ""
	data.refl = true
	
	data.forms.infinitive = {stem .. "ersi"}
	data.forms.gerund = {stem .. "endosi"}
	data.forms.pres_ptc = {stem .. "entesi"}
	table.insert(data.forms.past_ptc, stem .. "utosi")
	if mw.ustring.match(stem, "a$") then
		if args["inf"] and mw.ustring.match(args["inf"], "ne$") then
			data.forms.impr_2sg = {stem .. "itene", "non te ne [[" .. stem .. "rre]]", "non [[" .. stem .. "rtene]]"}
		elseif args["inf"] and mw.ustring.match(args["inf"], "la$") then
			data.forms.impr_2sg = {stem .. "itela", "non te la [[" .. stem .. "rre]]", "non [[" .. stem .. "rtela]]"}
		else
			data.forms.impr_2sg = {stem .. "i", "non ti [[" .. stem .. "rre]]", "non [[" .. stem .. "rti]]"}
		end	
	elseif args["inf"] and mw.ustring.match(args["inf"], "orsi$") then
		stem2 = stem:gsub("(n)$", {["n"] = "r"})
		if args["inf"] and mw.ustring.match(args["inf"], "ne$") then
			data.forms.impr_2sg = {stem .. "itene", "non te ne [[" .. stem2 .. "re]]", "non [[" .. stem2 .. "tene]]"}
		elseif args["inf"] and mw.ustring.match(args["inf"], "la$") then
			data.forms.impr_2sg = {stem .. "itela", "non te la [[" .. stem2 .. "re]]", "non [[" .. stem2 .. "tela]]"}
		else
			data.forms.impr_2sg = {stem .. "i", "non ti [[" .. stem2 .. "re]]", "non [[" .. stem2 .. "ti]]"}
		end	
	else
		if args["inf"] and mw.ustring.match(args["inf"], "ne$") then
			data.forms.impr_2sg = {stem .. "itene", "non te ne [[" .. stem .. "ere]]", "non [[" .. stem .. "ertene]]"}
		elseif args["inf"] and mw.ustring.match(args["inf"], "la$") then
			data.forms.impr_2sg = {stem .. "itela", "non te la [[" .. stem .. "ere]]", "non [[" .. stem .. "ertela]]"}
		else
			data.forms.impr_2sg = {stem .. "iti", "non ti [[" .. stem .. "ere]]", "non [[" .. stem .. "erti]]"}
		end	
	end	
	data.forms.impr_1pl = {stem .. "iamoci"}
	data.forms.impr_2pl = {stem .. "etevi"}
end

inflections["ire"] = function(args, data)
	local stem = args[1]
	
	data.forms.infinitive = {stem .. "ire"}
	data.forms.gerund = {stem .. "endo"}
	data.forms.pres_ptc = {stem .. "ente"}
	data.forms.past_ptc = {stem .. "ito"}
	
	data.forms.pres_indc_1sg = {stem .. "o"}
	data.forms.pres_indc_2sg = {stem .. "i"}
	data.forms.pres_indc_3sg = {stem .. "e"}
	data.forms.pres_indc_1pl = {stem .. "iamo"}
	data.forms.pres_indc_2pl = {stem .. "ite"}
	data.forms.pres_indc_3pl = {stem .. "ono"}
	
	data.forms.impf_indc_1sg = {stem .. "ivo"}
	data.forms.impf_indc_2sg = {stem .. "ivi"}
	data.forms.impf_indc_3sg = {stem .. "iva"}
	data.forms.impf_indc_1pl = {stem .. "ivamo"}
	data.forms.impf_indc_2pl = {stem .. "ivate"}
	data.forms.impf_indc_3pl = {stem .. "ivano"}
	
	data.forms.phis_indc_1sg = {stem .. "ii"}
	data.forms.phis_indc_2sg = {stem .. "isti"}
	data.forms.phis_indc_3sg = {stem .. "ì"}
	data.forms.phis_indc_1pl = {stem .. "immo"}
	data.forms.phis_indc_2pl = {stem .. "iste"}
	data.forms.phis_indc_3pl = {stem .. "irono"}
	
	data.forms.futr_indc_1sg = {stem .. "irò"}
	data.forms.futr_indc_2sg = {stem .. "irai"}
	data.forms.futr_indc_3sg = {stem .. "irà"}
	data.forms.futr_indc_1pl = {stem .. "iremo"}
	data.forms.futr_indc_2pl = {stem .. "irete"}
	data.forms.futr_indc_3pl = {stem .. "iranno"}
	
	data.forms.cond_1sg = {stem .. "irei"}
	data.forms.cond_2sg = {stem .. "iresti"}
	data.forms.cond_3sg = {stem .. "irebbe"}
	data.forms.cond_1pl = {stem .. "iremmo"}
	data.forms.cond_2pl = {stem .. "ireste"}
	data.forms.cond_3pl = {stem .. "irebbero"}
	
	data.forms.pres_subj_123sg = {stem .. "a"}
	data.forms.pres_subj_3sg = nil
	data.forms.pres_subj_1pl = {stem .. "iamo"}
	data.forms.pres_subj_2pl = {stem .. "iate"}
	data.forms.pres_subj_3pl = {stem .. "ano"}
	
	data.forms.impf_subj_12sg = {stem .. "issi"}
	data.forms.impf_subj_3sg = {stem .. "isse"}
	data.forms.impf_subj_1pl = {stem .. "issimo"}
	data.forms.impf_subj_2pl = {stem .. "iste"}
	data.forms.impf_subj_3pl = {stem .. "issero"}
	
	data.forms.impr_2sg = {stem .. "i", "non [[" .. stem .. "ire]]"}
	data.forms.impr_3sg = {stem .. "a"}
	data.forms.impr_1pl = {stem .. "iamo"}
	data.forms.impr_2pl = {stem .. "ite"}
	data.forms.impr_3pl = {stem .. "ano"}
end

inflections["irsi"] = function(args, data)
	inflections["ire"](args, data)
	
	local stem = args[1]
	data.refl = true
	
	data.forms.infinitive = {stem .. "irsi"}
	data.forms.gerund = {stem .. "endosi"}
	data.forms.pres_ptc = {stem .. "entesi"}
	table.insert(data.forms.past_ptc, stem .. "itosi")
	if args["inf"] and mw.ustring.match(args["inf"], "ne$") then
		data.forms.impr_2sg = {stem .. "itene", "non te ne [[" .. stem .. "ire]]", "non [[" .. stem .. "irtene]]"}
	elseif args["inf"] and mw.ustring.match(args["inf"], "la$") then
		data.forms.impr_2sg = {stem .. "itela", "non te la [[" .. stem .. "ire]]", "non [[" .. stem .. "irtela]]"}
	else
		data.forms.impr_2sg = {stem .. "iti", "non ti [[" .. stem .. "ire]]", "non [[" .. stem .. "irti]]"}
	end	
	data.forms.impr_1pl = {stem .. "iamoci"}
	data.forms.impr_2pl = {stem .. "itevi"}
end

inflections["ire-b"] = function(args, data)
	local stem = args[1]
	
	data.forms.infinitive = {stem .. "ire"}
	data.forms.gerund = {stem .. "endo"}
	data.forms.pres_ptc = {stem .. "ente"}
	data.forms.past_ptc = {stem .. "ito"}
	
	data.forms.pres_indc_1sg = {stem .. "isco"}
	data.forms.pres_indc_2sg = {stem .. "isci"}
	data.forms.pres_indc_3sg = {stem .. "isce"}
	data.forms.pres_indc_1pl = {stem .. "iamo"}
	data.forms.pres_indc_2pl = {stem .. "ite"}
	data.forms.pres_indc_3pl = {stem .. "iscono"}
	
	data.forms.impf_indc_1sg = {stem .. "ivo"}
	data.forms.impf_indc_2sg = {stem .. "ivi"}
	data.forms.impf_indc_3sg = {stem .. "iva"}
	data.forms.impf_indc_1pl = {stem .. "ivamo"}
	data.forms.impf_indc_2pl = {stem .. "ivate"}
	data.forms.impf_indc_3pl = {stem .. "ivano"}
	
	data.forms.phis_indc_1sg = {stem .. "ii"}
	data.forms.phis_indc_2sg = {stem .. "isti"}
	data.forms.phis_indc_3sg = {stem .. "ì"}
	data.forms.phis_indc_1pl = {stem .. "immo"}
	data.forms.phis_indc_2pl = {stem .. "iste"}
	data.forms.phis_indc_3pl = {stem .. "irono"}
	
	data.forms.futr_indc_1sg = {stem .. "irò"}
	data.forms.futr_indc_2sg = {stem .. "irai"}
	data.forms.futr_indc_3sg = {stem .. "irà"}
	data.forms.futr_indc_1pl = {stem .. "iremo"}
	data.forms.futr_indc_2pl = {stem .. "irete"}
	data.forms.futr_indc_3pl = {stem .. "iranno"}
	
	data.forms.cond_1sg = {stem .. "irei"}
	data.forms.cond_2sg = {stem .. "iresti"}
	data.forms.cond_3sg = {stem .. "irebbe"}
	data.forms.cond_1pl = {stem .. "iremmo"}
	data.forms.cond_2pl = {stem .. "ireste"}
	data.forms.cond_3pl = {stem .. "irebbero"} 
	
	data.forms.pres_subj_123sg = {stem .. "isca"}
	data.forms.pres_subj_3sg = nil
	data.forms.pres_subj_1pl = {stem .. "iamo"}
	data.forms.pres_subj_2pl = {stem .. "iate"}
	data.forms.pres_subj_3pl = {stem .. "iscano"}
	
	data.forms.impf_subj_12sg = {stem .. "issi"}
	data.forms.impf_subj_3sg = {stem .. "isse"}
	data.forms.impf_subj_1pl = {stem .. "issimo"}
	data.forms.impf_subj_2pl = {stem .. "iste"}
	data.forms.impf_subj_3pl = {stem .. "issero"}
	
	data.forms.impr_2sg = {stem .. "isci", "non [[" .. stem .. "ire]]"}
	data.forms.impr_3sg = {stem .. "isca"}
	data.forms.impr_1pl = {stem .. "iamo"}
	data.forms.impr_2pl = {stem .. "ite"}
	data.forms.impr_3pl = {stem .. "iscano"}
end

inflections["irsi-b"] = function(args, data)
	inflections["ire-b"](args, data)
	
	local stem = args[1]
	data.refl = true
	
	data.forms.infinitive = {stem .. "irsi"}
	data.forms.gerund = {stem .. "endosi"}
	data.forms.pres_ptc = {stem .. "entesi"}
	table.insert(data.forms.past_ptc, stem .. "itosi")
	if args["inf"] and mw.ustring.match(args["inf"], "ne$") then
		data.forms.impr_2sg = {stem .. "iscitene", "non te ne [[" .. stem .. "ire]]", "non [[" .. stem .. "irtene]]"}
	elseif args["inf"] and mw.ustring.match(args["inf"], "la$") then
		data.forms.impr_2sg = {stem .. "iscitela", "non te la [[" .. stem .. "ire]]", "non [[" .. stem .. "irtela]]"}
	else
		data.forms.impr_2sg = {stem .. "isciti", "non ti [[" .. stem .. "ire]]", "non [[" .. stem .. "irti]]"}
	end	
	data.forms.impr_1pl = {stem .. "iamoci"}
	data.forms.impr_2pl = {stem .. "itevi"}
end

inflections["urre"] = function(args, data)
	local stem = args[1]
	
	data.forms.infinitive = {stem .. "urre"}
	data.forms.gerund = {stem .. "ucendo"}
	data.forms.pres_ptc = {stem .. "ucente"}
	data.forms.past_ptc = {stem .. "otto"}
	
	data.forms.pres_indc_1sg = {stem .. "uco"}
	data.forms.pres_indc_2sg = {stem .. "uci"}
	data.forms.pres_indc_3sg = {stem .. "uce"}
	data.forms.pres_indc_1pl = {stem .. "uciamo"}
	data.forms.pres_indc_2pl = {stem .. "ucete"}
	data.forms.pres_indc_3pl = {stem .. "ucono"}
	
	data.forms.impf_indc_1sg = {stem .. "ucevo"}
	data.forms.impf_indc_2sg = {stem .. "ucevi"}
	data.forms.impf_indc_3sg = {stem .. "uceva"}
	data.forms.impf_indc_1pl = {stem .. "ucevamo"}
	data.forms.impf_indc_2pl = {stem .. "ucevate"}
	data.forms.impf_indc_3pl = {stem .. "ucevano"}
	
	data.forms.phis_indc_1sg = {stem .. "ussi"}
	data.forms.phis_indc_2sg = {stem .. "ucesti"}
	data.forms.phis_indc_3sg = {stem .. "usse"}
	data.forms.phis_indc_1pl = {stem .. "ucemmo"}
	data.forms.phis_indc_2pl = {stem .. "uceste"}
	data.forms.phis_indc_3pl = {stem .. "ussero"}
	
	data.forms.futr_indc_1sg = {stem .. "urrò"}
	data.forms.futr_indc_2sg = {stem .. "urrai"}
	data.forms.futr_indc_3sg = {stem .. "urrà"}
	data.forms.futr_indc_1pl = {stem .. "urremo"}
	data.forms.futr_indc_2pl = {stem .. "urrete"}
	data.forms.futr_indc_3pl = {stem .. "urranno"} 
	
	data.forms.cond_1sg = {stem .. "urrei"}
	data.forms.cond_2sg = {stem .. "urresti"}
	data.forms.cond_3sg = {stem .. "urrebbe"}
	data.forms.cond_1pl = {stem .. "urremmo"}
	data.forms.cond_2pl = {stem .. "urreste"}
	data.forms.cond_3pl = {stem .. "urrebbero"} 
	
	data.forms.pres_subj_123sg = {stem .. "uca"}
	data.forms.pres_subj_3sg = nil
	data.forms.pres_subj_1pl = {stem .. "uciamo"}
	data.forms.pres_subj_2pl = {stem .. "uciate"}
	data.forms.pres_subj_3pl = {stem .. "ucano"}
	
	data.forms.impf_subj_12sg = {stem .. "ucessi"}
	data.forms.impf_subj_3sg = {stem .. "ucesse"}
	data.forms.impf_subj_1pl = {stem .. "ucessimo"}
	data.forms.impf_subj_2pl = {stem .. "uceste"}
	data.forms.impf_subj_3pl = {stem .. "ucessero"}
	
	data.forms.impr_2sg = {stem .. "uci", "non [[" .. stem .. "urre]]"}
	data.forms.impr_3sg = {stem .. "uca"}
	data.forms.impr_1pl = {stem .. "uciamo"}
	data.forms.impr_2pl = {stem .. "ucete"}
	data.forms.impr_3pl = {stem .. "ucano"}
end

inflections["ursi"] = function(args, data)
	inflections["urre"](args, data)
	
	local stem = args[1]
	data.refl = true
	
	data.forms.infinitive = {stem .. "ursi"}
	data.forms.gerund = {stem .. "ucendosi"}
	data.forms.pres_ptc = {stem .. "ucentesi"}
	table.insert(data.forms.past_ptc, stem .. "ottosi")
	if args["inf"] and mw.ustring.match(args["inf"], "ne$") then
		data.forms.impr_2sg = {stem .. "ucitene", "non te ne [[" .. stem .. "urre]]", "non [[" .. stem .. "urtene]]"}
	elseif args["inf"] and mw.ustring.match(args["inf"], "la$") then
		data.forms.impr_2sg = {stem .. "ucitela", "non te la [[" .. stem .. "urre]]", "non [[" .. stem .. "urtela]]"}
	else
		data.forms.impr_2sg = {stem .. "uciti", "non ti [[" .. stem .. "urre]]", "non [[" .. stem .. "urti]]"}
	end	
	data.forms.impr_1pl = {stem .. "uciamoci"}
	data.forms.impr_2pl = {stem .. "ucetevi"}
end

inflections["fare"] = function(args, data)
	local stem = args[1]
	
	data.forms.infinitive = {stem .. "fare"}
	data.forms.gerund = {stem .. "facendo"}
	data.forms.pres_ptc = {stem .. "facente"}
	data.forms.past_ptc = {stem .. "fatto"}
	
	data.forms.pres_indc_1sg = {stem .. "faccio", stem .. "fò"}
	data.forms.pres_indc_2sg = {stem .. "fai"}
	data.forms.pres_indc_3sg = {stem .. "fà"}
	data.forms.pres_indc_1pl = {stem .. "facciamo"}
	data.forms.pres_indc_2pl = {stem .. "fate"}
	data.forms.pres_indc_3pl = {stem .. "fanno"}
	
	data.forms.impf_indc_1sg = {stem .. "facevo"}
	data.forms.impf_indc_2sg = {stem .. "facevi"}
	data.forms.impf_indc_3sg = {stem .. "faceva"}
	data.forms.impf_indc_1pl = {stem .. "facevamo"}
	data.forms.impf_indc_2pl = {stem .. "facevate"}
	data.forms.impf_indc_3pl = {stem .. "facevano"}
	
	data.forms.phis_indc_1sg = {stem .. "feci"}
	data.forms.phis_indc_2sg = {stem .. "facesti"}
	data.forms.phis_indc_3sg = {stem .. "fece"}
	data.forms.phis_indc_1pl = {stem .. "facemmo"}
	data.forms.phis_indc_2pl = {stem .. "faceste"}
	data.forms.phis_indc_3pl = {stem .. "fecero"}
	
	data.forms.futr_indc_1sg = {stem .. "farò"}
	data.forms.futr_indc_2sg = {stem .. "farai"}
	data.forms.futr_indc_3sg = {stem .. "farà"}
	data.forms.futr_indc_1pl = {stem .. "faremo"}
	data.forms.futr_indc_2pl = {stem .. "farete"}
	data.forms.futr_indc_3pl = {stem .. "faranno"}
	
	data.forms.cond_1sg = {stem .. "farei"}
	data.forms.cond_2sg = {stem .. "faresti"}
	data.forms.cond_3sg = {stem .. "farebbe"}
	data.forms.cond_1pl = {stem .. "faremmo"}
	data.forms.cond_2pl = {stem .. "fareste"}
	data.forms.cond_3pl = {stem .. "farebbero"} 
	
	data.forms.pres_subj_123sg = {stem .. "faccia"}
	data.forms.pres_subj_3sg = nil
	data.forms.pres_subj_1pl = {stem .. "facciamo"}
	data.forms.pres_subj_2pl = {stem .. "facciate"}
	data.forms.pres_subj_3pl = {stem .. "facciano"}
	
	data.forms.impf_subj_12sg = {stem .. "facessi"}
	data.forms.impf_subj_3sg = {stem .. "facesse"}
	data.forms.impf_subj_1pl = {stem .. "facessimo"}
	data.forms.impf_subj_2pl = {stem .. "faceste"}
	data.forms.impf_subj_3pl = {stem .. "facessero"}
	
	data.forms.impr_2sg = {stem .. "fa", stem .. "fai", stem .. "fa'", "non [[" .. stem .. "fare]]"}
	data.forms.impr_3sg = {stem .. "faccia"}
	data.forms.impr_1pl = {stem .. "facciamo"}
	data.forms.impr_2pl = {stem .. "fate"}
	data.forms.impr_3pl = {stem .. "facciano"}
end

-- Shows the table with the given forms
function make_table(data)
	return [=[<div class="NavFrame">
<div class="NavHead">&nbsp; &nbsp; ]=] .. m_baglantilar.tam_bag({dil = lang, alt = data.forms.infinitive[1]}, "sözcük").. [=[</div>
<div class="NavContent">
{| style="background:#F0F0F0;border-collapse:separate;border-spacing:2px;width:100%" class="inflection-table"
|-
! colspan="1" style="background:#e2e4c0" | <span title="infinito">mastar</span>
| colspan="1" | ]=] .. show_form(data.forms.infinitive) .. [=[

|-
! colspan="2" style="background:#e2e4c0" | <span title="verbo ausiliare">ek eylem</span>
| colspan="1" | ]=] .. show_form(data.forms.aux) .. [=[

! colspan="2" style="background:#e2e4c0" | <span title="gerundio">ulaç</span>
| colspan="2" | ]=] .. show_form(data.forms.gerund) .. [=[

|-
! colspan="2" style="background:#e2e4c0" |  <span title="participio presente">şimdiki zaman ortacı</span>
| colspan="1" | ]=] .. show_form(data.forms.pres_ptc) .. [=[

! colspan="2" style="background:#e2e4c0" | <span title="participio passato">geçmiş zaman ortacı</span>
| colspan="2" | ]=] .. show_form(data.forms.past_ptc) .. [=[

|-
! colspan="1" rowspan="2" style="background:#C0C0C0" | person
! colspan="3" style="background:#C0C0C0" | tekil
! colspan="3" style="background:#C0C0C0" | çoğul
|-
! style="background:#C0C0C0;width:12.5%" | 1. kişi
! style="background:#C0C0C0;width:12.5%" | 2. kişi
! style="background:#C0C0C0;width:12.5%" | 3. kişi
! style="background:#C0C0C0;width:12.5%" | 1. kişi
! style="background:#C0C0C0;width:12.5%" | 2. kişi
! style="background:#C0C0C0;width:12.5%" | 3. kişi
|-
! style="background:#c0cfe4" colspan="1" | <span title="indicativo">bildirme</span>
! style="background:#c0cfe4" | io
! style="background:#c0cfe4" | tu
! style="background:#c0cfe4" | lui/lei, esso/essa
! style="background:#c0cfe4" | noi
! style="background:#c0cfe4" | voi
! style="background:#c0cfe4" | loro, essi/esse
|-
! style="height:3em;background:#c0cfe4" colspan="1" | <span title="presente">şimdiki zaman</span>
| ]=] .. show_form(data.forms.pres_indc_1sg) .. [=[

| ]=] .. show_form(data.forms.pres_indc_2sg) .. [=[

| ]=] .. show_form(data.forms.pres_indc_3sg) .. [=[

| ]=] .. show_form(data.forms.pres_indc_1pl) .. [=[

| ]=] .. show_form(data.forms.pres_indc_2pl) .. [=[

| ]=] .. show_form(data.forms.pres_indc_3pl) .. [=[

|-
! style="height:3em;background:#c0cfe4" colspan="1" | <span title="imperfetto">kusurlu geçmiş zaman</span>
| ]=] .. show_form(data.forms.impf_indc_1sg) .. [=[

| ]=] .. show_form(data.forms.impf_indc_2sg) .. [=[

| ]=] .. show_form(data.forms.impf_indc_3sg) .. [=[

| ]=] .. show_form(data.forms.impf_indc_1pl) .. [=[

| ]=] .. show_form(data.forms.impf_indc_2pl) .. [=[

| ]=] .. show_form(data.forms.impf_indc_3pl) .. [=[

|-
! style="height:3em;background:#c0cfe4" colspan="1" | <span title="passato remoto">belirli geçmiş zaman</span>
| ]=] .. show_form(data.forms.phis_indc_1sg) .. [=[

| ]=] .. show_form(data.forms.phis_indc_2sg) .. [=[

| ]=] .. show_form(data.forms.phis_indc_3sg) .. [=[

| ]=] .. show_form(data.forms.phis_indc_1pl) .. [=[

| ]=] .. show_form(data.forms.phis_indc_2pl) .. [=[

| ]=] .. show_form(data.forms.phis_indc_3pl) .. [=[

|-
! style="height:3em;background:#c0cfe4" colspan="1" | <span title="futuro semplice">gelecek zaman</span>
| ]=] .. show_form(data.forms.futr_indc_1sg) .. [=[

| ]=] .. show_form(data.forms.futr_indc_2sg) .. [=[

| ]=] .. show_form(data.forms.futr_indc_3sg) .. [=[

| ]=] .. show_form(data.forms.futr_indc_1pl) .. [=[

| ]=] .. show_form(data.forms.futr_indc_2pl) .. [=[

| ]=] .. show_form(data.forms.futr_indc_3pl) .. [=[

|-
! style="background:#c0d8e4" colspan="1" | <span title="condizionale">şart</span>
! style="background:#c0d8e4" | io
! style="background:#c0d8e4" | tu
! style="background:#c0d8e4" | lui/lei, esso/essa
! style="background:#c0d8e4" | noi
! style="background:#c0d8e4" | voi
! style="background:#c0d8e4" | loro, essi/esse
|-
! style="height:3em;background:#c0d8e4" colspan="1" | <span title="condizionale presente">şimdiki zaman</span>
| ]=] .. show_form(data.forms.cond_1sg) .. [=[

| ]=] .. show_form(data.forms.cond_2sg) .. [=[

| ]=] .. show_form(data.forms.cond_3sg) .. [=[

| ]=] .. show_form(data.forms.cond_1pl) .. [=[

| ]=] .. show_form(data.forms.cond_2pl) .. [=[

| ]=] .. show_form(data.forms.cond_3pl) .. [=[

|-
! style="background:#c0e4c0" colspan="1" | <span title="congiuntivo">dilek</span>
! style="background:#c0e4c0" | che io
! style="background:#c0e4c0" | che tu
! style="background:#c0e4c0" | che lui/che lei, che esso/che essa
! style="background:#c0e4c0" | che noi
! style="background:#c0e4c0" | che voi
! style="background:#c0e4c0" | che loro, che essi/che esse
|-
! style="height:3em;background:#c0e4c0" | <span title="congiuntivo presente">şimdiki zaman</span>
| ]=] .. show_form(data.forms.pres_subj_1sg) .. [=[

| ]=] .. show_form(data.forms.pres_subj_2sg) .. [=[

| ]=] .. show_form(data.forms.pres_subj_3sg) .. [=[

| ]=] .. show_form(data.forms.pres_subj_1pl) .. [=[

| ]=] .. show_form(data.forms.pres_subj_2pl) .. [=[

| ]=] .. show_form(data.forms.pres_subj_3pl) .. [=[

|-
! style="height:3em;background:#c0e4c0" rowspan="1" | <span title="congiuntivo imperfetto">kusurlu geçmiş zaman</span>
| ]=] .. show_form(data.forms.impf_subj_1sg) .. [=[

| ]=] .. show_form(data.forms.impf_subj_2sg) .. [=[

| ]=] .. show_form(data.forms.impf_subj_3sg) .. [=[

| ]=] .. show_form(data.forms.impf_subj_1pl) .. [=[

| ]=] .. show_form(data.forms.impf_subj_2pl) .. [=[

| ]=] .. show_form(data.forms.impf_subj_3pl) .. [=[

|-
! colspan="1" rowspan="2" style="height:3em;background:#e4d4c0" | <span title="imperativo">emir</span>
! style="background:#e4d4c0" | &mdash;
! style="background:#e4d4c0" | tu
! style="background:#e4d4c0" | Lei
! style="background:#e4d4c0" | noi
! style="background:#e4d4c0" | voi
! style="background:#e4d4c0" | Loro
|-
|
| ]=] .. show_form(data.forms.impr_2sg) .. [=[

| ]=] .. show_form(data.forms.impr_3sg) .. [=[

| ]=] .. show_form(data.forms.impr_1pl) .. [=[

| ]=] .. show_form(data.forms.impr_2pl) .. [=[

| ]=] .. show_form(data.forms.impr_3pl) .. [=[

|-
|}</div></div>]=]
end

-- Shows forms with links, or a dash if empty
function show_form(subforms)
	if not subforms then
		return "&mdash;"
	elseif type(subforms) ~= "table" then
		error("a non-table value was given in the list of inflected forms.")
	elseif #subforms == 0 then
		return "&mdash;"
	end
	
	local ret = {}
	
	-- Go over each subform and insert links
	for key, subform in ipairs(subforms) do
		table.insert(ret, m_baglantilar.tam_bag({dil = lang, sozcuk = subform}))
	end
	
	return table.concat(ret, ", ")
end

return export