Shmuel Zeigerman wrote: > Here is a test case where LuaJIT 2.x (with JIT turned on) seems to fail > to collect garbage. The JIT-compiled traces specialize to closures, which in turn keep their upvalues anchored. E.g. save_table and the inner closure in SaveToString. Run jit.flush() once before collectgarbage() to check this is the case. To avoid this, rewrite the code without using transient closures. --Mike