summaryrefslogtreecommitdiff
path: root/parse.y
diff options
context:
space:
mode:
authornagachika <nagachika@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2020-03-07 09:44:38 +0000
committernagachika <nagachika@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2020-03-07 09:44:38 +0000
commit773b45bcc86861c30db135a2c558444ca7193761 (patch)
treee7146de54658bdf7d43fb53214ab7b5a15cc0ce0 /parse.y
parentca74f62a3abfa13c353737c74624d3ef00777036 (diff)
merge revision(s) 6e6844320de989cb88a154e2ac75066ccea1bba2: [Backport #16619]
Fixed duplicated warning As `command_rhs` is always a "value expression", `command_asgn` does not need the same check. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_6@67839 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'parse.y')
-rw-r--r--parse.y6
1 files changed, 0 insertions, 6 deletions
diff --git a/parse.y b/parse.y
index 0e919f1b02..16bde4db02 100644
--- a/parse.y
+++ b/parse.y
@@ -1211,7 +1211,6 @@ stmt : keyword_alias fitem {SET_LEX_STATE(EXPR_FNAME|EXPR_FITEM);} fitem
command_asgn : lhs '=' command_rhs
{
/*%%%*/
- value_expr($3);
$$ = node_assign(p, $1, $3, &@$);
/*% %*/
/*% ripper: assign!($1, $3) %*/
@@ -1219,7 +1218,6 @@ command_asgn : lhs '=' command_rhs
| var_lhs tOP_ASGN command_rhs
{
/*%%%*/
- value_expr($3);
$$ = new_op_assign(p, $1, $2, $3, &@$);
/*% %*/
/*% ripper: opassign!($1, $2, $3) %*/
@@ -1227,7 +1225,6 @@ command_asgn : lhs '=' command_rhs
| primary_value '[' opt_call_args rbracket tOP_ASGN command_rhs
{
/*%%%*/
- value_expr($6);
$$ = new_ary_op_assign(p, $1, $3, $5, $6, &@3, &@$);
/*% %*/
/*% ripper: opassign!(aref_field!($1, escape_Qundef($3)), $5, $6) %*/
@@ -1236,7 +1233,6 @@ command_asgn : lhs '=' command_rhs
| primary_value call_op tIDENTIFIER tOP_ASGN command_rhs
{
/*%%%*/
- value_expr($5);
$$ = new_attr_op_assign(p, $1, $2, $3, $4, $5, &@$);
/*% %*/
/*% ripper: opassign!(field!($1, $2, $3), $4, $5) %*/
@@ -1244,7 +1240,6 @@ command_asgn : lhs '=' command_rhs
| primary_value call_op tCONSTANT tOP_ASGN command_rhs
{
/*%%%*/
- value_expr($5);
$$ = new_attr_op_assign(p, $1, $2, $3, $4, $5, &@$);
/*% %*/
/*% ripper: opassign!(field!($1, $2, $3), $4, $5) %*/
@@ -1260,7 +1255,6 @@ command_asgn : lhs '=' command_rhs
| primary_value tCOLON2 tIDENTIFIER tOP_ASGN command_rhs
{
/*%%%*/
- value_expr($5);
$$ = new_attr_op_assign(p, $1, ID2VAL(idCOLON2), $3, $4, $5, &@$);
/*% %*/
/*% ripper: opassign!(field!($1, ID2VAL(idCOLON2), $3), $4, $5) %*/