From 28ad12f8fe889a741661eb99daacebd9243cc1ba Mon Sep 17 00:00:00 2001 From: Victor Stinner Date: Fri, 19 Mar 2021 12:41:49 +0100 Subject: bpo-43244: Remove symtable.h header file (GH-24910) Rename Include/symtable.h to to Include/internal/pycore_symtable.h, don't export symbols anymore (replace PyAPI_FUNC and PyAPI_DATA with extern) and rename functions: * PyST_GetScope() to _PyST_GetScope() * PySymtable_BuildObject() to _PySymtable_Build() * PySymtable_Free() to _PySymtable_Free() Remove PySymtable_Build(), Py_SymtableString() and Py_SymtableStringObject() functions. The Py_SymtableString() function was part the stable ABI by mistake but it could not be used, since the symtable.h header file was excluded from the limited C API. The Python symtable module remains available and is unchanged. --- Modules/symtablemodule.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'Modules/symtablemodule.c') diff --git a/Modules/symtablemodule.c b/Modules/symtablemodule.c index f6c378fdae..c3234920d5 100644 --- a/Modules/symtablemodule.c +++ b/Modules/symtablemodule.c @@ -1,8 +1,7 @@ #include "Python.h" -#include "code.h" #include "Python-ast.h" -#include "symtable.h" +#include "pycore_symtable.h" // struct symtable #include "clinic/symtablemodule.c.h" /*[clinic input] @@ -62,7 +61,7 @@ _symtable_symtable_impl(PyObject *module, PyObject *source, t = (PyObject *)st->st_top; Py_INCREF(t); PyMem_Free((void *)st->st_future); - PySymtable_Free(st); + _PySymtable_Free(st); return t; } -- cgit v1.2.1