diff options
Diffstat (limited to 'Include/internal/pycore_global_objects.h')
-rw-r--r-- | Include/internal/pycore_global_objects.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/Include/internal/pycore_global_objects.h b/Include/internal/pycore_global_objects.h index 82e89db..3561f68 100644 --- a/Include/internal/pycore_global_objects.h +++ b/Include/internal/pycore_global_objects.h @@ -49,6 +49,24 @@ struct _Py_global_objects { PyObject *interned; }; +#define _Py_INTERP_CACHED_OBJECT(interp, NAME) \ + (interp)->cached_objects.NAME + +struct _Py_interp_cached_objects { + int _not_set; +}; + +#define _Py_INTERP_STATIC_OBJECT(interp, NAME) \ + (interp)->static_objects.NAME +#define _Py_INTERP_SINGLETON(interp, NAME) \ + _Py_INTERP_STATIC_OBJECT(interp, singletons.NAME) + +struct _Py_interp_static_objects { + struct { + int _not_used; + } singletons; +}; + #ifdef __cplusplus } |