6 ms·
Didn't Clojure change the + function (hardly obscure!) from automatically updating ints to bigints and therefore never overflowing to throwing an exception if y
by thaumasiotes 8y ago
Didn't Clojure change the + function (hardly obscure!) from automatically updating ints to bigints and therefore never overflowing to throwing an exception if you added ints that were too big?
I've got a Clojure book with a spirited defense of why it's good that the simple symbol + just does what you'd expect instead of throwing exceptions based on an implementation detail, and it kind of falls flat now.
- puredanger 8y agoThat was over 7 years ago, so not particularly recent. And you can get the auto-promoting behavior with +' instead.
- solussd 8y agoYes, very early in Clojure's life and only after testing the change across several popular libraries.