lua-users home
lua-l archive

Re: About ifstat

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Thanks very much for your reply.
I still have problem on this point.
You said, " The luaK_patchtohere function patches all jump
instructions in the given list to jump to the current instruction
("here"). "
But the implementation of luaK_patchtohere confused me.
I need more help on this problem.
By the way, Is there more information or comments on lua source code?
Especially, lcode.c
void luaK_patchtohere (FuncState *fs, int list) {
 luaK_getlabel(fs);
 luaK_concat(fs, &fs->jpc, list);
}
int luaK_jump (FuncState *fs) {
 int jpc = fs->jpc; /* save list of jumps to here */
 int j;
 fs->jpc = NO_JUMP;
 j = luaK_codeAsBx(fs, OP_JMP, 0, NO_JUMP);
 luaK_concat(fs, &j, jpc); /* keep them on hold */
 return j;
}

AltStyle によって変換されたページ (->オリジナル) /