been included directly, consider including ``Python.h`` instead.
(Contributed by Victor Stinner in :issue:`35134`.)
+* The :c:func:`PyUnicode_CHECK_INTERNED` macro has been excluded from the
+ limited C API. It was never usable there, because it used internal structures
+ which are not available in the limited C API.
+ (Contributed by Victor Stinner in :issue:`46007`.)
+
+
Deprecated
----------
#define SSTATE_INTERNED_MORTAL 1
#define SSTATE_INTERNED_IMMORTAL 2
+/* Use only if you know it's a string */
+#define PyUnicode_CHECK_INTERNED(op) \
+ (((PyASCIIObject *)(op))->state.interned)
+
/* Return true if the string contains only ASCII characters, or 0 if not. The
string may be compact (PyUnicode_IS_COMPACT_ASCII) or not, but must be
ready. */
// and will be removed in Python 3.12. Use PyUnicode_InternInPlace() instead.
Py_DEPRECATED(3.10) PyAPI_FUNC(void) PyUnicode_InternImmortal(PyObject **);
-/* Use only if you know it's a string */
-#define PyUnicode_CHECK_INTERNED(op) \
- (((PyASCIIObject *)(op))->state.interned)
-
/* --- wchar_t support for platforms which support it --------------------- */
#ifdef HAVE_WCHAR_H
--- /dev/null
+The :c:func:`PyUnicode_CHECK_INTERNED` macro has been excluded from the limited
+C API. It was never usable there, because it used internal structures which are
+not available in the limited C API. Patch by Victor Stinner.