Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
1.0-JSR-5
-
None
-
None
-
Java 1.5, Win XP
Description
with JSR 05 I get an error when calling:
println new java.text.DecimalFormat().format(23)
groovy.lang.GroovyRuntimeException: Ambiguous method overloading for method java.text.DecimalFormat#format.
Cannot resolve which method to invoke for
due to overlapping prototypes between:
{long} {double}I have the workaround to call
println new java.text.DecimalFormat().format(23 as long)
but I don't like this very much.
An int fits perfectly in a long, so there shouldn't be any disambiguity
between long, double.