[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: kill coroutine
- From: Rici Lake <lua@...>
- Date: Sun, 21 Aug 2005 07:48:36 -0500
On 21-Aug-05, at 7:12 AM, Mike Pall wrote:
Rici Lake wrote:
The currently running thread (and therefore its stack) are always part
of the gc root. So is the "main thread" (and its stack).
That's not how it works internally in Lua 5.1 anymore.
Have a look at markroot() in lgc.c. Nowhere does it mark L,
the running thread (that called luaC_step).
atomic(), line 539:
markobject(g, L); /* mark running thread */
The comment leads me to believe that the intention is to mark the
running thread, which would seem logical.