Added missing tostring() call on args in lume.trace()

This commit is contained in:
rxi 2014-04-19 09:05:04 +01:00
parent beced85d6b
commit c2311f9821

View File

@ -349,7 +349,8 @@ function lume.trace(...)
local t = { "[" .. info.short_src .. ":" .. info.currentline .. "]" } local t = { "[" .. info.short_src .. ":" .. info.currentline .. "]" }
for i = 1, select("#", ...) do for i = 1, select("#", ...) do
local x = select(i, ...) local x = select(i, ...)
t[#t + 1] = (type(x) == "number") and lume.round(x, .01) or (x or "nil") x = (type(x) == "number") and lume.round(x, .01) or (x or "nil")
t[#t + 1] = tostring(x)
end end
print(table.concat(t, " ")) print(table.concat(t, " "))
end end