#[repr(C)]pub enum lua_GCOp {
LUA_GCSTOP = 0,
LUA_GCRESTART = 1,
LUA_GCCOLLECT = 2,
LUA_GCCOUNT = 3,
LUA_GCCOUNTB = 4,
LUA_GCISRUNNING = 5,
LUA_GCSTEP = 6,
LUA_GCSETGOAL = 7,
LUA_GCSETSTEPMUL = 8,
LUA_GCSETSTEPSIZE = 9,
}Expand description
Garbage collection operations that can be performed.
Variants§
LUA_GCSTOP = 0
Stops the incremental garbage collector.
LUA_GCRESTART = 1
Restarts the incremental garbage collector after a stop.
LUA_GCCOLLECT = 2
Runs a full garbage collection cycle.
LUA_GCCOUNT = 3
Counts the heap size in kilobytes.
LUA_GCCOUNTB = 4
Counts the remainder of the heap size in bytes, after the kilobytes.
LUA_GCISRUNNING = 5
Returns if the GC is running. This may still return true even if the GC is not actively collecting.
LUA_GCSTEP = 6
Performs an explicit GC step with the given size in kilobytes.
LUA_GCSETGOAL = 7
Sets the goal of the incremental garbage collector. The goal is given as a percentage of live data to all data, so 200% (the default) means that the heap is allowed to grow to twice the size of the live data.
LUA_GCSETSTEPMUL = 8
Sets the step multiplier of the incremental garbage collector. The GC will try to collect at least this percentage of the heap size each step.
LUA_GCSETSTEPSIZE = 9
Sets the step size of the incremental garbage collector. The GC will run a step after this many bytes are allocated.