lua-users home
lua-l archive

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


Roberto Ierusalimschy wrote:

I am not sure if its clear that Lua 4.1 will "support" coroutines as long
as you have a C library for coroutines (for instance ET's one, or those
that use longjmps); that is, it will co-operate with C for the task. We
are not implementing a "stackless" Lua, but a Lua with multiple stacks.
You need some way to create multiple stacks in C, and then each Lua stack
will run in paralel with its corresponding C stack.


I haven't had a chance to look at the pre-release yet, but will it support doing something like Bret M. did in GF? That is, I don't need to have C-level coroutines. I want to have a list of Lua execution "threads", and a simple C scheduler that just steps through and runs each process until it either calls a wait() function, or it executes a certain number of opcodes. Lightweight and effective. I was under the impression that 4.1 would support this model, but after following this thread I'm not so sure anymore.

Jason
379