diff --git a/Include/internal/pycore_global_objects.h b/Include/internal/pycore_global_objects.h index 0bf84ee26866ee..88cdc92e1ac029 100644 --- a/Include/internal/pycore_global_objects.h +++ b/Include/internal/pycore_global_objects.h @@ -12,10 +12,6 @@ extern "C" { #define _PY_NSMALLPOSINTS 257 #define _PY_NSMALLNEGINTS 5 -// _PyLong_GetZero() and _PyLong_GetOne() must always be available -#if _PY_NSMALLPOSINTS < 2 -# error "_PY_NSMALLPOSINTS must be greater than 1" -#endif // Only immutable objects should be considered runtime-global. diff --git a/Include/internal/pycore_long.h b/Include/internal/pycore_long.h index 58e00baee78108..299988d6b385b7 100644 --- a/Include/internal/pycore_long.h +++ b/Include/internal/pycore_long.h @@ -22,6 +22,11 @@ extern PyStatus _PyLong_InitTypes(PyInterpreterState *); #define _PyLong_SMALL_INTS _Py_SINGLETON(small_ints) +// _PyLong_GetZero() and _PyLong_GetOne() must always be available +#if _PY_NSMALLPOSINTS < 2 +# error "_PY_NSMALLPOSINTS must be greater than 1" +#endif + // Return a borrowed reference to the zero singleton. // The function cannot return NULL. static inline PyObject* _PyLong_GetZero(void)