3 ms·
Casting to signed long is demonstrably wrong. The code in question is (probably) pretty slow, offering plenty of room for improvement beyond just fixing the UB
by ncmncm 5y ago
Casting to signed long is demonstrably wrong.
The code in question is (probably) pretty slow, offering plenty of room for improvement beyond just fixing the UB. But it has seemed to work well enough, so far, like most things.