summaryrefslogtreecommitdiff
path: root/pygments/lexers/asm.py
diff options
context:
space:
mode:
Diffstat (limited to 'pygments/lexers/asm.py')
-rw-r--r--pygments/lexers/asm.py26
1 files changed, 13 insertions, 13 deletions
diff --git a/pygments/lexers/asm.py b/pygments/lexers/asm.py
index f995264c..f16dbadd 100644
--- a/pygments/lexers/asm.py
+++ b/pygments/lexers/asm.py
@@ -12,12 +12,14 @@
import re
from pygments.lexer import RegexLexer, include, bygroups, using, DelegatingLexer
-from pygments.lexers.compiled import DLexer, CppLexer, CLexer
+from pygments.lexers.c_cpp import CppLexer, CLexer
+from pygments.lexers.d import DLexer
from pygments.token import Text, Name, Number, String, Comment, Punctuation, \
- Other, Keyword, Operator
+ Other, Keyword, Operator
-__all__ = ['GasLexer', 'ObjdumpLexer','DObjdumpLexer', 'CppObjdumpLexer',
- 'CObjdumpLexer', 'LlvmLexer', 'NasmLexer', 'NasmObjdumpLexer', 'Ca65Lexer']
+__all__ = ['GasLexer', 'ObjdumpLexer', 'DObjdumpLexer', 'CppObjdumpLexer',
+ 'CObjdumpLexer', 'LlvmLexer', 'NasmLexer', 'NasmObjdumpLexer',
+ 'Ca65Lexer']
class GasLexer(RegexLexer):
@@ -154,11 +156,9 @@ class ObjdumpLexer(RegexLexer):
filenames = ['*.objdump']
mimetypes = ['text/x-objdump']
-
tokens = _objdump_lexer_tokens(GasLexer)
-
class DObjdumpLexer(DelegatingLexer):
"""
For the output of 'objdump -Sr on compiled D files'
@@ -220,11 +220,11 @@ class LlvmLexer(RegexLexer):
include('keyword'),
- (r'%' + identifier, Name.Variable),#Name.Identifier.Local),
- (r'@' + identifier, Name.Variable.Global),#Name.Identifier.Global),
- (r'%\d+', Name.Variable.Anonymous),#Name.Identifier.Anonymous),
- (r'@\d+', Name.Variable.Global),#Name.Identifier.Anonymous),
- (r'#\d+', Name.Variable.Global),#Name.Identifier.Global),
+ (r'%' + identifier, Name.Variable),
+ (r'@' + identifier, Name.Variable.Global),
+ (r'%\d+', Name.Variable.Anonymous),
+ (r'@\d+', Name.Variable.Global),
+ (r'#\d+', Name.Variable.Global),
(r'!' + identifier, Name.Variable),
(r'!\d+', Name.Variable.Anonymous),
(r'c?' + string, String),
@@ -402,7 +402,7 @@ class Ca65Lexer(RegexLexer):
.. versionadded:: 1.6
"""
- name = 'ca65'
+ name = 'ca65 assembler'
aliases = ['ca65']
filenames = ['*.s']
@@ -424,7 +424,7 @@ class Ca65Lexer(RegexLexer):
(r'\$[0-9a-f]+|[0-9a-f]+h\b', Number.Hex),
(r'\d+', Number.Integer),
(r'%[01]+', Number.Bin),
- (r'[#,.:()=]', Punctuation),
+ (r'[#,.:()=\[\]]', Punctuation),
(r'[a-z_.@$][\w.@$]*', Name),
]
}