[3.8] bpo-36763: PyConfig_Read() handles PySys_AddXOption() (GH-15431) by vstinner · Pull Request #15435 · python/cpython

@vstinner

PyConfig_Read() is now responsible to handle early calls to
PySys_AddXOption() and PySys_AddWarnOption().

Options added by PySys_AddXOption() are now handled the same way than
PyConfig.xoptions and command line -X options.

For example, PySys_AddXOption(L"faulthandler") enables faulthandler
as expected.

(cherry picked from commit 120b707)