diff --git a/package/CHANGELOG b/package/CHANGELOG index f409baf75ef..dc16ae96fe8 100644 --- a/package/CHANGELOG +++ b/package/CHANGELOG @@ -13,7 +13,7 @@ The rules for this file: * release numbers follow "Semantic Versioning" http://semver.org ------------------------------------------------------------------------------ -??/??/?? IAlibay +??/??/?? IAlibay, hmacdope * 2.7.0 @@ -22,6 +22,8 @@ Fixes Enhancements Changes + * Cython DEF statments have been replaced with compile time integer constants + as DEF is deprecated as of Cython>=3.0 (Issue #4237, PR #4246) Deprecations diff --git a/package/MDAnalysis/lib/nsgrid.pyx b/package/MDAnalysis/lib/nsgrid.pyx index 3782f96520b..a4e245e884e 100644 --- a/package/MDAnalysis/lib/nsgrid.pyx +++ b/package/MDAnalysis/lib/nsgrid.pyx @@ -83,18 +83,18 @@ import numpy as np from libcpp.vector cimport vector from libc cimport math -DEF END = -1 +cdef int END = -1 -DEF XX = 0 -DEF XY = 3 -DEF YY = 4 -DEF XZ = 6 -DEF YZ = 7 -DEF ZZ = 8 +cdef int XX = 0 +cdef int XY = 3 +cdef int YY = 4 +cdef int XZ = 6 +cdef int YZ = 7 +cdef int ZZ = 8 # Cube root of the maximum size of a 32 bit signed integer. If the system is divided into more # grids than this, integer overflow will occur. -DEF MAX_GRID_DIM = 1290 +cdef int MAX_GRID_DIM = 1290 ctypedef float coordinate[3]