mirror of
https://github.com/python/cpython.git
synced 2025-07-19 01:05:26 +00:00
New == syntax
This commit is contained in:
parent
4d8e859e8f
commit
bdfcfccbe5
73 changed files with 419 additions and 391 deletions
|
@ -50,19 +50,19 @@ def skipfile(file):
|
|||
# Skip executables
|
||||
try:
|
||||
data = open(file, 'r').read(len(EXECMAGIC))
|
||||
if data = EXECMAGIC: return 1
|
||||
if data == EXECMAGIC: return 1
|
||||
except:
|
||||
pass
|
||||
return 0
|
||||
|
||||
def badprefix(file):
|
||||
for bad in badprefixes:
|
||||
if file[:len(bad)] = bad: return 1
|
||||
if file[:len(bad)] == bad: return 1
|
||||
return 0
|
||||
|
||||
def badsuffix(file):
|
||||
for bad in badsuffixes:
|
||||
if file[-len(bad):] = bad: return 1
|
||||
if file[-len(bad):] == bad: return 1
|
||||
return 0
|
||||
|
||||
def go(args):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue