Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 12 Mar 2010 11:10:52 -0800
From:      Julian Elischer <julian@elischer.org>
To:        Gary Jennejohn <gary.jennejohn@freenet.de>, Garrett Cooper <yanefbsd@gmail.com>, freebsd-current@freebsd.org
Subject:   Re: HEADS UP: COMPAT_IA32 renamed COMPAT_FREEBSD32
Message-ID:  <4B9A91BC.5050203@elischer.org>
In-Reply-To: <20100312110221.GC99813@acme.spoerlein.net>
References:  <4B991C00.3010809@intertainservices.com>	<790a9fff1003111714s58d9ee4bl6454d1d52bf705b8@mail.gmail.com>	<7d6fde3d1003111720g7dccf93w1f51db88758a5c4d@mail.gmail.com>	<20100311.192423.683591382013853731.imp@bsdimp.com>	<7d6fde3d1003112024o646afbf2w1ee4d81abae7e608@mail.gmail.com>	<20100312113625.1b2b017f@ernst.jennejohn.org> <20100312110221.GC99813@acme.spoerlein.net>

next in thread | previous in thread | raw e-mail | index | archive | help
Ulrich Spörlein wrote:
> On Fri, 12.03.2010 at 11:36:25 +0100, Gary Jennejohn wrote:
>> On Thu, 11 Mar 2010 20:24:57 -0800
>> Garrett Cooper <yanefbsd@gmail.com> wrote:
>>
>>>     I can haz PR review then? Here's an easy one :)...
>>>
>>> http://www.freebsd.org/cgi/query-pr.cgi?pr=144644
>>>
>> Looks OK to me except I don't like the
>> 	if (something) {
>> 		one-line-of-code();
>> 	}
>> constructs, but according to style(9) these are sort-of OK, viz
>>
>>      Closing and opening braces go on the same line as the else.  Braces that
>>      are not necessary may be left out.
>>                        ^^^^^^^^^^^^^^^
>>              if (test)
>>                      stmt;
>>              else if (bar) {
>>                      stmt;
>>                      stmt;
>>              } else
>>                      stmt;
>>
>> Saved by the "may."
> 
> True, but some folks (me included) really hate it, when different
> bracing is used *within* the same statement. The example above really is
> horrible. If one if/else-if clause needs braces, just brace them all. This
> loses no vertical space (the dangling else excluded) and some folks find
> it visually more pleasing/easier to read.
> 
> ... hence begins the bikeshedding.

"Green"

My personal preference is that if one clause requires braces,
they all get them so you would never see

"else {"

or

"} else"

just
"else"
or
"} else {"

I just find it helps keep everything correctly associated when reading.

> 
> Bye,
> Uli
> _______________________________________________
> freebsd-current@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-current
> To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org"




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4B9A91BC.5050203>