Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Developing U++ » U++ Developers corner » is there U++ coding style reference?
Re: is there U++ coding style reference? [message #27788 is a reply to message #27627] Tue, 03 August 2010 13:05 Go to previous messageGo to previous message
mr_ped is currently offline  mr_ped
Messages: 825
Registered: November 2005
Location: Czech Republic - Praha
Experienced Contributor
I prefer the second option, because I pair the "}" with "if" and that's more interesting for me than pairing it with "{". But I can see this is matter of personal taste. (also I would write "if ( a == 123 ) {" (notice the spaces) to fully satisfy my taste Smile )

And assigning 123 to a in comparision without additional comment about intentionally doing so is not nice Wink (I write in such cases code this way to make my intention obvious: "if ( (a = 123) != 0 ) {", otherwise I consider it typo bug and fix it to "==")
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: using Ctrl::Add; required for templates / overloaded virtual functions
Next Topic: dll instead of exe
Goto Forum:
  


Current Time: Wed Jun 05 13:56:55 CEST 2024

Total time taken to generate the page: 0.02225 seconds