Catch-all proposal based on proxies
Tom Van Cutsem
tomvc at google.com
Thu Dec 10 15:22:12 PST 2009
On Thu, Dec 10, 2009 at 1:21 PM, Brendan Eich <brendan at mozilla.com> wrote:
> To avoid some "climbing meta ladder" issues, we purposely distinguish
>> between what we consider base-level operations, such as x.foo, and
>> meta-level operations, such as Object.getOwnProperty(x, 'foo'). We attempt
>> to be as fully transparent (leak free) as reasonably possible at
>> virtualizing base level operations. We attempt to be fully non-transparent
>> (leak like a firehose) to meta-level operations. Some of our classification
>> may seem weird: Object.prototype.toString() is meta-level. It can be used to
>> reveal that an object is a trapping proxy. Object.getOwnPropertyNames() is
>> meta-level. Object.keys() is base level.
> You're right, some of this is weird :-P. Any detailed rationale?
We don't have a solid rationale. We summarized the interactions between
these methods and proxies in a separate section:
The split between "base" and "meta" methods is certainly open for
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the es-discuss