Module:siwa-noun: Difference between revisions

No edit summary
No edit summary
Line 36: Line 36:
local xc = "[mnɲŋpbtdcɟkɡvðsɕzʑxɣhrlɬjw⁽ʰ⁾ʔː̥͡"..UNRELEASED.."]"
local xc = "[mnɲŋpbtdcɟkɡvðsɕzʑxɣhrlɬjw⁽ʰ⁾ʔː̥͡"..UNRELEASED.."]"
local pattern = xc .. "?(" .. vowels .. "+ː?)" .. xc .. "*"
local pattern = xc .. "?(" .. vowels .. "+ː?)" .. xc .. "*"
return {gsub(term, pattern, "%1")}
return gsub(term, pattern, "%1")
end
end


local function detect_quality(word)
local function detect_quality(word)
local stressed, n = syll_count(word)
local vs, n = syll_count(word)
local stressed = vs[1]
if find(stressed, vowels .. vowels .. vowels .. "?") or find(stressed, "ː") or n>=3 then
if find(stressed, vowels .. vowels .. vowels .. "?") or find(stressed, "ː") or n>=3 then
return "w" -- weak nouns
return "w" -- weak nouns