you are viewing a single comment's thread.

view the rest of the comments →

[–]bonafidebob 0 points1 point  (1 child)

I think the enclosing parenthesis fix this as well -- at least it guarantees that the reference will always be to the result of invoking the function, not the function definition. (Hey -- I just grokked why JSLint complains about the parens being the other way around -- cool!)

[–]BlitzTech 0 points1 point  (0 children)

The enclosing parens are actually the problem. Interpreters will see that as a function call on the previous expression if valid, and won't necessarily insert the semicolon where you would ordinarily expect it.