diff options
author | Victor Stinner <vstinner@python.org> | 2024-04-18 13:20:38 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-04-18 13:20:38 (GMT) |
commit | 340a02b590681d4753eef0ff63037d0ecb512271 (patch) | |
tree | 09300e1018a937cdbe5f4b7be2ccd3dc25402044 /Python | |
parent | 0a0756c5edd8c32783a39ef00c47fe4a54deecbc (diff) | |
download | cpython-340a02b590681d4753eef0ff63037d0ecb512271.zip cpython-340a02b590681d4753eef0ff63037d0ecb512271.tar.gz cpython-340a02b590681d4753eef0ff63037d0ecb512271.tar.bz2 |
gh-117987: Restore several functions removed in Python 3.13 alpha 1 (GH-117993)
Restore these functions removed in Python 3.13 alpha 1:
* Py_SetPythonHome()
* Py_SetProgramName()
* PySys_SetArgvEx()
* PySys_SetArgv()
Diffstat (limited to 'Python')
-rw-r--r-- | Python/pathconfig.c | 6 | ||||
-rw-r--r-- | Python/sysmodule.c | 6 |
2 files changed, 4 insertions, 8 deletions
diff --git a/Python/pathconfig.c b/Python/pathconfig.c index 50c6009..33abadd 100644 --- a/Python/pathconfig.c +++ b/Python/pathconfig.c @@ -251,8 +251,7 @@ Py_SetPath(const wchar_t *path) } -// Removed in Python 3.13 API, but kept for the stable ABI -PyAPI_FUNC(void) +void Py_SetPythonHome(const wchar_t *home) { int has_value = home && home[0]; @@ -275,8 +274,7 @@ Py_SetPythonHome(const wchar_t *home) } -// Removed in Python 3.13 API, but kept for the stable ABI -PyAPI_FUNC(void) +void Py_SetProgramName(const wchar_t *program_name) { int has_value = program_name && program_name[0]; diff --git a/Python/sysmodule.c b/Python/sysmodule.c index 7b4a643..05ee405 100644 --- a/Python/sysmodule.c +++ b/Python/sysmodule.c @@ -3872,8 +3872,7 @@ make_sys_argv(int argc, wchar_t * const * argv) return list; } -// Removed in Python 3.13 API, but kept for the stable ABI -PyAPI_FUNC(void) +void PySys_SetArgvEx(int argc, wchar_t **argv, int updatepath) { wchar_t* empty_argv[1] = {L""}; @@ -3917,8 +3916,7 @@ PySys_SetArgvEx(int argc, wchar_t **argv, int updatepath) } } -// Removed in Python 3.13 API, but kept for the stable ABI -PyAPI_FUNC(void) +void PySys_SetArgv(int argc, wchar_t **argv) { _Py_COMP_DIAG_PUSH |