lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Hy everybody,
How can I "explode" a table in a local scope like:

t = { foo=1, bar=2}
foo = 2

function foobaz()
  local_explode(t)
  local baz = foo + bar  -- baz = 3 (not 4)
end

print(foo) -- 2 (not 1)

-- Pablo