help-bison
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Conflicts shift/reduction


From: Hans Aberg
Subject: Re: Conflicts shift/reduction
Date: Thu, 14 Apr 2005 01:15:37 +0200

At 21:16 +0200 2005/04/13, Eduardo Robles Elvira wrote:
This is the bison output:
lea.y: conflicts: 3 shift/reduce, 4 reduce/reduce
lea.y:475.11-476.57: warning: rule never reduced because of conflicts:
elif_statement_list: elif_statement

How can I solve it ?

The standard attempt to resolve shift/reduce conflicts, is to use the --verbose option, and in the .output file, in the afflicted state and rules, put precedences of the tokens right before and after the ".". As the Bison manual says, a reduce/reduce conflict may indicate a serious problem with the grammar. If you are sure the grammar is OK, you might try the %glr option.
--
  Hans Aberg




reply via email to

[Prev in Thread] Current Thread [Next in Thread]