From 10a1cdfdb298b656dbfaaaecffb437d1a0b6ece9 Mon Sep 17 00:00:00 2001 From: CuriousLearner Date: Sat, 18 Feb 2017 17:31:31 +0530 Subject: [PATCH 1/5] bpo-22702: Improves documentation for str.join method --- Doc/library/stdtypes.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Doc/library/stdtypes.rst b/Doc/library/stdtypes.rst index d13fc3d9208d34..58ee6a3f6bd413 100644 --- a/Doc/library/stdtypes.rst +++ b/Doc/library/stdtypes.rst @@ -1720,9 +1720,9 @@ expression support in the :mod:`re` module). .. method:: str.join(iterable) Return a string which is the concatenation of the strings in the - :term:`iterable` *iterable*. A :exc:`TypeError` will be raised if there are - any non-string values in *iterable*, including :class:`bytes` objects. The - separator between elements is the string providing this method. + :term:`iterable` separated by the string ``str`` provided in this method. A + :exc:`TypeError` will be raised if there are any non-string values in + *iterable*, including :class:`bytes` objects. .. method:: str.ljust(width[, fillchar]) From 2ab7eb77ba158b62a15760f50f2106cf590fe5c4 Mon Sep 17 00:00:00 2001 From: CuriousLearner Date: Sun, 19 Feb 2017 15:41:50 +0530 Subject: [PATCH 2/5] Address review comments for str.join documentation --- Doc/library/stdtypes.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Doc/library/stdtypes.rst b/Doc/library/stdtypes.rst index 58ee6a3f6bd413..ab7ec9873fd6c8 100644 --- a/Doc/library/stdtypes.rst +++ b/Doc/library/stdtypes.rst @@ -1720,9 +1720,9 @@ expression support in the :mod:`re` module). .. method:: str.join(iterable) Return a string which is the concatenation of the strings in the - :term:`iterable` separated by the string ``str`` provided in this method. A - :exc:`TypeError` will be raised if there are any non-string values in - *iterable*, including :class:`bytes` objects. + :term:`iterable`. A :exc:`TypeError` will be raised if there are + any non-string values in *iterable*, including :class:`bytes` objects. + The separator between elements is the string providing this method. .. method:: str.ljust(width[, fillchar]) From 27b378811f7a05e5ad6cd1d10e710f91a44a18b2 Mon Sep 17 00:00:00 2001 From: CuriousLearner Date: Wed, 12 Apr 2017 21:11:19 +0530 Subject: [PATCH 3/5] Addresses review comments for str.join method documentation --- Doc/library/stdtypes.rst | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/Doc/library/stdtypes.rst b/Doc/library/stdtypes.rst index ab7ec9873fd6c8..c244b85af1879a 100644 --- a/Doc/library/stdtypes.rst +++ b/Doc/library/stdtypes.rst @@ -1719,10 +1719,10 @@ expression support in the :mod:`re` module). .. method:: str.join(iterable) - Return a string which is the concatenation of the strings in the - :term:`iterable`. A :exc:`TypeError` will be raised if there are - any non-string values in *iterable*, including :class:`bytes` objects. - The separator between elements is the string providing this method. + Return a string which is the concatenation of the strings in *iterable*. + A :exc:`TypeError` will be raised if there are any non-string values in + *iterable*, including :class:`bytes` objects. The separator between + elements is the string providing this method. .. method:: str.ljust(width[, fillchar]) @@ -2547,11 +2547,11 @@ arbitrary binary data. bytearray.join(iterable) Return a bytes or bytearray object which is the concatenation of the - binary data sequences in the :term:`iterable` *iterable*. A - :exc:`TypeError` will be raised if there are any values in *iterable* - that are not :term:`bytes-like objects `, including - :class:`str` objects. The separator between elements is the contents - of the bytes or bytearray object providing this method. + binary data sequences in the *iterable*. A :exc:`TypeError` will be + raised if there are any values in *iterable* that are not + :term:`bytes-like objects `, including :class:`str` + objects. The separator between elements is the contents of the bytes or + bytearray object providing this method. .. staticmethod:: bytes.maketrans(from, to) From c243c43f4aed2a4306da03d4b2c5057e5804e1e0 Mon Sep 17 00:00:00 2001 From: CuriousLearner Date: Thu, 13 Apr 2017 21:58:25 +0530 Subject: [PATCH 4/5] Minor fix addressing review comments to str.join method --- Doc/library/stdtypes.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/library/stdtypes.rst b/Doc/library/stdtypes.rst index c244b85af1879a..4fda2c444df95e 100644 --- a/Doc/library/stdtypes.rst +++ b/Doc/library/stdtypes.rst @@ -1721,7 +1721,7 @@ expression support in the :mod:`re` module). Return a string which is the concatenation of the strings in *iterable*. A :exc:`TypeError` will be raised if there are any non-string values in - *iterable*, including :class:`bytes` objects. The separator between + *iterable*, including :class:`bytes` objects. The separator between elements is the string providing this method. From 24fc04a63c33b75dcb1f7b53e64b096284254c0f Mon Sep 17 00:00:00 2001 From: CuriousLearner Date: Wed, 10 May 2017 16:58:36 +0530 Subject: [PATCH 5/5] Minor fix to bytearray.join() documentation addressing review comments --- Doc/library/stdtypes.rst | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Doc/library/stdtypes.rst b/Doc/library/stdtypes.rst index 4fda2c444df95e..71026370be8051 100644 --- a/Doc/library/stdtypes.rst +++ b/Doc/library/stdtypes.rst @@ -2547,10 +2547,10 @@ arbitrary binary data. bytearray.join(iterable) Return a bytes or bytearray object which is the concatenation of the - binary data sequences in the *iterable*. A :exc:`TypeError` will be - raised if there are any values in *iterable* that are not - :term:`bytes-like objects `, including :class:`str` - objects. The separator between elements is the contents of the bytes or + binary data sequences in *iterable*. A :exc:`TypeError` will be raised + if there are any values in *iterable* that are not :term:`bytes-like + objects `, including :class:`str` objects. The + separator between elements is the contents of the bytes or bytearray object providing this method.