ruby-changes:49649
From: mame <ko1@a...>
Date: Thu, 11 Jan 2018 13:25:39 +0900 (JST)
Subject: [ruby-changes:49649] mame:r61765 (trunk): parse.y: add a simple comment for COND_* and CMDARG_*
mame 2018-01-11 13:25:33 +0900 (Thu, 11 Jan 2018) New Revision: 61765 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=61765 Log: parse.y: add a simple comment for COND_* and CMDARG_* Modified files: trunk/parse.y Index: parse.y =================================================================== --- parse.y (revision 61764) +++ parse.y (revision 61765) @@ -125,12 +125,16 @@ static const rb_code_location_t NULL_LOC https://github.com/ruby/ruby/blob/trunk/parse.y#L125 # 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) -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/