comparison contrib/check-code.py @ 18183:e1caaeb5a2ed

check-code: disallow defunct <> operator Added a test for that and one other python3 check in test-check-code.t.
author Augie Fackler <raf@durin42.com>
date Tue, 01 Jan 2013 13:05:22 -0600
parents c582a71457e5
children 813b7a1f7036
comparison
equal deleted inserted replaced
18182:e6db64abfa87 18183:e1caaeb5a2ed
127 (r'lambda\s*\(.*,.*\)', 127 (r'lambda\s*\(.*,.*\)',
128 "tuple parameter unpacking not available in Python 3+"), 128 "tuple parameter unpacking not available in Python 3+"),
129 (r'(?<!def)\s+(cmp)\(', "cmp is not available in Python 3+"), 129 (r'(?<!def)\s+(cmp)\(', "cmp is not available in Python 3+"),
130 (r'\breduce\s*\(.*', "reduce is not available in Python 3+"), 130 (r'\breduce\s*\(.*', "reduce is not available in Python 3+"),
131 (r'\.has_key\b', "dict.has_key is not available in Python 3+"), 131 (r'\.has_key\b', "dict.has_key is not available in Python 3+"),
132 (r'\s<>\s', '<> operator is not available in Python 3+, use !='),
132 (r'^\s*\t', "don't use tabs"), 133 (r'^\s*\t', "don't use tabs"),
133 (r'\S;\s*\n', "semicolon"), 134 (r'\S;\s*\n', "semicolon"),
134 (r'[^_]_\("[^"]+"\s*%', "don't use % inside _()"), 135 (r'[^_]_\("[^"]+"\s*%', "don't use % inside _()"),
135 (r"[^_]_\('[^']+'\s*%", "don't use % inside _()"), 136 (r"[^_]_\('[^']+'\s*%", "don't use % inside _()"),
136 (r'(\w|\)),\w', "missing whitespace after ,"), 137 (r'(\w|\)),\w', "missing whitespace after ,"),