https://codereview.chromium.org/236143002/diff/1/src/collection.js
File src/collection.js (right):
https://codereview.chromium.org/236143002/diff/1/src/collection.js#newcode130
src/collection.js:130: if (typeof f !== 'function') {
On 2014/04/14 19:51:49, arv wrote:
On 2014/04/14 19:15:42, adamk wrote:
> I think you want IS_SPEC_FUNCTION(f) here, which is a macro
expanding to:
>
> %_ClassOf(arg) === 'Function'
IS_SPEC_FUNCTION is not correct any more. It tests that the instance
is a true
function. What we really care about is Callable. Most of the IS_SPEC
function
have been removed in the spec and now the spec checks for Callable
instead.
They are testing the same thing (whether the instance type is either
JS_FUNCTION or JS_FUNCTION_PROXY -- there are no other callables in V8).
However, IS_SPEC_FUNCTION does not require a runtime call, so is
preferable.
Somebody should fix the misleading comment in macros.py :)
https://codereview.chromium.org/236143002/
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.