mirror of
https://github.com/python/cpython.git
synced 2025-07-24 11:44:31 +00:00
#16518: use "bytes-like object" throughout the docs.
This commit is contained in:
parent
28faf03d44
commit
c228e96726
8 changed files with 24 additions and 28 deletions
|
@ -73,8 +73,8 @@ The module defines the following type:
|
|||
.. class:: array(typecode[, initializer])
|
||||
|
||||
A new array whose items are restricted by *typecode*, and initialized
|
||||
from the optional *initializer* value, which must be a list, object
|
||||
supporting the buffer interface, or iterable over elements of the
|
||||
from the optional *initializer* value, which must be a list, a
|
||||
:term:`bytes-like object`, or iterable over elements of the
|
||||
appropriate type.
|
||||
|
||||
If given a list or string, the initializer is passed to the new array's
|
||||
|
@ -91,7 +91,7 @@ Array objects support the ordinary sequence operations of indexing, slicing,
|
|||
concatenation, and multiplication. When using slice assignment, the assigned
|
||||
value must be an array object with the same type code; in all other cases,
|
||||
:exc:`TypeError` is raised. Array objects also implement the buffer interface,
|
||||
and may be used wherever buffer objects are supported.
|
||||
and may be used wherever :term:`bytes-like object`\ s are supported.
|
||||
|
||||
The following data items and methods are also supported:
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue