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

Function getjumpcontrol

third-party/lua-5.4.6/src/lcode.c:244–250  ·  view source on GitHub ↗

** Returns the position of the instruction "controlling" a given ** jump (that is, its condition), or the jump itself if it is ** unconditional. */

Source from the content-addressed store, hash-verified

242** unconditional.
243*/
244static Instruction *getjumpcontrol (FuncState *fs, int pc) {
245 Instruction *pi = &fs->f->code[pc];
246 if (pc >= 1 && testTMode(GET_OPCODE(*(pi-1))))
247 return pi-1;
248 else
249 return pi;
250}
251
252
253/*

Callers 3

patchtestregFunction · 0.70
need_valueFunction · 0.70
negateconditionFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected