Draft of Function.prototype.bind.
brendan at mozilla.com
Mon Nov 3 22:39:54 PST 2008
On Nov 3, 2008, at 10:26 PM, Maciej Stachowiak wrote:
> Beta 1 and I believe they have returned "function" from typeof that
> whole time. (The Mozilla bug report says otherwise but I think that
> testing must have been in error.)
Another report from 2005 testifies to the same result (typeof /hi/ ==
"object" in Safari):
Could also be in error, but is it possible that back then the result
> I'm not aware of any compatibility issues due to either the callable
Agreed, the only "compatibility" issue with callable regexps is that
some people read ECMA-262, the typeof sub-spec, and ask us to make
typeof /hi/ == "function", while others compare that to IE (and
Netscape 4, FWIW) and ask for "object".
> or the way typeof is reported as a result.
The typeof /hi/ == "function" result is considered broken by people
developing against other browsers, trying to separate function objects
from other kinds of objects, not caring about callable non-function
More information about the Es-discuss