MCPcopy Create free account
hub / github.com/RomanKubiak/ctrlr / localfunc

Function localfunc

Source/Misc/lua/src/lua.c:8741–8752  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

8739
8740
8741static void localfunc (LexState *ls) {
8742expdesc v, b;
8743FuncState *fs = ls->fs;
8744new_localvar(ls, str_checkname(ls), 0);
8745init_exp(&v, VLOCAL, fs->freereg);
8746luaK_reserveregs(fs, 1);
8747adjustlocalvars(ls, 1);
8748body(ls, &b, 0, ls->linenumber);
8749luaK_storevar(fs, &v, &b);
8750/* debug information will only see the variable after this point! */
8751getlocvar(fs, fs->nactvar - 1).startpc = fs->pc;
8752}
8753
8754
8755static void localstat (LexState *ls) {

Callers 1

statementFunction · 0.85

Calls 7

new_localvarFunction · 0.85
str_checknameFunction · 0.85
init_expFunction · 0.85
luaK_reserveregsFunction · 0.85
adjustlocalvarsFunction · 0.85
bodyFunction · 0.85
luaK_storevarFunction · 0.85

Tested by

no test coverage detected