[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Destroying yielded (but not finished) coroutines?
- From: Jan Kratochvíl <jan.kratochvil@...>
- Date: Fri, 14 Oct 2005 10:43:41 +0200
i run some coroutines in my application and sometime i want to interrupt
such coroutine and never continue in it. I got something like
state = lua_newthread( globalState );
lua_sethook( state, luaHook, LUA_MASKCOUNT, 10 );
luaL_loadbuffer(state, command, strlen(command), desc)
and then in luaHook i occasionaly yield the coroutine. But sometimes i
decide to interrupt execution of (yielded) command in
this coroutine. And it is my problem. I don't know how to mark this
coroutine to be garbage collectable? Is it possible?
Thanks for help in advance,
Illussion softworks, a.s