summaryrefslogtreecommitdiff
path: root/doc/source/reference
diff options
context:
space:
mode:
authorEric Wieser <wieser.eric@gmail.com>2017-11-03 01:03:33 -0700
committerEric Wieser <wieser.eric@gmail.com>2017-11-03 02:15:12 -0700
commit7cfbaf67ce18474c0c01b9e50052863112382742 (patch)
treea1da5c032dfd3f8e88e765a1f440522305499419 /doc/source/reference
parent103f23cfbf2fe89cb3d77cd1f730fef7ec9ec112 (diff)
downloadnumpy-7cfbaf67ce18474c0c01b9e50052863112382742.tar.gz
MAINT: Add a PyDataType_ISUNSIZED macro
This allows us to change how flexible types with no length are represented in future, to allow zero-size dtypes (#8970).
Diffstat (limited to 'doc/source/reference')
-rw-r--r--doc/source/reference/c-api.array.rst6
1 files changed, 6 insertions, 0 deletions
diff --git a/doc/source/reference/c-api.array.rst b/doc/source/reference/c-api.array.rst
index 79a886e71..7e42d3c5f 100644
--- a/doc/source/reference/c-api.array.rst
+++ b/doc/source/reference/c-api.array.rst
@@ -947,6 +947,12 @@ argument must be a :c:type:`PyObject *<PyObject>` that can be directly interpret
Type represents one of the flexible array types ( :c:data:`NPY_STRING`,
:c:data:`NPY_UNICODE`, or :c:data:`NPY_VOID` ).
+.. c:function:: PyDataType_ISUNSIZED(descr):
+
+ Type has no size information attached, and can be resized. Should only be
+ called on flexible dtypes. Types that are attached to an array will always
+ be sized, hence the array form of this macro not existing.
+
.. c:function:: PyTypeNum_ISUSERDEF(num)
.. c:function:: PyDataType_ISUSERDEF(descr)