MCPcopy Index your code
hub / github.com/RustPython/RustPython / __rsub__

Method __rsub__

extra_tests/snippets/builtin_complex.py:155–156  ·  view source on GitHub ↗
(self, other)

Source from the content-addressed store, hash-verified

153 return Complex(self.real - other, self.imag)
154
155 def __rsub__(self, other):
156 return Complex(other - self.real, -self.imag)
157
158 def __eq__(self, other):
159 return self.real == other.real and self.imag == other.imag

Callers 3

builtin_float.pyFile · 0.45
builtin_set.pyFile · 0.45
builtin_int.pyFile · 0.45

Calls 1

ComplexClass · 0.70

Tested by

no test coverage detected