[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1332434013.1946.10.camel@joe2Laptop>
Date: Thu, 22 Mar 2012 09:33:33 -0700
From: Joe Perches <joe@...ches.com>
To: richard -rw- weinberger <richard.weinberger@...il.com>
Cc: Phil Carmody <ext-phil.2.carmody@...ia.com>, apw@...onical.com,
hpa@...or.com, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/1] checkpatch.pl: thou shalt not use () or (...) in
function declarations
On Thu, 2012-03-22 at 16:49 +0100, richard -rw- weinberger wrote:
> On Thu, Mar 22, 2012 at 4:27 PM, Phil Carmody
> <ext-phil.2.carmody@...ia.com> wrote:
> > After HPA's wonderful lkml post, referenced, it seems worth trying to
> > detect this robomatically.
>
> See:
> http://marc.info/?l=linux-kernel&m=133193918813599
But Phil's test is better because it also
tests for function declarations on multiple
lines like
type
foo(...)
if ($ctx =~ /((\b$Type\s+$Ident)\s*\(\s*(?:\.\.\.)?\s*\))/) {
The ERROR needs updating for a --ignore type though.
Something like this may be better.
ERROR("FUNCTION_NO_PROTOTYPE",
"Bad function definition - $1 should probably be $2(void)\n" .
herecurr);
And I think the screed funny once but not useful.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists