[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Proposal: Lua Table Notation + load change
- From: Kevin Martin <kev82@...>
- Date: Thu, 28 Jun 2012 22:45:42 +0100
On 28 Jun 2012, at 22:22, Julien Duminil wrote:
> What do you think about this proposal?
In regards to proposal 2, why do you need to make any language changes? We use lua for data storage/transmission and we do something similar to:
local data = "{1, 2, 3}"
local f = load(string.format("return %s", data))
return f()
Doesn't that achieve the same as you're trying to do?
For security, we run f in a separate lua_State with no libraries, and then serialize it into the current state, but that's not necessary if you trust your data.
Thanks,
Kev