pub fn co_resume(state: &mut LuaState) -> Result<usize, LuaError>Expand description
coroutine.resume(co [, val1, ...]) — attempt to resume coroutine co.
On success pushes true followed by all values yielded or returned by co.
On failure pushes false followed by the error object.
The argument count handed to [aux_resume] is the stack top minus one: the
coroutine itself sits at index 1 and is not forwarded as an argument.
A sandbox budget trip is uncatchable: it re-raises into the caller frame
instead of returning false, msg, so code cannot keep a runaway coroutine
alive by resuming it in a loop.