[Python-3000-checkins] r63809 - in python/branches/py3k/Objects: bytearrayobject.c bytesobject.c unicodeobject.c

georg.brandl python-3000-checkins at python.org
Fri May 30 10:20:10 CEST 2008


Author: georg.brandl
Date: Fri May 30 10:20:09 2008
New Revision: 63809

Log:
Fix all return types for str/bytes/bytearray docstrings and make the wording more consistent.


Modified:
   python/branches/py3k/Objects/bytearrayobject.c
   python/branches/py3k/Objects/bytesobject.c
   python/branches/py3k/Objects/unicodeobject.c

Modified: python/branches/py3k/Objects/bytearrayobject.c
==============================================================================
--- python/branches/py3k/Objects/bytearrayobject.c	(original)
+++ python/branches/py3k/Objects/bytearrayobject.c	Fri May 30 10:20:09 2008
@@ -1081,7 +1081,7 @@
 }
 
 PyDoc_STRVAR(find__doc__,
-"B.find(sub [,start [,end]]) -> int\n\
+"B.find(sub[, start[, end]]) -> int\n\
 \n\
 Return the lowest index in B where subsection sub is found,\n\
 such that sub is contained within s[start,end].  Optional\n\
@@ -1099,7 +1099,7 @@
 }
 
 PyDoc_STRVAR(count__doc__,
-"B.count(sub [,start [,end]]) -> int\n\
+"B.count(sub[, start[, end]]) -> int\n\
 \n\
 Return the number of non-overlapping occurrences of subsection sub in\n\
 bytes B[start:end].  Optional arguments start and end are interpreted\n\
@@ -1132,7 +1132,7 @@
 
 
 PyDoc_STRVAR(index__doc__,
-"B.index(sub [,start [,end]]) -> int\n\
+"B.index(sub[, start[, end]]) -> int\n\
 \n\
 Like B.find() but raise ValueError when the subsection is not found.");
 
@@ -1152,7 +1152,7 @@
 
 
 PyDoc_STRVAR(rfind__doc__,
-"B.rfind(sub [,start [,end]]) -> int\n\
+"B.rfind(sub[, start[, end]]) -> int\n\
 \n\
 Return the highest index in B where subsection sub is found,\n\
 such that sub is contained within s[start,end].  Optional\n\
@@ -1171,7 +1171,7 @@
 
 
 PyDoc_STRVAR(rindex__doc__,
-"B.rindex(sub [,start [,end]]) -> int\n\
+"B.rindex(sub[, start[, end]]) -> int\n\
 \n\
 Like B.rfind() but raise ValueError when the subsection is not found.");
 
@@ -1258,7 +1258,7 @@
 
 
 PyDoc_STRVAR(startswith__doc__,
-"B.startswith(prefix [,start [,end]]) -> bool\n\
+"B.startswith(prefix[, start[, end]]) -> bool\n\
 \n\
 Return True if B starts with the specified prefix, False otherwise.\n\
 With optional start, test B beginning at that position.\n\
@@ -1298,7 +1298,7 @@
 }
 
 PyDoc_STRVAR(endswith__doc__,
-"B.endswith(suffix [,start [,end]]) -> bool\n\
+"B.endswith(suffix[, start[, end]]) -> bool\n\
 \n\
 Return True if B ends with the specified suffix, False otherwise.\n\
 With optional start, test B beginning at that position.\n\
@@ -2001,7 +2001,7 @@
     }
 
     if (to_len == 0) {
-        /* delete all occurances of 'from' bytes */
+        /* delete all occurrences of 'from' bytes */
         if (from_len == 1) {
             return replace_delete_single_character(
                     self, from_s[0], maxcount);
@@ -2037,7 +2037,7 @@
 
 
 PyDoc_STRVAR(replace__doc__,
-"B.replace(old, new[, count]) -> bytes\n\
+"B.replace(old, new[, count]) -> bytearray\n\
 \n\
 Return a copy of B with all occurrences of subsection\n\
 old replaced by new.  If the optional argument count is\n\
@@ -2187,7 +2187,7 @@
 }
 
 PyDoc_STRVAR(split__doc__,
-"B.split([sep[, maxsplit]]) -> list of bytearray\n\
+"B.split([sep[, maxsplit]]) -> list of bytearrays\n\
 \n\
 Return a list of the sections in B, using sep as the delimiter.\n\
 If sep is not given, B is split on ASCII whitespace characters\n\
@@ -2294,7 +2294,7 @@
 PyDoc_STRVAR(partition__doc__,
 "B.partition(sep) -> (head, sep, tail)\n\
 \n\
-Searches for the separator sep in B, and returns the part before it,\n\
+Search for the separator sep in B, and return the part before it,\n\
 the separator itself, and the part after it.  If the separator is not\n\
 found, returns B and two empty bytearray objects.");
 
@@ -2321,8 +2321,8 @@
 PyDoc_STRVAR(rpartition__doc__,
 "B.rpartition(sep) -> (tail, sep, head)\n\
 \n\
-Searches for the separator sep in B, starting at the end of B,\n\
-and returns the part before it, the separator itself, and the\n\
+Search for the separator sep in B, starting at the end of B,\n\
+and return the part before it, the separator itself, and the\n\
 part after it.  If the separator is not found, returns two empty\n\
 bytearray objects and B.");
 
@@ -2421,7 +2421,7 @@
 }
 
 PyDoc_STRVAR(rsplit__doc__,
-"B.rsplit(sep[, maxsplit]) -> list of bytearray\n\
+"B.rsplit(sep[, maxsplit]) -> list of bytearrays\n\
 \n\
 Return a list of the sections in B, using sep as the delimiter,\n\
 starting at the end of B and working to the front.\n\
@@ -2578,7 +2578,7 @@
 }
 
 PyDoc_STRVAR(extend__doc__,
-"B.extend(iterable int) -> None\n\
+"B.extend(iterable_of_ints) -> None\n\
 \n\
 Append all the elements from the iterator or sequence to the\n\
 end of B.");
@@ -2684,7 +2684,7 @@
 PyDoc_STRVAR(remove__doc__,
 "B.remove(int) -> None\n\
 \n\
-Remove the first occurance of a value in B.");
+Remove the first occurrence of a value in B.");
 static PyObject *
 bytes_remove(PyByteArrayObject *self, PyObject *arg)
 {
@@ -2735,7 +2735,8 @@
 PyDoc_STRVAR(strip__doc__,
 "B.strip([bytes]) -> bytearray\n\
 \n\
-Strip leading and trailing bytes contained in the argument.\n\
+Strip leading and trailing bytes contained in the argument\n\
+and return the result as a new bytearray.\n\
 If the argument is omitted, strip ASCII whitespace.");
 static PyObject *
 bytes_strip(PyByteArrayObject *self, PyObject *args)
@@ -2771,7 +2772,8 @@
 PyDoc_STRVAR(lstrip__doc__,
 "B.lstrip([bytes]) -> bytearray\n\
 \n\
-Strip leading bytes contained in the argument.\n\
+Strip leading bytes contained in the argument\n\
+and return the result as a new bytearray.\n\
 If the argument is omitted, strip leading ASCII whitespace.");
 static PyObject *
 bytes_lstrip(PyByteArrayObject *self, PyObject *args)
@@ -2804,7 +2806,8 @@
 PyDoc_STRVAR(rstrip__doc__,
 "B.rstrip([bytes]) -> bytearray\n\
 \n\
-Strip trailing bytes contained in the argument.\n\
+Strip trailing bytes contained in the argument\n\
+and return the result as a new bytearray.\n\
 If the argument is omitted, strip trailing ASCII whitespace.");
 static PyObject *
 bytes_rstrip(PyByteArrayObject *self, PyObject *args)
@@ -2835,9 +2838,9 @@
 }
 
 PyDoc_STRVAR(decode_doc,
-"B.decode([encoding[, errors]]) -> unicode object.\n\
+"B.decode([encoding[, errors]]) -> str\n\
 \n\
-Decodes B using the codec registered for encoding. encoding defaults\n\
+Decode B using the codec registered for encoding. encoding defaults\n\
 to the default encoding. errors may be given to set a different error\n\
 handling scheme.  Default is 'strict' meaning that encoding errors raise\n\
 a UnicodeDecodeError.  Other possible values are 'ignore' and 'replace'\n\
@@ -2860,7 +2863,7 @@
 PyDoc_STRVAR(alloc_doc,
 "B.__alloc__() -> int\n\
 \n\
-Returns the number of bytes actually allocated.");
+Return the number of bytes actually allocated.");
 
 static PyObject *
 bytes_alloc(PyByteArrayObject *self)
@@ -2869,9 +2872,10 @@
 }
 
 PyDoc_STRVAR(join_doc,
-"B.join(iterable_of_bytes) -> bytes\n\
+"B.join(iterable_of_bytes) -> bytearray\n\
 \n\
-Concatenates any number of bytearray objects, with B in between each pair.");
+Concatenate any number of bytes/bytearray objects, with B\n\
+in between each pair, and return the result as a new bytearray.");
 
 static PyObject *
 bytes_join(PyByteArrayObject *self, PyObject *it)
@@ -2944,7 +2948,7 @@
 }
 
 PyDoc_STRVAR(fromhex_doc,
-"bytearray.fromhex(string) -> bytearray\n\
+"bytearray.fromhex(string) -> bytearray (static method)\n\
 \n\
 Create a bytearray object from a string of hexadecimal numbers.\n\
 Spaces between two numbers are accepted.\n\
@@ -3121,10 +3125,10 @@
 };
 
 PyDoc_STRVAR(bytes_doc,
-"bytearray(iterable_of_ints) -> bytearray.\n\
-bytearray(string, encoding[, errors]) -> bytearray.\n\
-bytearray(bytes_or_bytearray) -> mutable copy of bytes_or_bytearray.\n\
-bytearray(memory_view) -> bytearray.\n\
+"bytearray(iterable_of_ints) -> bytearray\n\
+bytearray(string, encoding[, errors]) -> bytearray\n\
+bytearray(bytes_or_bytearray) -> mutable copy of bytes_or_bytearray\n\
+bytearray(memory_view) -> bytearray\n\
 \n\
 Construct an mutable bytearray object from:\n\
   - an iterable yielding integers in range(256)\n\
@@ -3132,7 +3136,7 @@
   - a bytes or a bytearray object\n\
   - any object implementing the buffer API.\n\
 \n\
-bytearray(int) -> bytearray.\n\
+bytearray(int) -> bytearray\n\
 \n\
 Construct a zero-initialized bytearray of the given length.");
 

Modified: python/branches/py3k/Objects/bytesobject.c
==============================================================================
--- python/branches/py3k/Objects/bytesobject.c	(original)
+++ python/branches/py3k/Objects/bytesobject.c	Fri May 30 10:20:09 2008
@@ -1208,7 +1208,7 @@
 PyDoc_STRVAR(partition__doc__,
 "B.partition(sep) -> (head, sep, tail)\n\
 \n\
-Searches for the separator sep in B, and returns the part before it,\n\
+Search for the separator sep in B, and return the part before it,\n\
 the separator itself, and the part after it.  If the separator is not\n\
 found, returns B and two empty bytes objects.");
 
@@ -1235,8 +1235,8 @@
 PyDoc_STRVAR(rpartition__doc__,
 "B.rpartition(sep) -> (tail, sep, head)\n\
 \n\
-Searches for the separator sep in B, starting at the end of B,\n\
-and returns the part before it, the separator itself, and the\n\
+Search for the separator sep in B, starting at the end of B,\n\
+and return the part before it, the separator itself, and the\n\
 part after it.  If the separator is not found, returns two empty\n\
 bytes objects and B.");
 
@@ -1423,7 +1423,7 @@
 PyDoc_STRVAR(join__doc__,
 "B.join(iterable_of_bytes) -> bytes\n\
 \n\
-Concatenates any number of bytes objects, with B in between each pair.\n\
+Concatenate any number of bytes objects, with B in between each pair.\n\
 Example: b'.'.join([b'ab', b'pq', b'rs']) -> b'ab.pq.rs'.");
 
 static PyObject *
@@ -1583,7 +1583,7 @@
 
 
 PyDoc_STRVAR(find__doc__,
-"B.find(sub [,start [,end]]) -> int\n\
+"B.find(sub[, start[, end]]) -> int\n\
 \n\
 Return the lowest index in S where substring sub is found,\n\
 such that sub is contained within s[start:end].  Optional\n\
@@ -1602,7 +1602,7 @@
 
 
 PyDoc_STRVAR(index__doc__,
-"B.index(sub [,start [,end]]) -> int\n\
+"B.index(sub[, start[, end]]) -> int\n\
 \n\
 Like B.find() but raise ValueError when the substring is not found.");
 
@@ -1622,7 +1622,7 @@
 
 
 PyDoc_STRVAR(rfind__doc__,
-"B.rfind(sub [,start [,end]]) -> int\n\
+"B.rfind(sub[, start[, end]]) -> int\n\
 \n\
 Return the highest index in B where substring sub is found,\n\
 such that sub is contained within s[start:end].  Optional\n\
@@ -1641,7 +1641,7 @@
 
 
 PyDoc_STRVAR(rindex__doc__,
-"B.rindex(sub [,start [,end]]) -> int\n\
+"B.rindex(sub[, start[, end]]) -> int\n\
 \n\
 Like B.rfind() but raise ValueError when the substring is not found.");
 
@@ -1792,7 +1792,7 @@
 
 
 PyDoc_STRVAR(count__doc__,
-"B.count(sub [,start [,end]]) -> int\n\
+"B.count(sub[, start[, end]]) -> int\n\
 \n\
 Return the number of non-overlapping occurrences of substring sub in\n\
 string S[start:end].  Optional arguments start and end are interpreted\n\
@@ -2494,7 +2494,7 @@
 	}
 
 	if (to_len == 0) {
-		/* delete all occurances of 'from' string */
+		/* delete all occurrences of 'from' string */
 		if (from_len == 1) {
 			return replace_delete_single_character(
 				self, from_s[0], maxcount);
@@ -2612,7 +2612,7 @@
 
 
 PyDoc_STRVAR(startswith__doc__,
-"B.startswith(prefix [,start [,end]]) -> bool\n\
+"B.startswith(prefix[, start[, end]]) -> bool\n\
 \n\
 Return True if B starts with the specified prefix, False otherwise.\n\
 With optional start, test B beginning at that position.\n\
@@ -2653,7 +2653,7 @@
 
 
 PyDoc_STRVAR(endswith__doc__,
-"B.endswith(suffix [,start [,end]]) -> bool\n\
+"B.endswith(suffix[, start[, end]]) -> bool\n\
 \n\
 Return True if B ends with the specified suffix, False otherwise.\n\
 With optional start, test B beginning at that position.\n\
@@ -2694,9 +2694,9 @@
 
 
 PyDoc_STRVAR(decode__doc__,
-"B.decode([encoding[, errors]]) -> object\n\
+"B.decode([encoding[, errors]]) -> str\n\
 \n\
-Decodes S using the codec registered for encoding. encoding defaults\n\
+Decode S using the codec registered for encoding. encoding defaults\n\
 to the default encoding. errors may be given to set a different error\n\
 handling scheme.  Default is 'strict' meaning that encoding errors raise\n\
 a UnicodeDecodeError.  Other possible values are 'ignore' and 'replace'\n\
@@ -3027,10 +3027,10 @@
 }
 
 PyDoc_STRVAR(string_doc,
-"bytes(iterable_of_ints) -> bytes.\n\
+"bytes(iterable_of_ints) -> bytes\n\
 bytes(string, encoding[, errors]) -> bytes\n\
-bytes(bytes_or_buffer) -> immutable copy of bytes_or_buffer.\n\
-bytes(memory_view) -> bytes.\n\
+bytes(bytes_or_buffer) -> immutable copy of bytes_or_buffer\n\
+bytes(memory_view) -> bytes\n\
 \n\
 Construct an immutable array of bytes from:\n\
   - an iterable yielding integers in range(256)\n\

Modified: python/branches/py3k/Objects/unicodeobject.c
==============================================================================
--- python/branches/py3k/Objects/unicodeobject.c	(original)
+++ python/branches/py3k/Objects/unicodeobject.c	Fri May 30 10:20:09 2008
@@ -6167,7 +6167,7 @@
 /* --- Unicode Object Methods --------------------------------------------- */
 
 PyDoc_STRVAR(title__doc__,
-"S.title() -> unicode\n\
+"S.title() -> str\n\
 \n\
 Return a titlecased version of S, i.e. words start with title case\n\
 characters, all remaining cased characters have lower case.");
@@ -6179,7 +6179,7 @@
 }
 
 PyDoc_STRVAR(capitalize__doc__,
-"S.capitalize() -> unicode\n\
+"S.capitalize() -> str\n\
 \n\
 Return a capitalized version of S, i.e. make the first character\n\
 have upper case.");
@@ -6192,7 +6192,7 @@
 
 #if 0
 PyDoc_STRVAR(capwords__doc__,
-"S.capwords() -> unicode\n\
+"S.capwords() -> str\n\
 \n\
 Apply .capitalize() to all words in S and return the result with\n\
 normalized whitespace (all whitespace strings are replaced by ' ').");
@@ -6256,7 +6256,7 @@
 }
 
 PyDoc_STRVAR(center__doc__,
-"S.center(width[, fillchar]) -> unicode\n\
+"S.center(width[, fillchar]) -> str\n\
 \n\
 Return S centered in a Unicode string of length width. Padding is\n\
 done using the specified fill character (default is a space)");
@@ -6601,9 +6601,9 @@
 }
 
 PyDoc_STRVAR(encode__doc__,
-"S.encode([encoding[,errors]]) -> string or unicode\n\
+"S.encode([encoding[, errors]]) -> bytes\n\
 \n\
-Encodes S using the codec registered for encoding. encoding defaults\n\
+Encode S using the codec registered for encoding. encoding defaults\n\
 to the default encoding. errors may be given to set a different error\n\
 handling scheme. Default is 'strict' meaning that encoding errors raise\n\
 a UnicodeEncodeError. Other possible values are 'ignore', 'replace' and\n\
@@ -6637,7 +6637,7 @@
 }
 
 PyDoc_STRVAR(expandtabs__doc__,
-"S.expandtabs([tabsize]) -> unicode\n\
+"S.expandtabs([tabsize]) -> str\n\
 \n\
 Return a copy of S where all tab characters are expanded using spaces.\n\
 If tabsize is not given, a tab size of 8 characters is assumed.");
@@ -6724,7 +6724,7 @@
 }
 
 PyDoc_STRVAR(find__doc__,
-"S.find(sub [,start [,end]]) -> int\n\
+"S.find(sub[, start[, end]]) -> int\n\
 \n\
 Return the lowest index in S where substring sub is found,\n\
 such that sub is contained within s[start:end].  Optional\n\
@@ -6789,7 +6789,7 @@
 }
 
 PyDoc_STRVAR(index__doc__,
-"S.index(sub [,start [,end]]) -> int\n\
+"S.index(sub[, start[, end]]) -> int\n\
 \n\
 Like S.find() but raise ValueError when the substring is not found.");
 
@@ -7152,7 +7152,7 @@
 }
 
 PyDoc_STRVAR(join__doc__,
-"S.join(sequence) -> unicode\n\
+"S.join(sequence) -> str\n\
 \n\
 Return a string which is the concatenation of the strings in the\n\
 sequence.  The separator between elements is S.");
@@ -7170,7 +7170,7 @@
 }
 
 PyDoc_STRVAR(ljust__doc__,
-"S.ljust(width[, fillchar]) -> int\n\
+"S.ljust(width[, fillchar]) -> str\n\
 \n\
 Return S left justified in a Unicode string of length width. Padding is\n\
 done using the specified fill character (default is a space).");
@@ -7193,7 +7193,7 @@
 }
 
 PyDoc_STRVAR(lower__doc__,
-"S.lower() -> unicode\n\
+"S.lower() -> str\n\
 \n\
 Return a copy of the string S converted to lowercase.");
 
@@ -7302,7 +7302,7 @@
 
 
 PyDoc_STRVAR(strip__doc__,
-"S.strip([chars]) -> unicode\n\
+"S.strip([chars]) -> str\n\
 \n\
 Return a copy of the string S with leading and trailing\n\
 whitespace removed.\n\
@@ -7320,7 +7320,7 @@
 
 
 PyDoc_STRVAR(lstrip__doc__,
-"S.lstrip([chars]) -> unicode\n\
+"S.lstrip([chars]) -> str\n\
 \n\
 Return a copy of the string S with leading whitespace removed.\n\
 If chars is given and not None, remove characters in chars instead.\n\
@@ -7337,7 +7337,7 @@
 
 
 PyDoc_STRVAR(rstrip__doc__,
-"S.rstrip([chars]) -> unicode\n\
+"S.rstrip([chars]) -> str\n\
 \n\
 Return a copy of the string S with trailing whitespace removed.\n\
 If chars is given and not None, remove characters in chars instead.\n\
@@ -7444,7 +7444,7 @@
 }
 
 PyDoc_STRVAR(replace__doc__,
-"S.replace (old, new[, maxsplit]) -> unicode\n\
+"S.replace (old, new[, maxsplit]) -> str\n\
 \n\
 Return a copy of S with all occurrences of substring\n\
 old replaced by new.  If the optional argument maxsplit is\n\
@@ -7616,7 +7616,7 @@
 }
 
 PyDoc_STRVAR(rfind__doc__,
-"S.rfind(sub [,start [,end]]) -> int\n\
+"S.rfind(sub[, start[, end]]) -> int\n\
 \n\
 Return the highest index in S where substring sub is found,\n\
 such that sub is contained within s[start:end].  Optional\n\
@@ -7647,7 +7647,7 @@
 }
 
 PyDoc_STRVAR(rindex__doc__,
-"S.rindex(sub [,start [,end]]) -> int\n\
+"S.rindex(sub[, start[, end]]) -> int\n\
 \n\
 Like S.rfind() but raise ValueError when the substring is not found.");
 
@@ -7678,7 +7678,7 @@
 }
 
 PyDoc_STRVAR(rjust__doc__,
-"S.rjust(width[, fillchar]) -> unicode\n\
+"S.rjust(width[, fillchar]) -> str\n\
 \n\
 Return S right justified in a Unicode string of length width. Padding is\n\
 done using the specified fill character (default is a space).");
@@ -7725,7 +7725,7 @@
 }
 
 PyDoc_STRVAR(split__doc__,
-"S.split([sep [,maxsplit]]) -> list of strings\n\
+"S.split([sep[, maxsplit]]) -> list of strings\n\
 \n\
 Return a list of the words in S, using sep as the\n\
 delimiter string.  If maxsplit is given, at most maxsplit\n\
@@ -7808,7 +7808,7 @@
 PyDoc_STRVAR(partition__doc__,
 "S.partition(sep) -> (head, sep, tail)\n\
 \n\
-Searches for the separator sep in S, and returns the part before it,\n\
+Search for the separator sep in S, and return the part before it,\n\
 the separator itself, and the part after it.  If the separator is not\n\
 found, returns S and two empty strings.");
 
@@ -7821,7 +7821,7 @@
 PyDoc_STRVAR(rpartition__doc__,
 "S.rpartition(sep) -> (tail, sep, head)\n\
 \n\
-Searches for the separator sep in S, starting at the end of S, and returns\n\
+Search for the separator sep in S, starting at the end of S, and return\n\
 the part before it, the separator itself, and the part after it.  If the\n\
 separator is not found, returns two empty strings and S.");
 
@@ -7856,7 +7856,7 @@
 }
 
 PyDoc_STRVAR(rsplit__doc__,
-"S.rsplit([sep [,maxsplit]]) -> list of strings\n\
+"S.rsplit([sep[, maxsplit]]) -> list of strings\n\
 \n\
 Return a list of the words in S, using sep as the\n\
 delimiter string, starting at the end of the string and\n\
@@ -7912,7 +7912,7 @@
 }
 
 PyDoc_STRVAR(swapcase__doc__,
-"S.swapcase() -> unicode\n\
+"S.swapcase() -> str\n\
 \n\
 Return a copy of S with uppercase characters converted to lowercase\n\
 and vice versa.");
@@ -8027,7 +8027,7 @@
 }
 
 PyDoc_STRVAR(translate__doc__,
-"S.translate(table) -> unicode\n\
+"S.translate(table) -> str\n\
 \n\
 Return a copy of the string S, where all characters have been mapped\n\
 through the given translation table, which must be a mapping of\n\
@@ -8042,7 +8042,7 @@
 }
 
 PyDoc_STRVAR(upper__doc__,
-"S.upper() -> unicode\n\
+"S.upper() -> str\n\
 \n\
 Return a copy of S converted to uppercase.");
 
@@ -8053,7 +8053,7 @@
 }
 
 PyDoc_STRVAR(zfill__doc__,
-"S.zfill(width) -> unicode\n\
+"S.zfill(width) -> str\n\
 \n\
 Pad a numeric string x with zeros on the left, to fill a field\n\
 of the specified width. The string x is never truncated.");
@@ -8198,12 +8198,12 @@
 #include "stringlib/string_format.h"
 
 PyDoc_STRVAR(format__doc__,
-"S.format(*args, **kwargs) -> unicode\n\
+"S.format(*args, **kwargs) -> str\n\
 \n\
 ");
 
 PyDoc_STRVAR(p_format__doc__,
-"S.__format__(format_spec) -> unicode\n\
+"S.__format__(format_spec) -> str\n\
 \n\
 ");
 
@@ -9108,7 +9108,7 @@
 }
 
 PyDoc_STRVAR(unicode_doc,
-"str(string [, encoding[, errors]]) -> object\n\
+"str(string[, encoding[, errors]]) -> str\n\
 \n\
 Create a new string object from the given encoded string.\n\
 encoding defaults to the current default string encoding.\n\


More information about the Python-3000-checkins mailing list