[issue34210] Small improvements in heapq (refactoring)

2018-07-25 Thread Raymond Hettinger
Raymond Hettinger added the comment: Additional notes: * reversed() is preferred over the range(n-1, -1, -1) style both for clarity and speed. If reversed is slower, then it would be mean that something is sly wrong with range.__reversed__ which should be able to iterate backwards as fast

[issue34210] Small improvements in heapq (refactoring)

2018-07-24 Thread Raymond Hettinger
Raymond Hettinger added the comment: Sorry, I don't consider any of these changes to be improvements and some make the code worse in some ways, overriding intentional coding decisions. -- nosy: +rhettinger resolution: -> rejected stage: patch review -> resolved status: open -> closed

[issue34210] Small improvements in heapq (refactoring)

2018-07-24 Thread Alexander Marshalov
Change by Alexander Marshalov <_...@marshalov.org>: -- title: Small improvements in heapq (refatoring) -> Small improvements in heapq (refactoring) ___ Python tracker ___