** Emit code for binary expressions that "produce values" ** (everything but logical operators 'and'/'or' and comparison ** operators). ** Expression to produce final result will be encoded in 'e1'. ** Because 'luaK_exp2RK' can free registers, its calls must be ** in "stack order" (that is, first on 'e2', which may have more ** recent registers to be released). */
| 1020 | ** recent registers to be released). |
| 1021 | */ |
| 1022 | static void codebinexpval (FuncState *fs, OpCode op, |
| 1023 | expdesc *e1, expdesc *e2, int line) { |
| 1024 | int rk2 = luaK_exp2RK(fs, e2); /* both operands are "RK" */ |
| 1025 | int rk1 = luaK_exp2RK(fs, e1); |
| 1026 | freeexps(fs, e1, e2); |
| 1027 | e1->u.info = luaK_codeABC(fs, op, 0, rk1, rk2); /* generate opcode */ |
| 1028 | e1->k = VRELOCABLE; /* all those operations are relocatable */ |
| 1029 | luaK_fixline(fs, line); |
| 1030 | } |
| 1031 | |
| 1032 | |
| 1033 | /* |
no test coverage detected