Skip to content

Commit 241c44d

Browse files
author
Branislav Zahradník
committed
[parser] Extract for-over cursor declarations into clause_for_cursor
Extract multiple ways how to declare cursor variable(s) of for-over loop into dedicated non-terminal allowing to merge `for-over` branches. Merged for-over branches of: - `for $scalar (...)` - `for my $scalar (...)` - `for my ($foo, $bar) (...)` - `for \ $scalar (...)` - `for my \ $scalar (..)` Branch `for ()` must still remain as far as LALR(1) grammar will run into shift/reduce conflict with `for (;;)` - there will be two possible paths between `KW_FOR` and `(`: - `KW_FOR remember '('` - from `for (;;)` branch - `KW_FOR remember clause_for_over_cursor '(` - from `for ()` (using default cursor)
1 parent 41d8528 commit 241c44d

File tree

4 files changed

+1592
-1654
lines changed

4 files changed

+1592
-1654
lines changed

0 commit comments

Comments
 (0)