mirror of
https://github.com/AdaCore/cpython.git
synced 2026-02-12 12:57:15 -08:00
Added new Py_IsInitalized() API function to test the 'initialized' flag.
This commit is contained in:
@@ -78,6 +78,14 @@ int Py_InteractiveFlag; /* Needed by Py_FdIsInteractive() below */
|
||||
|
||||
static int initialized = 0;
|
||||
|
||||
/* API to access the initialized flag -- useful for eroteric use */
|
||||
|
||||
int
|
||||
Py_IsInitialized()
|
||||
{
|
||||
return initialized;
|
||||
}
|
||||
|
||||
/* Global initializations. Can be undone by Py_Finalize(). Don't
|
||||
call this twice without an intervening Py_Finalize() call. When
|
||||
initializations fail, a fatal error is issued and the function does
|
||||
|
||||
Reference in New Issue
Block a user