Bug 275672
| Summary: | Implement RegExp modifiers (stage3 proposal) | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Jarred Sumner <jarred> |
| Component: | JavaScriptCore | Assignee: | Nobody <webkit-unassigned> |
| Status: | NEW | ||
| Severity: | Normal | CC: | karlcow, mark.lam, msaboff, webkit-bug-importer |
| Priority: | P2 | Keywords: | BrowserCompat, InRadar |
| Version: | WebKit Nightly Build | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| URL: | https://github.com/tc39/proposal-regexp-modifiers | ||
Jarred Sumner
The TC39 Regular Expression Pattern Modifiers for ECMAScript proposal has reached stage3 - https://github.com/tc39/proposal-regexp-modifiers
It shipped in V8 in Chrome 125/Edge 125
It adds syntax like the below:
```
/(?i:test)/.test('Test');
```
Currently, this throws an error like:
```
SyntaxError: Invalid regular expression: unrecognized character after (?
```
Related issue: https://github.com/oven-sh/bun/issues/11960
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Radar WebKit Bug Importer
<rdar://problem/130622886>