[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: OP_NEWTABLE > __gc > lua_getinfo > getfuncname fails assert
- From: Dave Hayden <dave@...>
- Date: Mon, 13 Jun 2016 15:48:22 -0700
I have a __gc function implemented in C that logs allocs and frees, calling lua_getinfo() to get a stack trace. In this case, the finalizer is being called via the checkGC() call in OP_NEWTABLE in luaV_execute. The assert claims that getfuncname() shouldn’t be called from OP_NEWTABLE, but this seems like a legit use case. (OP_CONCAT and OP_CLOSURE also call checkGC(); OP_CLOSURE would fail the assert, too.)
Bug, or am I doing it wrong? Or do you need more info?