Skip to content

regex v class set subtraction rejects Unicode escapes #370

Closed

Description

@robertmorelli

issue:
new RegExp("[\\u{17F}--\\u{212A}]", "v") throws a SyntaxError, but the pattern is valid.

repro:

console.log(new RegExp("[\\u{17F}--\\u{212A}]", "v").test("ſ"));
// SyntaxError: Expect a CharacterClassEscape but u found

expected:
prints true

system:
engine262 commit 678c2c0
macOS 27.0, arm64

Activity

  1. Jack-Works commented on Oct 14, 2026

    @Jack-Works
    Contributor

    thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions