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

Accept /[\-]/u as a valid regular expression #288

Merged
merged 1 commit into from Mar 2, 2024

Conversation

bnoordhuis
Copy link
Contributor

@bnoordhuis bnoordhuis commented Mar 2, 2024

The non-Unicode version of the pattern was already accepted.

test262 does not seem to test this particular pattern and I'm not 100% sure if it's actually per spec but both V8 and Spidermonkey accept it. - edit: see commit log

Fixes: #286

The non-Unicode version of the pattern was already accepted.

test262 tests it in an inverted sense in
test/built-ins/RegExp/unicode_restricted_identity_escape.js but
it appears to be per spec and both V8 and Spidermonkey accept it.

Fixes: quickjs-ng#286
@bnoordhuis
Copy link
Contributor Author

test262 does test it but in a roundabout way. Code updated, commit log amended.

@bnoordhuis bnoordhuis merged commit f406d6f into quickjs-ng:master Mar 2, 2024
35 checks passed
@bnoordhuis bnoordhuis deleted the fix286 branch March 2, 2024 12:29
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.

invalid escape sequence in regular expression
2 participants