lkml.org 
[lkml]   [2011]   [May]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] checkpatch: Suggest using min_t or max_t
From
Date
On Tue, 2011-05-24 at 16:35 -0700, Andrew Morton wrote:
> On Fri, 20 May 2011 13:24:48 -0700
> Joe Perches <joe@perches.com> wrote:
>
> > A common issue with min() or max() is using a cast on
> > one or both of the arguments when using min_t/max_t could
> > be better.
> >
> > Add cast detection to uses of min/max and suggest an
> > appropriate use of min_t or max_t instead.
>
> Causes this:
>
> akpm2:/usr/src/25> perl scripts/checkpatch.pl patches/drivers-gpio-vx855_gpioc-needs-slabh.patch
> Nested quantifiers in regex; marked by <-- HERE in m/(\((?:[^\(\)]++ <-- HERE |(?-1))*\))/ at scripts/checkpatch.pl line 271.

Something not making sense here.
I get no report when I try your patch.
(using checkpatch with the regex I sent)

Send the patch again?

$ perl --version

This is perl, v5.10.1 (*) built for i686-linux-gnu-thread-multi
(with 53 registered patches, see perl -V for more detail)

Copyright 1987-2009, Larry Wall

Perl may be copied only under the terms of either the Artistic License or the
GNU General Public License, which may be found in the Perl 5 source kit.

Complete documentation for Perl, including FAQ lists, should be found on
this system using "man perl" or "perldoc perl". If you have access to the
Internet, point your browser at http://www.perl.org/, the Perl Home Page.

$ ./scripts/checkpatch.pl gpio.mbox
total: 0 errors, 0 warnings, 7 lines checked

gpio.mbox has no obvious style problems and is ready for submission.



\
 
 \ /
  Last update: 2011-05-25 02:13    [W:0.075 / U:0.308 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site