[ruby/prism] Make PM_NODE_FLAG_COMMON_MASK into a constant
https://github.com/ruby/prism/commit/ec66feb595
This commit is contained in:
parent
e700582d98
commit
81fbacb59d
@ -55,7 +55,7 @@ typedef uint16_t pm_node_flags_t;
|
||||
#define PM_NODE_FLAG_BITS (sizeof(pm_node_flags_t) * 8)
|
||||
static const pm_node_flags_t PM_NODE_FLAG_NEWLINE = (1 << (PM_NODE_FLAG_BITS - 1));
|
||||
static const pm_node_flags_t PM_NODE_FLAG_STATIC_LITERAL = (1 << (PM_NODE_FLAG_BITS - 2));
|
||||
static const pm_node_flags_t PM_NODE_FLAG_COMMON_MASK = PM_NODE_FLAG_NEWLINE | PM_NODE_FLAG_STATIC_LITERAL;
|
||||
static const pm_node_flags_t PM_NODE_FLAG_COMMON_MASK = (1 << (PM_NODE_FLAG_BITS - 1)) | (1 << (PM_NODE_FLAG_BITS - 2));
|
||||
|
||||
// For easy access, we define some macros to check node type
|
||||
#define PM_NODE_TYPE(node) ((enum pm_node_type)node->type)
|
||||
|
Loading…
x
Reference in New Issue
Block a user