Skip to content

Generalize AST Flags to a single 4-byte flag #42

Description

@Ed94

Right now there is:

ModuleFlag ModuleFlags;
union {
b32 IsFunction; // Used by typedef to not serialize the name field.
b32 IsParamPack; // Used by typename to know if type should be considered a parameter pack.
OperatorT Op;
AccessSpec ParentAccess;
s32 NumEntries;
};

At the end of the AST data layout. We can simplify the layout to:

CodeFlag CodeFlags;
union {
OperatorT Op;
AccessSpec ParentAccess;
s32 NumEntries;
};

Where CodeFlag is an enum : u32

This would leave open the ability for others to add their own flags without much hassle.

Metadata

Metadata

Assignees

Labels

Projects

Status
Todo

Relationships

None yet

Development

No branches or pull requests

Issue actions