All of lore.kernel.org
 help / color / mirror / Atom feed
From: mru@kth.se (Måns Rullgård)
To: linux-kernel@vger.kernel.org
Subject: Re: Lindent fixed to match reality
Date: Thu, 29 Jan 2004 21:52:12 +0100	[thread overview]
Message-ID: <yw1xn0861nr7.fsf@kth.se> (raw)
In-Reply-To: <20040129204250.GL16675@khan.acc.umu.se> (David Weinehall's message of "Thu, 29 Jan 2004 21:42:50 +0100")

David Weinehall <tao@acc.umu.se> writes:

> On Thu, Jan 29, 2004 at 09:35:03PM +0100, Måns Rullgård wrote:
>> David Weinehall <tao@acc.umu.se> writes:
>> 
>> >> b) (no -bs) "sizeof(foo)" rather than "sizeof (foo)"
>> >
>> > I can't really see the logic in this, though I know a lot of people do
>> > it.  I try to stay consistent, thus I do:
>> >
>> > if ()
>> > for ()
>> > case ()
>> > while ()
>> > sizeof ()
>> > typeof ()
>> >
>> > since they're all parts of the language, rather than
>> > functions/macros or invocations of such.
>> 
>> What I fail to see here is why that should make a difference regarding
>> whitespace before the parens.
>
> All I'm trying to say, is that we should be consistent; most code
> has:
>
> if (), for (), case (), while ()
>
> (and possibly sizeof foo, typeof foo)
>
> but
>
> sizeof(foo), typeof(foo)
>
> which is what I dislike (consistancy is good.)

Well, those have function-like semantics in that they have a value,
unlike an if statement.  That could possibly explain the difference.
I know perfectly well that sizeof is not a function, so don't bother
explaining that.

-- 
Måns Rullgård
mru@kth.se

  reply	other threads:[~2004-01-29 20:52 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-01-29 19:37 Lindent fixed to match reality Matt Mackall
2004-01-29 19:44 ` Linus Torvalds
2004-01-29 20:00   ` Matt Mackall
2004-01-29 20:15 ` David Weinehall
2004-01-29 20:35   ` Måns Rullgård
2004-01-29 20:42     ` David Weinehall
2004-01-29 20:52       ` Måns Rullgård [this message]
2004-01-29 21:46   ` Matt Mackall
2004-01-29 22:37   ` Andries Brouwer
2004-01-29 22:54     ` David Weinehall
2004-01-29 23:17       ` Tim Hockin
2004-01-29 23:43         ` David Weinehall
2004-01-30 14:44           ` Theodore Ts'o
2004-01-30 17:49             ` David Weinehall
2004-01-30 21:08   ` Eric W. Biederman
2004-01-29 20:17 ` Roland Dreier
2004-01-29 20:37 ` Erik Hensema
2004-01-29 21:55   ` Krzysztof Halasa
2004-01-30 16:36     ` Linus Torvalds
2004-01-30 10:38   ` Jan-Benedict Glaw

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=yw1xn0861nr7.fsf@kth.se \
    --to=mru@kth.se \
    --cc=linux-kernel@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.