[issue15812] inspect.getframeinfo() cannot show first line
Serhiy Storchaka
report at bugs.python.org
Mon Jan 2 01:36:36 EST 2017
Serhiy Storchaka added the comment:
start is bounded to 0 twice.
start = max(start, 0)
start = max(0, min(start, len(lines) - context))
The first line can be just removed. Or two above lines can be rewritten as:
start = min(start, len(lines) - context)
start = max(start, 0)
----------
nosy: +serhiy.storchaka
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue15812>
_______________________________________
More information about the Python-bugs-list
mailing list