gcc -DPy_NO_DEPRECATED_API option?

I have been following the discussions on removing deprecated macros and functions from the C API. I checked my code, PyCXX and have a coupld of issues that is easy to fix. But I may have missed something.
What would help me is to be able to build extensions with all the deprecated pieces of the C API removed.
A bit like the way the limited C API works via the -DPy_LIMITED_API=0x03040000 option.
What do you think?
Barry

You use -Werror to treat compiler warnings as errors. In GCC, __attribute__((__deprecated__)) emits a compiler warning.
Victor
Le mar. 16 juin 2020 à 13:11, Barry Scott <barry@barrys-emacs.org> a écrit :
-- Night gathers, and now my watch begins. It shall not end until my death.

Some APIs including PyUnicode_AsUnicode had not been marked as deprecated. But I marked them deprecated yesterday.
Macros like PyUnicode_AS_UNICODE will produce warning because they use PyUnicode_AsUnicode internally.
So please try the master branch.
Regards,
On Thu, Jun 18, 2020 at 4:12 AM Barry Scott <barry@barrys-emacs.org> wrote:
-- Inada Naoki <songofacandy@gmail.com>

You use -Werror to treat compiler warnings as errors. In GCC, __attribute__((__deprecated__)) emits a compiler warning.
Victor
Le mar. 16 juin 2020 à 13:11, Barry Scott <barry@barrys-emacs.org> a écrit :
-- Night gathers, and now my watch begins. It shall not end until my death.

Some APIs including PyUnicode_AsUnicode had not been marked as deprecated. But I marked them deprecated yesterday.
Macros like PyUnicode_AS_UNICODE will produce warning because they use PyUnicode_AsUnicode internally.
So please try the master branch.
Regards,
On Thu, Jun 18, 2020 at 4:12 AM Barry Scott <barry@barrys-emacs.org> wrote:
-- Inada Naoki <songofacandy@gmail.com>
participants (3)
-
Barry Scott
-
Inada Naoki
-
Victor Stinner