Content-Length: 1519 | pFad | http://github.com/python/cpython/pull/108451.patch
69D409C0
From 980087624d6974ac3785c9ac58401eda4e9c9cb0 Mon Sep 17 00:00:00 2001
From: Victor Stinner
Date: Thu, 24 Aug 2023 21:09:18 +0200
Subject: [PATCH] gh-106320: Remove private _PyList function
Move private functions to the internal C API (pycore_list.h):
* _PyList_Extend()
* _PyList_DebugMallocStats()
No longer export these functions.
---
Include/cpython/listobject.h | 3 ---
Include/internal/pycore_list.h | 4 +++-
2 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/Include/cpython/listobject.h b/Include/cpython/listobject.h
index b3b23985de7a66..661610548733fd 100644
--- a/Include/cpython/listobject.h
+++ b/Include/cpython/listobject.h
@@ -21,9 +21,6 @@ typedef struct {
Py_ssize_t allocated;
} PyListObject;
-PyAPI_FUNC(PyObject *) _PyList_Extend(PyListObject *, PyObject *);
-PyAPI_FUNC(void) _PyList_DebugMallocStats(FILE *out);
-
/* Cast argument to PyListObject* type. */
#define _PyList_CAST(op) \
(assert(PyList_Check(op)), _Py_CAST(PyListObject*, (op)))
diff --git a/Include/internal/pycore_list.h b/Include/internal/pycore_list.h
index b2e503c87542bf..056be2c80c8ce6 100644
--- a/Include/internal/pycore_list.h
+++ b/Include/internal/pycore_list.h
@@ -8,7 +8,9 @@ extern "C" {
# error "this header requires Py_BUILD_CORE define"
#endif
-#include "listobject.h" // _PyList_CAST()
+
+extern PyObject* _PyList_Extend(PyListObject *, PyObject *);
+extern void _PyList_DebugMallocStats(FILE *out);
/* runtime lifecycle */
--- a PPN by Garber Painting Akron. With Image Size Reduction included!Fetched URL: http://github.com/python/cpython/pull/108451.patch
Alternative Proxies:
Alternative Proxy
pFad Proxy
pFad v3 Proxy
pFad v4 Proxy