Minor type confusion in proxies proposal?

Sean Eagan seaneagan1 at gmail.com
Tue Jul 5 10:55:53 PDT 2011


On Tue, Jul 5, 2011 at 9:45 AM, Sean Eagan <seaneagan1 at gmail.com> wrote:
> I think if an "Object.toPropertyDescriptor" function were introduced,
> then this protection burden may be sufficiently small.  This would be
> similar to the FixedHandler approach of providing *optional* builtin
> invariant maintenance support.  The first argument to this function
> would be the object to convert to a property descriptor,  and there
> could potentially be a second argument which could be a boolean as to
> whether to keep non-standard attributes.

Object.toPropertyDescriptor could also allow us to directly return
"getOwnPropertyDescriptor" trap return values, as this value could
then be tamed by proxy consumers in a standard, efficient, and
convenient manner.

Cheers,
Sean Eagan


More information about the es-discuss mailing list