|
|
RetroX
|
|
Reply #17 Posted on: July 24, 2010, 09:33:59 am |
|
|
Master of all things Linux
Location: US Joined: Apr 2008
Posts: 1055
|
The braces are aligned.
if() { } vs. if() { } Symmetry.
|
|
|
Logged
|
My Box: Phenom II 3.4GHz X4 | ASUS ATI RadeonHD 5770, 1GB GDDR5 RAM | 1x4GB DDR3 SRAM | Arch Linux, x86_64 (Cube) / Windows 7 x64 (Blob)Why do all the pro-Microsoft people have troll avatars?
|
|
|
|
|
|
score_under
|
|
Reply #21 Posted on: July 24, 2010, 06:44:01 pm |
|
|
Joined: Aug 2008
Posts: 308
|
I'm trying to save vertical space because the IDEs I use don't have good ways of saving vertical space for me This is part of the reason I use Notepad2 for coding. You can also zoom out if things get bad. And then of course... some monitors can rotate, if the worst comes to the worst
|
|
|
Logged
|
|
|
|
|
Josh @ Dreamland
|
|
Reply #23 Posted on: July 25, 2010, 12:07:14 am |
|
|
Prince of all Goldfish
Location: Pittsburgh, PA, USA Joined: Feb 2008
Posts: 2950
|
I myself can't stand when you have snippets like this:
if (something) { something_minuscule(); continue; } So, of course, I never put one-liners in braces
if (something) something_minor(); Most people don't. And I do my very best to cram things into one line, even if they end up getting pretty ugly themselves...
something ? something_unremarkable() : void(); Operator, is nice, too...
if (something) a++, b++, c++, d=e=f; And then there's those times I just totally ugly it up because continue and operator, don't agree.
if (something) { something_tedious(); continue; } And if I've got two things that really need done, I group them like Ism does.
if (something) { thing1(); thing2(); } I'm not afraid to put a continue; or the like after thing2(), either.
But when I'm navigating code flow, Ism's method makes my skin crawl, and I hate the rest of your proposals, too. Of course, that's just my opinion. It's one thing to waste space, it's another to cloud structure.
|
|
« Last Edit: July 25, 2010, 12:12:41 am by Josh @ Dreamland »
|
Logged
|
"That is the single most cryptic piece of code I have ever seen." -Master PobbleWobble "I disapprove of what you say, but I will defend to the death your right to say it." -Evelyn Beatrice Hall, Friends of Voltaire
|
|
|
|
Josh @ Dreamland
|
|
Reply #25 Posted on: July 25, 2010, 12:21:59 pm |
|
|
Prince of all Goldfish
Location: Pittsburgh, PA, USA Joined: Feb 2008
Posts: 2950
|
As usual.
|
|
|
Logged
|
"That is the single most cryptic piece of code I have ever seen." -Master PobbleWobble "I disapprove of what you say, but I will defend to the death your right to say it." -Evelyn Beatrice Hall, Friends of Voltaire
|
|
|
|