Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 31 Mar 2009 14:08:45 +0200
From:      Polytropon <freebsd@edvax.de>
To:        William Gordon Rutherdale <will.rutherdale@utoronto.ca>
Cc:        Gary Kline <kline@thought.org>, FreeBSD Mailing List <freebsd-questions@freebsd.org>
Subject:   Re: Why??  (prog question)
Message-ID:  <20090331140845.a1ece3c0.freebsd@edvax.de>
In-Reply-To: <49D202F0.9010104@utoronto.ca>
References:  <20090331025726.GA10888@thought.org> <20090331112122.ae329221.freebsd@edvax.de> <49D202F0.9010104@utoronto.ca>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 31 Mar 2009 07:48:00 -0400, William Gordon Rutherdale <will.rutherdale@utoronto.ca> wrote:
> Tabbing is the worst form of indentation.  It is *much* better to use 
> spaces consistently.

may I ask what exactly you mean by "consistently"? I've seen
various opinions about how many spaces make up one indentation level,
beginning from 1, over 4, up to 10. Where's the consistency, or is
it defined on a per-programmer basis?

And why is this much better?

When I would compare both indentation forms, I'd say that tabbing
is the better form because
 + you can set your individually preferred tab with using the
   settings of your editor, be it 1, 4 or 8,
 + you can change the indentation while you're coding, e. g. when
   the indentation level makes the code exceed the right margin
   of your editor's window,
 + you need more keypressing to get through the indentation with
   the spaces, one keypress per space, while you only need one
   keypress per tab (which equals one indentation level),
 + per indentation level only 1 byte is needed (tab = ASCII 9), while
   spacing requires more bytes, one per space (space = ASCII 32),
 + while you can convert tabs into spaces, you cannot easily convert
   spaces back into tabs, and finally
 + even FreeBSD uses the tabbing style.

I'm aware that one can argue about where { is to be placed, but
I don't see any valid reason to use spaces for indentation instead
of tabs (which I would even call "standard").

It's a honest question: What are your arguments for using tabs?
Hint: "it is *much* better" doesn't count. :-)



// EDIT: added one further argument pro tab
/*


-- 
Polytropon
>From Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20090331140845.a1ece3c0.freebsd>