Skip to content

Commit

Permalink
Mention public macros in docs
Browse files Browse the repository at this point in the history
  • Loading branch information
skirpichev committed Oct 29, 2023
1 parent 0ce377a commit 1f9f2fc
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
3 changes: 2 additions & 1 deletion Doc/library/stdtypes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -723,7 +723,8 @@ made available to Python as the :attr:`modulus` attribute of
.. impl-detail::

Currently, the prime used is ``P = 2**31 - 1`` on machines with 32-bit C

Check warning on line 725 in Doc/library/stdtypes.rst

View workflow job for this annotation

GitHub Actions / Docs / Docs

c:macro reference target not found: _PyHASH_BITS
longs and ``P = 2**61 - 1`` on machines with 64-bit C longs.
longs and ``P = 2**61 - 1`` on machines with 64-bit C longs. The exponent
of this Mersenne prime is available as :c:macro:`_PyHASH_BITS` macro.

Here are the rules in detail:

Expand Down
9 changes: 6 additions & 3 deletions Doc/library/sys.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1022,19 +1022,22 @@ always available.

.. attribute:: hash_info.modulus

The prime modulus P used for numeric hash scheme
The prime modulus P used for numeric hash scheme. Available also as

Check warning on line 1025 in Doc/library/sys.rst

View workflow job for this annotation

GitHub Actions / Docs / Docs

c:macro reference target not found: _PyHASH_MODULUS
:c:macro:`_PyHASH_MODULUS` macro.

.. attribute:: hash_info.inf

The hash value returned for a positive infinity
The hash value returned for a positive infinity. Available also as

Check warning on line 1030 in Doc/library/sys.rst

View workflow job for this annotation

GitHub Actions / Docs / Docs

c:macro reference target not found: _PyHASH_INF
:c:macro:`_PyHASH_INF` macro.

.. attribute:: hash_info.nan

(This attribute is no longer used)

.. attribute:: hash_info.imag

The multiplier used for the imaginary part of a complex number
The multiplier used for the imaginary part of a complex number.

Check warning on line 1039 in Doc/library/sys.rst

View workflow job for this annotation

GitHub Actions / Docs / Docs

c:macro reference target not found: _PyHASH_IMAG
Available also as :c:macro:`_PyHASH_IMAG` macro.

.. attribute:: hash_info.algorithm

Expand Down

0 comments on commit 1f9f2fc

Please sign in to comment.