Message3572

Author flaviojs
Recipients infrared
Date 2018-04-18.20:17:38
Content
Submitted a fix that catches yields and simulates the behavior of luaL_dostring
by copying over the remaining data.

If the code yields then 'run_lua' will return LUA_YIELD, allowing the caller to
decide what comes next.
Currently the return value is always ignored, so a yield will be equivalent to a
return.

Note that I'm unsure if this is a proper fix because I don't know:
1) if the code is meant to interact with the target state or the coroutine that
is currently running;
2) what should happen to the yielded/returned data. Note that the data might be
"polluting" the stack of the target and be a cause of problems somewhere else.
History
Date User Action Args
2018-04-18 20:17:38flaviojssetmessageid: <1524082658.56.0.781658752051.issue670@freedroid.org>
2018-04-18 20:17:38flaviojssetrecipients: + infrared
2018-04-18 20:17:38flaviojslinkissue670 messages
2018-04-18 20:17:38flaviojscreate