yacc warning about useless rule

Jens Kallup <jkallup@web.de>
Mon, 13 Feb 2012 22:22:56 +0100

          From comp.compilers

Related articles
yacc warning about useless rule jkallup@web.de (Jens Kallup) (2012-02-13)
| List of all articles for this month |
From: Jens Kallup <jkallup@web.de>
Newsgroups: comp.compilers
Date: Mon, 13 Feb 2012 22:22:56 +0100
Organization: CNNTP
Keywords: yacc, question, comment
Posted-Date: 13 Feb 2012 19:41:18 EST

Hello there,


I get the following Warning:


conflicts: 7 shift/reduce
pcode.y:64.12-66.5: warning: rule useless in parser due to conflicts:
$@1: /* empty */




is this a error?
why is it display?
give it a glue?


thanks
Jens
[Yes, it's an error. It's telling you that your grammar can't be
turned into a LALR parser, and the parser it did generate will never
reduce that rule. Solution: find the conflicts and fix them. -John]


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.