diff options
| author | eileencodes <eileencodes@gmail.com> | 2024-10-01 14:50:45 -0400 |
|---|---|---|
| committer | Kevin Newton <kddnewton@gmail.com> | 2024-12-16 10:51:22 -0500 |
| commit | a21237571e57e1c6992d41424300996303859b3e (patch) | |
| tree | cf3ce94973de1e79fbed590858a3c43eecb58f0f /include/ruby/internal | |
| parent | 8eaa976cbe20ef81a3dd17097337394bf798d7f0 (diff) | |
[ruby/prism] Fix 3112 - disallow commas after block arg
Prism was already disallowing arguments after block args, but in
parse.y, any comma after a block arg is a syntax error. This moves the
error handling into `PM_TOKEN_UAMPERSAND` where we can check if the
current type is `PM_TOKEN_COMMA`then raise an error. I've also updated
the tests to include the examplesfrom ruby/prism#3112.
Fixes: ruby/prism#3112
https://github.com/ruby/prism/commit/754cf8eddc
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/12358
Diffstat (limited to 'include/ruby/internal')
0 files changed, 0 insertions, 0 deletions
