(log = console.log)
| 359 | } |
| 360 | |
| 361 | public dumpStack(log = console.log): void { |
| 362 | const top = this.getTop() |
| 363 | |
| 364 | for (let i = 1; i <= top; i++) { |
| 365 | const type = this.lua.lua_type(this.address, i) |
| 366 | const typename = this.lua.lua_typename(this.address, type) |
| 367 | const pointer = this.getPointer(i) |
| 368 | const name = this.indexToString(i) |
| 369 | const value = this.getValue(i, type) |
| 370 | |
| 371 | log(i, typename, pointer, name, value) |
| 372 | } |
| 373 | } |
| 374 | |
| 375 | public assertOk(result: LuaReturn): void { |
| 376 | if (result !== LuaReturn.Ok && result !== LuaReturn.Yield) { |
nothing calls this directly
no test coverage detected