This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH 1/4] -Wmisleading-indentation: don't warn in presence of entirely blank lines
- From: Patrick Palka <patrick at parcs dot ath dot cx>
- To: Mike Stump <mikestump at comcast dot net>
- Cc: David Malcolm <dmalcolm at redhat dot com>, GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Thu, 29 Oct 2015 13:56:02 -0400
- Subject: Re: [PATCH 1/4] -Wmisleading-indentation: don't warn in presence of entirely blank lines
- Authentication-results: sourceware.org; auth=none
- References: <1446137381-32748-1-git-send-email-dmalcolm at redhat dot com> <1446137381-32748-2-git-send-email-dmalcolm at redhat dot com> <CA+C-WL8jJ_LWMPSqLMFhfqg+Mpf+pzpLFT-Sbg-ZN7qa_9A9DA at mail dot gmail dot com> <CA+C-WL86Xf116PnCnF9CLBPeEaP-=xKjhCzveS-gxJyTmR7Ctw at mail dot gmail dot com> <F1AC80DE-5BEC-4BD5-AF0B-009942BCEED6 at comcast dot net>
On Thu, Oct 29, 2015 at 1:50 PM, Mike Stump <mikestump@comcast.net> wrote:
> On Oct 29, 2015, at 10:42 AM, Patrick Palka <patrick@parcs.ath.cx> wrote:
>> However we should definitely not warn on
>>
>> if (foo)
>> bar ();
>>
>> {
>> baz ();
>> }
>>
>> Since that is valid GNU-style code :)
>
> Iâll put it differently; no, that formatting is wrong.
>
Ah, okay. That simplifies things then. (I've seen that style used in
GCC and in GDB so I assumed it was valid GNU style since I couldn't
find a section in the style guide that explicitly stated how to indent
there.)