[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Pine.LNX.4.64.0706152122050.32724@fbirervta.pbzchgretzou.qr>
Date: Fri, 15 Jun 2007 21:31:27 +0200 (CEST)
From: Jan Engelhardt <jengelh@...putergmbh.de>
To: "Kok, Auke" <auke-jan.h.kok@...el.com>
cc: Cyrill Gorcunov <gorcunov@...il.com>,
Randy Dunlap <randy.dunlap@...cle.com>,
Chris Friesen <cfriesen@...tel.com>,
dave young <hidave.darkstar@...il.com>,
Willy Tarreau <w@....eu>, LKML <linux-kernel@...r.kernel.org>
Subject: Re: coding style
On Jun 15 2007 12:21, Kok, Auke wrote:
> Cyrill Gorcunov wrote:
>> [Jan Engelhardt - Fri, Jun 15, 2007 at 09:10:49PM +0200]
>> | On Jun 15 2007 11:03, Randy Dunlap wrote:
>> | > >
>> | > > "use tabs for indents and spaces for alignment"
>> | > >
>> | > > If that means you need to use two dozen spaces, then so be it.
>> | >
>> | >I don't think that's what that rule means, but I didn't write it,
>> | >so I'm not absolutely sure about it.
>> | >
>> | >but we know that tab stops are every 8th character, not 4 :)
>> |
>> | Hardly.
>> |
>> Jan, as I see from CodingStyle:
>>
>> "Tabs are 8 characters, and thus indentations are also 8 characters."
>>
>> Actually it would be perfect to get strict rules also for math. and log.
>> operators being splitted on several lines:
>
> this doesn't say anything about alignment, which was his point :)
Well tabs should _never_ be assumed to be 8, and in this regard, as I
see it, CodingStyle has a bug. Tabs are there so that the user can set
their width according to _their_ taste, simply so that both sides,
from CodingStyle:
Tabs are 8 characters, and thus indentations are also 8
characters. There are heretic movements that try to make
indentations 4 (or even 2!) characters deep, and that is akin
to trying to define the value of PI to be 3.
Linus (did he wrote that part?) and the heretics both can have their fun
without impacting each other. If we wanted to force the user to have
exactly 8 screen blanks, we should use spaces throughout.
(And BTW, int pi = 3.141592 _is_ going to be 3 ;-) and floating point
is mostly an agreed no-go in kernel anyway, even if it's supported.)
Jan
--
-
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