Re: newbie: better approach for list processing with bison++?

2014-06-05 Thread Evan Lavelle
This is perhaps more canonical: param_list : /* nothing */ { $$ = new ParamListNode(); } | param_item_list{ $$ = $1; } ; param_item_list : param { $$ = new ParamListNode($1); } | param_item_list ',' param { $$ = $1->addChild($3); }

Re: newbie: better approach for list processing with bison++?

2014-06-05 Thread Hans Aberg
On 5 Jun 2014, at 02:46, Grant McKenzie wrote: > newbie alert... This is the list for Bison [1], which supports C++ - see the manual. 1. https://gnu.org/software/bison/ ___ help-bison@gnu.org https://lists.gnu.org/mailman/listinfo/help-bison

newbie: better approach for list processing with bison++?

2014-06-05 Thread Grant McKenzie
Hi, newbie alert - this is my first grammar so bare with me! opt_parameter_list: /* EMPTY */ { $$ = new IdentifierListNode( NULL, NULL ); } | parameter_list { $$ = $1; } parameter_list: IDENTIFIER {