Without the parameters and easier formatting, it would look like this:
a
: b a c
| a (c a | b c)
;
When a
's left recursive alternative is matched n times, it would just mean that (c a | b c)
will be matched n times, pre-pended with the terminating b a c
(the first alternative). That means that this rule will always start with b a c
, followed by zero or more occurrences of (c a | b c)
:
a
: b a c (c a | b c)*
;