Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.
Sign upGetFunctionRealm argument #814
Comments
This comment has been minimized.
Show comment
Hide comment
This comment has been minimized.
Show comment
Hide comment
|
How could a proxy be callable, but its target not be? |
This comment has been minimized.
Show comment
Hide comment
This comment has been minimized.
Show comment
Hide comment
jmdyck
Feb 11, 2017
Collaborator
Ah, ProxyCreate() will make the proxy callable only if the target is.
But that seems unnecessarily restrictive: if the handler has an "apply" method, why does the target need to be callable?
|
Ah, ProxyCreate() will make the proxy callable only if the target is. But that seems unnecessarily restrictive: if the handler has an "apply" method, why does the target need to be callable? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
jmdyck commentedFeb 11, 2017
•
edited
The abstract operation
GetFunctionRealm(_obj_)asserts that_obj_is a callable object. However, consider the steps later in the definition:I don't think there's a guarantee that
_obj_.[[ProxyTarget]]is callable, in which case the recursive call would fail the assertion.