Brendan Eich wrote:
Dmitry Soshnikov wrote:var FOO = 42; function bar(x, y = FOO + z) { var z = 10; } // Error .. ?Translating to JS as it is: var FOO = 42; function bar(x, y) { if (y === void 0) y = FOO + z; var z = 10;}
Another benefit of the simple semantics: existing JITs can optimize easily, no new semantics to special-case. This is not a dominant concern but it is a selling point from my experience dealing with (and playing one on TV ;-)) implementors.
/be _______________________________________________ es-discuss mailing list [email protected] https://mail.mozilla.org/listinfo/es-discuss

