Pattern matches one type of paren but not another

2023-05-28 Thread Maury Markowitz
Following, sort of, some advice I received earlier I modified my bison by adding this: open_bracket: '(' | '['; close_bracket: ')' | ']’; And then modified the original code thus: variable: VARIABLE_NAME { variable_t *new = malloc(sizeof(*new)); new->name = $1; new->subscripts

Re: Pattern matches one type of paren but not another

2023-05-28 Thread Hans Åberg
> On 28 May 2023, at 20:12, Maury Markowitz wrote: > > Following, sort of, some advice I received earlier I modified my bison by > adding this: > > open_bracket: > '(' | '['; > close_bracket: > ')' | ']’; You probably do not want to exchange delimiter types, as in "(…]" and "[…)". > And the