Fixed number printing in lume.trace for Lua5.3

This commit is contained in:
rxi 2015-08-15 11:37:32 +01:00
parent ca338b8833
commit 16848d83a5

View File

@ -639,7 +639,7 @@ function lume.trace(...)
for i = 1, select("#", ...) do for i = 1, select("#", ...) do
local x = select(i, ...) local x = select(i, ...)
if type(x) == "number" then if type(x) == "number" then
x = tonumber(lume.round(x, .01)) x = string.format("%g", lume.round(x, .01))
end end
t[#t + 1] = tostring(x) t[#t + 1] = tostring(x)
end end