47,715
edits
![]() | We're back! Sorry, bad combo of sickness, funeral and a month-long trip abroad. The site is back now. ![]() |
No edit summary |
No edit summary |
||
Line 1: | Line 1: | ||
local | local m_put = require("Module:parse utilities") | ||
local m_table = require("Module:table") | local m_table = require("Module:table") | ||
Line 38: | Line 38: | ||
for i, item in ipairs(args[a]) do | for i, item in ipairs(args[a]) do | ||
if item:find("<") and not item:find("^[^<]*<[a-z]*[^a-z:]") then | if item:find("<") and not item:find("^[^<]*<[a-z]*[^a-z:]") then | ||
local run = | local run = m_put.parse_balanced_segment_run | ||
term = run[1] | |||
for j = 2, #run - 1, 2 do | for j = 2, #run - 1, 2 do | ||
local modtext = run[j]:match("^<(.*)>$") | local modtext = run[j]:match("^<(.*)>$") | ||
local prefix, arg = modtext:match("^([a-z]+):(.*)$") | local prefix, arg = modtext:match("^([a-z]+):(.*)$") | ||
alt = prefix == "a" and arg or nil | |||
cat = prefix == "c" and arg or nil | |||
table.insert(links, link(term, alt)) | |||
table.insert(categories, "Soc'ul' terms inherited from Wascotl *" .. (cat or term)) | |||
end | end | ||
end | end | ||
end | end |