diff options
author | gbrandl <devnull@localhost> | 2006-12-20 15:40:48 +0100 |
---|---|---|
committer | gbrandl <devnull@localhost> | 2006-12-20 15:40:48 +0100 |
commit | 746e0fa822472ea365ef1596bd97c112536356cc (patch) | |
tree | 8879970319c87a69c46689fb5bef296109f846c8 | |
parent | 14d194fcdd43466e41cebceec764ad928d31ab3d (diff) | |
download | pygments-746e0fa822472ea365ef1596bd97c112536356cc.tar.gz |
[svn] Fix one TODO item.
-rw-r--r-- | TODO | 11 | ||||
-rw-r--r-- | pygments/lexer.py | 2 | ||||
-rw-r--r-- | pygments/lexers/compiled.py | 6 |
3 files changed, 10 insertions, 9 deletions
@@ -25,12 +25,6 @@ for 0.6 * mysql/postgresql/sqlite * tcl -- tell the C(++) and PHP lexers how to differ between Operators and text. - -- add support for function name highlighting to c++ lexer - -- readd property support for C# lexer - for 0.7 ------- @@ -39,6 +33,11 @@ for 0.7 - moin parser +- readd property support for C# lexer? that is, find a regex that doesn't + backtrack to death... + +- add support for function name highlighting to c++ lexer + - pygmentize presets? - more unit tests (pygmentize, all formatters comprehensively) 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|' |