On Fri, 28 Aug 2009, Eric Blake wrote: > According to Joel E. Denny on 8/28/2009 2:51 AM: > > The second one looks easy to fix, but I'm not actually seeing either of > > the warnings. What gcc and flex are you using? Here are mine: > > flex 2.5.35 > gcc 3.4.4
Thanks. I pushed the following to master and branch-2.5. I think it'll fix the named_ref shadowing warning you saw. For the warning you found on branch-2.4.2, the cause is not immediately obvious to me, and I'm not inclined to chase it down. As for the other warning, I don't see it from a newer gcc. In this case, we're also dealing with flex-generated code, which is not usually fun to work around. >From 2646cd540bfdd35f457e0e0a1bcc5f9b26a96849 Mon Sep 17 00:00:00 2001 From: Joel E. Denny <[email protected]> Date: Sat, 29 Aug 2009 16:25:58 -0400 Subject: [PATCH] Fix gcc 3.4.4 shadowing warning reported by Eric Blake. See <http://lists.gnu.org/archive/html/bison-patches/2009-08/msg00093.html>. * src/scan-code.h (code_props_rule_action_init): Rename named_ref arg to name so it doesn't shadow named_ref type. This makes it consistent with the function definition in scan-code.l anyway. --- ChangeLog | 10 ++++++++++ src/scan-code.h | 2 +- 2 files changed, 11 insertions(+), 1 deletions(-) diff --git a/ChangeLog b/ChangeLog index 4de30cf..3e6fd1b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,13 @@ +2009-08-29 Joel E. Denny <[email protected]> + + Fix gcc 3.4.4 shadowing warning reported by Eric Blake. + See + <http://lists.gnu.org/archive/html/bison-patches/2009-08/msg00093.html>. + * src/scan-code.h (code_props_rule_action_init): Rename + named_ref arg to name so it doesn't shadow named_ref type. This + makes it consistent with the function definition in scan-code.l + anyway. + 2009-08-28 Joel E. Denny <[email protected]> %define: accept unquoted values. diff --git a/src/scan-code.h b/src/scan-code.h index 11cf5d0..c98a54a 100644 --- a/src/scan-code.h +++ b/src/scan-code.h @@ -134,7 +134,7 @@ void code_props_symbol_action_init (code_props *self, char const *code, */ void code_props_rule_action_init (code_props *self, char const *code, location code_loc, struct symbol_list *rule, - named_ref *named_ref); + named_ref *name); /** * \pre -- 1.5.4.3
