Silent numerical overflow has to be one of the most costly "features" introduced in prog langs – rivaling the horrible null.
-
-
Replying to @viktorklang
.
@viktorklang However, I think BigInteger optimized for small values should be the default. Let performance be an optimization, not default2 replies 0 retweets 0 likes -
Replying to @dcsobral
@dcsobral@viktorklang Check out SafeLong in Spire. I've also heard that IBM's JVM does optimize BigInteger for small values. /cc@d62 replies 0 retweets 0 likes -
Replying to @tixxit
.
@tixxit@viktorklang@d6 Yeah, but the most important thing would be calling it int or number, and use signed32BitsInteger for the other.1 reply 0 retweets 0 likes -
Replying to @dcsobral
@dcsobral@tixxit@viktorklang There's just no pleasing you is there??? We have spire.math.Number though it's not just overflow safe int ;)1 reply 0 retweets 0 likes -
Replying to @d6
.
@d6@tixxit@viktorklang Don't get me wrong -- I loved learning about it. But my point is that this is what languages should *push*.1 reply 0 retweets 0 likes -
Replying to @dcsobral
@dcsobral@d6@tixxit@viktorklang Correct but slow isn't popular :( Trig benches were used to deride Java < 5 due to strictfp default.1 reply 0 retweets 0 likes -
Replying to @tixxit
@tixxit@d6@viktorklang Yeah, people prefer faster over correct. I can make it very fast if it doesn't have to work, though.1 reply 0 retweets 0 likes
@dcsobral @d6 @viktorklang lol. type BigInt = Long ; // Fast arbitrary precision int.
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.