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: pgpEZyZLWwJqm.pgp
Description: PGP signature

Reply via email to