92 (r'[\x80-\xff]', "non-ASCII character literal"), |
92 (r'[\x80-\xff]', "non-ASCII character literal"), |
93 (r'("\')\.format\(', "str.format() not available in Python 2.4"), |
93 (r'("\')\.format\(', "str.format() not available in Python 2.4"), |
94 (r'^\s*with\s+', "with not available in Python 2.4"), |
94 (r'^\s*with\s+', "with not available in Python 2.4"), |
95 (r'(?<!def)\s+(any|all|format)\(', |
95 (r'(?<!def)\s+(any|all|format)\(', |
96 "any/all/format not available in Python 2.4"), |
96 "any/all/format not available in Python 2.4"), |
|
97 (r'(?<!def)\s+(callable)\(', |
|
98 "callable not available in Python 3, use hasattr(f, '__call__')"), |
97 (r'if\s.*\selse', "if ... else form not available in Python 2.4"), |
99 (r'if\s.*\selse', "if ... else form not available in Python 2.4"), |
98 (r'([\(\[]\s\S)|(\S\s[\)\]])', "gratuitous whitespace in () or []"), |
100 (r'([\(\[]\s\S)|(\S\s[\)\]])', "gratuitous whitespace in () or []"), |
99 # (r'\s\s=', "gratuitous whitespace before ="), |
101 # (r'\s\s=', "gratuitous whitespace before ="), |
100 (r'[^>< ](\+=|-=|!=|<>|<=|>=|<<=|>>=)\S', |
102 (r'[^>< ](\+=|-=|!=|<>|<=|>=|<<=|>>=)\S', |
101 "missing whitespace around operator"), |
103 "missing whitespace around operator"), |