diff options
Diffstat (limited to 'Grammar/python.gram')
-rw-r--r-- | Grammar/python.gram | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Grammar/python.gram b/Grammar/python.gram index cbd4bc0..8e49490 100644 --- a/Grammar/python.gram +++ b/Grammar/python.gram @@ -40,6 +40,10 @@ type_expressions[asdl_seq*]: _PyPegen_seq_append_to_end(p, CHECK(_PyPegen_seq_append_to_end(p, a, b)), c) } | a=','.expression+ ',' '*' b=expression { _PyPegen_seq_append_to_end(p, a, b) } | a=','.expression+ ',' '**' b=expression { _PyPegen_seq_append_to_end(p, a, b) } + | '*' a=expression ',' '**' b=expression { + _PyPegen_seq_append_to_end(p, CHECK(_PyPegen_singleton_seq(p, a)), b) } + | '*' a=expression { _PyPegen_singleton_seq(p, a) } + | '**' a=expression { _PyPegen_singleton_seq(p, a) } | ','.expression+ statements[asdl_seq*]: a=statement+ { _PyPegen_seq_flatten(p, a) } |