PATCH: Bad signed int to long long conversion
Torbjorn Granlund
tg at gmplib.org
Thu Dec 1 23:27:28 CET 2011
Vincent Lefevre <vincent at vinc17.net> writes:
On 2011-12-01 13:13:05 +0100, Torbjorn Granlund wrote:
> Let's not get too alarmed by this "bug";
> I'd argue that the real bug is in the C standard.
No, the C standard is correct.
By definition?
I don't mind that somebody patches up all occurences of signed negation
where the smallest negative value could hypothetically appear. I just
never saw any problems with the usage in GMP, and prefer to work on
problem i think are real.
We actually do avoid right shift of signed numbers in GMP, but that is
actually a less hypothetical problem.
Language standards are good things, but we should reap their benefits,
not become their slaves.
--
Torbjörn
More information about the gmp-bugs
mailing list