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

Function finaltarget

third-party/lua-5.5.0/src/lcode.c:1911–1921  ·  view source on GitHub ↗

** return the final target of a jump (skipping jumps to jumps) */

Source from the content-addressed store, hash-verified

1909** return the final target of a jump (skipping jumps to jumps)
1910*/
1911static int finaltarget (Instruction *code, int i) {
1912 int count;
1913 for (count = 0; count < 100; count++) { /* avoid infinite loops */
1914 Instruction pc = code[i];
1915 if (GET_OPCODE(pc) != OP_JMP)
1916 break;
1917 else
1918 i += GETARG_sJ(pc) + 1;
1919 }
1920 return i;
1921}
1922
1923
1924/*

Callers 1

luaK_finishFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected