bison-patches
[Top][All Lists]
Advanced

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

Re: redeclarations: say "previous" not "first" declaration


From: Akim Demaille
Subject: Re: redeclarations: say "previous" not "first" declaration
Date: Sat, 8 Jul 2006 22:45:54 +0200

In the case of symbol redeclarations, Bison was reporting the location of the previous declaration but calling it the first declaration. Since it's an error, I don't see why it matters which it does as long as it uses the
right word.

Agreed.  But it seems more consistent to ignore the failures, and
therefore to stick to the first declaration.  I didn't know it had
this behavior, thanks for stating.  In other places (%type, %printer
etc.) it ignores following definitions and sticks to the first one.
We should stick to this scheme for consistency.  That's also what
the compilers I know do (gcc uses the word "previous" though :)

In the case of merger result type clashes, I changed it to match what
Bison was doing for symbol redeclarations.  I'm not sure why this is a
warning and not an error.

What would you like to have happen?

I'd say this is an error, and we should stick to definition #1.




reply via email to

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