summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorthatch <devnull@localhost>2008-09-24 20:12:46 -0700
committerthatch <devnull@localhost>2008-09-24 20:12:46 -0700
commit52afb43cd14c7a9a63c4788c25b078994c32c146 (patch)
tree32b7efcd5648f6d0d423e0e93b81c260044aac7b
parent62eae3e36222566c700d0a530983bac806b4639f (diff)
downloadpygments-52afb43cd14c7a9a63c4788c25b078994c32c146.tar.gz
Give Python3TracebackLexer a new name since it was shadowing the main
PythonTracebackLexer, which once again allows SyntaxError to work for pytb files. Add example file to make sure of this in the future.
-rw-r--r--pygments/lexers/_mapping.py2
-rw-r--r--pygments/lexers/agile.py2
-rw-r--r--tests/examplefiles/pytb_test2.pytb (renamed from tests/examplefiles/pycon_test2.pycon)1
3 files changed, 2 insertions, 3 deletions
diff --git a/pygments/lexers/_mapping.py b/pygments/lexers/_mapping.py
index ba107b26..f9efdb16 100644
--- a/pygments/lexers/_mapping.py
+++ b/pygments/lexers/_mapping.py
@@ -109,7 +109,7 @@ LEXERS = {
'PhpLexer': ('pygments.lexers.web', 'PHP', ('php', 'php3', 'php4', 'php5'), ('*.php', '*.php[345]'), ('text/x-php',)),
'PovrayLexer': ('pygments.lexers.other', 'POVRay', ('pov',), ('*.pov', '*.inc'), ('text/x-povray',)),
'Python3Lexer': ('pygments.lexers.agile', 'Python 3', ('python3', 'py3'), (), ('text/x-python3', 'application/x-python3')),
- 'Python3TracebackLexer': ('pygments.lexers.agile', 'Python Traceback', ('py3tb',), ('*.py3tb',), ('text/x-python3-traceback',)),
+ 'Python3TracebackLexer': ('pygments.lexers.agile', 'Python 3.0 Traceback', ('py3tb',), ('*.py3tb',), ('text/x-python3-traceback',)),
'PythonConsoleLexer': ('pygments.lexers.agile', 'Python console session', ('pycon',), (), ('text/x-python-doctest',)),
'PythonLexer': ('pygments.lexers.agile', 'Python', ('python', 'py'), ('*.py', '*.pyw', '*.sc', 'SConstruct', 'SConscript'), ('text/x-python', 'application/x-python')),
'PythonTracebackLexer': ('pygments.lexers.agile', 'Python Traceback', ('pytb',), ('*.pytb',), ('text/x-python-traceback',)),
diff --git a/pygments/lexers/agile.py b/pygments/lexers/agile.py
index 3b49572a..6141d272 100644
--- a/pygments/lexers/agile.py
+++ b/pygments/lexers/agile.py
@@ -394,7 +394,7 @@ class Python3TracebackLexer(RegexLexer):
*New in Pygments 0.12.*
"""
- name = 'Python Traceback'
+ name = 'Python 3.0 Traceback'
aliases = ['py3tb']
filenames = ['*.py3tb']
mimetypes = ['text/x-python3-traceback']
diff --git a/tests/examplefiles/pycon_test2.pycon b/tests/examplefiles/pytb_test2.pytb
index d8e6c966..c4d20339 100644
--- a/tests/examplefiles/pycon_test2.pycon
+++ b/tests/examplefiles/pytb_test2.pytb
@@ -1,3 +1,2 @@
-Pilot:~/code/pygments/pygments-tim/tests/examplefiles tim$ python temp.py
File "temp.py", line 1
SyntaxError: Non-ASCII character '\xc3' in file temp.py on line 1, but no encoding declared; see http://www.python.org/peps/pep-0263.html for details