MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / copy_negate

Method copy_negate

tools/python-3.11.9-amd64/Lib/_pydecimal.py:3033–3038  ·  view source on GitHub ↗

Returns a copy with the sign inverted.

(self)

Source from the content-addressed store, hash-verified

3031 return _dec_from_triple(0, self._int, self._exp, self._is_special)
3032
3033 def copy_negate(self):
3034 """Returns a copy with the sign inverted."""
3035 if self._sign:
3036 return _dec_from_triple(0, self._int, self._exp, self._is_special)
3037 else:
3038 return _dec_from_triple(1, self._int, self._exp, self._is_special)
3039
3040 def copy_sign(self, other, context=None):
3041 """Returns self with the sign of other."""

Callers 4

__neg__Method · 0.95
__pow__Method · 0.95
__sub__Method · 0.45
copy_negateMethod · 0.45

Calls 1

_dec_from_tripleFunction · 0.85

Tested by

no test coverage detected