Skip to content
Opensource internals
  • Posts

Capsule

CPython's PyCapsule Implementation in C: A void* Wrapper for Extension Modules

Oct 20, 2026 9 min read Jay Hubbert

A PyCapsule is a typed, name-checked void* wrapper: the name stops you reading the wrong capsule, and the destructor gets one shot to clean up before the memory goes.

PythonCpythonInternalsCapsule

Read more →

© 2026 Jay Hubbert · Built with Hugo 0.168.0

RSS ·