<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ruby.git/test/prism/errors/endless_method_command_call_parameters.txt, branch v4.0.2</title>
<subtitle>The Ruby Programming Language</subtitle>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/'/>
<entry>
<title>[ruby/prism] Reject `def f a, (b) = 1`</title>
<updated>2025-11-06T13:31:46+00:00</updated>
<author>
<name>Earlopain</name>
<email>14981592+Earlopain@users.noreply.github.com</email>
</author>
<published>2025-11-01T20:45:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=d73eba51853fde74624984b3063bd648b664e3e3'/>
<id>d73eba51853fde74624984b3063bd648b664e3e3</id>
<content type='text'>
Fixes [#Bug 21660], followup to https://github.com/ruby/prism/pull/3674

https://github.com/ruby/prism/commit/fb445a49e5

Co-Authored-By: tomoya ishida &lt;tomoyapenguin@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fixes [#Bug 21660], followup to https://github.com/ruby/prism/pull/3674

https://github.com/ruby/prism/commit/fb445a49e5

Co-Authored-By: tomoya ishida &lt;tomoyapenguin@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/prism] For these special cases, there exists no optional argument type. Since a endless method is started with `=`, there was ambiguity here. We have to simply reject these in all cases.</title>
<updated>2025-10-08T13:04:57+00:00</updated>
<author>
<name>Earlopain</name>
<email>14981592+Earlopain@users.noreply.github.com</email>
</author>
<published>2025-10-08T12:54:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=b8f8d646a64f883652b44780c4174a85f98d1c82'/>
<id>b8f8d646a64f883652b44780c4174a85f98d1c82</id>
<content type='text'>
This adds a new error for the following reason:
* `def foo arg = nil` is interpreted as a normal method call with optional `arg` without matching `end`
* `def foo *arg = nil; end` is interpreted as a endless method call that has body `nil` with extraneous `end`

`def foo *arg = nil` is somewhere inbetween and I don't know how to otherwise indicate the error.
Now the second case above also shows the newly added error message.

Fixes [Bug #21623]

https://github.com/ruby/prism/commit/e1910d4492
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This adds a new error for the following reason:
* `def foo arg = nil` is interpreted as a normal method call with optional `arg` without matching `end`
* `def foo *arg = nil; end` is interpreted as a endless method call that has body `nil` with extraneous `end`

`def foo *arg = nil` is somewhere inbetween and I don't know how to otherwise indicate the error.
Now the second case above also shows the newly added error message.

Fixes [Bug #21623]

https://github.com/ruby/prism/commit/e1910d4492
</pre>
</div>
</content>
</entry>
</feed>
