* The :c:func:`PyModule_AddType` function is added to help adding a type to a module.
(Contributed by Dong-hee Na in :issue:`40024`.)
+* The Windows registry is no longer used to initialize :data:`sys.path` when
+ the ``-E`` option is used. This is significant when embedding Python on
+ Windows.
+ (Contributed by Zackery Spytz in :issue:`8901`.)
+
Deprecated
==========
{
int skiphome = calculate->home==NULL ? 0 : 1;
#ifdef Py_ENABLE_SHARED
- calculate->machine_path = getpythonregpath(HKEY_LOCAL_MACHINE, skiphome);
- calculate->user_path = getpythonregpath(HKEY_CURRENT_USER, skiphome);
+ if (!Py_IgnoreEnvironmentFlag) {
+ calculate->machine_path = getpythonregpath(HKEY_LOCAL_MACHINE,
+ skiphome);
+ calculate->user_path = getpythonregpath(HKEY_CURRENT_USER, skiphome);
+ }
#endif
/* We only use the default relative PYTHONPATH if we haven't
anything better to use! */