I might do something like this:Don't align things vertically for the sake of aligning them, align them so that they're readable! The fragment above borders on obfuscation. There's a mind-numbing repetitive pattern on the right, and thismy $func = ($foo > 7) ? $bar && \&bar_mysub || $baz && \&baz_mysub : $bar && \&bar_other_mysub || $baz && \&baz_other_mysub; $func->($foo) if $func;
thing on the left. Yuch. I had to stop and really look at that fragment to get past the visual clutter.|| : ||
In reply to Re: Re: (jeffa) 2Re: (Ovid - Why I love nested If-Else blocks)
by dws
in thread Why I Hate Nested If-Else blocks
by jeffa
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |