summaryrefslogtreecommitdiff
path: root/numpy/core/include
diff options
context:
space:
mode:
authorMatti Picus <matti.picus@gmail.com>2018-10-19 11:30:07 +0300
committerGitHub <noreply@github.com>2018-10-19 11:30:07 +0300
commita2fb23aa0844731438e6b9c9d09644e48aa4900b (patch)
tree3d0585ca39046eeb8a0cdaf59b1e0aff4bb5ec04 /numpy/core/include
parent1ba4173d20f16348f793c1d87f8cc03cd87588ad (diff)
parentc8e15bafb0d811d8dd805ddf521d102eaac08079 (diff)
downloadnumpy-a2fb23aa0844731438e6b9c9d09644e48aa4900b.tar.gz
Merge pull request #11175 from mhvk/gufunc-signature-modification2
ENH: Generalized ufunc signature expansion for frozen and flexible dimensions
Diffstat (limited to 'numpy/core/include')
-rw-r--r--numpy/core/include/numpy/ufuncobject.h23
1 files changed, 23 insertions, 0 deletions
diff --git a/numpy/core/include/numpy/ufuncobject.h b/numpy/core/include/numpy/ufuncobject.h
index 9d48ab608..85f8a6c08 100644
--- a/numpy/core/include/numpy/ufuncobject.h
+++ b/numpy/core/include/numpy/ufuncobject.h
@@ -209,9 +209,32 @@ typedef struct _tagPyUFuncObject {
* set by nditer object.
*/
npy_uint32 iter_flags;
+
+ /* New in NPY_API_VERSION 0x0000000D and above */
+
+ /*
+ * for each core_num_dim_ix distinct dimension names,
+ * the possible "frozen" size (-1 if not frozen).
+ */
+ npy_intp *core_dim_sizes;
+
+ /*
+ * for each distinct core dimension, a set of UFUNC_CORE_DIM* flags
+ */
+ npy_uint32 *core_dim_flags;
+
+
+
} PyUFuncObject;
#include "arrayobject.h"
+/* Generalized ufunc; 0x0001 reserved for possible use as CORE_ENABLED */
+/* the core dimension's size will be determined by the operands. */
+#define UFUNC_CORE_DIM_SIZE_INFERRED 0x0002
+/* the core dimension may be absent */
+#define UFUNC_CORE_DIM_CAN_IGNORE 0x0004
+/* flags inferred during execution */
+#define UFUNC_CORE_DIM_MISSING 0x00040000
#define UFUNC_ERR_IGNORE 0
#define UFUNC_ERR_WARN 1