Exponentiation operator precedence
Mark S. Miller
erights at google.com
Tue Aug 25 15:11:50 UTC 2015
I think we should drop the feature. Given the conflict between
* the history of ** in other languages,
* the general pattern that unary binds tighter than binary
any solution at this point will confuse many people. These confusions will
not result in a confusing static rejection but in runtime behavior that
*sometimes* violates expectations. I was all for adding ** to the language
when it did not have these problems. But it does. The minor convenience it
adds is not worth these costs. By contrast, no one is confused about the
parsing of calls to Math.pow.
When in doubt, leave it out.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the es-discuss