[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Re-using a thread without reloading the LUA file, from C/C++
- From: "Lionel Fumery" <lif-ml@...>
- Date: Fri, 27 Jul 2007 15:25:26 +0200
Wow, it's working now, it was so simple...
Thank you a lot for your help,
----- Original Message -----
From: "Luiz Henrique de Figueiredo" <firstname.lastname@example.org>
To: "Lua list" <email@example.com>
Sent: Friday, July 27, 2007 2:37 PM
Subject: Re: Re-using a thread without reloading the LUA file, from C/C++
- Does anybody know how to keep the function in the thread ?
Duplicate it with lua_pushvalue before pushing the argument and resuming.
Make sure that the stack is at the same level when you resume again (that
pop all values returned by lua_resume).