Non-generic traps for non-generic objects (was: Overriding Map/etc with get/set hooks?)

Jason Orendorff jason.orendorff at gmail.com
Fri May 24 11:53:19 PDT 2013


On Fri, May 24, 2013 at 12:02 PM, Tab Atkins Jr. <jackalmage at gmail.com>wrote:

> On Fri, May 24, 2013 at 9:27 AM, Jason Orendorff
> <jason.orendorff at gmail.com> wrote:
> > Counterproposal: address this in WebIDL. Add a magic [Maplike] tag that
> > means something like: [...]
>
>  [...] It's not the *best* solution, because the easy magic is only there
> for
> spec authors, but it's the best so far.


I see your point. I think this is a case where spec authors definitely have
a problem, but JS programmers will not sweat it that much.

In JS it's just so easy:  https://gist.github.com/jorendorff/5645591

-j
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20130524/70fca58f/attachment.html>


More information about the es-discuss mailing list