Module:gender and number/basic

local export = {}

--[=[	This is a simplified version of Module:gender and number that handles the most common cases without loading the full module. ]=]--

function export.format_list(specs, lang, pos_for_cat, sort_key) local gender, spec if not pos_for_cat and not sort_key and #specs == 1 and type(specs[1]) == "string" then spec = specs[1] if spec == "m" then gender = "masculine" elseif spec == "f" then gender = "feminine" elseif spec == "n" then gender = "neuter" elseif spec == "c" then gender = "common" end end

if gender then return ' ' .. spec .. ' '	end

return require("Module:gender and number").format_list(specs, lang, pos_for_cat, sort_key) end

return export