Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

+ ruby28.y: extracted excessed_comma rule. #706

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 3 additions & 1 deletion lib/parser/ruby28.y
Expand Up @@ -1483,6 +1483,8 @@ opt_block_args_tail:
result = []
}

excessed_comma: tCOMMA

block_param: f_arg tCOMMA f_block_optarg tCOMMA f_rest_arg opt_block_args_tail
{
result = val[0].
Expand Down Expand Up @@ -1517,7 +1519,7 @@ opt_block_args_tail:
concat(val[2]).
concat(val[3])
}
| f_arg tCOMMA
| f_arg excessed_comma
| f_arg tCOMMA f_rest_arg tCOMMA f_arg opt_block_args_tail
{
result = val[0].
Expand Down