This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH 2/2] PR c/68187: fix overzealous -Wmisleading-indentation (comment #1)
- From: Marek Polacek <polacek at redhat dot com>
- To: Bernd Schmidt <bschmidt at redhat dot com>
- Cc: Patrick Palka <patrick at parcs dot ath dot cx>, David Malcolm <dmalcolm at redhat dot com>, GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Fri, 4 Mar 2016 14:05:41 +0100
- Subject: Re: [PATCH 2/2] PR c/68187: fix overzealous -Wmisleading-indentation (comment #1)
- Authentication-results: sourceware.org; auth=none
- References: <1457018483-26829-1-git-send-email-dmalcolm at redhat dot com> <1457018483-26829-2-git-send-email-dmalcolm at redhat dot com> <CA+C-WL9w-4EUDfDUxY4RZ8Tvm5+oOiEdRk8sA0kEWCQf-xavEg at mail dot gmail dot com> <56D98540 dot 30702 at redhat dot com>
On Fri, Mar 04, 2016 at 01:53:20PM +0100, Bernd Schmidt wrote:
> On 03/03/2016 06:15 PM, Patrick Palka wrote:
> >Cool, this also fixes the false-positives seen in bdwgc, whose coding
> >style suggests indenting things inside an #ifdef as if it were an
> >if(), e.g.:
> >
> > if (a)
> > foo ();
> ># ifndef A
> > bar ();
> ># endif
> > ...
>
> Once again I find myself thinking this is not a false positive, but terrible
> code we should warn for.
I agree. It seems entirely sane to warn here.
Marek