8000 MAINT: Cython restore NPY_MAXDIMS and add NPY_RAVEL_AXIS · numpy/numpy@71d6b63 · GitHub
[go: up one dir, main page]

Skip to content

Commit 71d6b63

Browse files
committed
MAINT: Cython restore NPY_MAXDIMS and add NPY_RAVEL_AXIS
1 parent 8111907 commit 71d6b63

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

numpy/__init__.cython-30.pxd

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,10 @@ cdef extern from "numpy/arrayobject.h":
155155

156156
NPY_UPDATE_ALL
157157

158+
cdef enum:
159+
NPY_MAXDIMS # 64 on NumPy 2.x and 32 on NumPy 1.x
160+
NPY_RAVEL_AXIS # Used for functions like PyArray_Mean
161+
158162
enum:
159163
# Added in NumPy 1.7 to replace the deprecated enums above.
160164
NPY_ARRAY_C_CONTIGUOUS

numpy/__init__.pxd

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,10 @@ cdef extern from "numpy/arrayobject.h":
150150

151151
NPY_UPDATE_ALL
152152

153+
cdef enum:
154+
NPY_MAXDIMS # 64 on NumPy 2.x and 32 on NumPy 1.x
155+
NPY_RAVEL_AXIS # Used for functions like PyArray_Mean
156+
153157
enum:
154158
# Added in NumPy 1.7 to replace the deprecated enums above.
155159
NPY_ARRAY_C_CONTIGUOUS

0 commit comments

Comments
 (0)
0