On 11/25/14, 2:48 PM, Allen Wirfs-Brock wrote:
It would be trivial to change the ES spec. to allow for the script this binding 
and global object to be set to independent value when a Realm is created.

I think we do want this, but that's not enough, unfortunately. Consider this script, executed at toplevel:

Object.defineProperty(Object.prototype, "foo", { get: function() { return this; } });
  var z = foo;

Is z a Window or a WindowProxy? In browsers, as far as I can tell, it's interoperably a WindowProxy. I put a testcase at http://web.mit.edu/bzbarsky/www/testcases/windowproxy/getter-on-proto-chain-root.html if people want to take a look. This wouldn't be covered by the "script this binding" bit, though, or would it?

-Boris
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to