https://github.com/python/cpython/commit/c292f7f56311b305c673415651c919a7633d36cc
commit: c292f7f56311b305c673415651c919a7633d36cc
branch: main
author: Victor Stinner <vstin...@python.org>
committer: vstinner <vstin...@python.org>
date: 2025-04-25T09:28:34+02:00
summary:

gh-127604: Only define dump_pointer() if CAN_C_BACKTRACE (#132897)

files:
M Python/traceback.c

diff --git a/Python/traceback.c b/Python/traceback.c
index 0a9f571cac7fb0..ff8d29fa5207be 100644
--- a/Python/traceback.c
+++ b/Python/traceback.c
@@ -879,12 +879,14 @@ _Py_DumpHexadecimal(int fd, uintptr_t value, Py_ssize_t 
width)
     dump_hexadecimal(fd, value, width, 0);
 }
 
+#ifdef CAN_C_BACKTRACE
 static void
 dump_pointer(int fd, void *ptr)
 {
     PUTS(fd, "0x");
     dump_hexadecimal(fd, (uintptr_t)ptr, sizeof(void*), 1);
 }
+#endif
 
 static void
 dump_char(int fd, char ch)

_______________________________________________
Python-checkins mailing list -- python-checkins@python.org
To unsubscribe send an email to python-checkins-le...@python.org
https://mail.python.org/mailman3/lists/python-checkins.python.org/
Member address: arch...@mail-archive.com

Reply via email to