Module:xchc-noun: Difference between revisions

No edit summary
No edit summary
Line 29: Line 29:
local ipa = wordpron(word)
local ipa = wordpron(word)
local backh = ipa:match("ɛ") and "ɛ" or ipa:match("ɔ") and "ɔ" or nil
local backh = ipa:match("ɛ") and "ɛ" or ipa:match("ɔ") and "ɔ" or nil
local repl = {["ɛ"] = data.e, ["ɔ"] = data.o}
local repl = {["ɛ"] = data.e, ["ɔ"] = data.o,}
return word:gsub("B", repl[backh or def])
return word:gsub("B", repl[backh or def])
end
end
Line 57: Line 57:
  or wordpron(word):match("[ɛa]$") and "н"
  or wordpron(word):match("[ɛa]$") and "н"
  or wordpron(word):match("[uoɔ]$") and "ӈ"
  or wordpron(word):match("[uoɔ]$") and "ӈ"
  or gsubbh("Bӈ",{["o"]="о̆",["e"]="э̆"},"o")
  or gsubbh("Bӈ",{["o"]="о̆",["e"]="э̆"},"ɔ")
data.pl = {
data.pl = {
["i"] = wordpron(word):match(voiceless .. "ː?$") and gsubbh("фBд",{["o"]="ө",["e"]="э"},"e") or gsubbh("вBд",{["o"]="ө",["e"]="э"},"e"),
["i"] = wordpron(word):match(voiceless .. "ː?$") and gsubbh("фBд",{["o"]="ө",["e"]="э"},"ɛ") or gsubbh("вBд",{["o"]="ө",["e"]="э"},"ɛ"),
["a"] = wordpron(word):match(voiceless .. "ː?$") and gsubbh("шBд",{["o"]="о̆",["e"]="э̆"},"o") or gsbubh("жBд",{["o"]="о̆",["e"]="э̆"},"o")
["a"] = wordpron(word):match(voiceless .. "ː?$") and gsubbh("шBд",{["o"]="о̆",["e"]="э̆"},"ɔ") or gsbubh("жBд",{["o"]="о̆",["e"]="э̆"},"ɔ")
}
}
Line 118: Line 118:
["dat"] = w_number[n_sh]:match(vowel .. "ː?$") and "ша" or w_number[n_sh]:match(voiced .. "ː?$") and "за" or "са",
["dat"] = w_number[n_sh]:match(vowel .. "ː?$") and "ша" or w_number[n_sh]:match(voiced .. "ː?$") and "за" or "са",
["gen"] = "ля",
["gen"] = "ля",
["ins"] = w_number[n_sh]:match(vowel .. "ː?$") and "лза" or gsubbh("Bлз",{["o"]="ө",["e"]="э"},"o"),
["ins"] = w_number[n_sh]:match(vowel .. "ː?$") and "лза" or gsubbh("Bлз",{["o"]="ө",["e"]="э"},"ɔ"),
["pro"] = gsubbh("сBц","ө", "э", nil, nil, "ө"),
["pro"] = gsubbh("сBц","ө", "э", nil, nil, "ɔ"),
["ade"] = "ляц",
["ade"] = "ляц",
["abl"] = gsubbh("сB",{["r"]="u",["u"]="i"},"r") .. gsubrh("шR",{["o"]="о̄̆",["e"]="э̄̆"},"e"),
["abl"] = gsubrh("сB",{["r"]="u",["u"]="i"},"r") .. gsubbh("шR",{["o"]="о̄̆",["e"]="э̄̆"},"ɛ"),
["ill"] = gsubrh("кRб",{["r"]="ү",["u"]="ы"},"u"),
["ill"] = gsubrh("кRб",{["r"]="ү",["u"]="ы"},"u"),
}
}