diff options
author | Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> | 2021-05-14 22:25:43 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-14 22:25:43 (GMT) |
commit | fa9de0c383581936de3338c8dc6b58c10a6e27b8 (patch) | |
tree | 694893cec32db516ff97914063cb9b034675d6ea /Lib/numbers.py | |
parent | c90642b0d48e5ab40d05b526311ba19bb87f3233 (diff) | |
download | cpython-fa9de0c383581936de3338c8dc6b58c10a6e27b8.zip cpython-fa9de0c383581936de3338c8dc6b58c10a6e27b8.tar.gz cpython-fa9de0c383581936de3338c8dc6b58c10a6e27b8.tar.bz2 |
bpo-44072: fix Complex, Integral docs for `**` (GH-25986)
In numbers module docstrings and docs.
(cherry picked from commit 4aa63d65a9971d14f1a2131b989dca0dab514a9d)
Co-authored-by: Rory Yorke <rory.yorke@gmail.com>
Diffstat (limited to 'Lib/numbers.py')
-rw-r--r-- | Lib/numbers.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/Lib/numbers.py b/Lib/numbers.py index ed815ef..5b98e64 100644 --- a/Lib/numbers.py +++ b/Lib/numbers.py @@ -33,7 +33,7 @@ class Complex(Number): """Complex defines the operations that work on the builtin complex type. In short, those are: a conversion to complex, .real, .imag, +, -, - *, /, abs(), .conjugate, ==, and !=. + *, /, **, abs(), .conjugate, ==, and !=. If it is given heterogeneous arguments, and doesn't have special knowledge about them, it should fall back to the builtin complex @@ -292,7 +292,11 @@ class Rational(Real): class Integral(Rational): - """Integral adds a conversion to int and the bit-string operations.""" + """Integral adds methods that work on integral numbers. + + In short, these are conversion to int, pow with modulus, and the + bit-string operations. + """ __slots__ = () |