| 340 | } |
| 341 | |
| 342 | void DisplayFunction(Idx<Variable> variable, lua_State *L, int index) { |
| 343 | lua_Debug ar{}; |
| 344 | lua_pushvalue(L, index); |
| 345 | if (lua_getinfo(L, ">Snu", &ar) == 0) { |
| 346 | variable->value = ToPointer(L, index); |
| 347 | } |
| 348 | else { |
| 349 | switch (luaVersion) { |
| 350 | case LuaVersion::LUA_54: { |
| 351 | DisplayFunction54(variable, L, index, ar.u.ar54); |
| 352 | break; |
| 353 | } |
| 354 | default: { |
| 355 | variable->value = ToPointer(L, index); |
| 356 | break; |
| 357 | } |
| 358 | } |
| 359 | } |
| 360 | lua_settop(L, index); |
| 361 | } |
| 362 | #endif |
| 363 | // algorithm optimization |
| 364 | void Debugger::GetVariable(lua_State *L, Idx<Variable> variable, int index, int depth, bool queryHelper) { |
no test coverage detected