Author: christian.heimes
Date: Sat Nov 3 15:28:58 2007
New Revision: 58828
Modified:
python/branches/py3k-pep3137/Doc/library/array.rst
Log:
Updated documentation of the array type's initializer.
Modified: python/branches/py3k-pep3137/Doc/library/array.rst
==============================================================================
--- python/branches/py3k-pep3137/Doc/library/array.rst (original)
+++ python/branches/py3k-pep3137/Doc/library/array.rst Sat Nov 3 15:28:58 2007
@@ -56,8 +56,9 @@
.. function:: array(typecode[, initializer])
Return a new array whose items are restricted by *typecode*, and initialized
- from the optional *initializer* value, which must be a list, string, or
iterable
- over elements of the appropriate type.
+ from the optional *initializer* value, which must be a list, object
+ supporting the buffer interface, or iterable over elements of the
+ appropriate type.
If given a list or string, the initializer is passed to the new array's
:meth:`fromlist`, :meth:`fromstring`, or :meth:`fromunicode` method (see
below)
@@ -69,6 +70,10 @@
Obsolete alias for :func:`array`.
+.. data:: typecodes
+
+ A string with all available type codes.
+
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,
_______________________________________________
Python-3000-checkins mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-3000-checkins