-
Notifications
You must be signed in to change notification settings - Fork 865
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
Add support for ES2024 Regex v flag #1219
Conversation
acorn/src/regexp.js
Outdated
) { | ||
pos = state.pos | ||
} | ||
state.pos = pos |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it actually valid for --
/&&
to occur but then not be followed by a set operand? If not, why not move the parsing of the operand into the if
and make it raise rather than return a boolean?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I changed it to raise an error if the operator is not followed by an operand.
0265d1b
Thanks for integrating all my comments! |
Thank you for the many reviews! I will check the follow up diff. |
This is a continuation of #1216 and #1218.