aboutsummaryrefslogtreecommitdiff
path: root/lstate.h
diff options
context:
space:
mode:
Diffstat (limited to 'lstate.h')
-rw-r--r--lstate.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/lstate.h b/lstate.h
index c290ff32..1aef2f75 100644
--- a/lstate.h
+++ b/lstate.h
@@ -251,8 +251,8 @@ typedef struct global_State {
251 lua_Alloc frealloc; /* function to reallocate memory */ 251 lua_Alloc frealloc; /* function to reallocate memory */
252 void *ud; /* auxiliary data to 'frealloc' */ 252 void *ud; /* auxiliary data to 'frealloc' */
253 lu_mem totalbytes; /* number of bytes currently allocated */ 253 lu_mem totalbytes; /* number of bytes currently allocated */
254 l_obj totalobjs; /* total number of objects allocated - GCdebt */ 254 l_obj totalobjs; /* total number of objects allocated + GCdebt */
255 l_obj GCdebt; /* bytes allocated not yet compensated by the collector */ 255 l_obj GCdebt; /* objects counted but not yet allocated */
256 l_obj marked; /* number of objects marked in a GC cycle */ 256 l_obj marked; /* number of objects marked in a GC cycle */
257 l_obj GClastmajor; /* objects at last major collection */ 257 l_obj GClastmajor; /* objects at last major collection */
258 stringtable strt; /* hash table for strings */ 258 stringtable strt; /* hash table for strings */
@@ -388,7 +388,7 @@ union GCUnion {
388 388
389 389
390/* actual number of total objects allocated */ 390/* actual number of total objects allocated */
391#define gettotalobjs(g) ((g)->totalobjs + (g)->GCdebt) 391#define gettotalobjs(g) ((g)->totalobjs - (g)->GCdebt)
392 392
393 393
394LUAI_FUNC void luaE_setdebt (global_State *g, l_obj debt); 394LUAI_FUNC void luaE_setdebt (global_State *g, l_obj debt);