Mercurial > public > mercurial-scm > hg
comparison contrib/check-code.py @ 25030:33298a8b472f
check-code: allow with statements
We dropped python 2.4 compatibility.
author | Pierre-Yves David <pierre-yves.david@fb.com> |
---|---|
date | Wed, 13 May 2015 11:49:38 -0700 |
parents | e0ce8d8630f3 |
children | 68633ff2b608 |
comparison
equal
deleted
inserted
replaced
25029:e0ce8d8630f3 | 25030:33298a8b472f |
---|---|
246 # "don't capitalize non-exception classes"), | 246 # "don't capitalize non-exception classes"), |
247 # (r'in range\(', "use xrange"), | 247 # (r'in range\(', "use xrange"), |
248 # (r'^\s*print\s+', "avoid using print in core and extensions"), | 248 # (r'^\s*print\s+', "avoid using print in core and extensions"), |
249 (r'[\x80-\xff]', "non-ASCII character literal"), | 249 (r'[\x80-\xff]', "non-ASCII character literal"), |
250 (r'("\')\.format\(', "str.format() not available in Python 2.4"), | 250 (r'("\')\.format\(', "str.format() not available in Python 2.4"), |
251 (r'^\s*with\s+', "with not available in Python 2.4"), | |
252 (r'\.isdisjoint\(', "set.isdisjoint not available in Python 2.4"), | 251 (r'\.isdisjoint\(', "set.isdisjoint not available in Python 2.4"), |
253 (r'^\s*os\.path\.relpath', "relpath not available in Python 2.4"), | 252 (r'^\s*os\.path\.relpath', "relpath not available in Python 2.4"), |
254 (r'(?<!def)\s+(any|all|format)\(', | 253 (r'(?<!def)\s+(any|all|format)\(', |
255 "any/all/format not available in Python 2.4", 'no-py24'), | 254 "any/all/format not available in Python 2.4", 'no-py24'), |
256 (r'if\s.*\selse', "if ... else form not available in Python 2.4"), | 255 (r'if\s.*\selse', "if ... else form not available in Python 2.4"), |