]> granicus.if.org Git - python/commitdiff
Issue #23352: Document that Py_buffer.suboffsets must be NULL if no suboffsets
authorStefan Krah <skrah@bytereef.org>
Sun, 1 Feb 2015 18:42:12 +0000 (19:42 +0100)
committerStefan Krah <skrah@bytereef.org>
Sun, 1 Feb 2015 18:42:12 +0000 (19:42 +0100)
are required.

Doc/c-api/buffer.rst

index 230c6a957f388b60f7714c37e3aab039e6b9bbaf..9cfd15282288c9d0ad541baec411ede91e8c5d01 100644 (file)
@@ -198,6 +198,9 @@ a buffer, see :c:func:`PyObject_GetBuffer`.
       indicates that no de-referencing should occur (striding in a contiguous
       memory block).
 
+      If all suboffsets are negative (i.e. no de-referencing is needed, then
+      this field must be NULL (the default value). 
+
       This type of array representation is used by the Python Imaging Library
       (PIL). See `complex arrays`_ for further information how to access elements
       of such an array.