Method
__sub__
(
&self,
other: PyObjectRef,
vm: &VirtualMachine,
)
Source from the content-addressed store, hash-verified
| 622 | } |
| 623 | |
| 624 | fn __sub__( |
| 625 | &self, |
| 626 | other: PyObjectRef, |
| 627 | vm: &VirtualMachine, |
| 628 | ) -> PyResult<PyArithmeticValue<Self>> { |
| 629 | if let Ok(other) = AnySet::try_from_object(vm, other) { |
| 630 | Ok(PyArithmeticValue::Implemented(self.op( |
| 631 | other, |
| 632 | PySetInner::difference, |
| 633 | vm, |
| 634 | )?)) |
| 635 | } else { |
| 636 | Ok(PyArithmeticValue::NotImplemented) |
| 637 | } |
| 638 | } |
| 639 | |
| 640 | fn __rsub__( |
| 641 | zelf: PyRef<Self>, |
Tested by
no test coverage detected