mirror of
https://github.com/python/cpython.git
synced 2025-07-24 11:44:31 +00:00
Some new blood and some updated versions.
This commit is contained in:
parent
fdb8fb8b31
commit
64e736ba4e
7 changed files with 1105 additions and 14 deletions
|
@ -354,6 +354,8 @@ def normpath(path):
|
|||
while i < len(comps):
|
||||
if comps[i] == '.':
|
||||
del comps[i]
|
||||
while i < len(comps) and comps[i] == '':
|
||||
del comps[i]
|
||||
elif comps[i] == '..' and i > 0 and comps[i-1] not in ('', '..'):
|
||||
del comps[i-1:i+1]
|
||||
i = i-1
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue