45,647
edits
No edit summary |
No edit summary |
||
Line 42: | Line 42: | ||
elseif item:find("<") and not item:find("^[^<]*<[a-z]*[^a-z:]") then | elseif item:find("<") and not item:find("^[^<]*<[a-z]*[^a-z:]") then | ||
local run = m_put.parse_balanced_segment_run(item, "<", ">") | local run = m_put.parse_balanced_segment_run(item, "<", ">") | ||
local orig_param = a + i - 1 | |||
local function parse_err(msg) | |||
error(msg .. ": " .. orig_param .. "= " .. table.concat(run)) | |||
end | |||
term = run[1] | term = run[1] | ||
for j = 2, #run - 1, 2 do | for j = 2, #run - 1, 2 do | ||
if run[j + 1] ~= "" then | |||
parse_err("Extraneous text '" .. run[j + 1] .. "' after modifier") | |||
end | |||
local modtext = run[j]:match("^<(.*)>$") | local modtext = run[j]:match("^<(.*)>$") | ||
local prefix, arg = modtext:match("^([a-z]+):(.*)$") | local prefix, arg = modtext:match("^([a-z]+):(.*)$") |