Module:qhv-adj/data: Difference between revisions

no edit summary
No edit summary
No edit summary
Line 11: Line 11:
setmetatable(d["I"], {__call = function(self, args, data)
setmetatable(d["I"], {__call = function(self, args, data)
local stem = args[1]
local stem = args[1]
local s = sub(stem, -1) == "s"
local stemr = (sub(stem, -2) == "rz" and sub(stem, 1, -2) .. "j" or sub(stem, -1) == "s" and sub(stem, 1, -2) .. "j"
local j = sub(stem, -1) == "j"
or sub(stem, -1) == "j" and stem or stem .. "r")
local stemr = s and sub(stem, 1, -2) .. "j" or j and stem or stem .. "r"
data.decl_type = "I"
data.decl_type = "I"
table.insert(data.categories, "High Valyrian class-I adjectives")
table.insert(data.categories, "High Valyrian class-I adjectives")