On Fri, 15 Dec 2006 22:59:12 +0100, Jan Engelhardt said:
> I take it that people will automatically DTRT for obscure cases like
> shown before. Well, and if they don't, hopefully some reviewer catches
> things like 3*i + l<<2.
So I hacked up a few very ugly 'find|egrep' to look for some cases of
On Dec 15 2006 21:27, Jörn Engel wrote:
>On Fri, 15 December 2006 22:01:10 +0100, Jan Engelhardt wrote:
>> On Dec 15 2006 15:56, Dmitry Torokhov wrote:
>> >
>> > outside the loop? If not then it is better to keep style consistent
>> > and not use condensed form in loops either.
>>
>> Don't you al
On Fri, 15 December 2006 22:01:10 +0100, Jan Engelhardt wrote:
> On Dec 15 2006 15:56, Dmitry Torokhov wrote:
> >
> > Would you write:
> >
> > i+=2;
> >
> > outside the loop? If not then it is better to keep style consistent
> > and not use condensed form in loops either.
>
> Don't you all ev
Jörn Engel wrote:
On Fri, 15 December 2006 21:10:14 +, Jörn Engel wrote:
Like so? I manually edited the patch and weakened a few of the space
rules, basically the ones in dispute in this thread.
Btw, this doesn't apply to my git tree at all (just pulled):
Hunk #1 FAILED at 35.
Hunk #2 FAI
On Fri, 15 December 2006 12:26:59 -0800, Randy Dunlap wrote:
>
> then send patches :)
Like so? I manually edited the patch and weakened a few of the space
rules, basically the ones in dispute in this thread.
From: Randy Dunlap <[EMAIL PROTECTED]>
Add some kernel coding style comments, mostly
On Fri, 15 December 2006 21:10:14 +, Jörn Engel wrote:
>
> Like so? I manually edited the patch and weakened a few of the space
> rules, basically the ones in dispute in this thread.
Btw, this doesn't apply to my git tree at all (just pulled):
Hunk #1 FAILED at 35.
Hunk #2 FAILED at 94.
Hunk
On Dec 15 2006 15:56, Dmitry Torokhov wrote:
> On 12/15/06, Jörn Engel <[EMAIL PROTECTED]> wrote:
>> On Fri, 15 December 2006 09:00:37 -0800, Randy Dunlap wrote:
>> > On Fri, 15 Dec 2006 16:07:17 +0100 Pavel Machek wrote:
>> >
>> > > Not in simple cases.
>> > >
>> > > 3*i + 2*j should be writen
On 12/15/06, Jörn Engel <[EMAIL PROTECTED]> wrote:
On Fri, 15 December 2006 09:00:37 -0800, Randy Dunlap wrote:
> On Fri, 15 Dec 2006 16:07:17 +0100 Pavel Machek wrote:
>
> > Not in simple cases.
> >
> > 3*i + 2*j should be writen like that. Not like
> > (3 * i) + (2 * j)
>
> I would just
On Friday, 15 December 2006 18:00, Randy Dunlap wrote:
> On Fri, 15 Dec 2006 16:07:17 +0100 Pavel Machek wrote:
>
> > On Fri 2006-12-15 08:52:22, Scott Preece wrote:
> > > On 12/15/06, Pavel Machek <[EMAIL PROTECTED]> wrote:
> > > >Hi!
> > > >
> > > >> Pavel Machek wrote:
> > > >> >> From: Randy D
On Fri, 15 Dec 2006 20:11:27 + Jörn Engel wrote:
> On Fri, 15 December 2006 09:00:37 -0800, Randy Dunlap wrote:
> > On Fri, 15 Dec 2006 16:07:17 +0100 Pavel Machek wrote:
> >
> > > Not in simple cases.
> > >
> > > 3*i + 2*j should be writen like that. Not like
> > > (3 * i) + (2 * j)
> >
On Fri, 15 December 2006 09:00:37 -0800, Randy Dunlap wrote:
> On Fri, 15 Dec 2006 16:07:17 +0100 Pavel Machek wrote:
>
> > Not in simple cases.
> >
> > 3*i + 2*j should be writen like that. Not like
> > (3 * i) + (2 * j)
>
> I would just write it as:
> 3 * i + 2 * j
So would I.
On Dec 15 2006 15:28, Stefan Richter wrote:
>Pavel Machek wrote:
>>> Pavel Machek wrote:
>>> >> From: Randy Dunlap <[EMAIL PROTECTED]>
>>> >> +Use one space around (on each side of) most binary and ternary
>>> >> operators,
>>> >> +such as any of these:
>>> >> += + - < > * / % |
On Fri, 15 Dec 2006 15:28:44 +0100 Stefan Richter wrote:
> Pavel Machek wrote:
> >> Pavel Machek wrote:
> >> >> From: Randy Dunlap <[EMAIL PROTECTED]>
> >> >> +Use one space around (on each side of) most binary and ternary
> >> >> operators,
> >> >> +such as any of these:
> >> >> + = + -
On Fri, 15 Dec 2006 16:07:17 +0100 Pavel Machek wrote:
> On Fri 2006-12-15 08:52:22, Scott Preece wrote:
> > On 12/15/06, Pavel Machek <[EMAIL PROTECTED]> wrote:
> > >Hi!
> > >
> > >> Pavel Machek wrote:
> > >> >> From: Randy Dunlap <[EMAIL PROTECTED]>
> > >> >> +Use one space around (on each side
On 12/15/06, Pavel Machek <[EMAIL PROTECTED]> wrote:
On Fri 2006-12-15 08:52:22, Scott Preece wrote
>
> I think the mistake illuminates why parentheses should be the rule. If
> you're thinking about using spacing to convey grouping, use
> parentheses instead...
Not in simple cases.
3*i
On Fri 2006-12-15 08:52:22, Scott Preece wrote:
> On 12/15/06, Pavel Machek <[EMAIL PROTECTED]> wrote:
> >Hi!
> >
> >> Pavel Machek wrote:
> >> >> From: Randy Dunlap <[EMAIL PROTECTED]>
> >> >> +Use one space around (on each side of) most binary and ternary
> >operators,
> >> >> +such as any of th
Scott Preece wrote:
> I think the mistake illuminates why parentheses should be the rule. If
> you're thinking about using spacing to convey grouping, use
> parentheses instead...
But then, we do reflect operator precedence by omitting whitespace
around . and ->, before [], or after unary & and *.
On 12/15/06, Pavel Machek <[EMAIL PROTECTED]> wrote:
Hi!
> Pavel Machek wrote:
> >> From: Randy Dunlap <[EMAIL PROTECTED]>
> >> +Use one space around (on each side of) most binary and ternary operators,
> >> +such as any of these:
> >> + = + - < > * / % | & ^ <= >= == != ? :
> >
Pavel Machek wrote:
>> Pavel Machek wrote:
>> >> From: Randy Dunlap <[EMAIL PROTECTED]>
>> >> +Use one space around (on each side of) most binary and ternary operators,
>> >> +such as any of these:
>> >> + = + - < > * / % | & ^ <= >= == != ? :
>> >
>> > Actually, this should not be
Hi!
> Pavel Machek wrote:
> >> From: Randy Dunlap <[EMAIL PROTECTED]>
> >> +Use one space around (on each side of) most binary and ternary operators,
> >> +such as any of these:
> >> + = + - < > * / % | & ^ <= >= == != ? :
> >
> > Actually, this should not be hard rule. We want t
Pavel Machek wrote:
>> From: Randy Dunlap <[EMAIL PROTECTED]>
>> +Use one space around (on each side of) most binary and ternary operators,
>> +such as any of these:
>> += + - < > * / % | & ^ <= >= == != ? :
>
> Actually, this should not be hard rule. We want to allow
>
>
Hi!
> From: Randy Dunlap <[EMAIL PROTECTED]>
>
> Add some kernel coding style comments, mostly pulled from emails
> by Andrew Morton, Jesper Juhl, and Randy Dunlap.
...
> Signed-off-by: Randy Dunlap <[EMAIL PROTECTED]>
> Acked-by: Jesper Juhl <[EMAIL PROTECTED]>
ACK.
> +Use one space around (on
On Dec 7 2006 16:55, Randy Dunlap wrote:
>Date: Thu, 7 Dec 2006 16:55:08 -0800
>From: Randy Dunlap <[EMAIL PROTECTED]>
>To: lkml
>Cc: [EMAIL PROTECTED], akpm <[EMAIL PROTECTED]>
>Subject: [PATCH/v2] CodingStyle updates
>
>From: Randy Dunlap <[EMAIL PROTECT
From: Randy Dunlap <[EMAIL PROTECTED]>
Add some kernel coding style comments, mostly pulled from emails
by Andrew Morton, Jesper Juhl, and Randy Dunlap.
- add paragraph on switch/case indentation (with fixes)
- add paragraph on multiple-assignments
- add more on Braces
- add section on Spaces; ad
24 matches
Mail list logo