[issue30620] textwrap: dedent contains logic that can never execute

2017-06-15 Thread Mariatta Wijaya
Changes by Mariatta Wijaya : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ __

[issue30620] textwrap: dedent contains logic that can never execute

2017-06-15 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset 7a801839e9a88bdcac5aaab494b532230fcf7caa by Mariatta (Jonathan Eunice) in branch 'master': bpo-30620: Remove dead lines from textwrap.dedent (GH-2064) https://github.com/python/cpython/commit/7a801839e9a88bdcac5aaab494b532230fcf7caa --

[issue30620] textwrap: dedent contains logic that can never execute

2017-06-11 Thread Mariatta Wijaya
Changes by Mariatta Wijaya : -- stage: -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https:/

[issue30620] textwrap: dedent contains logic that can never execute

2017-06-11 Thread Emily Morehouse
Emily Morehouse added the comment: Jonathan, could you improve the comments for the dedent function? You have a great understanding of the logic flow from your proof and it would be beneficial to document this to avoid future confusion. Specifically, it should be clear that Clause 2 inherently

[issue30620] textwrap: dedent contains logic that can never execute

2017-06-11 Thread Raymond Hettinger
Changes by Raymond Hettinger : -- assignee: -> emilyemorehouse ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue30620] textwrap: dedent contains logic that can never execute

2017-06-11 Thread Emily Morehouse
Emily Morehouse added the comment: The logic in your proof is certainly sound. The only time that the else statement within Clause 4 (to use terminology from the proof) would execute is either 1) if margin is equal to indent, which is handled in Clause 2, or 2) if the margin is None, whic

[issue30620] textwrap: dedent contains logic that can never execute

2017-06-09 Thread Jonathan Eunice
Changes by Jonathan Eunice : -- pull_requests: +2126 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://ma

[issue30620] textwrap: dedent contains logic that can never execute

2017-06-09 Thread Jonathan Eunice
New submission from Jonathan Eunice: textwrap.dedent contains a bit of code that appears logical at first blush, but in fact can never execute under any input conditions. Not only are the lines "dead code," they are the only thing (i.e. only non-debugging lines) now standing in the way of text