From: Joe Perches <joe@perches.com>
To: Andy Whitcroft <apw@canonical.com>
Cc: Eric Nelson <eric.nelson@boundarydevices.com>,
akpm@linux-foundation.org, linux-kernel@vger.kernel.org,
linux-kbuild@vger.kernel.org
Subject: Re: [PATCH V3] checkpatch: check for whitespace before semicolon at EOL
Date: Mon, 28 May 2012 08:12:36 -0700 [thread overview]
Message-ID: <1338217956.2202.27.camel@joe2Laptop> (raw)
In-Reply-To: <20120528144259.GA5878@dm>
On Mon, 2012-05-28 at 15:42 +0100, Andy Whitcroft wrote:
> On Sun, May 27, 2012 at 05:00:46PM -0700, Eric Nelson wrote:
> > +# check for whitespace before a non-naked semicolon
> > + if ($line =~ /^\+.*\S\s+;/) {
> > + CHK("SPACING",
> > + "space prohibited before semicolon\n" . $herecurr);
> > + }
> > +
>
> Would this not also falsly trigger on 'for (foo = 10; foo; foo--) {' ?
No, it checks for a non-space, then requires whitespace before the semi
next prev parent reply other threads:[~2012-05-28 15:12 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-28 0:00 [PATCH V3] checkpatch: check for whitespace before semicolon at EOL Eric Nelson
2012-05-28 14:42 ` Andy Whitcroft
2012-05-28 15:12 ` Joe Perches [this message]
2012-05-28 15:15 ` Eric Nelson
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=1338217956.2202.27.camel@joe2Laptop \
--to=joe@perches.com \
--cc=akpm@linux-foundation.org \
--cc=apw@canonical.com \
--cc=eric.nelson@boundarydevices.com \
--cc=linux-kbuild@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/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