MCPcopy Create free account
hub / github.com/PlutoLang/Pluto / codeunexpval

Function codeunexpval

src/lcode.cpp:1615–1621  ·  view source on GitHub ↗

** Emit code for unary expressions that "produce values" ** (everything but 'not'). ** Expression to produce final result will be encoded in 'e'. */

Source from the content-addressed store, hash-verified

1613** Expression to produce final result will be encoded in 'e'.
1614*/
1615static void codeunexpval (FuncState *fs, OpCode op, expdesc *e, int line) {
1616 int r = luaK_exp2anyreg(fs, e); /* opcodes operate only on registers */
1617 freeexp(fs, e);
1618 e->u.pc = luaK_codeABC(fs, op, 0, r, 0); /* generate opcode */
1619 e->k = VRELOC; /* all those operations are relocatable */
1620 luaK_fixline(fs, line);
1621}
1622
1623
1624/*

Callers 1

luaK_prefixFunction · 0.85

Calls 3

luaK_exp2anyregFunction · 0.85
freeexpFunction · 0.85
luaK_fixlineFunction · 0.85

Tested by

no test coverage detected