It would be nice to be able to define combinators for non-terminals, like writing <symbol> * for the Kleene star operator. Conceptually, this can be implemented as a new non-terminal, defined something like
<symbol> * -> # epsilon
<symbol> * -> <symbol> <symbol> *
However, we would need this definition once (and only once) for each non-terminal with which the * operator is used. For example, we would need another, similar definition if we tried to use <expression> * somewhere else in the program.
Currently this is impossible, because non-terminals must be symbols, and symbols cannot be created dynamically, so there is no way to implement an operator like * whose semantics include dynamically generating new non-terminals.
Depends on #7.
It would be nice to be able to define combinators for non-terminals, like writing
<symbol> *for the Kleene star operator. Conceptually, this can be implemented as a new non-terminal, defined something likeHowever, we would need this definition once (and only once) for each non-terminal with which the
*operator is used. For example, we would need another, similar definition if we tried to use<expression> *somewhere else in the program.Currently this is impossible, because non-terminals must be symbols, and symbols cannot be created dynamically, so there is no way to implement an operator like
*whose semantics include dynamically generating new non-terminals.Depends on #7.