ruby-syntax-tree / syntax_tree

Interact with the Ruby syntax tree
https://ruby-syntax-tree.github.io/syntax_tree/
MIT License
563 stars 54 forks source link

Fix Ruby build on HEAD #337

Closed kddnewton closed 1 year ago

kddnewton commented 1 year ago

This fixes two bugs. The first is that in an in clause, you need to use the then keyword or parentheses if the pattern you are matching is an endless range.

The second is that we are associating the then keyword with the wrong in clauses because they come in in reverse order and we're deleting them from the parent clauses incorrectly.