[issue13754] str.ljust and str.rjust do not exactly describes original string return
New submission from py.user <port139@yandex.ru>: http://docs.python.org/py3k/library/stdtypes.html#str.ljust str.ljust(width[, fillchar])¶ Return the string left justified in a string of length width. Padding is done using the specified fillchar (default is a space). The original string is returned if width is less than len(s). str.rjust(width[, fillchar])¶ Return the string right justified in a string of length width. Padding is done using the specified fillchar (default is a space). The original string is returned if width is less than len(s). "less than len(s)" -> "less than or equal to len(s)" ---------- assignee: docs@python components: Documentation messages: 151000 nosy: docs@python, py.user priority: normal severity: normal status: open title: str.ljust and str.rjust do not exactly describes original string return versions: Python 3.2 _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue13754> _______________________________________
py.user <port139@yandex.ru> added the comment: str.zfill also ---------- _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue13754> _______________________________________
Terry J. Reedy <tjreedy@udel.edu> added the comment: The short doc strings do not mention the issue either way. I think it ok to leave them as they are. While the claim is how the functions *should* operate, I verified that it is how they *do* operate in all three branches. ---------- assignee: docs@python -> terry.reedy keywords: +easy, patch nosy: +terry.reedy stage: -> needs patch versions: +Python 2.7, Python 3.3 _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue13754> _______________________________________
Roundup Robot <devnull@psf.upfronthosting.co.za> added the comment: New changeset 3aed8787ce5c by Terry Jan Reedy in branch '2.7': Closes #13754 String returned if less than *or equal to* x 3 http://hg.python.org/cpython/rev/3aed8787ce5c New changeset 3f2e5fd17b76 by Terry Jan Reedy in branch '3.2': #13754 String returned if less than *or equal to* x 3 http://hg.python.org/cpython/rev/3f2e5fd17b76 New changeset 0df85a2ebe4d by Terry Jan Reedy in branch 'default': Merge with 3.2 http://hg.python.org/cpython/rev/0df85a2ebe4d ---------- nosy: +python-dev resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue13754> _______________________________________
participants (3)
-
py.user
-
Roundup Robot
-
Terry J. Reedy