This is the mail archive of the
mailing list for the GDB project.
Re: [PATCH 18/348] Fix -Wsahdow warnings
> Date: Sun, 27 Nov 2011 14:52:45 +0100 (CET)
> From: Mark Kettenis <email@example.com>
> CC: firstname.lastname@example.org, email@example.com,
> > Date: Fri, 25 Nov 2011 20:19:55 +0200
> > From: Eli Zaretskii <firstname.lastname@example.org>
> > > Date: Fri, 25 Nov 2011 17:26:04 +0100 (CET)
> > > From: Mark Kettenis <email@example.com>
> > > CC: firstname.lastname@example.org, email@example.com,
> > > firstname.lastname@example.org
> > >
> > > Since there is absolutely no problem with a local variable that has
> > > the same name as a library function, this is bad.
> > You are, in effect, saying that the wisdom of coding "down the middle
> > of a programming language" is wrong. We will have to disagree on
> > that, sorry. FWIW, I don't think a large project should live
> > dangerously just because some versions of some compiler will flag
> > these clashes even without -Wshadow.
> I think you're still missing my point.
No, I'm not. I understood perfectly what you are saying. We just
don't agree on whether having local variables by the name of an
external function is or isn't a practice to be avoided.