Private symbols auto-unwrapping proxies (was: Security Demands Simplicity (was: Private Slots))

Herby Vojčík herby at mailbox.sk
Tue Jan 29 09:56:47 PST 2013



Brandon Benvie wrote:
> To elaborate, I've realized that my main disagreement with your position
> (really my care at all with the private discussion) is much better
> solved by introducing [[CallProperty]]. That is: Proxies currently

... and complicates object model. My main problem with [[CallProperty]] 
is the discrepancy between [[Get]] (used in [[Get]]+[[Call]]) and 
[[CallProperty]] (my assumption that by [[CallProperty]] you mean 
operation that replaces [[Get]]+[[Call]]).

I'd solve it otherwise. Let's say that foo.bar(baz) is split to _three_ 
operations: [[Get]]+[[OopBind]]+[[Call]], where [[OopBind]] resolves 
this. Then, proxies should only be able to trap [[OopBind]] (but it will 
still be the same combination, involving trappable [[Get]] at the 
beginning and ending with (direct) [[Call]]).

> handle |this| binding of method calls very poorly. I'm all for either
> removing private or making it *really* private, but Proxies are
> basically worthless in the private middleground which causes them to
> break half the time in ES6 code. But [[CallProperty]] fixes the issue in
> a way that seems acceptable to all parties.

Herby


More information about the es-discuss mailing list