https://github.com/python/cpython/commit/db61f622c6e3185fc499e69fc933f8cd42738fd3
commit: db61f622c6e3185fc499e69fc933f8cd42738fd3
branch: main
author: AN Long <[email protected]>
committer: Fidget-Spinner <[email protected]>
date: 2026-02-01T04:01:45Z
summary:
Fix unused variable 'COLORS' warning in optimizer.c (#144373)
files:
M Python/optimizer.c
diff --git a/Python/optimizer.c b/Python/optimizer.c
index b8208c7d888e38..2802ef17dbf5c2 100644
--- a/Python/optimizer.c
+++ b/Python/optimizer.c
@@ -1993,6 +1993,8 @@ find_line_number(PyCodeObject *code, _PyExecutorObject
*executor)
#define BLACK "#000000"
#define LOOP "#00c000"
+#ifdef Py_STATS
+
static const char *COLORS[10] = {
"9",
"8",
@@ -2005,8 +2007,6 @@ static const char *COLORS[10] = {
"1",
WHITE,
};
-
-#ifdef Py_STATS
const char *
get_background_color(_PyUOpInstruction const *inst, uint64_t max_hotness)
{
_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3//lists/python-checkins.python.org
Member address: [email protected]