Write scopes in id order, so we don't need to write out the id itself. Add the
size of the scope to the output file and a flag bit that tells us if the scope has a size. git-svn-id: svn://svn.cc65.org/cc65/trunk@5097 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
@@ -44,16 +44,24 @@
|
||||
|
||||
|
||||
|
||||
/* Size of scope available? */
|
||||
#define SCOPE_SIZELESS 0x00U /* No scope size available */
|
||||
#define SCOPE_SIZE 0x01U /* Scope has a size */
|
||||
#define SCOPE_MASK_SIZE 0x01U /* Size mask */
|
||||
|
||||
#define SCOPE_HAS_SIZE(x) (((x) & SCOPE_MASK_SIZE) == SCOPE_SIZE)
|
||||
|
||||
|
||||
/* Scope types */
|
||||
enum {
|
||||
SCOPETYPE_GLOBAL, /* Global level */
|
||||
SCOPETYPE_FILE, /* File level */
|
||||
SCOPETYPE_PROC, /* .PROC */
|
||||
SCOPETYPE_SCOPE, /* .SCOPE */
|
||||
SCOPETYPE_HAS_DATA = SCOPETYPE_SCOPE, /* Last scope that contains data */
|
||||
SCOPETYPE_STRUCT, /* .STRUCT/.UNION */
|
||||
SCOPETYPE_ENUM, /* .ENUM */
|
||||
SCOPETYPE_UNDEF = 0xFF
|
||||
SCOPE_GLOBAL, /* Global level */
|
||||
SCOPE_FILE, /* File level */
|
||||
SCOPE_PROC, /* .PROC */
|
||||
SCOPE_SCOPE, /* .SCOPE */
|
||||
SCOPE_HAS_DATA = SCOPE_SCOPE, /* Last scope that contains data */
|
||||
SCOPE_STRUCT, /* .STRUCT/.UNION */
|
||||
SCOPE_ENUM, /* .ENUM */
|
||||
SCOPE_UNDEF = 0xFF
|
||||
};
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user