| 292 | */ |
| 293 | #include <iostream> |
| 294 | static int luaK_code (FuncState *fs, Instruction i) { |
| 295 | Proto *f = fs->f; |
| 296 | dischargejpc(fs); /* 'pc' will change */ |
| 297 | /* put new instruction in code array */ |
| 298 | luaM_growvector(fs->ls->L, f->code, fs->pc, f->sizecode, Instruction, |
| 299 | MAX_INT, "opcodes"); |
| 300 | f->code[fs->pc] = i; |
| 301 | /* save corresponding line information */ |
| 302 | luaM_growvector(fs->ls->L, f->lineinfo, fs->pc, f->sizelineinfo, int, |
| 303 | MAX_INT, "opcodes"); |
| 304 | f->lineinfo[fs->pc] = fs->ls->lastline; |
| 305 | return fs->pc++; |
| 306 | } |
| 307 | |
| 308 | |
| 309 | /* |
no test coverage detected