(self)
| 662 | |
| 663 | @testing.fixture |
| 664 | def modulus(self): |
| 665 | class MyInteger(Integer): |
| 666 | class comparator_factory(Integer.Comparator): |
| 667 | def modulus(self): |
| 668 | return UnaryExpression( |
| 669 | self.expr, |
| 670 | modifier=operators.custom_op("%"), |
| 671 | type_=MyInteger, |
| 672 | ) |
| 673 | |
| 674 | def modulus_prefix(self): |
| 675 | return UnaryExpression( |
| 676 | self.expr, |
| 677 | operator=operators.custom_op("%"), |
| 678 | type_=MyInteger, |
| 679 | ) |
| 680 | |
| 681 | return MyInteger |
| 682 | |
| 683 | @testing.combinations( |
| 684 | ("format",), |