V0.8 fix for shift/reduce warning
This patch fixes the oversight in the previous patch and eliminated the shift/reduce warning. Apply it after the previous one.
This commit is contained in:
parent
83ee7e7988
commit
24b097ce89
17
parse.y
17
parse.y
|
|
@ -195,7 +195,7 @@ const static struct str_pair_t str_strength = { PGate::STRONG, PGate::STRONG };
|
|||
%type <expr> lavalue lpvalue
|
||||
%type <expr> delay_value delay_value_simple
|
||||
%type <exprs> delay1 delay3 delay3_opt
|
||||
%type <exprs> expression_list
|
||||
%type <exprs> expression_list expression_list_proper
|
||||
%type <exprs> assign assign_list
|
||||
|
||||
%type <exprs> range range_opt
|
||||
|
|
@ -929,6 +929,19 @@ expression_list
|
|||
}
|
||||
;
|
||||
|
||||
expression_list_proper
|
||||
: expression_list_proper ',' expression
|
||||
{ svector<PExpr*>*tmp = new svector<PExpr*>(*$1, $3);
|
||||
delete $1;
|
||||
$$ = tmp;
|
||||
}
|
||||
| expression
|
||||
{ svector<PExpr*>*tmp = new svector<PExpr*>(1);
|
||||
(*tmp)[0] = $1;
|
||||
$$ = tmp;
|
||||
}
|
||||
;
|
||||
|
||||
|
||||
expr_primary
|
||||
: number
|
||||
|
|
@ -2859,7 +2872,7 @@ statement
|
|||
delete $1;
|
||||
$$ = tmp;
|
||||
}
|
||||
| identifier '(' expression_list ')' ';'
|
||||
| identifier '(' expression_list_proper ')' ';'
|
||||
{ PCallTask*tmp = new PCallTask(*$1, *$3);
|
||||
tmp->set_file(@1.text);
|
||||
tmp->set_lineno(@1.first_line);
|
||||
|
|
|
|||
Loading…
Reference in New Issue