Re: style(9) question

From: FreeLSD <freelsd_at_rea.mbslab.kiae.ru>
Date: Thu, 2 Mar 2006 15:52:55 +0300
> 	Values in return statements should be enclosed in parentheses.
> 
> What's the rationale of this? From time to time I see small commits
> just changing "return foo;" -> "return (foo);". I think the first form
> is quite natural and not ambiguous. Shouldn't we remove this advise from 
> style(9)?
 Don't know about the exact reason for "return (foo);" grammar, but for such
small commits I can say, that there are another point in style(9):
-----
     Stylistic changes (including whitespace changes) are hard on the source
     repository and are to be avoided without good reason.  Code that is
     approximately FreeBSD KNF style compliant in the repository must not
     diverge from compliance.
-----
 So, such small commits are not very clever.

 By the way: I am also interested about the return (foo) rationale ;)
-- 
Yours, LSD

BOFH excuse #302:
microelectronic Riemannian curved-space fault in write-only file system
Received on Thu Mar 02 2006 - 11:52:58 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:53 UTC