Eric Snow <ericsnowcurren...@gmail.com> added the comment:
On Fri, Feb 11, 2022 at 1:36 AM Christoph Reiter <rep...@bugs.python.org> wrote: > Sorry if off topic, but I noticed that CPython doesn't deprecate macros in > code, while with gcc/clang it's possible to show compiler warnings for them > using some pragma magic: > [snip] > Maybe that makes getting rid of them easier in the long run? That's a good question. We do have Py_DEPRECATED() (in Include/pyport.h), which is used for symbols. I'm not sure anyone has given much thought to deprecating macros, but it's probably worth considering. I recommend that you post something about this to python-...@python.org. FWIW, here are other explanations of how to deprecate macros: * https://stackoverflow.com/questions/57478368/what-is-the-best-way-to-mark-macro-as-deprecated/57479189#57479189 * https://stackoverflow.com/questions/2681259/how-to-deprecate-a-c-pre-processor-macro-in-gcc/29297970#29297970 ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue46541> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com