The source project of this merge request has been removed.
Fix Mod operator
This MR corrects the sign of the result in the case of a negative divisor or dividend.
The sign of the result of the % operator in C++ is that of the dividend:
7 % (-3) = 1
(-7) % 3 = -1
The expected sign of the result of the [Mod] operator is that of the divisor:
7 Mod (-3) = -2 (and not 1)
(-7) Mod 3 = 2 (and not -1)
Edited by Olivier Antoni