Skip to content
JS
JavaScript error

SyntaxError

The JavaScript exception "invalid class set operation in regular expression" occurs when a double punctuator sequence appears in a v-mode character class but it is not recognized by the syntax.

Reference entryJavaScriptFetched
SyntaxError: Invalid regular expression: /[&&]/v: Invalid set operation in character class (V8-based)
As listed by MDN Web Docs
SyntaxError: invalid class set operation in regular expression (Firefox)
As listed by MDN Web Docs
SyntaxError: Invalid regular expression: invalid operation in class set (Safari)
As listed by MDN Web Docs
Category
SyntaxError
Severity
error
Runtime
both
or press Cmd/Ctrl + Enter. The text is only sent to this site to match it.
Source: MDN Web Docs. Data fetched 2026-09-25T01:48:37.274Z.