diff options
author | Victor Stinner <vstinner@redhat.com> | 2019-05-22 21:58:50 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-05-22 21:58:50 (GMT) |
commit | 022be02dcfdfd9011415804bb4553a33fa7ec8f3 (patch) | |
tree | 6c4f3b4afed8475e6504786cb176044eade9ef02 /Include/internal | |
parent | e4d300e07c33a9a77549c62d8687d8fe130c53d5 (diff) | |
download | cpython-022be02dcfdfd9011415804bb4553a33fa7ec8f3.zip cpython-022be02dcfdfd9011415804bb4553a33fa7ec8f3.tar.gz cpython-022be02dcfdfd9011415804bb4553a33fa7ec8f3.tar.bz2 |
bpo-36763: Add _PyPreConfig._config_init (GH-13481)
* _PyPreConfig_GetGlobalConfig() and _PyCoreConfig_GetGlobalConfig()
now do nothing if the configuration was not initialized with
_PyPreConfig_InitCompatConfig() and _PyCoreConfig_InitCompatConfig()
* Remove utf8_mode=-2 special case: use utf8_mode=-1 instead.
* Fix _PyPreConfig_InitPythonConfig():
* isolated = 0 instead of -1
* use_environment = 1 instead of -1
* Rename _PyConfig_INIT to _PyConfig_INIT_COMPAT
* Rename _PyPreConfig_Init() to _PyPreConfig_InitCompatConfig()
* Rename _PyCoreConfig_Init() to _PyCoreConfig_InitCompatConfig()
* PyInterpreterState_New() now uses _PyCoreConfig_InitPythonConfig()
as default configuration, but it's very quickly overriden anyway.
* _freeze_importlib.c uses _PyCoreConfig_SetString() to set
program_name.
* Cleanup preconfig_init_utf8_mode(): cmdline is always non-NULL.
Diffstat (limited to 'Include/internal')
-rw-r--r-- | Include/internal/pycore_coreconfig.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Include/internal/pycore_coreconfig.h b/Include/internal/pycore_coreconfig.h index 324e0b8..b17737a 100644 --- a/Include/internal/pycore_coreconfig.h +++ b/Include/internal/pycore_coreconfig.h @@ -120,7 +120,7 @@ PyAPI_FUNC(_PyInitError) _PyPreCmdline_Read(_PyPreCmdline *cmdline, /* --- _PyPreConfig ----------------------------------------------- */ -PyAPI_FUNC(void) _PyPreConfig_Init(_PyPreConfig *config); +PyAPI_FUNC(void) _PyPreConfig_InitCompatConfig(_PyPreConfig *config); PyAPI_FUNC(void) _PyPreConfig_InitFromCoreConfig( _PyPreConfig *config, const _PyCoreConfig *coreconfig); @@ -139,7 +139,7 @@ PyAPI_FUNC(_PyInitError) _PyPreConfig_Write(const _PyPreConfig *config); /* --- _PyCoreConfig ---------------------------------------------- */ -PyAPI_FUNC(void) _PyCoreConfig_Init(_PyCoreConfig *config); +PyAPI_FUNC(void) _PyCoreConfig_InitCompatConfig(_PyCoreConfig *config); PyAPI_FUNC(_PyInitError) _PyCoreConfig_Copy( _PyCoreConfig *config, const _PyCoreConfig *config2); |