public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "Valdis Klētnieks" <valdis.kletnieks@vt.edu>
To: Joe Perches <joe@perches.com>
Cc: Gilad Ben-Yossef <gilad@benyossef.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] scripts/checkpatch.pl - fix *_NOTIFIER_HEAD handling
Date: Thu, 08 Aug 2019 02:08:15 -0400	[thread overview]
Message-ID: <56763.1565244495@turing-police> (raw)
In-Reply-To: <33e3b8748959b2f56b906b0bfd790df322f1ed3c.camel@perches.com>

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset=us-ascii, Size: 1003 bytes --]

On Wed, 07 Aug 2019 22:50:47 -0700, Joe Perches said:
> On Wed, 2019-08-07 at 21:36 -0400, Valdis Klētnieks wrote:

> >  				^.DEFINE_$Ident\(\Q$name\E\)|
> >  				^.DECLARE_$Ident\(\Q$name\E\)|
> >  				^.LIST_HEAD\(\Q$name\E\)|
> > -				^.{$Ident}_NOTIFIER_HEAD\(\Q$name\E\)|
> > +				^.${Ident}_NOTIFIER_HEAD\(\Q$name\E\)|
>
> Perhaps also better to convert all the '\Q$name\E' to '\s*\Q$name\E\s*'

Yes, but that would need to be a separate patch.  The question would be if we
consider 'DEFINE_foo( barbaz )' and similar with whitespace to be desirable
style or not.

[/usr/src/linux-next] grep '\\Q$name\\E' scripts/checkpatch.pl
				^.DEFINE_$Ident\(\Q$name\E\)|
				^.DECLARE_$Ident\(\Q$name\E\)|
				^.LIST_HEAD\(\Q$name\E\)|
				^.${Ident}_NOTIFIER_HEAD\(\Q$name\E\)|
				^.(?:$Storage\s+)?$Type\s*\(\s*\*\s*\Q$name\E\s*\)\s*\(|
				\b\Q$name\E(?:\s+$Attribute)*\s*(?:;|=|\[|\()

We already have the \s* in one place. Somebody else can decide if it should
be in the other 5 places or not. :)


[-- Attachment #2: Type: application/pgp-signature, Size: 832 bytes --]

  reply	other threads:[~2019-08-08  6:08 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-08  1:36 [PATCH] scripts/checkpatch.pl - fix *_NOTIFIER_HEAD handling Valdis Klētnieks
2019-08-08  5:50 ` Joe Perches
2019-08-08  6:08   ` Valdis Klētnieks [this message]
2019-08-08  6:17     ` Joe Perches
2019-08-08 12:45     ` Joe Perches

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=56763.1565244495@turing-police \
    --to=valdis.kletnieks@vt.edu \
    --cc=akpm@linux-foundation.org \
    --cc=gilad@benyossef.com \
    --cc=joe@perches.com \
    --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