** Fix jump instruction at position 'pc' to jump to 'dest'. ** (Jump addresses are relative in Lua) */
| 101 | ** (Jump addresses are relative in Lua) |
| 102 | */ |
| 103 | static void fixjump (FuncState *fs, int pc, int dest) { |
| 104 | Instruction *jmp = &fs->f->code[pc]; |
| 105 | int offset = dest - (pc + 1); |
| 106 | lua_assert(dest != NO_JUMP); |
| 107 | if (abs(offset) > MAXARG_sBx) |
| 108 | luaX_syntaxerror(fs->ls, "control structure too long"); |
| 109 | SETARG_sBx(*jmp, offset); |
| 110 | } |
| 111 | |
| 112 | |
| 113 | /* |
no test coverage detected