[Python-Dev] collections.sortedtree
Kristján Valur Jónsson
kristjan at ccpgames.com
Thu Mar 27 10:25:05 CET 2014
True.
I've long since added a heapdel() to our local fork.
a heappop(idx=0) extension would do the same
I can provide a patch if there is interest.
K
Ideally, I think you should be able to replace the cancelled item with
the last item in the heap and then fix the heap in logarithmic time,
but the heapq API doesn't seem to provide a way to do this.
Regards
Antoine.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20140327/847face7/attachment.html>
More information about the Python-Dev
mailing list