(self, a, b)
| 225 | class Mod(Div): # Sharing GenerateInputLengths. |
| 226 | def GetOpString(self): return "%" |
| 227 | def GenerateResult(self, a, b): |
| 228 | result = a % b |
| 229 | if a < 0 and result > 0: |
| 230 | result -= abs(b) |
| 231 | if a > 0 and result < 0: |
| 232 | result += abs(b) |
| 233 | return result |
| 234 | |
| 235 | class Shl(BinaryOp): |
| 236 | def GetOpString(self): return "<<" |