[Python-Dev] Re: PEP 674 – Disallow using macros as l-value (version 2)

2022年1月26日 15:04:13 -0800

Hi,
My PEP 674 proposed to change PyDescr_TYPE() and PyDescr_NAME()
macros. This change breaks M2Crypto and mecab-python3 projects in code
generated by SWIG. I tried two solutions to prevent SWIG accessing
PyDescrObject members directly:
https://bugs.python.org/issue46538 
At the end, IMO it's too much work, whereas there is no need in the
short term to modify the PyDescrObject structure, or structure
inheriting from PyDescrObject.
So I excluded PyDescr_TYPE() and PyDescr_NAME() macros from PEP 674 to
leave them unchanged:
https://python.github.io/peps/pep-0674/#pydescr-name-and-pydescr-type-are-left-unchanged
Today, the PEP 674 only affects 9 projects on the top 5000 PyPI
projects (+ 22 projects which have to re-run Cython).
Victor
_______________________________________________
Python-Dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/[email protected]/message/SKZ5UTNJD3AAYIBTL6D4Y7XKGI2PZSIF/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to