Hi Andy,
When I started using checkpatch I was confused by the following WARN message:
no space between function name and open parenthesis
I thought the problem was that a space was missing while the truth is the opposite.
How about the following patch?
--- checkpatch.pl.old 2008-01-04 13:37:51.000000000 +0100
+++ checkpatch.pl 2008-01-04 13:37:24.000000000 +0100
@@ -1117,7 +1117,7 @@
while ($line =~ /($Ident)\s+\(/g) {
if ($1 !~ /^(?:if|for|while|switch|return|volatile|__volatile__|__attribute__|format|__extension__|Copyright|case)$/ &&
$line !~ /$Type\s+\(/ && $line !~ /^.\#\s*define\b/) {
- WARN("no space between function name and open parenthesis '('\n" . $herecurr);
+ WARN("don't put a space between function name and open parenthesis '('\n" . $herecurr);
}
}
# Check operator spacing.
On Mon, Jan 14, 2008 at 11:29:13PM +0100, Paolo Ciarrocchi wrote:
> Hi Andy,
> When I started using checkpatch I was confused by the following WARN message:
>
> no space between function name and open parenthesis
>
> I thought the problem was that a space was missing while the truth is the opposite.
>
> How about the following patch?
I can see how that language would be confusing. Your patch makes the
english clearer, but somehow seems clumsy. There must be a better way
to say this. I will think on it and see what I can come up with.
-apw
On Jan 28, 2008 3:56 PM, Andy Whitcroft <[email protected]> wrote:
> On Mon, Jan 14, 2008 at 11:29:13PM +0100, Paolo Ciarrocchi wrote:
> > Hi Andy,
> > When I started using checkpatch I was confused by the following WARN message:
> >
> > no space between function name and open parenthesis
> >
> > I thought the problem was that a space was missing while the truth is the opposite.
> >
> > How about the following patch?
>
> I can see how that language would be confusing. Your patch makes the
> english clearer, but somehow seems clumsy. There must be a better way
> to say this. I will think on it and see what I can come up with.
Fair enought, I'm not English mother tongue and I'm sure you can come
up with a better
sentence :-)
BTW, is there a public repo I can track to look at all the new patches?
Thanks.
Ciao,
--
Paolo
http://paolo.ciarrocchi.googlepages.com/
On Mon, Jan 28, 2008 at 4:13 PM, Paolo Ciarrocchi
<[email protected]> wrote:
>
> On Jan 28, 2008 3:56 PM, Andy Whitcroft <[email protected]> wrote:
> > On Mon, Jan 14, 2008 at 11:29:13PM +0100, Paolo Ciarrocchi wrote:
> > > Hi Andy,
> > > When I started using checkpatch I was confused by the following WARN message:
> > >
> > > no space between function name and open parenthesis
> > >
> > > I thought the problem was that a space was missing while the truth is the opposite.
> > >
> > > How about the following patch?
> >
> > I can see how that language would be confusing. Your patch makes the
> > english clearer, but somehow seems clumsy. There must be a better way
> > to say this. I will think on it and see what I can come up with.
>
> Fair enought, I'm not English mother tongue and I'm sure you can come
> up with a better
> sentence :-)
AFAICS the problem is still present.
Ciao,
--
Paolo
http://paolo.ciarrocchi.googlepages.com/
On Feb. 23, 2008, 5:38 -0800, "Paolo Ciarrocchi" <[email protected]> wrote:
> On Mon, Jan 28, 2008 at 4:13 PM, Paolo Ciarrocchi
> <[email protected]> wrote:
>> On Jan 28, 2008 3:56 PM, Andy Whitcroft <[email protected]> wrote:
>> > On Mon, Jan 14, 2008 at 11:29:13PM +0100, Paolo Ciarrocchi wrote:
>> > > Hi Andy,
>> > > When I started using checkpatch I was confused by the following WARN message:
>> > >
>> > > no space between function name and open parenthesis
>> > >
>> > > I thought the problem was that a space was missing while the truth is the opposite.
>> > >
>> > > How about the following patch?
>> >
>> > I can see how that language would be confusing. Your patch makes the
>> > english clearer, but somehow seems clumsy. There must be a better way
>> > to say this. I will think on it and see what I can come up with.
>>
>> Fair enought, I'm not English mother tongue and I'm sure you can come
>> up with a better
>> sentence :-)
>
> AFAICS the problem is still present.
>
> Ciao,
How about:
- WARN("no space between function name and open parenthesis '('\n" . $herecurr);
+ WARN("there should be no space between function name and open parenthesis '('\n" . $herecurr);
The original phrasing can be interpreted like "there is no space between ..." and the correct
interpretation should be "there should be no space between ..."
Benny
On Sun, Feb 24, 2008 at 4:18 PM, Benny Halevy <[email protected]> wrote:
[...]
> How about:
> - WARN("no space between function name and open parenthesis '('\n" . $herecurr);
> + WARN("there should be no space between function name and open parenthesis '('\n" . $herecurr);
I originally suggested:
+ WARN("don't put a space between
function name and open parenthesis '('\n" . $herecurr);
but I really prefer your version.
> The original phrasing can be interpreted like "there is no space between ..." and the correct
> interpretation should be "there should be no space between ..."
Indeed.
Ciao,
--
Paolo
http://paolo.ciarrocchi.googlepages.com/
On Sun, Feb 24, 2008 at 07:14:13PM +0100, Paolo Ciarrocchi wrote:
> On Sun, Feb 24, 2008 at 4:18 PM, Benny Halevy <[email protected]> wrote:
> [...]
> > How about:
> > - WARN("no space between function name and open parenthesis '('\n" . $herecurr);
> > + WARN("there should be no space between function name and open parenthesis '('\n" . $herecurr);
>
> I originally suggested:
> + WARN("don't put a space between
> function name and open parenthesis '('\n" . $herecurr);
> but I really prefer your version.
>
> > The original phrasing can be interpreted like "there is no space between ..." and the correct
> > interpretation should be "there should be no space between ..."
>
> Indeed.
As we want the messages to be as short as possible, I am leaning towards
standardising on:
spaces prohibited <where>
spaces required <where>
-apw
On Feb. 24, 2008, 19:29 -0800, Andy Whitcroft <[email protected]> wrote:
> On Sun, Feb 24, 2008 at 07:14:13PM +0100, Paolo Ciarrocchi wrote:
>> On Sun, Feb 24, 2008 at 4:18 PM, Benny Halevy <[email protected]> wrote:
>> [...]
>>> How about:
>>> - WARN("no space between function name and open parenthesis '('\n" . $herecurr);
>>> + WARN("there should be no space between function name and open parenthesis '('\n" . $herecurr);
>> I originally suggested:
>> + WARN("don't put a space between
>> function name and open parenthesis '('\n" . $herecurr);
>> but I really prefer your version.
>>
>>> The original phrasing can be interpreted like "there is no space between ..." and the correct
>>> interpretation should be "there should be no space between ..."
>> Indeed.
>
> As we want the messages to be as short as possible, I am leaning towards
> standardising on:
>
> spaces prohibited <where>
> spaces required <where>
Sounds good to me.
Benny
>
> -apw
On 2/25/08, Andy Whitcroft
> As we want the messages to be as short as possible, I am leaning towards
> standardising on:
>
> spaces prohibited <where>
> spaces required <where>
>
in that case i would prefer:
space not required <where>
space required <where>
ciao,
--
Paolo
http://paolo.ciarrocchi.googlepages.com/
On Mon, Feb 25, 2008 at 10:21:01AM +0330, Paolo Ciarrocchi wrote:
> On 2/25/08, Andy Whitcroft
> > As we want the messages to be as short as possible, I am leaning towards
> > standardising on:
> >
> > spaces prohibited <where>
> > spaces required <where>
> >
> in that case i would prefer:
> space not required <where>
> space required <where>
"not required" implies that you don't have to have the space, but you
can can have it if you want. So I don't think thats quite right either.
-apw