mirror of
https://github.com/python/cpython.git
synced 2025-07-08 03:45:36 +00:00
Implement and apply PEP 322, reverse iteration
This commit is contained in:
parent
f607fc5395
commit
85c20a41df
12 changed files with 198 additions and 9 deletions
|
@ -201,7 +201,7 @@ def _dist_try_harder(distname,version,id):
|
|||
if os.path.isdir('/usr/lib/setup'):
|
||||
# Check for slackware verson tag file (thanks to Greg Andruk)
|
||||
verfiles = os.listdir('/usr/lib/setup')
|
||||
for n in range(len(verfiles)-1, -1, -1):
|
||||
for n in reversed(xrange(len(verfiles))):
|
||||
if verfiles[n][:14] != 'slack-version-':
|
||||
del verfiles[n]
|
||||
if verfiles:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue