diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2006-07-11 12:53:29 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2006-07-11 12:53:29 -0300 |
commit | 3ca9af51a4f060cf2178901a67a21f8269af3224 (patch) | |
tree | 4f1bb541280aa8b4960b16d0925eca60adb2b1a8 /lstate.h | |
parent | c7b89dd28097296bbc14d9b47b4cea72514b2b76 (diff) | |
download | lua-3ca9af51a4f060cf2178901a67a21f8269af3224.tar.gz lua-3ca9af51a4f060cf2178901a67a21f8269af3224.tar.bz2 lua-3ca9af51a4f060cf2178901a67a21f8269af3224.zip |
emergency garbage collector (core forces a GC when allocation fails)
Diffstat (limited to 'lstate.h')
-rw-r--r-- | lstate.h | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lstate.h,v 2.23 2005/07/09 13:22:34 roberto Exp roberto $ | 2 | ** $Id: lstate.h,v 2.24 2006/02/06 18:27:59 roberto Exp roberto $ |
3 | ** Global State | 3 | ** Global State |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -71,6 +71,7 @@ typedef struct global_State { | |||
71 | void *ud; /* auxiliary data to `frealloc' */ | 71 | void *ud; /* auxiliary data to `frealloc' */ |
72 | lu_byte currentwhite; | 72 | lu_byte currentwhite; |
73 | lu_byte gcstate; /* state of garbage collector */ | 73 | lu_byte gcstate; /* state of garbage collector */ |
74 | lu_byte emergencygc; /* true when collect was trigged by alloc error */ | ||
74 | int sweepstrgc; /* position of sweep in `strt' */ | 75 | int sweepstrgc; /* position of sweep in `strt' */ |
75 | GCObject *rootgc; /* list of all collectable objects */ | 76 | GCObject *rootgc; /* list of all collectable objects */ |
76 | GCObject **sweepgc; /* position of sweep in `rootgc' */ | 77 | GCObject **sweepgc; /* position of sweep in `rootgc' */ |
@@ -161,7 +162,6 @@ union GCObject { | |||
161 | #define obj2gco(v) (cast(GCObject *, (v))) | 162 | #define obj2gco(v) (cast(GCObject *, (v))) |
162 | 163 | ||
163 | 164 | ||
164 | LUAI_FUNC lua_State *luaE_newthread (lua_State *L); | ||
165 | LUAI_FUNC void luaE_freethread (lua_State *L, lua_State *L1); | 165 | LUAI_FUNC void luaE_freethread (lua_State *L, lua_State *L1); |
166 | 166 | ||
167 | #endif | 167 | #endif |