| 5587 | |
| 5588 | |
| 5589 | LUA_API int lua_yield (lua_State *L, int nresults) { |
| 5590 | luai_userstateyield(L, nresults); |
| 5591 | lua_lock(L); |
| 5592 | if (L->nCcalls > L->baseCcalls) |
| 5593 | luaG_runerror(L, "attempt to yield across metamethod/C-call boundary"); |
| 5594 | L->base = L->top - nresults; /* protect stack slots below */ |
| 5595 | L->status = LUA_YIELD; |
| 5596 | lua_unlock(L); |
| 5597 | return -1; |
| 5598 | } |
| 5599 | |
| 5600 | |
| 5601 | int luaD_pcall (lua_State *L, Pfunc func, void *u, |
no test coverage detected