diff options
| author | mame <mame@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2018-01-11 04:25:33 +0000 |
|---|---|---|
| committer | mame <mame@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2018-01-11 04:25:33 +0000 |
| commit | f41b4b1bfb4a29f8648a74f124bd0ca60307aaf8 (patch) | |
| tree | 025948303a67fd3b20ea86eae8c8d6bfb1d70036 | |
| parent | 5ab288f53b0e68c3bac72cf8c03d826edd5121a6 (diff) | |
parse.y: add a simple comment for COND_* and CMDARG_*
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61765 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
| -rw-r--r-- | parse.y | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -125,12 +125,16 @@ static const rb_code_location_t NULL_LOC = { {0, -1}, {0, -1} }; # define BITSTACK_SET_P(stack) (SHOW_BITSTACK(stack, #stack), (stack)&1) # define BITSTACK_SET(stack, n) ((stack)=(n), SHOW_BITSTACK(stack, #stack"(set)")) +/* A flag to identify keyword_do_cond, "do" keyword after condition expression. + Examples: `while ... do`, `until ... do`, and `for ... in ... do` */ #define COND_PUSH(n) BITSTACK_PUSH(cond_stack, (n)) #define COND_POP() BITSTACK_POP(cond_stack) #define COND_LEXPOP() BITSTACK_LEXPOP(cond_stack) #define COND_P() BITSTACK_SET_P(cond_stack) #define COND_SET(n) BITSTACK_SET(cond_stack, (n)) +/* A flag to identify keyword_do_block; "do" keyword after command_call. + Example: `foo 1, 2 do`. */ #define CMDARG_PUSH(n) BITSTACK_PUSH(cmdarg_stack, (n)) #define CMDARG_POP() BITSTACK_POP(cmdarg_stack) #define CMDARG_LEXPOP() BITSTACK_LEXPOP(cmdarg_stack) |
