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

Function lua_getreadonly

other_src/lua/src/lapi.cpp:1075–1087  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1073#ifdef LUA_READONLY_TABLES
1074
1075LUA_API int lua_getreadonly (lua_State *L, int idx) { /*BZ*/
1076 StkId o;
1077 Table* t;
1078 lu_byte readonly;
1079 lua_lock(L);
1080 api_checknelems(L, 1);
1081 o = index2adr(L, idx);
1082 api_check(L, ttistable(o));
1083 t = hvalue(o);
1084 readonly = t->readonly;
1085 lua_unlock(L);
1086 return cast(int, readonly);
1087}
1088
1089
1090LUA_API void lua_setreadonly (lua_State *L, int idx, int state) { /*BZ*/

Callers 1

treadonlyFunction · 0.85

Calls 1

index2adrFunction · 0.70

Tested by

no test coverage detected