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

Function localfunc

depends/lua/src/lparser.c:1432–1440  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1430
1431
1432static void localfunc (LexState *ls) {
1433 expdesc b;
1434 FuncState *fs = ls->fs;
1435 new_localvar(ls, str_checkname(ls)); /* new local variable */
1436 adjustlocalvars(ls, 1); /* enter its scope */
1437 body(ls, &b, 0, ls->linenumber); /* function created in next register */
1438 /* debug information will only see the variable after this point! */
1439 getlocvar(fs, b.u.info)->startpc = fs->pc;
1440}
1441
1442
1443static void localstat (LexState *ls) {

Callers 1

statementFunction · 0.85

Calls 5

new_localvarFunction · 0.85
str_checknameFunction · 0.85
adjustlocalvarsFunction · 0.85
bodyFunction · 0.85
getlocvarFunction · 0.85

Tested by

no test coverage detected