]> granicus.if.org Git - python/commitdiff
Issue #22575: Revise bytearray entry for 2.7.
authorTerry Jan Reedy <tjreedy@udel.edu>
Fri, 10 Oct 2014 17:02:55 +0000 (13:02 -0400)
committerTerry Jan Reedy <tjreedy@udel.edu>
Fri, 10 Oct 2014 17:02:55 +0000 (13:02 -0400)
Doc/library/functions.rst

index 82c1e64849a69cc7159e2b81f6e0835ade23a3d0..c4d1eaa40b115ab1e43b72886630a95064cdcbeb 100644 (file)
@@ -119,9 +119,9 @@ available.  They are listed here in alphabetical order.
    The optional *source* parameter can be used to initialize the array in a few
    different ways:
 
-   * If it is a *string*, you must also give the *encoding* (and optionally,
-     *errors*) parameters; :func:`bytearray` then converts the string to
-     bytes using :meth:`str.encode`.
+   * If it is *unicode*, you must also give the *encoding* (and optionally,
+     *errors*) parameters; :func:`bytearray` then converts the unicode to
+     bytes using :meth:`unicode.encode`.
 
    * If it is an *integer*, the array will have that size and will be
      initialized with null bytes.