mirror of
https://github.com/python/cpython.git
synced 2025-08-30 05:35:08 +00:00
bpo-32030: Cleanup pymain_main() (#4935)
* Reorganize pymain_main() to make the code more flat * Clear configurations before pymain_update_sys_path() * Mark Py_FatalError() and _Py_FatalInitError() with _Py_NO_RETURN * Replace _PyMain.run_code variable with a new RUN_CODE() macro * Move _PyMain.cf into a local variable in pymain_run_python()
This commit is contained in:
parent
c4bca95106
commit
1976086362
2 changed files with 101 additions and 79 deletions
|
@ -2003,13 +2003,13 @@ exit:
|
|||
}
|
||||
}
|
||||
|
||||
void
|
||||
void _Py_NO_RETURN
|
||||
Py_FatalError(const char *msg)
|
||||
{
|
||||
fatal_error(NULL, msg, -1);
|
||||
}
|
||||
|
||||
void
|
||||
void _Py_NO_RETURN
|
||||
_Py_FatalInitError(_PyInitError err)
|
||||
{
|
||||
/* On "user" error: exit with status 1.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue