MCPcopy Create free account
hub / github.com/axmolengine/axmol / json_fetch_config

Function json_fetch_config

3rdparty/lua/lua-cjson/lua_cjson.c:205–214  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

203/* ===== CONFIGURATION ===== */
204
205static json_config_t *json_fetch_config(lua_State *l)
206{
207 json_config_t *cfg;
208
209 cfg = (json_config_t *)lua_touserdata(l, lua_upvalueindex(1));
210 if (!cfg)
211 luaL_error(l, "BUG: Unable to fetch CJSON configuration");
212
213 return cfg;
214}
215
216/* Ensure the correct number of arguments have been provided.
217 * Pad with nil to allow other functions to simply check arg[i]

Callers 3

json_arg_initFunction · 0.85
json_encodeFunction · 0.85
json_decodeFunction · 0.85

Calls 2

lua_touserdataFunction · 0.85
luaL_errorFunction · 0.85

Tested by

no test coverage detected