Skip to content

Commit

Permalink
Support find pattern for pattern matching syntax
Browse files Browse the repository at this point in the history
This PR Support find pattern matching for Ruby 2.8 (3.0) parser.
Parser gem supports this syntax by whitequark/parser#714.
  • Loading branch information
koic authored and marcandre committed Jul 3, 2020
1 parent 41976bc commit f0534b5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Expand Up @@ -2,6 +2,10 @@

## master (unreleased)

### New features

* [#50](https://github.com/rubocop-hq/rubocop-ast/pull/50): Support find pattern matching for Ruby 2.8 (3.0) parser. ([@koic][])

## 0.1.0 (2020-06-26)

### New features
Expand Down
2 changes: 1 addition & 1 deletion lib/rubocop/ast/traversal.rb
Expand Up @@ -34,7 +34,7 @@ def walk(node)
match_with_lvasgn begin kwbegin return
in_match match_alt
match_as array_pattern array_pattern_with_tail
hash_pattern const_pattern
hash_pattern const_pattern find_pattern
index indexasgn].freeze
SECOND_CHILD_ONLY = %i[lvasgn ivasgn cvasgn gvasgn optarg kwarg
kwoptarg].freeze
Expand Down

0 comments on commit f0534b5

Please sign in to comment.