summaryrefslogtreecommitdiffstats
path: root/Include
diff options
context:
space:
mode:
authorVictor Stinner <vstinner@redhat.com>2019-05-17 09:12:09 (GMT)
committerGitHub <noreply@github.com>2019-05-17 09:12:09 (GMT)
commitfed02e15b39b6f1521ea21654be5fc0757a8720a (patch)
tree976c7abd1f4a66a97aba89de3688405b9a5161b3 /Include
parent245f528a92d7748dbd7acf9cba860153c143bbfe (diff)
downloadcpython-fed02e15b39b6f1521ea21654be5fc0757a8720a.zip
cpython-fed02e15b39b6f1521ea21654be5fc0757a8720a.tar.gz
cpython-fed02e15b39b6f1521ea21654be5fc0757a8720a.tar.bz2
bpo-36763: Remove _PyCoreConfig.program (GH-13373)
Use _PyCoreConfig.program_name instead.
Diffstat (limited to 'Include')
-rw-r--r--Include/cpython/coreconfig.h14
1 files changed, 9 insertions, 5 deletions
diff --git a/Include/cpython/coreconfig.h b/Include/cpython/coreconfig.h
index b531118..1ba2663 100644
--- a/Include/cpython/coreconfig.h
+++ b/Include/cpython/coreconfig.h
@@ -218,11 +218,15 @@ typedef struct {
always exists and is never empty. */
_PyWstrList argv;
- /* Program: argv[0] or "".
- Used to display Python usage if parsing command line arguments fails.
- Used to initialize the default value of program_name */
- wchar_t *program;
- wchar_t *program_name; /* Program name, see also Py_GetProgramName() */
+ /* Program name:
+
+ - If Py_SetProgramName() was called, use its value.
+ - On macOS, use PYTHONEXECUTABLE environment variable if set.
+ - If WITH_NEXT_FRAMEWORK macro is defined, use __PYVENV_LAUNCHER__
+ environment variable is set.
+ - Use argv[0] if available and non-empty.
+ - Use "python" on Windows, or "python3 on other platforms. */
+ wchar_t *program_name;
_PyWstrList xoptions; /* Command line -X options */
_PyWstrList warnoptions; /* Warnings options */