[Python-checkins] bpo-37973: Improve the docstrings of sys.float_info (GH-19218)

Zackery Spytz webhook-mailer at python.org
Sun May 24 06:03:57 EDT 2020


https://github.com/python/cpython/commit/fdc5a94279736a7715dd35c5354a3c27098d0897
commit: fdc5a94279736a7715dd35c5354a3c27098d0897
branch: master
author: Zackery Spytz <zspytz at gmail.com>
committer: GitHub <noreply at github.com>
date: 2020-05-24T11:03:52+01:00
summary:

bpo-37973: Improve the docstrings of sys.float_info (GH-19218)

Taken from https://docs.python.org/3/library/sys.html#sys.float_info

files:
M Objects/floatobject.c

diff --git a/Objects/floatobject.c b/Objects/floatobject.c
index 9f5014092cf20..cc0ae8ce81908 100644
--- a/Objects/floatobject.c
+++ b/Objects/floatobject.c
@@ -59,12 +59,14 @@ static PyStructSequence_Field floatinfo_fields[] = {
                     "is a normalized float"},
     {"min_10_exp",      "DBL_MIN_10_EXP -- minimum int e such that 10**e is "
                     "a normalized"},
-    {"dig",             "DBL_DIG -- digits"},
+    {"dig",             "DBL_DIG -- maximum number of decimal digits that "
+                    "can be faithfully represented in a float"},
     {"mant_dig",        "DBL_MANT_DIG -- mantissa digits"},
     {"epsilon",         "DBL_EPSILON -- Difference between 1 and the next "
                     "representable float"},
     {"radix",           "FLT_RADIX -- radix of exponent"},
-    {"rounds",          "FLT_ROUNDS -- rounding mode"},
+    {"rounds",          "FLT_ROUNDS -- rounding mode used for arithmetic "
+                    "operations"},
     {0}
 };
 



More information about the Python-checkins mailing list