mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
proc.h: MRB_ASPEC_REST() macro return 1 or 0
MRB_ASPEC_REST() is macro just only checks whether truthy or falsy. And truthy means exist 1 rest argument in current proc.
This commit is contained in:
@@ -37,7 +37,7 @@ struct RProc {
|
||||
/* aspec access */
|
||||
#define MRB_ASPEC_REQ(a) (((a) >> 18) & 0x1f)
|
||||
#define MRB_ASPEC_OPT(a) (((a) >> 13) & 0x1f)
|
||||
#define MRB_ASPEC_REST(a) ((a) & (1<<12))
|
||||
#define MRB_ASPEC_REST(a) (((a) >> 12) & 0x1)
|
||||
#define MRB_ASPEC_POST(a) (((a) >> 7) & 0x1f)
|
||||
#define MRB_ASPEC_KEY(a) (((a) >> 2) & 0x1f)
|
||||
#define MRB_ASPEC_KDICT(a) ((a) & (1<<1))
|
||||
|
||||
Reference in New Issue
Block a user