| 604 | |
| 605 | |
| 606 | static int jumponcond (FuncState *fs, expdesc *e, int cond) { |
| 607 | if (e->k == VRELOCABLE) { |
| 608 | Instruction ie = getcode(fs, e); |
| 609 | if (GET_OPCODE(ie) == OP_NOT) { |
| 610 | fs->pc--; /* remove previous OP_NOT */ |
| 611 | return condjump(fs, OP_TEST, GETARG_B(ie), 0, !cond); |
| 612 | } |
| 613 | /* else go through */ |
| 614 | } |
| 615 | discharge2anyreg(fs, e); |
| 616 | freeexp(fs, e); |
| 617 | return condjump(fs, OP_TESTSET, NO_REG, e->u.info, cond); |
| 618 | } |
| 619 | |
| 620 | |
| 621 | void luaK_goiftrue (FuncState *fs, expdesc *e) { |
no test coverage detected