MCPcopy Create free account
hub / github.com/DFHack/dfhack / exprstat

Function exprstat

depends/lua/src/lparser.c:1489–1502  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1487
1488
1489static void exprstat (LexState *ls) {
1490 /* stat -> func | assignment */
1491 FuncState *fs = ls->fs;
1492 struct LHS_assign v;
1493 suffixedexp(ls, &v.v);
1494 if (ls->t.token == '=' || ls->t.token == ',') { /* stat -> assignment ? */
1495 v.prev = NULL;
1496 assignment(ls, &v, 1);
1497 }
1498 else { /* stat -> func */
1499 check_condition(ls, v.v.k == VCALL, "syntax error");
1500 SETARG_C(getinstruction(fs, &v.v), 1); /* call statement uses no results */
1501 }
1502}
1503
1504
1505static void retstat (LexState *ls) {

Callers 1

statementFunction · 0.85

Calls 2

suffixedexpFunction · 0.85
assignmentFunction · 0.85

Tested by

no test coverage detected