| 1392 | |
| 1393 | |
| 1394 | LUA_API const char *lua_getupvalue (lua_State *L, int funcindex, int n) { |
| 1395 | const char *name; |
| 1396 | TValue *val = NULL; /* to avoid warnings */ |
| 1397 | lua_lock(L); |
| 1398 | name = aux_upvalue(index2value(L, funcindex), n, &val, NULL); |
| 1399 | if (name) { |
| 1400 | setobj2s(L, L->top.p, val); |
| 1401 | api_incr_top(L); |
| 1402 | } |
| 1403 | lua_unlock(L); |
| 1404 | return name; |
| 1405 | } |
| 1406 | |
| 1407 | |
| 1408 | LUA_API const char *lua_setupvalue (lua_State *L, int funcindex, int n) { |
no test coverage detected