MCPcopy Create free account
hub / github.com/ObEngine/ObEngine / localfunc

Function localfunc

extlibs/lua/src/lparser.c:1708–1717  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1706
1707
1708static void localfunc (LexState *ls) {
1709 expdesc b;
1710 FuncState *fs = ls->fs;
1711 int fvar = fs->nactvar; /* function's variable index */
1712 new_localvar(ls, str_checkname(ls)); /* new local variable */
1713 adjustlocalvars(ls, 1); /* enter its scope */
1714 body(ls, &b, 0, ls->linenumber); /* function created in next register */
1715 /* debug information will only see the variable after this point! */
1716 localdebuginfo(fs, fvar)->startpc = fs->pc;
1717}
1718
1719
1720static int getlocalattribute (LexState *ls) {

Callers 1

statementFunction · 0.85

Calls 5

new_localvarFunction · 0.85
str_checknameFunction · 0.85
adjustlocalvarsFunction · 0.85
bodyFunction · 0.85
localdebuginfoFunction · 0.85

Tested by

no test coverage detected