Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 2 Mar 2006 20:58:42 +0200 (EET)
From:      Dmitry Pryanishnikov <dmitry@atlantis.dp.ua>
To:        Colin Percival <cperciva@freebsd.org>
Cc:        freebsd-current@freebsd.org, Robert Watson <rwatson@freebsd.org>
Subject:   Re: style(9) question
Message-ID:  <20060302204103.W46260@atlantis.atlantis.dp.ua>
In-Reply-To: <4407226D.3050901@freebsd.org>
References:  <20060302105229.P83093@atlantis.atlantis.dp.ua> <20060302163633.H77029@fledge.watson.org> <4407226D.3050901@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help

Hello!

On Thu, 2 Mar 2006, Colin Percival wrote:
>> I can't really think of a good reason
>> for return (foo) over return foo
>
> I'm not sure if this qualifies as a *good* reason, but
> writing "return (foo)" is more consistent with other
> keyword usage: "if (foo)", "for (foo)", "while (foo)",
> "switch (foo)".

  OTOH, our style doesn't recommend parentheses after "case" and type names; 
indeed,

int (i);
extern char (j);

case ('1'):

looks ugly despite being perfectly legal (at least from GCC's POV).


Sincerely, Dmitry
-- 
Atlantis ISP, System Administrator
e-mail:  dmitry@atlantis.dp.ua
nic-hdl: LYNX-RIPE



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