Re: bison c-parse.y:1115.19-20: $$ for the midrule at $4 of `structsp' has no declared type

Hans Aberg <haberg-news@telia.com>
Mon, 31 Oct 2011 20:49:28 +0100

          From comp.compilers

Related articles
bison c-parse.y:1115.19-20: $$ for the midrule at $4 of `structsp' has alessandro.basili@cern.ch (Alessandro Basili) (2011-10-31)
Re: bison c-parse.y:1115.19-20: $$ for the midrule at $4 of `structsp' haberg-news@telia.com (Hans Aberg) (2011-10-31)
Re: bison c-parse.y:1115.19-20: $$ for the midrule at $4 of `structsp' alessandro.basili@cern.ch (Alessandro Basili) (2011-11-02)
Re: bison c-parse.y:1115.19-20: $$ for the midrule at $4 of `structsp' gneuner2@comcast.net (George Neuner) (2011-11-02)
Re: bison c-parse.y:1115.19-20: $$ for the midrule at $4 of `structsp' gneuner2@comcast.net (George Neuner) (2011-11-04)
Re: bison c-parse.y:1115.19-20: $$ for the midrule at $4 of `structsp' alessandro.basili@cern.ch (Alessandro Basili) (2011-11-06)
Re: bison c-parse.y:1115.19-20: $$ for the midrule at $4 of `structsp' gah@ugcs.caltech.edu (glen herrmannsfeldt) (2011-11-07)
Re: bison c-parse.y:1115.19-20: $$ for the midrule at $4 of `structsp' gneuner2@comcast.net (George Neuner) (2011-11-07)
| List of all articles for this month |
From: Hans Aberg <haberg-news@telia.com>
Newsgroups: comp.compilers
Date: Mon, 31 Oct 2011 20:49:28 +0100
Organization: A noiseless patient Spider
References: 11-10-020
Keywords: bison
Posted-Date: 01 Nov 2011 16:00:24 EDT

On 2011/10/31 14:15, Alessandro Basili wrote:
> ... then I got the following message:
>
>> cd .; bison -v -d c-parse.y -o c-parse.c
>> c-parse.y: conflicts: 10 shift/reduce
>> c-parse.y: expected 8 shift/reduce conflicts
>
> I believe I'm in the dark here.


Usually, it means that one has to get hold of the authors of the
package, to find out what they had in mind:


One can deliberately leave shift/reduce conflicts, in which case Bison
will issue a warning, which can be suppressed %expect (see section 3.7.8
"Suppressing Conflict Warnings" in the Bison manual).


However, there is no way to be sure of that. Especially when it say
expected 8, and you got 10. But the compile and parser will run.


Hans
[I made the obvious patches and also got 10 rather than 8. I agree,
give this decade-old code a try and see if it works. -John]



Post a followup to this message

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