Define the type of marking flags as unsigned int.

We could define it as _Bool since we are going to use C99, but unsigned
int is more portable (even in C89!) and extensible (when we decide to
use tri-color marking GC.)

Signed-off-by: OGINO Masanori <masanori.ogino@gmail.com>
This commit is contained in:
OGINO Masanori 2014-01-19 17:15:30 +09:00
parent 9495e9bf5c
commit 9be7ffc5fc
1 changed files with 3 additions and 5 deletions

View File

@ -9,16 +9,14 @@
extern "C" {
#endif
enum pic_gc_mark {
PIC_GC_UNMARK = 0,
PIC_GC_MARK
};
#define PIC_GC_UNMARK 0
#define PIC_GC_MARK 1
union header {
struct {
union header *ptr;
size_t size;
enum pic_gc_mark mark : 1;
unsigned int mark : 1;
} s;
long alignment[2];
};