diff options
Diffstat (limited to 'lgc.h')
| -rw-r--r-- | lgc.h | 10 |
1 files changed, 5 insertions, 5 deletions
| @@ -1,5 +1,5 @@ | |||
| 1 | /* | 1 | /* |
| 2 | ** $Id: lgc.h,v 2.61 2013/08/16 18:55:49 roberto Exp roberto $ | 2 | ** $Id: lgc.h,v 2.62 2013/08/19 14:18:43 roberto Exp roberto $ |
| 3 | ** Garbage Collector | 3 | ** Garbage Collector |
| 4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
| 5 | */ | 5 | */ |
| @@ -76,10 +76,9 @@ | |||
| 76 | #define WHITE0BIT 0 /* object is white (type 0) */ | 76 | #define WHITE0BIT 0 /* object is white (type 0) */ |
| 77 | #define WHITE1BIT 1 /* object is white (type 1) */ | 77 | #define WHITE1BIT 1 /* object is white (type 1) */ |
| 78 | #define BLACKBIT 2 /* object is black */ | 78 | #define BLACKBIT 2 /* object is black */ |
| 79 | #define FINALIZEDBIT 3 /* object has been separated for finalization */ | 79 | #define FINALIZEDBIT 3 /* object has been marked for finalization */ |
| 80 | #define SEPARATED 4 /* object is in 'finobj' list or in 'tobefnz' */ | 80 | #define FIXEDBIT 4 /* object is fixed (should not be collected) */ |
| 81 | #define FIXEDBIT 5 /* object is fixed (should not be collected) */ | 81 | #define LOCALBIT 5 /* object is not local */ |
| 82 | #define LOCALBIT 6 /* object is not local */ | ||
| 83 | /* bit 7 is currently used by tests (luaL_checkmemory) */ | 82 | /* bit 7 is currently used by tests (luaL_checkmemory) */ |
| 84 | 83 | ||
| 85 | #define WHITEBITS bit2mask(WHITE0BIT, WHITE1BIT) | 84 | #define WHITEBITS bit2mask(WHITE0BIT, WHITE1BIT) |
| @@ -91,6 +90,7 @@ | |||
| 91 | (!testbits((x)->gch.marked, WHITEBITS | bitmask(BLACKBIT))) | 90 | (!testbits((x)->gch.marked, WHITEBITS | bitmask(BLACKBIT))) |
| 92 | #define islocal(x) (!testbit((x)->gch.marked, LOCALBIT)) | 91 | #define islocal(x) (!testbit((x)->gch.marked, LOCALBIT)) |
| 93 | 92 | ||
| 93 | #define tofinalize(x) testbit((x)->gch.marked, FINALIZEDBIT) | ||
| 94 | 94 | ||
| 95 | #define otherwhite(g) (g->currentwhite ^ WHITEBITS) | 95 | #define otherwhite(g) (g->currentwhite ^ WHITEBITS) |
| 96 | #define isdeadm(ow,m) (!(((m) ^ WHITEBITS) & (ow))) | 96 | #define isdeadm(ow,m) (!(((m) ^ WHITEBITS) & (ow))) |
