3 ms·
It's been a while but IIRC Groovy (a JVM language) overloaded "+" etc to let you operate on BigDecimals using standard operators. Obviously Groovy is very obscu
by signal11 8y ago
It's been a while but IIRC Groovy (a JVM language) overloaded "+" etc to let you operate on BigDecimals using standard operators. Obviously Groovy is very obscure compared to Java, but Java has had Project Coin and its successors for a while now -- their remit was to add syntax sugar to the language to make using it more plesant. Making working with arbitrary-precision math easier should be something the Java language authors should support, so I'm hoping they'll consider adding support for arithmetic on BigDecimal in future releases (especially now that they are on a faster release cadence).