On Jun 25, 2005, at 20:38, Patrick R. Michaud wrote:

I've just checked in changes to PGE that enable it to support
grammars, as well as some more built-in rules...

These are totally awesome. On the plane today, I converted the Punie parser over to use the shiny new grammars. My one frustration so far is that subrule calls for a rule from a grammar always have to be fully specified, even if the subrule is in the same grammar. It makes for some verbose constructs:

    p6rule("1", "PunieGrammar", "term")
    p6rule("print \s* <PunieGrammar::expr>", "PunieGrammar", "gprint")
p6rule("<PunieGrammar::gprint> | <PunieGrammar::term>", "PunieGrammar", "expr")
    p6rule("<PunieGrammar::expr>;", "PunieGrammar", "line")

instead of:

    p6rule("1", "PunieGrammar", "term")
    p6rule("print \s* <expr>", "PunieGrammar", "gprint")
    p6rule("<gprint> | <term>", "PunieGrammar", "expr")
    p6rule("<expr>;", "PunieGrammar", "line")

Early days yet, so this is mainly saying "This is something I'm looking forward to."

Thanks, Patrick!
Allison

Reply via email to