It does make it a little hard to understand how the parser/ast_builder works.
But the rest seems easy enough to understand.
This is a hand-written parser for the shell itself (portable shell parsing portable shell):
https://gist.github.com/alganet/23df53c567b8a0bf959ecbc7b689...
It's an incomplete idea from around a year ago. The approach taken here (aliases as macro-like evals, AST generation using shell variables) became the backbone for the BNF parser generator.
This one is much simpler to understand. Simpler grammars tend to produce parser code that looks more like this one.
> It does make it a little hard to understand
Or much easier to backdoor...