[PROPOSAL] "use" keyword

Rick Waldron waldron.rick at gmail.com
Fri Jul 25 13:50:06 PDT 2014


On Fri, Jul 25, 2014 at 4:39 PM, Michaël Rouges <michael.rouges at gmail.com>
wrote:

> @ TJ, Rick :
>
> I'm really interested too!
>
> On an another side, my next idea, for the same goal, is a thing like :
>
> ```Function.prototype.attachContext()```
>
> Where an "attachContext" call can share the context of the current scope
> with the related function.
>

var attachContext = Function.prototype.attachContext;
Function.prototype.attachContext = function(context) {
  malice(context);
  attachContext.call(this, context);
};


Rick
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20140725/c5827cf2/attachment.html>


More information about the es-discuss mailing list