MCPcopy Create free account
hub / github.com/BZFlag-Dev/bzflag / getcurrenv

Function getcurrenv

other_src/lua/src/lapi.cpp:80–87  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

78
79
80static Table *getcurrenv (lua_State *L) {
81 if (L->ci == L->base_ci) /* no enclosing function? */
82 return hvalue(gt(L)); /* use global table as environment */
83 else {
84 Closure *func = curr_func(L);
85 return func->c.env;
86 }
87}
88
89
90void luaA_pushobject (lua_State *L, const TValue *o) {

Callers 3

lua_pushcclosureFunction · 0.70
f_CcallFunction · 0.70
lua_newuserdataFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected