Searched refs:lua_state (Results 1 – 1 of 1) sorted by relevance
/packages/services/Car/tools/telemetry/lua-interpreter/ |
D | lua_engine.cc | 79 bool ConvertJsonToLuaTable(lua_State* lua_state, std::string published_data, in ConvertJsonToLuaTable() argument 85 luaL_dofile(lua_state, "json.lua"); in ConvertJsonToLuaTable() 92 lua_getfield(lua_state, /*index=*/-1, "decode"); in ConvertJsonToLuaTable() 100 lua_pushstring(lua_state, published_data.c_str()); in ConvertJsonToLuaTable() 106 lua_pcall(lua_state, /*nargs=*/1, /*nresults=*/1, /*msgh=*/0); in ConvertJsonToLuaTable() 110 if (!lua_istable(lua_state, lua_gettop(lua_state))) { in ConvertJsonToLuaTable() 112 std::string(lua_tostring(lua_state, lua_gettop(lua_state))); in ConvertJsonToLuaTable() 113 lua_pop(lua_state, 2); in ConvertJsonToLuaTable() 123 lua_insert(lua_state, /*index=*/-2); in ConvertJsonToLuaTable() 131 lua_getfield(lua_state, /*index=*/-1, "decode"); in ConvertJsonToLuaTable() [all …]
|