View Single Post
  #44  
Old 10-12-2005, 02:55 PM
fnord_too fnord_too is offline
Senior Member
 
Join Date: May 2004
Location: Norfolk, VA
Posts: 672
Default Re: Pet peeve: optional comma

I prefer A, even though some claim it is wrong. I like A bacuase, in rare cases, B can lead to ambiguity and I am a nit. I also like having my opening brace on its own line, even though most IDEs and text put them on the line with the block definition.

(For the non coders,
<font class="small">Code:</font><hr /><pre>
public void useless() {
int x = 0;
}
</pre><hr />
is far infrerior to
<font class="small">Code:</font><hr /><pre>
public void useless()
{
int x = 0;
}
</pre><hr />

though
<font class="small">Code:</font><hr /><pre>
public void useless() {int x = 0;}
</pre><hr />

is ok by me.)
Reply With Quote