summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2012-02-05 09:59:12 +0100
committerGeorg Brandl <georg@python.org>2012-02-05 09:59:12 +0100
commit58d4fdd34d36de2204aa97ee2dbb9a6182af1efa (patch)
treee2f2c02229dd882a70c75981f2fdc7da09537678
parent6603116d93582289094219009f150f591f63cbf3 (diff)
downloadpygments-58d4fdd34d36de2204aa97ee2dbb9a6182af1efa.tar.gz
Closes #721: accept char literals in GAS lexer.
-rw-r--r--pygments/lexers/asm.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/pygments/lexers/asm.py b/pygments/lexers/asm.py
index 82933bc8..5be028a9 100644
--- a/pygments/lexers/asm.py
+++ b/pygments/lexers/asm.py
@@ -13,7 +13,8 @@ import re
from pygments.lexer import RegexLexer, include, bygroups, using, DelegatingLexer
from pygments.lexers.compiled import DLexer, CppLexer, CLexer
-from pygments.token import *
+from pygments.token import Text, Name, Number, String, Comment, Punctuation, \
+ Other, Keyword, Operator
__all__ = ['GasLexer', 'ObjdumpLexer','DObjdumpLexer', 'CppObjdumpLexer',
'CObjdumpLexer', 'LlvmLexer', 'NasmLexer']
@@ -72,6 +73,7 @@ class GasLexer(RegexLexer):
('%' + identifier, Name.Variable),
# Numeric constants
('$'+number, Number.Integer),
+ (r"$'(.|\\')'", String.Char),
(r'[\r\n]+', Text, '#pop'),
(r'#.*?$', Comment, '#pop'),
include('punctuation'),