On 06/10/11 00:02, Juan Ignacio Dopazo wrote:
On Wed, Oct 5, 2011 at 10:36 PM, Jake Verbaten <[email protected] <mailto:[email protected]>> wrote:

    Object.create does indeed require  propertydescriptors as the
    second argument. This is the easiest way to send meta-data like
    read-only.

    However it's verbose and the defaults are restrictive. I've
    written a small library (github.com/Raynos/pd
    <http://github.com/Raynos/pd>) to make it less verbose, you might
    find it useful.


That's what Object.getOwnPropertyDescriptors <http://wiki.ecmascript.org/doku.php?id=strawman:extended_object_api> would be for. I don't know why it hasn't gotten into Harmony yet.
Hm, how exactly would `#getOwnPropertyDescriptors' fix the verbosity of property descriptors when creating new slots in an object? Or were you referring to another issue? If so, I missed it, would you care to explain a little better?
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to