chakra-core / chakra-core/ChakraCore

Raw bracket is not allowed in regular expression with unicode flag

Open
#6,460 0 comments 2 reactions 0 assignees View on GitHub
Bug
Dominant language
JavaScript
Stars
9.3k
Forks
1.2k
PR merge metrics
No merged PRs in 30d

Description

Hello,
This regexp is not valid, but chakra pass without throw a syntax error.

version: 1.11.19
OS: Linux Ubuntu 19.10 x64

steps to reproduce:
```
var x = /[\u{61}-b]b]/u;
^
```
Actual results:
```
pass without errors
```

Expected results:
```
SyntaxError: raw bracket is not allowed in regular expression with unicode flag
```
V8, SpiderMonkey, Hermes and JavaScriptCore works as expected.

cinfuzz

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.