MCPcopy Create free account
hub / github.com/ObEngine/ObEngine / reverse

Function reverse

extlibs/lua/src/lapi.c:200–207  ·  view source on GitHub ↗

** Reverse the stack segment from 'from' to 'to' ** (auxiliary to 'lua_rotate') ** Note that we move(copy) only the value inside the stack. ** (We do not move additional fields that may exist.) */

Source from the content-addressed store, hash-verified

198** (We do not move additional fields that may exist.)
199*/
200static void reverse (lua_State *L, StkId from, StkId to) {
201 for (; from < to; from++, to--) {
202 TValue temp;
203 setobj(L, &temp, s2v(from));
204 setobjs2s(L, from, to);
205 setobj2s(L, to, &temp);
206 }
207}
208
209
210/*

Callers 5

lua_rotateFunction · 0.70
loadMethod · 0.50
getNodePathMethod · 0.50
operator()Method · 0.50
convexHullFunction · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected