Module:siwa-headword: Difference between revisions

no edit summary
No edit summary
No edit summary
Line 344: Line 344:
-- If you have a POS in its singular form, call pluralize() in [[Module:string utilities]] to
-- If you have a POS in its singular form, call pluralize() in [[Module:string utilities]] to
-- pluralize it in a smart fashion that knows when to add '-s' and when to add '-es'.
-- pluralize it in a smart fashion that knows when to add '-s' and when to add '-es'.
--
 
-- If `best_guess` is given and the POS is in neither the lemma nor non-lemma list, guess
-- based on whether it ends in " forms"; otherwise, return nil.
function pos_lemma_or_nonlemma(plpos)
function pos_lemma_or_nonlemma(plpos)
-- Is it a lemma category?
-- Is it a lemma category?
if isLemma[plpos] or isLemma[plpos:gsub("^reconstructed ", "")] then
if isLemma[plpos] then
return "lemma"
return "lemma"
-- Is it a nonlemma category?
-- Is it a nonlemma category?