https://github.com/python/cpython/commit/4f24b92aa0677ed5310dd2d1572b55f4e30c88ef
commit: 4f24b92aa0677ed5310dd2d1572b55f4e30c88ef
branch: main
author: Sergey B Kirpichev <[email protected]>
committer: hauntsaninja <[email protected]>
date: 2024-01-15T14:19:59-08:00
summary:
gh-114070: correct the specification of ``digit`` in the float() docs (#114080)
files:
M Doc/library/functions.rst
diff --git a/Doc/library/functions.rst b/Doc/library/functions.rst
index 4682ec9c924757..37234f7a5a2485 100644
--- a/Doc/library/functions.rst
+++ b/Doc/library/functions.rst
@@ -668,16 +668,15 @@ are always available. They are listed here in
alphabetical order.
sign: "+" | "-"
infinity: "Infinity" | "inf"
nan: "nan"
- digitpart: `!digit` (["_"] `!digit`)*
+ digit: <a Unicode decimal digit, i.e. characters in Unicode general
category Nd>
+ digitpart: `digit` (["_"] `digit`)*
number: [`digitpart`] "." `digitpart` | `digitpart` ["."]
exponent: ("e" | "E") ["+" | "-"] `digitpart`
floatnumber: number [`exponent`]
floatvalue: [`sign`] (`floatnumber` | `infinity` | `nan`)
- Here ``digit`` is a Unicode decimal digit (character in the Unicode general
- category ``Nd``). Case is not significant, so, for example, "inf", "Inf",
- "INFINITY", and "iNfINity" are all acceptable spellings for positive
- infinity.
+ Case is not significant, so, for example, "inf", "Inf", "INFINITY", and
+ "iNfINity" are all acceptable spellings for positive infinity.
Otherwise, if the argument is an integer or a floating point number, a
floating point number with the same value (within Python's floating point
_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/python-checkins.python.org/
Member address: [email protected]