On C23 and newer and on C++11 and newer, `nullptr` is preferred over `NULL` to specify a "null pointer". Python has a private `_Py_NULL` macro for that. Static inline functions should use Py_NULL rather than using directly NULL to prevent C++ compiler warnings.

```c
#if (defined (__STDC_VERSION__) && __STDC_VERSION__ > 201710L) \
        || (defined(__cplusplus) && __cplusplus >= 201103)
#  define _Py_NULL nullptr
#else
#  define _Py_NULL NULL
#endif
```

I propose to make the macro public to make it usable in more cases: rename `_Py_NULL` to `Py_NULL`.


<!-- gh-linked-prs -->
### Linked PRs
* gh-119852
<!-- /gh-linked-prs -->

[C API] Add a public Py_nullptr macro (rename private _Py_NULL)
This is a GitHub Issue
repo:cpython
owner:python
Title : [C API] Add a public Py_nullptr macro (rename private _Py_NULL)
Issue date:

--- start body ---
On C23 and newer and on C++11 and newer, `nullptr` is preferred over `NULL` to specify a "null pointer". Python has a private `_Py_NULL` macro for that. Static inline functions should use Py_NULL rather than using directly NULL to prevent C++ compiler warnings.

```c
#if (defined (__STDC_VERSION__) && __STDC_VERSION__ > 201710L) \
        || (defined(__cplusplus) && __cplusplus >= 201103)
#  define _Py_NULL nullptr
#else
#  define _Py_NULL NULL
#endif
```

I propose to make the macro public to make it usable in more cases: rename `_Py_NULL` to `Py_NULL`.


<!-- gh-linked-prs -->
### Linked PRs
* gh-119852
<!-- /gh-linked-prs -->

--- end body ---
