eric6/ThirdParty/Pygments/pygments/lexers/special.py

changeset 7547
21b0534faebc
parent 6942
2602857055c5
child 7701
25f42e208e08
--- a/eric6/ThirdParty/Pygments/pygments/lexers/special.py	Tue Apr 21 19:44:19 2020 +0200
+++ b/eric6/ThirdParty/Pygments/pygments/lexers/special.py	Tue Apr 21 19:47:10 2020 +0200
@@ -5,15 +5,16 @@
 
     Special lexers.
 
-    :copyright: Copyright 2006-2017 by the Pygments team, see AUTHORS.
+    :copyright: Copyright 2006-2019 by the Pygments team, see AUTHORS.
     :license: BSD, see LICENSE for details.
 """
 
 import re
+from io import BytesIO
 
 from pygments.lexer import Lexer
 from pygments.token import Token, Error, Text
-from pygments.util import get_choice_opt, text_type, BytesIO
+from pygments.util import get_choice_opt
 
 
 __all__ = ['TextLexer', 'RawTokenLexer']
@@ -35,6 +36,7 @@
     def analyse_text(text):
         return TextLexer.priority
 
+
 _ttype_cache = {}
 
 line_re = re.compile(b'.*?\n')
@@ -63,7 +65,7 @@
         Lexer.__init__(self, **options)
 
     def get_tokens(self, text):
-        if isinstance(text, text_type):
+        if isinstance(text, str):
             # raw token stream never has any non-ASCII characters
             text = text.encode('ascii')
         if self.compress == 'gz':

eric ide

mercurial