MCPcopy Create free account
hub / github.com/Achain-Dev/Achain / lua_table_to_map_with_nested

Function lua_table_to_map_with_nested

src/Chain/libraries/glua/lauxlib.cpp:2520–2529  ·  view source on GitHub ↗

* read lua table to hashmap */

Source from the content-addressed store, hash-verified

2518* read lua table to hashmap
2519*/
2520GluaTableMapP lua_table_to_map_with_nested(lua_State *L, int index, std::list<const void*> &jsons, size_t recur_depth)
2521{
2522 if (index > lua_gettop(L))
2523 return nullptr;
2524 if (!lua_istable(L, index))
2525 return nullptr;
2526 GluaTableMapP map = luaL_create_lua_table_map_in_memory_pool(L);
2527 luaL_traverse_table_with_nested(L, index, lua_table_to_map_traverser_with_nested, map, jsons, recur_depth);
2528 return map;
2529}
2530
2531struct GluaStorageValue lua_type_to_storage_value_type_with_nested(lua_State *L, int index, size_t len, std::list<const void *> &jsons, size_t recur_depth)
2532{

Calls 3

lua_gettopFunction · 0.85

Tested by

no test coverage detected