cpython/Modules/_ctypes
Petr Viktorin 8923ca418c
gh-145921: Add "_DuringGC" functions for tp_traverse (GH-145925)
There are newly documented restrictions on tp_traverse:

    The traversal function must not have any side effects.
    It must not modify the reference counts of any Python
    objects nor create or destroy any Python objects.

* Add several functions that are guaranteed side-effect-free,
  with a _DuringGC suffix.
* Use these in ctypes
* Consolidate tp_traverse docs in gcsupport.rst, moving unique
  content from typeobj.rst there

Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
2026-04-08 09:15:11 +02:00
..
clinic GH-135763: AC: Use `Py_ssize_t(allow_negative=False)` (#138394) 2025-09-02 21:29:05 +01:00
_ctypes.c gh-145921: Add "_DuringGC" functions for tp_traverse (GH-145925) 2026-04-08 09:15:11 +02:00
_ctypes_test.c Remove unreachable break statements in _ctypes_test.c (#140585) 2025-10-25 14:59:12 +00:00
_ctypes_test.h Copy ctypes-0.9.9.4 sources from external into the trunk. 2006-03-08 19:35:11 +00:00
_ctypes_test_generated.c.h gh-128715: Expose ctypes.CField, with info attributes (GH-128950) 2025-03-24 14:18:34 +01:00
callbacks.c gh-134486: Fix missing alloca() symbol in _ctypes on NetBSD (#134487) 2025-05-23 13:11:04 +02:00
callproc.c gh-76007: Deprecate __version__ attribute in ctypes (#142679) 2025-12-15 13:30:23 +02:00
cfield.c gh-143164: Fix incorrect error message for ctypes bitfield overflow (GH-143165) 2025-12-25 19:08:43 +02:00
ctypes.h gh-145921: Add "_DuringGC" functions for tp_traverse (GH-145925) 2026-04-08 09:15:11 +02:00
malloc_closure.c gh-141770: Annotate anonymous mmap usage if "-X dev" is used (gh-142079) 2025-12-08 14:47:19 +00:00
stgdict.c Fix typo: "occured" =>"occurred" (#134928) 2025-07-19 11:48:04 +03:00