diff options
Diffstat (limited to 'pygments')
-rw-r--r-- | pygments/lexer.py | 2 | ||||
-rw-r--r-- | pygments/lexers/compiled.py | 6 |
2 files changed, 5 insertions, 3 deletions
diff --git a/pygments/lexer.py b/pygments/lexer.py index 092870ce..16a6b8ab 100644 --- a/pygments/lexer.py +++ b/pygments/lexer.py @@ -543,7 +543,7 @@ def do_insertions(insertions, tokens): The result is a combined token stream. - XXX: The indices yielded by this function are not correct! + FIXME: The indices yielded by this function are not correct! """ insertions = iter(insertions) try: diff --git a/pygments/lexers/compiled.py b/pygments/lexers/compiled.py index 37a5983a..08a5c90d 100644 --- a/pygments/lexers/compiled.py +++ b/pygments/lexers/compiled.py @@ -55,7 +55,8 @@ class CLexer(RegexLexer): (r'0[0-7]+[Ll]?', Number.Oct), (r'(\d+\.\d*|\.\d+)', Number.Float), (r'\d+', Number.Integer), - (r'[~!%^&*()+=|\[\]:,.<>/?-]', Punctuation), # missing: Operators + (r'[~!%^&*+=|?:<>/-]', Operator), + (r'[()\[\],.]', Punctuation), (r'(auto|break|case|const|continue|default|do|else|enum|extern|' r'for|goto|if|register|restricted|return|sizeof|static|struct|' r'switch|typedef|union|volatile|virtual|while)\b', Keyword), @@ -145,7 +146,8 @@ class CppLexer(RegexLexer): (r'0[0-7]+[Ll]?', Number.Oct), (r'(\d+\.\d*|\.\d+)', Number.Float), (r'\d+', Number.Integer), - (r'[~!%^&*()+=|\[\]:;,.<>/?-]', Punctuation), + (r'[~!%^&*+=|?:<>/-]', Operator), + (r'[()\[\],.]', Punctuation), (r'(asm|auto|break|case|catch|const|const_cast|continue|' r'default|delete|do|dynamic_cast|else|enum|explicit|export|' r'extern|for|friend|goto|if|mutable|namespace|new|operator|' |