[Python-checkins] [3.11] gh-90744: Fix erroneous doc links in the sys module (GH-101319) (#102321)

hugovk webhook-mailer at python.org
Thu Mar 2 00:43:54 EST 2023


https://github.com/python/cpython/commit/9a5f2e8562a4349bfb1b00465f75ee270592744e
commit: 9a5f2e8562a4349bfb1b00465f75ee270592744e
branch: 3.11
author: Hugo van Kemenade <hugovk at users.noreply.github.com>
committer: hugovk <hugovk at users.noreply.github.com>
date: 2023-03-02T07:43:44+02:00
summary:

[3.11] gh-90744: Fix erroneous doc links in the sys module (GH-101319) (#102321)

Co-authored-by: Hugo van Kemenade <hugovk at users.noreply.github.com>
Co-authored-by: Brad Wolfe <brad.wolfe at gmail.com>
Co-authored-by: Furkan Onder <furkanonder at protonmail.com>
Fix erroneous doc links in the sys module (#101319)

files:
M Doc/library/sys.rst

diff --git a/Doc/library/sys.rst b/Doc/library/sys.rst
index b458040c876b..36155d632363 100644
--- a/Doc/library/sys.rst
+++ b/Doc/library/sys.rst
@@ -568,49 +568,55 @@ always available.
 
    .. tabularcolumns:: |l|l|L|
 
-   +---------------------+----------------+--------------------------------------------------+
-   | attribute           | float.h macro  | explanation                                      |
-   +=====================+================+==================================================+
-   | :const:`epsilon`    | DBL_EPSILON    | difference between 1.0 and the least value       |
-   |                     |                | greater than 1.0 that is representable as a float|
-   |                     |                |                                                  |
-   |                     |                | See also :func:`math.ulp`.                       |
-   +---------------------+----------------+--------------------------------------------------+
-   | :const:`dig`        | DBL_DIG        | maximum number of decimal digits that can be     |
-   |                     |                | faithfully represented in a float;  see below    |
-   +---------------------+----------------+--------------------------------------------------+
-   | :const:`mant_dig`   | DBL_MANT_DIG   | float precision: the number of base-``radix``    |
-   |                     |                | digits in the significand of a float             |
-   +---------------------+----------------+--------------------------------------------------+
-   | :const:`max`        | DBL_MAX        | maximum representable positive finite float      |
-   +---------------------+----------------+--------------------------------------------------+
-   | :const:`max_exp`    | DBL_MAX_EXP    | maximum integer *e* such that ``radix**(e-1)`` is|
-   |                     |                | a representable finite float                     |
-   +---------------------+----------------+--------------------------------------------------+
-   | :const:`max_10_exp` | DBL_MAX_10_EXP | maximum integer *e* such that ``10**e`` is in the|
-   |                     |                | range of representable finite floats             |
-   +---------------------+----------------+--------------------------------------------------+
-   | :const:`min`        | DBL_MIN        | minimum representable positive *normalized* float|
-   |                     |                |                                                  |
-   |                     |                | Use :func:`math.ulp(0.0) <math.ulp>` to get the  |
-   |                     |                | smallest positive *denormalized* representable   |
-   |                     |                | float.                                           |
-   +---------------------+----------------+--------------------------------------------------+
-   | :const:`min_exp`    | DBL_MIN_EXP    | minimum integer *e* such that ``radix**(e-1)`` is|
-   |                     |                | a normalized float                               |
-   +---------------------+----------------+--------------------------------------------------+
-   | :const:`min_10_exp` | DBL_MIN_10_EXP | minimum integer *e* such that ``10**e`` is a     |
-   |                     |                | normalized float                                 |
-   +---------------------+----------------+--------------------------------------------------+
-   | :const:`radix`      | FLT_RADIX      | radix of exponent representation                 |
-   +---------------------+----------------+--------------------------------------------------+
-   | :const:`rounds`     | FLT_ROUNDS     | integer constant representing the rounding mode  |
-   |                     |                | used for arithmetic operations.  This reflects   |
-   |                     |                | the value of the system FLT_ROUNDS macro at      |
-   |                     |                | interpreter startup time.  See section 5.2.4.2.2 |
-   |                     |                | of the C99 standard for an explanation of the    |
-   |                     |                | possible values and their meanings.              |
-   +---------------------+----------------+--------------------------------------------------+
+   +---------------------+---------------------+--------------------------------------------------+
+   | attribute           | float.h macro       | explanation                                      |
+   +=====================+=====================+==================================================+
+   | ``epsilon``         | ``DBL_EPSILON``     | difference between 1.0 and the least value       |
+   |                     |                     | greater than 1.0 that is representable as a float|
+   |                     |                     |                                                  |
+   |                     |                     | See also :func:`math.ulp`.                       |
+   +---------------------+---------------------+--------------------------------------------------+
+   | ``dig``             | ``DBL_DIG``         | maximum number of decimal digits that can be     |
+   |                     |                     | faithfully represented in a float;  see below    |
+   +---------------------+---------------------+--------------------------------------------------+
+   | ``mant_dig``        | ``DBL_MANT_DIG``    | float precision: the number of base-``radix``    |
+   |                     |                     | digits in the significand of a float             |
+   +---------------------+---------------------+--------------------------------------------------+
+   | ``max``             | ``DBL_MAX``         | maximum representable positive finite float      |
+   +---------------------+---------------------+--------------------------------------------------+
+   | ``max_exp``         | ``DBL_MAX_EXP``     | maximum integer *e* such that ``radix**(e-1)`` is|
+   |                     |                     | a representable finite float                     |
+   +---------------------+---------------------+--------------------------------------------------+
+   | ``max_10_exp``      | ``DBL_MAX_10_EXP``  | maximum integer *e* such that ``10**e`` is in the|
+   |                     |                     | range of representable finite floats             |
+   +---------------------+---------------------+--------------------------------------------------+
+   | ``min``             | ``DBL_MIN``         | minimum representable positive *normalized* float|
+   |                     |                     |                                                  |
+   |                     |                     | Use :func:`math.ulp(0.0) <math.ulp>` to get the  |
+   |                     |                     | smallest positive *denormalized* representable   |
+   |                     |                     | float.                                           |
+   +---------------------+---------------------+--------------------------------------------------+
+   | ``min_exp``         | ``DBL_MIN_EXP``     | minimum integer *e* such that ``radix**(e-1)`` is|
+   |                     |                     | a normalized float                               |
+   +---------------------+---------------------+--------------------------------------------------+
+   | ``min_10_exp``      | ``DBL_MIN_10_EXP``  | minimum integer *e* such that ``10**e`` is a     |
+   |                     |                     | normalized float                                 |
+   +---------------------+---------------------+--------------------------------------------------+
+   | ``radix``           | ``FLT_RADIX``       | radix of exponent representation                 |
+   +---------------------+---------------------+--------------------------------------------------+
+   | ``rounds``          | ``FLT_ROUNDS``      | integer representing the rounding mode for       |
+   |                     |                     | floating-point arithmetic. This reflects the     |
+   |                     |                     | value of the system ``FLT_ROUNDS`` macro at      |
+   |                     |                     | interpreter startup time:                        |
+   |                     |                     | ``-1`` indeterminable,                           |
+   |                     |                     | ``0`` toward zero,                               |
+   |                     |                     | ``1`` to nearest,                                |
+   |                     |                     | ``2`` toward positive infinity,                  |
+   |                     |                     | ``3`` toward negative infinity                   |
+   |                     |                     |                                                  |
+   |                     |                     | All other values for ``FLT_ROUNDS`` characterize |
+   |                     |                     | implementation-defined rounding behavior.        |
+   +---------------------+---------------------+--------------------------------------------------+
 
    The attribute :attr:`sys.float_info.dig` needs further explanation.  If
    ``s`` is any string representing a decimal number with at most



More information about the Python-checkins mailing list