Sugar for *.prototype and for calling methods as functions

Andreas Rossberg rossberg at google.com
Tue Feb 21 05:06:22 PST 2012


On 21 February 2012 13:59, Brandon Benvie <brandon at brandonbenvie.com> wrote:
> I would ask as an exploratory idea: is there any interest in, and what
> problems exist with exposing most {Builtin}.prototype.* methods as unbound
> functional {Builtin}.* functions. Or failing that, a more succint expression
> for the following:
>
> Function.prototype.[call/apply].bind({function}).
> Array.prototype.[map/reduce/forEach].call(arraylike, callback)
> Object.set('key', va)

There is a proposal for making available existing functions via modules in ES6:

http://wiki.ecmascript.org/doku.php?id=harmony:modules_standard

If there are methods missing from this list that can reasonably be
used as stand-alone functions, then I'm sure nobody will object to
adding them.

/Andreas


More information about the es-discuss mailing list