summaryrefslogtreecommitdiffstats
path: root/Python
diff options
context:
space:
mode:
authorMichael Droettboom <mdboom@gmail.com>2024-07-16 22:38:29 (GMT)
committerGitHub <noreply@github.com>2024-07-16 22:38:29 (GMT)
commitf036a463dbc43d25712183dc6afa4e38c1aaf93d (patch)
treeeb1b6608d1ba8ae069b0c432a29fa04cb0e231e5 /Python
parent4e35dd607b0f32657341e6c4f583d14964ee1699 (diff)
downloadcpython-f036a463dbc43d25712183dc6afa4e38c1aaf93d.zip
cpython-f036a463dbc43d25712183dc6afa4e38c1aaf93d.tar.gz
cpython-f036a463dbc43d25712183dc6afa4e38c1aaf93d.tar.bz2
GH-121583: Remove dependency from pystats.h to internal header file (GH-121587)
Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
Diffstat (limited to 'Python')
-rw-r--r--Python/specialize.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/Python/specialize.c b/Python/specialize.c
index 497feca..3af0dea 100644
--- a/Python/specialize.c
+++ b/Python/specialize.c
@@ -29,6 +29,10 @@ GCStats _py_gc_stats[NUM_GENERATIONS] = { 0 };
static PyStats _Py_stats_struct = { .gc_stats = _py_gc_stats };
PyStats *_Py_stats = NULL;
+#if PYSTATS_MAX_UOP_ID < MAX_UOP_ID
+#error "Not enough space allocated for pystats. Increase PYSTATS_MAX_UOP_ID to at least MAX_UOP_ID"
+#endif
+
#define ADD_STAT_TO_DICT(res, field) \
do { \
PyObject *val = PyLong_FromUnsignedLongLong(stats->field); \