MCPcopy Create free account
hub / github.com/DFHack/dfhack / luaK_concat

Function luaK_concat

depends/lua/src/lcode.c:116–127  ·  view source on GitHub ↗

** Concatenate jump-list 'l2' into jump-list 'l1' */

Source from the content-addressed store, hash-verified

114** Concatenate jump-list 'l2' into jump-list 'l1'
115*/
116void luaK_concat (FuncState *fs, int *l1, int l2) {
117 if (l2 == NO_JUMP) return; /* nothing to concatenate? */
118 else if (*l1 == NO_JUMP) /* no original list? */
119 *l1 = l2; /* 'l1' points to 'l2' */
120 else {
121 int list = *l1;
122 int next;
123 while ((next = getjump(fs, list)) != NO_JUMP) /* find last element */
124 list = next;
125 fixjump(fs, list, l2); /* last element links to 'l2' */
126 }
127}
128
129
130/*

Callers 7

test_then_blockFunction · 0.85
luaK_jumpFunction · 0.85
luaK_patchtohereFunction · 0.85
exp2regFunction · 0.85
luaK_goiftrueFunction · 0.85
luaK_goiffalseFunction · 0.85
luaK_posfixFunction · 0.85

Calls 2

getjumpFunction · 0.85
fixjumpFunction · 0.85

Tested by 1

test_then_blockFunction · 0.68