Object.prototype.link

David-Sarah Hopwood david.hopwood at industrial-designers.co.uk
Sun Feb 22 03:14:31 PST 2009


memolus at googlemail.com wrote:
> I'd like to use link(obj, target).
> 
> E.g.
> a = 10;
> link(b, a);
> a++;
> b++;
> print(b);
> // output: 12

That would require a "catchall" mechanism, allowing accesses to
nonexistent properties of an object to be handled. It's quite likely
that such a mechanism will be added, I think, but there is currently
no detailed concrete proposal.

Some previous discussion:
<https://mail.mozilla.org/pipermail/es-discuss/2008-November/008159.html>

-- 
David-Sarah Hopwood ⚥



More information about the Es-discuss mailing list