lua-users home
lua-l archive

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


Hi,

You can put the local variables in a table, and set it as the 
envinronment of the function that loadstring returns. If you also want 
the current global environment, you can set the global environment as 
the __index metamethod of the table where you put the locals.

There is an example of this technique in the RemDebug source code, check 
http://luaforge.net/projects/remdebug.

--
Fabio Mascarenhas

On Wed, Apr 26, 2006 at 01:09:46PM +0300, Dmitriy Iassenev wrote:
> hello,
> 
> I am working with LUA debugging functions for the visual LUA debugger
> and there is a question about watches implementation.
> 
> Is it possible to evaluate an expression using local variables and
> upvalues from the specified stack level?
> 
> -- 
> Best regards,
>  Dmitriy                            mailto:iassenev@gsc-game.kiev.ua
> 

Attachment: signature.asc
Description: Digital signature