1. Adam Koprowski
  2. pygments-main

Commits

Joshua Peek  committed abe6a7b

Escape clojure regex string

  • Participants
  • Parent commits db34fea
  • Branches default

Comments (0)

Files changed (1)

File pygments/lexers/agile.py

View file
  • Ignore whitespace
     valid_name = r'[\w!$%*+,<=>?/.-]+'
 
     def _multi_escape(entries):
-        return '|'.join([re.escape(entry) + '(?![\\w-!$%*+,<=>?/.-])'
+        return '|'.join([re.escape(entry) + re.escape('(?![\\w-!$%*+,<=>?/.-])')
                          for entry in entries])
 
     tokens = {