public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "J. Bruce Fields" <bfields@fieldses.org>
To: Benny Halevy <bhalevy@panasas.com>
Cc: James Courtier-Dutton <James@superbug.co.uk>,
	Xavier Bestel <xavier.bestel@free.fr>,
	lkml <linux-kernel@vger.kernel.org>
Subject: Re: Coding Style: indenting with tabs vs. spaces
Date: Mon, 12 Nov 2007 10:38:06 -0500	[thread overview]
Message-ID: <20071112153806.GA27855@fieldses.org> (raw)
In-Reply-To: <47380B14.3010604@panasas.com>

On Mon, Nov 12, 2007 at 10:13:08AM +0200, Benny Halevy wrote:
> checkpatch allows to indent with any number of tabs and up to 7 spaces.
> This is consistent with Documentation/CodingStyle and therefore can be
> considered "correct".  However, forcing everybody to the same tab expansion
> setup is too limiting, especially when working in several environments
> at the same time where some of them may not be the linux kernel.
> 
> Using only spaces as DervishD suggested works around that using brute force
> by forcing the user to the author's preference which is legitimate but
> may not be the most productive way.
> 
> I think that my proposal of using tabs as logical indents only (as Xav put it)
> and spaces for decorative alignment provides the best of both worlds.
> One can expand the tabs to any number of spaces as one likes and then
> the trailing spaces will work on any editor setup as long as you use
> fixed-width font.  That's not considered "correct" as per checkpatch but
> works much better for me.

The tabs-for-indent, spaces-for-alignment policy been proposed before;
this:

	http://marc.info/?t=119251728100004&r=1&w=2

was only on the git mailing list, but we could probably dig up similar
discussions on lkml with some more work.

Speaking as someone who doesn't care, but doesn't see it as a
particularly interesting discussion, either....

--b.

  reply	other threads:[~2007-11-12 15:38 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-11-08 10:36 Coding Style: indenting with tabs vs. spaces Benny Halevy
2007-11-08 15:58 ` Chris Snook
2007-11-12  8:17   ` Benny Halevy
2007-11-10 12:04 ` DervishD
2007-11-10 12:27   ` Xavier Bestel
2007-11-10 16:50     ` DervishD
2007-11-11  9:23       ` James Courtier-Dutton
2007-11-12  8:13         ` Benny Halevy
2007-11-12 15:38           ` J. Bruce Fields [this message]
2007-11-12 16:30           ` DervishD
2007-11-11  8:57     ` Benny Halevy

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20071112153806.GA27855@fieldses.org \
    --to=bfields@fieldses.org \
    --cc=James@superbug.co.uk \
    --cc=bhalevy@panasas.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=xavier.bestel@free.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox