** Performs a basic GC step if collector is running. (If collector is ** not running, set a reasonable debt to avoid it being called at ** every single check.) */
| 1688 | ** every single check.) |
| 1689 | */ |
| 1690 | void luaC_step (lua_State *L) { |
| 1691 | global_State *g = G(L); |
| 1692 | if (!gcrunning(g)) /* not running? */ |
| 1693 | luaE_setdebt(g, -2000); |
| 1694 | else { |
| 1695 | if(isdecGCmodegen(g)) |
| 1696 | genstep(L, g); |
| 1697 | else |
| 1698 | incstep(L, g); |
| 1699 | } |
| 1700 | } |
| 1701 | |
| 1702 | |
| 1703 | /* |
no test coverage detected