Kaydet (Commit) 8dbbb969 authored tarafından Raymond Hettinger's avatar Raymond Hettinger

Add cautionary note on the use of PySequence_Fast_ITEMS.

üst feef51d9
......@@ -143,6 +143,10 @@ Sequence Protocol
Return the underlying array of PyObject pointers. Assumes that *o* was returned
by :cfunc:`PySequence_Fast` and *o* is not *NULL*.
Note, if a list gets resized, the reallocation may relocate the items array.
So, only use the underlying array pointer in contexts where the sequence
cannot change.
.. versionadded:: 2.4
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment