New submission from Vikash Raja Samuel Selvin <selvin.samu...@gmail.com>:
>>> bisect.bisect_right(l, 5.1, -1) Traceback (most recent call last): File "<stdin>", line 1, in <module> ValueError: lo must be non-negative >>> l [0, 1, 2, 3, 4, 5, 5, 5, 6, 7, 8, 9] >>> bisect.bisect_right(l, 5.1, 0, -2) 0 In order to be consistent with the behavior for lo and not return wrong answers when hi is provided with a negative value ---------- components: Library (Lib) messages: 370416 nosy: samuel72 priority: normal severity: normal status: open title: hi param in bisect module should not accept negative values type: behavior _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue40832> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com