[issue17670] Improve str.expandtabs() doc

2013-04-21 Thread Ned Deily
Changes by Ned Deily : -- resolution: -> fixed stage: commit review -> committed/rejected status: open -> closed type: enhancement -> ___ Python tracker ___ ___

[issue17670] Improve str.expandtabs() doc

2013-04-21 Thread Roundup Robot
Roundup Robot added the comment: New changeset 6a02d2af814f by Ned Deily in branch '2.7': Issue #17670: Provide an example of expandtabs() usage. http://hg.python.org/cpython/rev/6a02d2af814f New changeset 5b6ccab52a4d by Ned Deily in branch '3.3': Issue #17670: Provide an example of expandtabs(

[issue17670] Improve str.expandtabs() doc

2013-04-21 Thread Eli Bendersky
Eli Bendersky added the comment: LGTM! -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.or

[issue17670] Improve str.expandtabs() doc

2013-04-20 Thread Ned Deily
Changes by Ned Deily : Added file: http://bugs.python.org/file29957/issue17670_doc_rev_2.patch ___ Python tracker ___ ___ Python-bugs-list mai

[issue17670] Improve str.expandtabs() doc

2013-04-20 Thread Ned Deily
Ned Deily added the comment: Another round based on comments. I also just noticed that the current doc incorrectly claims that tabs are replaced by *zero* or more spaces. Return a copy of the string where all tab characters are replaced by one or more spaces, depending on the current co

[issue17670] Improve str.expandtabs() doc

2013-04-15 Thread Eli Bendersky
Eli Bendersky added the comment: It's better, although the distinction between "tab column" and "tab position" is not entirely clear. -- ___ Python tracker ___ _

[issue17670] Improve str.expandtabs() doc

2013-04-15 Thread Ned Deily
Ned Deily added the comment: Thanks for the suggested. Here's a revised wording and a slightly more legible example: Return a copy of the string where all tab characters are replaced by zero or more spaces, depending on the current tab column and the given tab size. Starting at the f

[issue17670] Improve str.expandtabs() doc

2013-04-13 Thread Ezio Melotti
Ezio Melotti added the comment: "This doesn’t understand other non-printing characters or escape sequences." This might also be improved. Does it mean that all characters are considered having len(c) == 1, even if they are not printable or escape sequence (and which escape sequences? \f, \v?)

[issue17670] Improve str.expandtabs() doc

2013-04-12 Thread Eli Bendersky
Eli Bendersky added the comment: I agree the doc could be clearer and Ned's example is very good. However I'd go one step forward and add a further elaboration of how the method works. This is the current doc (in default branch): Return a copy of the string where all tab characters are repla

[issue17670] Improve str.expandtabs() doc

2013-04-12 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- title: expandtabs() weirdness -> Improve str.expandtabs() doc ___ Python tracker ___ ___ Python-bugs-li