MCPcopy Create free account
hub / github.com/Serial-Studio/Serial-Studio / localfunc

Function localfunc

lib/lua/src/lparser.c:1689–1698  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1687
1688
1689static void localfunc (LexState *ls) {
1690 expdesc b;
1691 FuncState *fs = ls->fs;
1692 int fvar = fs->nactvar; /* function's variable index */
1693 new_localvar(ls, str_checkname(ls)); /* new local variable */
1694 adjustlocalvars(ls, 1); /* enter its scope */
1695 body(ls, &b, 0, ls->linenumber); /* function created in next register */
1696 /* debug information will only see the variable after this point! */
1697 localdebuginfo(fs, fvar)->startpc = fs->pc;
1698}
1699
1700
1701static int getlocalattribute (LexState *ls) {

Callers 1

statementFunction · 0.85

Calls 5

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

Tested by

no test coverage detected