Module:qay-verb: Difference between revisions

Jump to navigation Jump to search
no edit summary
No edit summary
No edit summary
Line 19: Line 19:
local function detect_decl(word)
local function detect_decl(word)
if word:match("a$") then
if word:match("a$") then
return "a"
return "a", {word}
elseif word:match("[eiou]$") or word:match("[eiou]y") then
elseif word:match("[eiou]$") or word:match("[eiou]y") then
return "v"
return "v", {word}
elseif word:match("[ptkbdgmncvshrlj][ptkbdgmncvshrlj]") then
elseif word:match("[ptkbdgmncvshrlj][ptkbdgmncvshrlj]") then
return "2c"
return "2c", {word}
else
else
return "c"
return "c", {word}
end
end
end
end
Line 47: Line 47:
numbers = {parent_args[1]}
numbers = {parent_args[1]}
else
else
decl_type, numbers = export.detect_decl(word, parent_args.c)
decl_type, numbers = detect_decl(word)
end
end
end
end

Navigation menu