Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing coverage: Function.prototype.toString revision behavior on a Proxied function #1453

Closed
ajklein opened this issue Feb 22, 2018 · 2 comments
Assignees

Comments

@ajklein
Copy link
Contributor

ajklein commented Feb 22, 2018

We just got a report in v8 about non-compliance with a new bit of logic in the Function.prototype.toString revision proposal. In particular, step 3 of the algorithm says:

If Type(func) is Object and IsCallable(func) is true, then return an implementation-dependent String source code representation of func. The representation must have the syntax of a NativeFunction.

This is a change in behavior from the current spec, which throws a TypeError in this case. This doesn't seem to be covered by any test262 test.

@michaelficarra @erights to verify that I'm reading the proposal correctly.

@ljharb
Copy link
Member

ljharb commented Feb 23, 2018

I agree that you're reading the proposal correctly; however I'm surprised at this change, and it seems like it's an unintentional change in the proposal.

@michaelficarra
Copy link
Member

michaelficarra commented Feb 23, 2018

This was an intentional change in response to tc39/Function-prototype-toString-revision#3. I recall talking about it in committee, but I think it was only in side conversations.

edit: /cc @claudepache

@rwaldron rwaldron self-assigned this Apr 9, 2018
rwaldron added a commit to rwaldron/test262 that referenced this issue Apr 10, 2018
rwaldron added a commit to rwaldron/test262 that referenced this issue Apr 10, 2018
rwaldron added a commit to rwaldron/test262 that referenced this issue Apr 10, 2018
rwaldron added a commit to rwaldron/test262 that referenced this issue Apr 10, 2018
rwaldron added a commit to rwaldron/test262 that referenced this issue Apr 10, 2018
rwaldron added a commit to rwaldron/test262 that referenced this issue Apr 10, 2018
rwaldron added a commit to rwaldron/test262 that referenced this issue Apr 10, 2018
rwaldron added a commit to rwaldron/test262 that referenced this issue Apr 11, 2018
rwaldron added a commit to rwaldron/test262 that referenced this issue Apr 18, 2018
rwaldron added a commit to rwaldron/test262 that referenced this issue Apr 18, 2018
rwaldron added a commit to rwaldron/test262 that referenced this issue Apr 19, 2018
rwaldron added a commit to rwaldron/test262 that referenced this issue Apr 19, 2018
chicoxyzzy pushed a commit to chicoxyzzy/test262 that referenced this issue May 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants