diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2020-08-07 11:21:44 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2020-08-07 11:21:44 -0300 |
commit | 7c3cb71fa48fbe84d9d9c664eb646446fb80898b (patch) | |
tree | 43d2b2282853b882877e42a0b8ec7467c9bb0e9e /lgc.h | |
parent | 68109afcdb59a7eeb75bacf055abce3e56a53645 (diff) | |
download | lua-7c3cb71fa48fbe84d9d9c664eb646446fb80898b.tar.gz lua-7c3cb71fa48fbe84d9d9c664eb646446fb80898b.tar.bz2 lua-7c3cb71fa48fbe84d9d9c664eb646446fb80898b.zip |
Free bit 7 of GC 'marked' field
Tables were using this bit to indicate their array sizes were real
('isrealasize'), but this bit can be useful for tests. Instead, they
can use bit 7 of their 'flag' field for that purpose. (There are only
six fast-access metamethods.) This 'flag' field only exists in tables,
so this use does not affect other types.
Diffstat (limited to 'lgc.h')
-rw-r--r-- | lgc.h | 3 |
1 files changed, 1 insertions, 2 deletions
@@ -69,8 +69,7 @@ | |||
69 | 69 | ||
70 | /* | 70 | /* |
71 | ** Layout for bit use in 'marked' field. First three bits are | 71 | ** Layout for bit use in 'marked' field. First three bits are |
72 | ** used for object "age" in generational mode. Last bit is free | 72 | ** used for object "age" in generational mode. |
73 | ** to be used by respective objects. | ||
74 | */ | 73 | */ |
75 | #define WHITE0BIT 3 /* object is white (type 0) */ | 74 | #define WHITE0BIT 3 /* object is white (type 0) */ |
76 | #define WHITE1BIT 4 /* object is white (type 1) */ | 75 | #define WHITE1BIT 4 /* object is white (type 1) */ |