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
JavaScript: Distinguish {lo}
and {lo,}
in the regular expression parser.
#2854
JavaScript: Distinguish {lo}
and {lo,}
in the regular expression parser.
#2854
Conversation
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.
LGTM. Thanks for jumping in and fixing this immediately.
@@ -0,0 +1,3 @@ | |||
/a{1}/; | |||
/a{1,}/; | |||
/a{1,5}/; |
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.
Can we add the non-bound /a{,1}/;
for completeness?
(/a{,1}/.test('a{,1}') === true
)
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.
That's a syntax error, I believe.
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.
But I may be wrong, let me check...
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.
And indeed I'm wrong, we are more lenient than the ECMAScript standard. Yay, us!
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.
Apparently we treat a missing lower bound as zero, which is not how v8 handles it. That is, however, orthogonal to this PR.
c127ee1
to
cd1b5ca
Compare
cd1b5ca
to
bad4f36
Compare
bad4f36
to
00dc26b
Compare
00dc26b
to
4346691
Compare
No description provided.