3 ms·
I tend to like it if the left-hand-side is overwhelmingly the default code-path, or to keep all assignments aligned (ones with caveats then stick out like a sor
by Groxx 15y ago
I tend to like it if the left-hand-side is overwhelmingly the default code-path, or to keep all assignments aligned (ones with caveats then stick out like a sore thumb).
How do you feel then about things like this?
variable = if something
val
else
another_val
end
(insert your personal indentation choice, of course)
- aaronblohowiak 15y agoThis does not cause any "backtracking" when tracing the code execution with the gray interpreter.
- Groxx 15y ago>'with the gray interpreter' sorry, ya lost me there. Are you referring to a language interpreter? In that case, which one? The only difference I can see for interpreters is that it necessitates parsing the entire line before acting, which all but the most highly-tuned (and designed for this purpose) interpreted-languages probably already do.
- deleted 15y ago[deleted]
- damncabbage 15y agoI'm guessing that he's referring to his brain.
- Groxx 15y agoAhahaha, of course, that makes sense. Thanks, I may have to wake up the hamster in mine :)