Message414056
Good news, the difference on Windows was easy enough to find, bad news total refs are now negative!
--- a/Objects/exceptions.c
+++ b/Objects/exceptions.c
@@ -3647,8 +3647,7 @@ _PyBuiltins_AddExceptions(PyObject *bltinmod)
#define INIT_ALIAS(NAME, TYPE) \
do { \
- Py_INCREF(PyExc_ ## TYPE); \
- Py_XDECREF(PyExc_ ## NAME); \
+ Py_XSETREF(PyExc_ ## NAME, PyExc_ ## TYPE); \
PyExc_ ## NAME = PyExc_ ## TYPE; \
if (PyDict_SetItemString(mod_dict, # NAME, PyExc_ ## NAME)) { \
return -1; \
As the PyExc_* aliases just deprecated names for PyExc_OSError, there is no need to increment their refcounts. Or they could be decremented in Fini(). Or they could finally be removed entirely. |
|
Date |
User |
Action |
Args |
2022-02-26 01:29:38 | jkloth | set | recipients:
+ jkloth, vstinner |
2022-02-26 01:29:38 | jkloth | set | messageid: <1645838978.31.0.114008331345.issue46857@roundup.psfhosted.org> |
2022-02-26 01:29:38 | jkloth | link | issue46857 messages |
2022-02-26 01:29:38 | jkloth | create | |
|