[asterisk-dev] Coding guidelines change (proposed)
Tzafrir Cohen
tzafrir.cohen at xorcom.com
Wed Feb 27 03:47:20 CST 2008
To repeat what I wrote:
On Tue, Feb 26, 2008 at 10:30:02PM +0200, Tzafrir Cohen wrote:
> On Tue, Feb 26, 2008 at 11:46:37AM -0600, Tilghman Lesher wrote:
> > I'd like to propose a change to the coding guidelines, and I'm airing it here
> > for specific feedback before we make this change. Currently, our standard
> > is that if you have a single statement following an if/for/while construct,
> > then we do not require parentheses around the single statement. While this
> > is legal C, it has caused a number of issues in the past, where another
> > statement was added at that indentation level, but without adding the
> > necessary braces.
> >
> > Are there any comments or objections before we implement this change?
>
> Current coding guidelines already require that a nested block will have
> braces. I wonder if those issues are related to bad indentation.
>
> Could you please point to one or two such cases?
Again, I'm not convinced. And nobody seems to bother providing
examples.
With the lengthy functions that currently exist in Asterisk, I rather
spare some lines. It looks simpler to read.
--
Tzafrir Cohen
icq#16849755 jabber:tzafrir.cohen at xorcom.com
+972-50-7952406 mailto:tzafrir.cohen at xorcom.com
http://www.xorcom.com iax:guest at local.xorcom.com/tzafrir
More information about the asterisk-dev
mailing list