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

JS: Add ECMAScript 2024 v Flag Operators for Regex Parsing #18899

Open
wants to merge 19 commits into
base: main
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Added test cases for intersection
  • Loading branch information
Napalys committed Mar 3, 2025
commit fa5093f6ad65fbb9064c910d95feb1e908c5889d
7 changes: 7 additions & 0 deletions javascript/extractor/tests/es2024/input/intersection.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
/[[abc]&&[bcd]]/v; // Valid use of intersection operator, matches b or c
/abc&&bcd/v; //Valid regex, but no intersection operation: Matches the literal string "abc&&bcd"
/[abc]&&[bcd]/v; // Valid regex, but incorrect intersection operation:
// - Matches a single character from [abc]
// - Then the literal "&&"
// - Then a single character from [bcd]
/[[abc]&&[bcd]&&[c]]/v; // Valid use of intersection operator, matches c
Loading
Oops, something went wrong.