Skip to content

Commit 151eb4c

Browse files
authored
Merge pull request #3 from encukou/add-sys.abi_info
sys.abi_info: Use Sphinx markup for attributes
2 parents ed7b6d9 + 15f065a commit 151eb4c

1 file changed

Lines changed: 25 additions & 16 deletions

File tree

Doc/library/sys.rst

Lines changed: 25 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -27,22 +27,31 @@ always available. Unless explicitly noted otherwise, all variables are read-only
2727

2828
The following attributes are available:
2929

30-
*pointer_bits* is the width of pointers in bits, as an integer, equivalent
31-
to ``8 * sizeof(void *)``, i.e. usually ``32`` or ``64``.
32-
33-
*free_threaded* is a boolean indicating whether the interpreter supports
34-
running in free-threaded mode (i.e. with the GIL disabled).
35-
This reflects the presence of the :option:`--disable-gil` configure option,
36-
or the setting of the ``DisableGil`` property on Windows, respectively.
37-
38-
*debug* is a boolean indicating whether the interpreter was built in
39-
:ref:`debug mode <debug-build>`.
40-
This reflects the presence of the :option:`--with-pydebug` configure option,
41-
or the ``Debug`` configuration on Windows, respectively.
42-
43-
*byteorder* is a string indicating the native byte order, either ``'big'``
44-
or ``'little'``.
45-
This is the same as the :data:`sys.byteorder` attribute.
30+
.. attribute:: abi_info.pointer_bits
31+
32+
The width of pointers in bits, as an integer, equivalent
33+
to ``8 * sizeof(void *)``. Usually, this is ``32`` or ``64``.
34+
35+
.. attribute:: abi_info.free_threaded
36+
37+
A boolean indicating whether the interpreter was built with
38+
:term:`free threading` support.
39+
This reflects the presence of the :option:`--disable-gil` configure
40+
option, or the setting of the ``DisableGil`` property on Windows,
41+
respectively.
42+
43+
.. attribute:: abi_info.debug
44+
45+
A boolean indicating whether the interpreter was built in
46+
:ref:`debug mode <debug-build>`.
47+
This reflects the presence of the :option:`--with-pydebug` configure
48+
option, or the ``Debug`` configuration on Windows, respectively.
49+
50+
.. attribute:: abi_info.byteorder
51+
52+
A string indicating the native byte order, either ``'big'`` or
53+
``'little'``.
54+
This is the same as the :data:`byteorder` attribute.
4655

4756

4857
.. data:: abiflags

0 commit comments

Comments
 (0)