[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date: Mon, 15 Feb 2016 16:56:29 -0800
From: Joe Perches <joe@...ches.com>
To: Oleg Drokin <green@...uxhacker.ru>,
Andy Whitcroft <apw@...onical.com>
Cc: LKML <linux-kernel@...r.kernel.org>
Subject: Re: checkpatch falsepositives in Lustre code
On Mon, 2016-02-15 at 18:49 -0500, Oleg Drokin wrote:
> Hello!
>
>
> As I am going over Lustre to clean up the code style, I noticed this bunch below.
>
> Those all are function definitions, though I guess it might have been foiled by
> return type on the previous line?
> Now sure if anything could be done about this.
>
> Thanks.
>
> ERROR: that open brace { should be on the previous line
> #2098: FILE: drivers/staging/lustre/lustre/libcfs/hash.c:1358:
> +cfs_ash_for_each_enter(struct cfs_hash *hs)
> +{
[etc...]
Yeah, that's a defect of some type.
I'm not sure if it's really possible to handle it well though.
Maybe there could be a test added for something like
"^[\+ ](?:$Declare\s*|DeclareMisordered\s*)?\$Ident\("
to find what looks like function declarations in the
first column to avoid some of these false positives.
Andy?
Powered by blists - more mailing lists