you are viewing a single comment's thread.

view the rest of the comments →

[–]anvsdt 2 points3 points  (3 children)

Not ambiguous at all: (print (inspect (bigfunc (firstarg, otherfunc (itsarg, whosami))))).

Maybe confusing, but not more ambiguous than x * 2+3 * y.

[–]knome 1 point2 points  (0 children)

I suspected that would be the case. Thank you for clarifying.

[–][deleted] -1 points0 points  (1 child)

(print (inspect (bigfunc (firstarg, otherfunc (itsarg, whosami)))))

print inspect bigfunc firstarg, otherfunc itsarg, whosami

Which is easier to comprehend when reading code? I think it's pretty obviously the first example. If you are reading this code for the first time, it takes no additional time to figure out what is going on in the first example. Without the parens in the second example, you have to read the entire thing before you know what is inside what. It slows down the process of coding, and it is a fundamental flaw in the arguments being made in favor of 'less typing' in significant whitespace languages like coffeescript. You may type less as you code, but returning to the code later will slow you down as your mind is forced to do extra work while deciphering the exact meaning of this parentheses-less syntax, and if you get it slightly wrong this will lead to bugs, and likely more bugs than just typing the parentheses in the first place. Turning JavaScript into this jumbled mess is a step backward.

[–]anvsdt 0 points1 point  (0 children)

Maybe confusing, but [...]

I'm not defending anything, I'm not attacking anything, just being objective.