Skip to content

Commit

Permalink
Allow multiple patterns after match
Browse files Browse the repository at this point in the history
  • Loading branch information
theHamsta committed Dec 14, 2021
1 parent 3c903f0 commit 0881390
Showing 1 changed file with 24 additions and 4 deletions.
28 changes: 24 additions & 4 deletions test/corpus/pattern_matching.txt
Original file line number Diff line number Diff line change
Expand Up @@ -460,10 +460,7 @@ match x,:

(module
(match_statement
(tuple
(integer)
(integer)
(integer))
(identifier)
(case_clause
(list_splat_pattern
(identifier))
Expand All @@ -472,3 +469,26 @@ match x,:
(assignment
(identifier)
(integer)))))))

================================================================================
Multiple match patterns
================================================================================

match ..., ...:
case a, b:
return locals()

--------------------------------------------------------------------------------

(module
(match_statement
(ellipsis)
(ellipsis)
(case_clause
(identifier)
(identifier)
(block
(return_statement
(call
(identifier)
(argument_list)))))))

0 comments on commit 0881390

Please sign in to comment.