Skip to content

Commit 648b8eb

Browse files
committed
Document missing type flags.
1 parent 0629261 commit 648b8eb

1 file changed

Lines changed: 39 additions & 0 deletions

File tree

Doc/c-api/typeobj.rst

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1498,6 +1498,45 @@ and :c:data:`PyType_Type` effectively act as defaults.)
14981498
This flag is present in header files, but is not be used.
14991499
It will be removed in a future version of CPython
15001500

1501+
.. c:macro:: Py_TPFLAGS_HAVE_VERSION_TAG
1502+
This is a :term:`soft deprecated` macro that does nothing.
1503+
Historically, this would indicate that the
1504+
:c:member:`~PyTypeObject.tp_version_tag` field was available and
1505+
initialized.
1506+
1507+
.. c:macro:: Py_TPFLAGS_INLINE_VALUES
1508+
This bit indicates that instances of this type will have an "inline values"
1509+
array (containing the object's attributes) placed directly after the end
1510+
of the object.
1511+
1512+
This requires that :c:macro:`Py_TPFLAGS_HAVE_GC` is set.
1513+
1514+
**Inheritance:**
1515+
1516+
This flag is not inherited.
1517+
1518+
.. versionadded:: 3.13
1519+
1520+
.. c:macro:: Py_TPFLAGS_IS_ABSTRACT
1521+
This bit indicates that this is an abstract type and therefore cannot
1522+
be instantiated.
1523+
1524+
**Inheritance:**
1525+
1526+
This flag is not inherited.
1527+
1528+
.. seealso::
1529+
:mod:`abc`
1530+
1531+
.. c:macro:: Py_TPFLAGS_HAVE_STACKLESS_EXTENSION
1532+
1533+
Internal. Do not set or unset this flag.
1534+
Historically, this was a reserved flag for use in Stackless Python.
1535+
1536+
.. warning::
1537+
This flag is present in header files, but is not be used.
1538+
This may be removed in a future version of CPython.
1539+
15011540
15021541
.. c:member:: const char* PyTypeObject.tp_doc
15031542

0 commit comments

Comments
 (0)