Optional braces

Jonathan M Davis jmdavisProg at gmx.com
Sun Aug 21 13:08:19 PDT 2011


On Sunday, August 21, 2011 12:47:22 Nick Sabalausky wrote:
> "Andrei Alexandrescu" <SeeWebsiteForEmail at erdani.org> wrote in message
> news:j2luh6$23bb$1 at digitalmars.com...
> 
> > One thing I'd subjectively like is to require braces on both branches of
> > if/else if at least one has braces.
> 
> Yuck! I'd really hate that.

As would I. I pretty much only use braces with a single-statement if statement 
if either the condition or the statement doesn't fit on one line. I consider 
the braces to be wasteful and unnecessary otherwise. But everyone has different 
ideas about what they prefer in formatting.

- Jonathan M Davis


More information about the Digitalmars-d mailing list