Jump to content

Module:akk-conj/g/weakness

From Wiktionary, the free dictionary


return function (roots, args)
    local R1 = {
    	["a"]    = "I-a",
    	["e"]    = "I-e",
        ["j"]    = "I-e",
        ["w"]    = "I-w",
        ["n"]    = "I-n"
    }
    local R2 = {
    	["a"]    = "II-a",
    	["e"]    = "II-e",
        ["j"]    = "II-j",
        ["w"]    = "II-w",
    }
    local R3 = {
    	["a"]    = "III-a",
    	["e"]    = "III-e",
        ["y"]    = "III-y",
        ["w"]    = "III-w",
    }

    if R2[roots[2]] then
        return R2[roots[2]]
    elseif R3[roots[3]] then
        return R3[roots[3]]
	elseif R1[roots[1]] then 
        if roots[1] == "w" then
        	return R1[roots[1]].." ''"..args.class.."''"
        else
        	return R1[roots[1]]
        end
	end
	if args.class == "e" then
		return "Sound e-i"
	end
end