diff options
author | Jean Abou-Samra <jean@abou-samra.fr> | 2022-01-31 22:00:40 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-31 22:00:40 +0100 |
commit | c81e97c3c281492ac6fdf4abc841ac5b63f3f303 (patch) | |
tree | 8d52ec56246f4d08a4eb0d16317cc5c261ebfd05 /pygments/lexers/javascript.py | |
parent | b1edee0c8f736276a86e30d8edaed1f581e009d0 (diff) | |
download | pygments-git-c81e97c3c281492ac6fdf4abc841ac5b63f3f303.tar.gz |
Remove now redundant re.UNICODE and (?u) (#2058)
Diffstat (limited to 'pygments/lexers/javascript.py')
-rw-r--r-- | pygments/lexers/javascript.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/pygments/lexers/javascript.py b/pygments/lexers/javascript.py index e8012819..1dc0c57d 100644 --- a/pygments/lexers/javascript.py +++ b/pygments/lexers/javascript.py @@ -42,7 +42,7 @@ class JavascriptLexer(RegexLexer): mimetypes = ['application/javascript', 'application/x-javascript', 'text/x-javascript', 'text/javascript'] - flags = re.DOTALL | re.UNICODE | re.MULTILINE + flags = re.DOTALL | re.MULTILINE tokens = { 'commentsandwhitespace': [ @@ -1439,7 +1439,7 @@ class JuttleLexer(RegexLexer): mimetypes = ['application/juttle', 'application/x-juttle', 'text/x-juttle', 'text/juttle'] - flags = re.DOTALL | re.UNICODE | re.MULTILINE + flags = re.DOTALL | re.MULTILINE tokens = { 'commentsandwhitespace': [ @@ -1525,7 +1525,7 @@ class NodeConsoleLexer(Lexer): for match in line_re.finditer(text): line = match.group() if line.startswith('> '): - insertions.append((len(curcode), + insertions.append((len(curcode), [(0, Generic.Prompt, line[:2])])) curcode += line[2:] @@ -1534,21 +1534,21 @@ class NodeConsoleLexer(Lexer): code = line.lstrip('.') lead = len(line) - len(code) - insertions.append((len(curcode), + insertions.append((len(curcode), [(0, Generic.Prompt, line[:lead])])) curcode += code else: if curcode: - yield from do_insertions(insertions, + yield from do_insertions(insertions, jslexer.get_tokens_unprocessed(curcode)) curcode = '' insertions = [] - yield from do_insertions([], + yield from do_insertions([], jslexer.get_tokens_unprocessed(line)) if curcode: - yield from do_insertions(insertions, + yield from do_insertions(insertions, jslexer.get_tokens_unprocessed(curcode)) |