mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
vm_core.h: vm_call_flag_bits
* vm_core.h (vm_call_flag_bits): define VM_CALL flags by using enum constants. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59518 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
206596c867
commit
d11dfab569
1 changed files with 24 additions and 10 deletions
34
vm_core.h
34
vm_core.h
|
@ -941,16 +941,30 @@ enum vm_check_match_type {
|
||||||
#define VM_CHECKMATCH_TYPE_MASK 0x03
|
#define VM_CHECKMATCH_TYPE_MASK 0x03
|
||||||
#define VM_CHECKMATCH_ARRAY 0x04
|
#define VM_CHECKMATCH_ARRAY 0x04
|
||||||
|
|
||||||
#define VM_CALL_ARGS_SPLAT (0x01 << 0) /* m(*args) */
|
enum vm_call_flag_bits {
|
||||||
#define VM_CALL_ARGS_BLOCKARG (0x01 << 1) /* m(&block) */
|
VM_CALL_ARGS_SPLAT_bit, /* m(*args) */
|
||||||
#define VM_CALL_FCALL (0x01 << 2) /* m(...) */
|
VM_CALL_ARGS_BLOCKARG_bit, /* m(&block) */
|
||||||
#define VM_CALL_VCALL (0x01 << 3) /* m */
|
VM_CALL_FCALL_bit, /* m(...) */
|
||||||
#define VM_CALL_ARGS_SIMPLE (0x01 << 4) /* (ci->flag & (SPLAT|BLOCKARG)) && blockiseq == NULL && ci->kw_arg == NULL */
|
VM_CALL_VCALL_bit, /* m */
|
||||||
#define VM_CALL_BLOCKISEQ (0x01 << 5) /* has blockiseq */
|
VM_CALL_ARGS_SIMPLE_bit, /* (ci->flag & (SPLAT|BLOCKARG)) && blockiseq == NULL && ci->kw_arg == NULL */
|
||||||
#define VM_CALL_KWARG (0x01 << 6) /* has kwarg */
|
VM_CALL_BLOCKISEQ_bit, /* has blockiseq */
|
||||||
#define VM_CALL_TAILCALL (0x01 << 7) /* located at tail position */
|
VM_CALL_KWARG_bit, /* has kwarg */
|
||||||
#define VM_CALL_SUPER (0x01 << 8) /* super */
|
VM_CALL_TAILCALL_bit, /* located at tail position */
|
||||||
#define VM_CALL_OPT_SEND (0x01 << 9) /* internal flag */
|
VM_CALL_SUPER_bit, /* super */
|
||||||
|
VM_CALL_OPT_SEND_bit, /* internal flag */
|
||||||
|
VM_CALL__END
|
||||||
|
};
|
||||||
|
|
||||||
|
#define VM_CALL_ARGS_SPLAT (0x01 << VM_CALL_ARGS_SPLAT_bit)
|
||||||
|
#define VM_CALL_ARGS_BLOCKARG (0x01 << VM_CALL_ARGS_BLOCKARG_bit)
|
||||||
|
#define VM_CALL_FCALL (0x01 << VM_CALL_FCALL_bit)
|
||||||
|
#define VM_CALL_VCALL (0x01 << VM_CALL_VCALL_bit)
|
||||||
|
#define VM_CALL_ARGS_SIMPLE (0x01 << VM_CALL_ARGS_SIMPLE_bit)
|
||||||
|
#define VM_CALL_BLOCKISEQ (0x01 << VM_CALL_BLOCKISEQ_bit)
|
||||||
|
#define VM_CALL_KWARG (0x01 << VM_CALL_KWARG_bit)
|
||||||
|
#define VM_CALL_TAILCALL (0x01 << VM_CALL_TAILCALL_bit)
|
||||||
|
#define VM_CALL_SUPER (0x01 << VM_CALL_SUPER_bit)
|
||||||
|
#define VM_CALL_OPT_SEND (0x01 << VM_CALL_OPT_SEND_bit)
|
||||||
|
|
||||||
enum vm_special_object_type {
|
enum vm_special_object_type {
|
||||||
VM_SPECIAL_OBJECT_VMCORE = 1,
|
VM_SPECIAL_OBJECT_VMCORE = 1,
|
||||||
|
|
Loading…
Reference in a new issue