Message357631
Although the implementation of the heapq.merge function uses an underlying heap structure, its behavior centers on iterators. For this reason, I believe there should either be an alias to this function in the itertools module or at least a recipe in the itertools docs describing the use of heapq.merge.
Furthermore, I have an implementation (attached) of heapq.merge that is twice as fast for two iterables (as used in mergesort and other common cases), and is faster for up to 6 or 7 iterables. I think it would be nice to special-case this for small numbers of iterables for this significant speedup. |
|
Date |
User |
Action |
Args |
2019-11-29 02:44:21 | Dennis Sweeney | set | recipients:
+ Dennis Sweeney |
2019-11-29 02:44:21 | Dennis Sweeney | set | messageid: <1574995461.08.0.901532396583.issue38938@roundup.psfhosted.org> |
2019-11-29 02:44:20 | Dennis Sweeney | link | issue38938 messages |
2019-11-29 02:44:20 | Dennis Sweeney | create | |
|