From: Eli Zaretskii <eliz@gnu.org>
To: Andrey Smirnov <andrew.smirnov@gmail.com>
Cc: mark.kettenis@xs4all.nl, gdb-patches@sourceware.org
Subject: Re: [PATCH 18/348] Fix -Wsahdow warnings
Date: Thu, 24 Nov 2011 11:36:00 -0000 [thread overview]
Message-ID: <E1RTXal-0000ie-0n@fencepost.gnu.org> (raw)
In-Reply-To: <CAHQ1cqHjSYQL75PS8xqEASXXnh5jzMGH+JX7ti_9SKZ+5UOtKA@mail.gmail.com> (message from Andrey Smirnov on Thu, 24 Nov 2011 10:16:14 +0600)
> Date: Thu, 24 Nov 2011 10:16:14 +0600
> From: Andrey Smirnov <andrew.smirnov@gmail.com>
> Cc: gdb-patches <gdb-patches@sourceware.org>
>
> > It seems a lot of the changes posted up until now are dealing with
> > that type of "conflict". Â I'd really like to see those dropped from
> > this set.
> >
>
> It is not a "conflict". It is a conflict.
I'm with Andrey on this one. Catching variables that clash with
well-known global identifiers, such as library functions, are about
the only good reason for using -Wsahdow; all the other kinds of
"shadowing" it flags are usually perfectly correct usage of C.
(I was actually bitten once by a mysterious bug caused by a variable
whose name was identical to an external symbol that came from a
library. I don't wish anybody to get into such a conundrum.)
next prev parent reply other threads:[~2011-11-24 11:36 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-22 13:01 Andrey Smirnov
2011-11-22 18:03 ` Tom Tromey
2011-11-23 16:36 ` Mark Kettenis
2011-11-23 16:41 ` Ulrich Weigand
2011-11-23 18:21 ` Pedro Alves
2011-11-23 18:42 ` Joel Brobecker
2011-11-23 20:24 ` Mark Kettenis
2011-11-24 4:16 ` Andrey Smirnov
2011-11-24 11:36 ` Eli Zaretskii [this message]
2011-11-24 22:01 ` Joel Brobecker
2011-11-25 0:48 ` Andrey Smirnov
2011-11-25 14:26 ` Joel Brobecker
2011-11-25 15:52 ` About adding -Wshadow option by default (was Re: [PATCH 18/348] Fix -Wsahdow warnings) Pierre Muller
2011-11-25 16:36 ` Mark Kettenis
2011-11-29 19:18 ` [PATCH 18/348] Fix -Wsahdow warnings Tom Tromey
2011-11-30 3:48 ` Andrey Smirnov
2011-11-30 14:59 ` Tom Tromey
2011-12-01 4:15 ` Andrey Smirnov
2011-12-02 17:08 ` Tom Tromey
2011-11-25 12:03 ` Eli Zaretskii
2011-11-25 15:11 ` Mark Kettenis
2011-11-25 15:41 ` Eli Zaretskii
2011-11-25 16:26 ` Mark Kettenis
2011-11-25 18:20 ` Eli Zaretskii
2011-11-27 13:53 ` Mark Kettenis
2011-11-27 14:55 ` Pedro Alves
2011-11-27 16:35 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=E1RTXal-0000ie-0n@fencepost.gnu.org \
--to=eliz@gnu.org \
--cc=andrew.smirnov@gmail.com \
--cc=gdb-patches@sourceware.org \
--cc=mark.kettenis@xs4all.nl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox