Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-13934

Escaping of parentheses/brackets/braces in shell regular expression literals does not work

    • Type: Icon: Bug Bug
    • Resolution: Won't Fix
    • Priority: Icon: Minor - P4 Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: Shell
    • None
    • ALL

      > db.foo.find({name: /\\/}).count();
      0  // great, no records contain backslash
      > db.foo.find({name: /\(/}).count();
      ... }
      SyntaxError: Unexpected token }
      

      Same for [ and {{{}}*

      • That was an attempt to highlight {. I hate Jira's weird syntax when everyone else uses Markdown.

            Assignee:
            backlog-server-platform DO NOT USE - Backlog - Platform Team
            Reporter:
            dandv Dan Dascalescu
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: