2 ms·
> It uses by default BigDecimal and BigInteger for literal numeric types Apache Groovy uses by default BigDecimal for literal decimal types, but only uses BigI
by vorg 9y ago
> It uses by default BigDecimal and BigInteger for literal numeric types
Apache Groovy uses by default BigDecimal for literal decimal types, but only uses BigInteger for literal integral types when it would overflow the largest available primitive type for that literal. You can force a BigInteger by using the suffix `g` on the integral literal. Perhaps misunderstanding this is the source of some hard-to-find bugs in some of your Groovy code.