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

Revert "Prevent harness code not loading when async/generator/asyncGenerator not supported" #4166

Conversation

anba
Copy link
Contributor

@anba anba commented Jul 24, 2024

Reverts #4164 because it added incorrect code:

js> Object.getPrototypeOf(new Function('async function () {}')).constructor;
typein:3:16 SyntaxError: function statement requires a name:
typein:3:16 async function () {}
typein:3:16 ...............^
Stack:
  @typein:1:23

@anba anba requested a review from a team as a code owner July 24, 2024 16:41
ptomato added a commit to ptomato/test262 that referenced this pull request Jul 24, 2024
Function statements require a name.

See tc39#4166
@ptomato
Copy link
Contributor

ptomato commented Jul 24, 2024

Thanks, @anba. Alternatively, #4167 should fix the problem.

Sorry about that. I guess #4118 would have prevented this.

ptomato added a commit that referenced this pull request Jul 24, 2024
* Fix syntax error from #4164

Function statements require a name.

See #4166

* Apply suggestions from code review

Co-authored-by: Jordan Harband <[email protected]>

---------

Co-authored-by: Jordan Harband <[email protected]>
@ptomato
Copy link
Contributor

ptomato commented Jul 24, 2024

Hopefully fixed now.

@ptomato ptomato closed this Jul 24, 2024
@anba anba deleted the revert-4164-3032_dont_throw_on_unsupported_hidden_constructor branch August 28, 2024 13:17
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

Successfully merging this pull request may close these issues.

2 participants