22
33.. _stable :
44
5- **********************************
6- Stable Appliction Binary Interface
7- **********************************
5+ ***********************************
6+ Stable Application Binary Interface
7+ ***********************************
88
99Traditionally, the C API of Python will change with every release.
1010Most changes will be source-compatible, typically by only adding API,
@@ -23,13 +23,15 @@ need to be recompiled to link with a newer one.
2323
2424Since Python 3.2, a subset of the API has been declared to guarantee
2525a stable ABI. Extension modules wishing to use this API need to define
26- Py_LIMITED_API. A number of interpreter details then become hidden
26+ `` Py_LIMITED_API `` . A number of interpreter details then become hidden
2727from the extension module; in return, a module is built that works
28- on any 3.x version (x>=2) without recompilation. In some cases, the
29- stable ABI needs to be extended with new functions. Extensions modules
30- wishing to use these new APIs need to set Py_LIMITED_API to the
31- PY_VERSION_HEX value of the minimum Python version they want to
32- support (e.g. 0x03030000 for Python 3.3). Such modules will work
28+ on any 3.x version (x>=2) without recompilation.
29+
30+ In some cases, the stable ABI needs to be extended with new functions.
31+ Extension modules wishing to use these new APIs need to set
32+ ``Py_LIMITED_API `` to the ``PY_VERSION_HEX `` value (see
33+ :ref: `apiabiversion `) of the minimum Python version they want to
34+ support (e.g. ``0x03030000 `` for Python 3.3). Such modules will work
3335on all subsequent Python releases, but fail to load (because of
3436missing symbols) on the older releases.
3537
0 commit comments