# HG changeset patch # User Augie Fackler # Date 1431801063 14400 # Node ID 3b5cd6f13dccf771078e632fb2e3fb9e215faaf1 # Parent fb7b9a765bb9fe6e2e9cc05493f77ba02359fa66 check-code: un-ban any() now that we're on 2.6 diff -r fb7b9a765bb9 -r 3b5cd6f13dcc contrib/check-code.py --- a/contrib/check-code.py Sun May 17 18:11:02 2015 -0700 +++ b/contrib/check-code.py Sat May 16 14:31:03 2015 -0400 @@ -243,8 +243,8 @@ # (r'^\s*print\s+', "avoid using print in core and extensions"), (r'[\x80-\xff]', "non-ASCII character literal"), (r'("\')\.format\(', "str.format() not available in Python 2.4"), - (r'(? EOF $ cat > non-py24.py < # Using builtins that does not exist in Python 2.4 - > if any(): + > if True: > x = all() > y = format(x) > - > # Do not complain about our own definition - > def any(x): - > pass - > > # try/except/finally block does not exist in Python 2.4 > try: > pass @@ -85,19 +81,16 @@ ./quote.py:5: > '"""', 42+1, """and missing whitespace in expression - ./non-py24.py:2: - > if any(): - any/all/format not available in Python 2.4 ./non-py24.py:3: > x = all() - any/all/format not available in Python 2.4 + all/format not available in Python 2.4 ./non-py24.py:4: > y = format(x) - any/all/format not available in Python 2.4 - ./non-py24.py:28: + all/format not available in Python 2.4 + ./non-py24.py:24: > try: no yield inside try/finally in Python 2.4 - ./non-py24.py:33: + ./non-py24.py:29: > try: no yield inside try/finally in Python 2.4 ./classstyle.py:4: