rules precedence in bison

Posted by arbiadr on Stack Overflow See other posts from Stack Overflow or by arbiadr
Published on 2010-03-02T10:18:16Z Indexed on 2010/03/14 7:05 UTC
Read the original article Hit count: 411

Filed under:
|
|

Hi

Here is the grammar rules:

ProcessExpression :  EventExpression "->" ProcessExpression

                    | ProcessName ;

Please can you tell me how can I tell to bison that the first rule has the highest precedence than the second one?

I have tried:

%nonassoc PROC

%right "->"

ProcessExpression :  EventExpression "->" ProcessExpression

                    | ProcessName % prec PROC;

But without any result. Thank you.

© Stack Overflow or respective owner

Related posts about bison

Related posts about rules