[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Lua registry, environment, and threads.
- From: Mark Hamburg <mark@...>
- Date: Sun, 10 Jan 2010 11:46:19 -0800
On Jan 10, 2010, at 5:56 AM, Cosmin Apreutesei wrote:
> How about a built-in function ecall(env,f,...) ? And of course,
> ecall() would NOT be implemented via setfenv(), so you could still
> call f() properly from another thread while inside ecall().
See my recent posting. This takes a change in the runtime to store environments in call frames. On the other hand, for precisely these sort of reasons, I think it would be a good change. As it is, setfenv is not friendly toward threaded (i.e., coroutine) code or other reentrant cases.
Mark
- References:
- Lua registry, environment, and threads., Christian Tellefsen
- Re: Lua registry, environment, and threads., Roberto Ierusalimschy
- Re: Lua registry, environment, and threads., Christian Tellefsen
- Re: Lua registry, environment, and threads., Roberto Ierusalimschy
- Re: Lua registry, environment, and threads., Mark Hamburg
- Re: Lua registry, environment, and threads., Patrick Donnelly
- Re: Lua registry, environment, and threads., Roberto Ierusalimschy
- Re: Lua registry, environment, and threads., Alexander Gladysh
- Re: Lua registry, environment, and threads., Cosmin Apreutesei
- Re: Lua registry, environment, and threads., Matthew Wild
- Re: Lua registry, environment, and threads., Cosmin Apreutesei