Skip to content

[explicit-resource-management] Add remaining tests specific to using statement syntax #4483

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

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

rbuckton
Copy link
Contributor

In an effort to make review more manageable, this extracts the remaining tests specific to using statement syntax from #3866

@rbuckton rbuckton requested a review from a team as a code owner May 12, 2025 15:48
---*/

$DONOTEVALUATE();
for (using of of [1, 2, 3]) { }
Copy link
Contributor

@JLHwung JLHwung May 20, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you add a new test case when for (using of starts a for-variable-declaration, e.g.

for(using of = null;;;);

This should be valid according to current spec, but a few implementations reject it as if it always started a for-of statement.

c.f. tc39/proposal-explicit-resource-management#248

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in fc3079a

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants