fix dump() recursion detection

only detect recursions for table values.
pull/1188/head
Hans-Werner Hilse 10 years ago
parent fd81ebdc00
commit 7e0b49edd1

@ -13,6 +13,7 @@ local function _serialize(what, outt, indent, max_lv, history)
return
end
if type(what) == "table" then
history = history or {}
for up, item in ipairs(history) do
if item == what then
@ -22,8 +23,6 @@ local function _serialize(what, outt, indent, max_lv, history)
return
end
end
if type(what) == "table" then
local new_history = { what, unpack(history) }
local didrun = false
insert(outt, "{")

Loading…
Cancel
Save