Skip to content

Instantly share code, notes, and snippets.

@lgolubyev
Created May 24, 2022 12:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lgolubyev/9f4dd9a54170a56c67a540c86c2b2d6b to your computer and use it in GitHub Desktop.
Save lgolubyev/9f4dd9a54170a56c67a540c86c2b2d6b to your computer and use it in GitHub Desktop.
positional_pattern
: type? positional_pattern_clause length_pattern_clause? property_or_list_pattern_clause? simple_designation?
;
property_or_list_pattern_clause
: list_pattern_clause
| property_pattern_clause
;
property_pattern_clause
: '{' (subpattern (',' subpattern)* ','?)? '}'
;
list_pattern_clause
: '{' pattern (',' pattern)* ','? '}'
;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment