bug-bison
[Top][All Lists]
Advanced

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

Re: in manual of bison 1.35 - small bug


From: Paul Eggert
Subject: Re: in manual of bison 1.35 - small bug
Date: Fri, 29 Nov 2002 23:47:39 -0800 (PST)

> Date: Fri, 29 Nov 2002 13:27:26 +0100
> From: address@hidden
> 
> i get:
> 
> polish.y:71: warning: type mismatch with previous implicit declaration
> /usr/share/bison/bison.simple:924: warning: previous implicit declaration of 
> `yyerror'
> polish.y:71: warning: `yyerror' was previously implicitly declared to return 
> `int'

That is because your parser calls yyerror before defining or declaring it.
You need to put a forward declaration in your prologue, e.g.:

%{
  void yyerror (char const *);
%}

I have added some commentary to the Bison manual about this subject.
See the patch in
<http://mail.gnu.org/pipermail/bison-patches/2002-November/001416.html>.




reply via email to

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