GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||
GeezerVison is showing github.com — gh-73487: Convert _decimal to use Argument Clinic (part 4) by skirpichev · Pull Request #137931 · python/cpython Conversation
|
|
Docstrings diff: --- ref.txt 2025-08-20 12:30:34.001295564 +0300 +++ patch.txt 2025-08-20 12:29:57.118168737 +0300 @@ -108,13 +108,16 @@ | Methods defined here: | | Etiny(self, /) - | Return a value equal to Emin - prec + 1, which is the minimum exponent value - | for subnormal results. When underflow occurs, the exponent is set to Etiny. + | Return a value equal to Emin - prec + 1. + | + | This is the minimum exponent value for subnormal results. When + | underflow occurs, the exponent is set to Etiny. | | Etop(self, /) - | Return a value equal to Emax - prec + 1. This is the maximum exponent - | if the _clamp field of the context is set to 1 (IEEE clamp mode). Etop() - | must not be negative. + | Return a value equal to Emax - prec + 1. + | + | This is the maximum exponent if the _clamp field of the context is set + | to 1 (IEEE clamp mode). Etop() must not be negative. | | __copy__(self, /) | @@ -437,10 +440,12 @@ class Decimal(builtins.object) | Decimal(value='0', context=None) | - | Construct a new Decimal object. 'value' can be an integer, string, tuple, - | or another Decimal object. If no value is given, return Decimal('0'). The - | context does not affect the conversion and is only passed to determine if - | the InvalidOperation trap is active. + | Construct a new Decimal object. + | + | value can be an integer, string, tuple, or another Decimal object. If + | no value is given, return Decimal('0'). The context does not affect + | the conversion and is only passed to determine if the InvalidOperation + | trap is active. | | Methods defined here: | @@ -454,12 +459,14 @@ | True if self else False | | __ceil__(self, /) + | Return the ceiling as an Integral. | | __complex__(self, /) + | Convert this value to exact type complex. | | __copy__(self, /) | - | __deepcopy__(self, object, /) + | __deepcopy__(self, memo, /) | | __divmod__(self, value, /) | Return divmod(self, value). @@ -471,6 +478,7 @@ | float(self) | | __floor__(self, /) + | Return the floor as an Integral. | | __floordiv__(self, value, /) | Return self//value. @@ -524,7 +532,7 @@ | Return divmod(value, self). | | __reduce__(self, /) - | Helper for pickle. + | Return state information for pickling. | | __repr__(self, /) | Return repr(self). @@ -538,7 +546,8 @@ | __rmul__(self, value, /) | Return value*self. | - | __round__(...) + | __round__(self, ndigits=<unrepresentable>, /) + | Return the Integral closest to self, rounding half toward even. | | __rpow__(self, value, mod=None, /) | Return pow(value, self, mod). @@ -550,7 +559,7 @@ | Return value/self. | | __sizeof__(self, /) - | Size of object in memory, in bytes. + | Returns size in memory, in bytes | | __str__(self, /) | Return str(self). @@ -562,6 +571,7 @@ | Return self/value. | | __trunc__(self, /) + | Return the Integral closest to x between 0 and x. | | adjusted(self, /) | Return the adjusted exponent (exp + digits - 1) of the number. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
LGTM. 👍
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Thanks! A |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.