On Sun, Mar 20, 2011 at 6:42 PM, <dhu...@hudes.org> wrote: > In terms of considering parser improvements or reimplementation, the first > step is to come up with a formal grammar for the language. > Preferably a Context Free Grammar (CFG) expressed in BNF or EBNF. > Once we have that we have options > - any of several Perl implementations including Parse::Yapp / Parse::Eyapp > - using bison to generate a parser in C and then gluing that in with XS or > even Inline::C
One could describe the Graph::Easy format grammar as a state machine, draw the state machine with Graph::Easy, then implement a parser from your diagram, with Graph::Easy::StateMachine<http://cpan.uwinnipeg.ca/htdocs/Graph-Easy-StateMachine/Graph/Easy/StateMachine.html> , for a future Graph::Easy that is self-hosting. How cool would that be or what? -- "This is not a 'bug'. Being documented, it is merely a 'restriction'." -- Intercal manual