mirror of https://github.com/python/cpython
heappop(): Use "while True" instead of "while 1".
This commit is contained in:
parent
d2cf1ab0e2
commit
a0b3a00bc5
|
@ -142,7 +142,7 @@ def heappop(heap):
|
|||
returnitem = heap[0]
|
||||
item = heap.pop()
|
||||
pos = 0
|
||||
while 1:
|
||||
while True:
|
||||
child2pos = (pos + 1) * 2
|
||||
child1pos = child2pos - 1
|
||||
if child2pos < endpos:
|
||||
|
|
Loading…
Reference in New Issue