summaryrefslogtreecommitdiffstats
path: root/Tools/scripts/suff.py
diff options
context:
space:
mode:
authorAndrew M. Kuchling <amk@amk.ca>2003-05-13 18:14:25 (GMT)
committerAndrew M. Kuchling <amk@amk.ca>2003-05-13 18:14:25 (GMT)
commitac6df95d07aa3951f8bfc6febce132e09850db73 (patch)
tree5bc66133d5d093e099b622ac3cd35e216f60a389 /Tools/scripts/suff.py
parentbf1bef820c5af6b0a9a60abe1564ac35f036fdcb (diff)
downloadcpython-ac6df95d07aa3951f8bfc6febce132e09850db73.zip
cpython-ac6df95d07aa3951f8bfc6febce132e09850db73.tar.gz
cpython-ac6df95d07aa3951f8bfc6febce132e09850db73.tar.bz2
Fix use of 'file' as a variable name.
(I've tested the fixes, but please proofread anyway.)
Diffstat (limited to 'Tools/scripts/suff.py')
-rwxr-xr-xTools/scripts/suff.py14
1 files changed, 7 insertions, 7 deletions
diff --git a/Tools/scripts/suff.py b/Tools/scripts/suff.py
index e085cd0..ee7499f 100755
--- a/Tools/scripts/suff.py
+++ b/Tools/scripts/suff.py
@@ -9,21 +9,21 @@ import sys
def main():
files = sys.argv[1:]
suffixes = {}
- for file in files:
- suff = getsuffix(file)
+ for filename in files:
+ suff = getsuffix(filename)
if not suffixes.has_key(suff):
suffixes[suff] = []
- suffixes[suff].append(file)
+ suffixes[suff].append(filename)
keys = suffixes.keys()
keys.sort()
for suff in keys:
print `suff`, len(suffixes[suff])
-def getsuffix(file):
+def getsuffix(filename):
suff = ''
- for i in range(len(file)):
- if file[i] == '.':
- suff = file[i:]
+ for i in range(len(filename)):
+ if filename[i] == '.':
+ suff = filename[i:]
return suff
main()