first implementation of ephemerons

This commit is contained in:
Roberto Ierusalimschy
2007-10-31 13:41:19 -02:00
parent 0e961ad47a
commit 5e8dd55574
3 changed files with 83 additions and 51 deletions

View File

@@ -1,5 +1,5 @@
/*
** $Id: lstate.h,v 2.28 2007/02/07 17:48:52 roberto Exp roberto $
** $Id: lstate.h,v 2.29 2007/10/29 16:51:20 roberto Exp roberto $
** Global State
** See Copyright Notice in lua.h
*/
@@ -78,9 +78,9 @@ typedef struct global_State {
GCObject **sweepgc; /* position of sweep in `rootgc' */
GCObject *gray; /* list of gray objects */
GCObject *grayagain; /* list of objects to be traversed atomically */
GCObject *weakvalue; /* list of value-weak tables */
GCObject *weakkey; /* list of key-weak tables */
GCObject *weakkeyvalue; /* list of all-weak tables */
GCObject *weak; /* list of (something) weak tables */
GCObject *ephemeron; /* list of ephemeron tables */
GCObject *allweak; /* list of all-weak tables */
GCObject *tmudata; /* last element of list of userdata to be GC */
Mbuffer buff; /* temporary buffer for string concatentation */
lu_mem GCthreshold;