Module:Sandbox/Erutuon: Difference between revisions

Content deleted Content added
fixed
m rm logging
Line 9:
return error(string.format(level, ...), 2)
end
end
 
function mw.logf(...)
return mw.log(string.format(...))
end
 
Line 140 ⟶ 136:
return expand_range(char1, char2)
end)
--[[
mw.log(
print_char_set_map(
get_chars_in_scripts(
expanded_pattern:gmatch "[%z\1-\127\194-\244][\128-\191]*")))
--]]
return ('* <div style="overflow-wrap: break-word;">%s</div><br>%s')
Line 193 ⟶ 182:
increment = function(self, script_code, amount)
self[script_code] = (self[script_code] or 0) + (amount or 1)
-- mw.logf("incremented %s by %d", script_code, amount or 1)
end,
clear = function (self)
Line 232 ⟶ 220:
index = index + 1
end
end
-- mw.logf("range above U+%04X: U+%04X-U+%04X (%s)", codepoint,
-- ranges[index][1], ranges[index][2], ranges[index][3])
local count = 0
local range = ranges[index]
while codepoint < range[1] and codepoint <= block[2]
and not singles[codepoint] do
ifcount codepoint= <count range[1]+ then1
count = count + 1
end
codepoint = codepoint + 1
end
Line 246 ⟶ 231:
end
end
-- mw.logf("U+%04X", codepoint)
end