Stan Lo 2eab962c53 [ruby/prism] Allow command calls in endless method bodies within assignments
Previously, endless method definitions in assignment contexts like
`x = def f = p 1` would fail to parse because command calls (method
calls without parentheses) were only accepted when the surrounding
binding power was less than `PM_BINDING_POWER_COMPOSITION`.

This fix specifically checks for assignment context and allows command
calls in those cases while maintaining the existing behavior for other
contexts. This ensures that:

- `x = def f = p 1` parses correctly (previously failed)
- `private def f = puts "Hello"` still produces the expected error

https://github.com/ruby/prism/commit/722af59ba3
2025-07-29 17:18:41 +00:00
..
2025-03-18 19:06:34 +00:00
2025-03-18 19:06:34 +00:00