MCPcopy Create free account
hub / github.com/EmmyLua/EmmyLuaDebugger / luaK_patchlist

Function luaK_patchlist

third-party/lua-5.3.5/src/lcode.c:263–270  ·  view source on GitHub ↗

** Path all jumps in 'list' to jump to 'target'. ** (The assert means that we cannot fix a jump to a forward address ** because we only know addresses once code is generated.) */

Source from the content-addressed store, hash-verified

261** because we only know addresses once code is generated.)
262*/
263void luaK_patchlist (FuncState *fs, int list, int target) {
264 if (target == fs->pc) /* 'target' is current position? */
265 luaK_patchtohere(fs, list); /* add list to pending jumps */
266 else {
267 lua_assert(target < fs->pc);
268 patchlistaux(fs, list, target, NO_REG, target);
269 }
270}
271
272
273/*

Callers 3

closegotoFunction · 0.70
repeatstatFunction · 0.70
forbodyFunction · 0.70

Calls 2

luaK_patchtohereFunction · 0.70
patchlistauxFunction · 0.70

Tested by

no test coverage detected