| Age | Commit message (Collapse) | Author |
|
blocks/lambda
Blocks and lambdas inherit anonymous arguments from the method they are a part of.
They themselves don't allow to introduce new anonymous arguments.
While you can write this:
```rb
def foo(*)
bar { |**| }
end
```
referecing the new parameter inside of the block will always be a syntax error.
https://github.com/ruby/prism/commit/2cbd27e134
|
|
https://github.com/ruby/prism/commit/e98ea15596
Notes:
Merged: https://github.com/ruby/ruby/pull/11643
|
|
|
|
It's possible to repeat parameters in method definitions like so:
```ruby
def foo(_a, _a)
end
```
The compiler needs to know to adjust the local table size to account for
these duplicate names. We'll use the repeated parameter flag to account
for the extra stack space required
https://github.com/ruby/prism/commit/b443cb1f60
Co-Authored-By: Kevin Newton <kddnewton@gmail.com>
Co-Authored-By: Jemma Issroff <jemmaissroff@gmail.com>
|
|
Fix https://github.com/ruby/prism/pull/1936
https://github.com/ruby/prism/commit/232e77a003
|
|
It is for supporting `def foo(bar = (def baz(bar) = bar; 1)) = 2` case.
https://github.com/ruby/prism/commit/c789a833c5
|
|
Fix https://github.com/ruby/prism/pull/1839
https://github.com/ruby/prism/commit/5784ab749f
|
|
(https://github.com/ruby/prism/pull/1591)
https://github.com/ruby/prism/commit/46b8576dd0
|
|
https://github.com/ruby/prism/commit/2a11bfee76
|
|
|