[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: How access local variables with load*() functions
- From: Peter Shook <peter.shook.engineer@...>
- Date: Thu, 8 Sep 2005 22:04:22 -0400
Sorry, my Lua skills are a little rusty. It's better to put put the
assert around the call to loadstring so that you get the syntax error
messages.
local fun = assert(loadstring[[
print 'second'
local x, y, z = ...
print('x','y','z')
print(x, y, z)
]])
local a, b, c = 'one', 'two', 'three'
print 'first'
print('a','b','c')
print(a, b, c)
fun(a, b, c)