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

Lhs check for let left of in and instanceof is only checking in #21

Open
pvdz opened this issue May 18, 2021 · 0 comments
Open

Lhs check for let left of in and instanceof is only checking in #21

pvdz opened this issue May 18, 2021 · 0 comments

Comments

@pvdz
Copy link
Owner

pvdz commented May 18, 2021

Silly oversight. Also need to write a test for it.

if ($tp_next_type === $ID_in || $tp_next_type === $ID_in) {
      return THROW_RANGE('Cannot use `let` as a regular var name as the lhs of `in` or `instanceof` in a toplevel expression statement', tok_getStart(), tok_getStop()); // And why would you.
    }
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

1 participant