On Friday, 18 March 2016 at 05:20:35 UTC, Ola Fosheim Grøstaf wrote:
Only providing modular arithmetics is a significant language design flaw, but as long as all integers are defined to be modular then there is no fundamental semantic difference either.

`ulong.max` and `-1L` are fundamentally different semantically, even with two's complement modular arithmetic.

Just because a few operations (addition and subtraction, mainly) can use a common implementation for both, does not change that. Division, for example, cannot be done correctly without knowing whether the inputs are signed or not.

Reply via email to