Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e4870b5

Browse files
committed
Limit which operators get colorized
1 parent 9b8ede6 commit e4870b5

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Tools/scripts/pycolorize.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ def colorize(source):
2828
kind, prev_kind = '', kind
2929
if tok_type == tokenize.COMMENT:
3030
kind = 'comment'
31-
elif tok_type == tokenize.OP:
31+
elif tok_type == tokenize.OP and tok_str[:1] not in '{}[](),.:;':
3232
kind = 'operator'
3333
elif tok_type == tokenize.STRING:
3434
kind = 'string'

0 commit comments

Comments
 (0)