gh-131238: Use pycore_interp_structs.h header (#131481)

Replace pycore_runtime_structs.h include with pycore_interp_structs.h
include in internal headers.
This commit is contained in:
Victor Stinner 2025-03-20 00:13:25 +01:00 committed by GitHub
parent a8cb5e4a43
commit a7411025c5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 10 additions and 12 deletions

View file

@ -8,8 +8,8 @@ extern "C" {
# error "this header requires Py_BUILD_CORE define"
#endif
#include "pycore_interp_structs.h" // struct codecs_state
#include "pycore_lock.h" // PyMutex
#include "pycore_runtime_structs.h" // struct codecs_state
/* Initialize codecs-related state for the given interpreter, including
registering the first codec search function. Must be called before any other

View file

@ -9,7 +9,7 @@ extern "C" {
#endif
#include <locale.h> // struct lconv
#include "pycore_runtime_structs.h" // _Py_error_handler
#include "pycore_interp_structs.h" // _Py_error_handler
/* A routine to check if a file descriptor can be select()-ed. */

View file

@ -8,8 +8,8 @@ extern "C" {
# error "this header requires Py_BUILD_CORE define"
#endif
#include "pycore_pystate.h"
#include "pycore_runtime_structs.h"
#include "pycore_interp_structs.h" // PyGC_Head
#include "pycore_pystate.h" // _PyInterpreterState_GET()
#include "pycore_typedefs.h" // _PyInterpreterFrame

View file

@ -9,9 +9,9 @@ extern "C" {
# error "this header requires Py_BUILD_CORE define"
#endif
#include "pycore_lock.h" // PyMutex
#include "pycore_runtime_structs.h" // _import_state
#include "pycore_hashtable.h" // _Py_hashtable_t
#include "pycore_interp_structs.h" // _import_state
#include "pycore_lock.h" // PyMutex
extern int _PyImport_IsInitialized(PyInterpreterState *);

View file

@ -8,9 +8,6 @@ extern "C" {
# error "this header requires Py_BUILD_CORE define"
#endif
#include <stdbool.h> // bool
#include "pycore_runtime_structs.h"
#include "pycore_genobject.h" // _PyGen_FetchStopIterationValue

View file

@ -8,7 +8,8 @@ extern "C" {
# error "this header requires Py_BUILD_CORE define"
#endif
#include "pycore_runtime_structs.h"
#include "pycore_runtime_structs.h" // _PyRuntimeState
/* API */

View file

@ -57,7 +57,7 @@ extern "C" {
# error "this header requires Py_BUILD_CORE define"
#endif
#include "pycore_runtime_structs.h"
#include "pycore_runtime_structs.h" // _PyTimeFraction
#ifdef __clang__
struct timeval;

View file

@ -9,8 +9,8 @@ extern "C" {
#endif
#include "pycore_function.h"
#include "pycore_interp_structs.h" // managed_static_type_state
#include "pycore_moduleobject.h" // PyModuleObject
#include "pycore_runtime_structs.h" // type state
#include "pycore_stats.h"