MCPcopy Create free account
hub / github.com/Snapchat/KeyDB / localstat

Function localstat

deps/lua/src/lparser.c:1179–1195  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1177
1178
1179static void localstat (LexState *ls) {
1180 /* stat -> LOCAL NAME {`,' NAME} [`=' explist1] */
1181 int nvars = 0;
1182 int nexps;
1183 expdesc e;
1184 do {
1185 new_localvar(ls, str_checkname(ls), nvars++);
1186 } while (testnext(ls, ','));
1187 if (testnext(ls, '='))
1188 nexps = explist1(ls, &e);
1189 else {
1190 e.k = VVOID;
1191 nexps = 0;
1192 }
1193 adjust_assign(ls, nvars, nexps, &e);
1194 adjustlocalvars(ls, nvars);
1195}
1196
1197
1198static int funcname (LexState *ls, expdesc *v) {

Callers 1

statementFunction · 0.85

Calls 6

new_localvarFunction · 0.85
str_checknameFunction · 0.85
testnextFunction · 0.85
explist1Function · 0.85
adjust_assignFunction · 0.85
adjustlocalvarsFunction · 0.85

Tested by

no test coverage detected