[New] use Reflect.apply‑based callability detection#54
Merged
ljharb merged 1 commit intoinspect-js:masterfrom May 30, 2020
Merged
[New] use Reflect.apply‑based callability detection#54ljharb merged 1 commit intoinspect-js:masterfrom
Reflect.apply‑based callability detection#54ljharb merged 1 commit intoinspect-js:masterfrom
Conversation
ljharb
reviewed
May 19, 2020
Reflect.apply‑based callability detectionReflect.apply‑based callability detection
6a0d2a8 to
32e14cf
Compare
ljharb
added a commit
that referenced
this pull request
Sep 9, 2020
…-like Caused by #54; see enzymejs/enzyme#2439
ljharb
added a commit
that referenced
this pull request
Sep 21, 2020
Caused by #54; see enzymejs/enzyme#2439
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Based on the
IsConstructorimplementation in ljharb/es-abstract#93 and tc39/ecma262#1798 (comment).This makes
isCallableuseReflect.applywith abadArrayLikewhenReflect.applyand accessor descriptors are supported.This has the advantage of supporting proxies in environments that don’t implement tc39/ecma262#664 (tc39/ecma262#697).