[issue13274] heapq pure python version uses islice without guarding for negative counts
report at bugs.python.org
Sun Oct 30 22:38:16 CET 2011
Raymond Hettinger <raymond.hettinger at gmail.com> added the comment:
I went ahead an added the guards to the pure python code.
Still disagree with your assertion that non-cpython implementations were somehow broken when an undefined behavior was implemented in a different way -- nsmallest() and nlargest() have no guaranteed meaning for negative numbers.
Python tracker <report at bugs.python.org>
More information about the Python-bugs-list