You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by bu...@apache.org on 2005/06/09 08:42:36 UTC
DO NOT REPLY [Bug 33841] -
[beanutils] FloatLocaleConverter cannot parse negative values
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=33841>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=33841
------- Additional Comments From skitching@apache.org 2005-06-09 08:42 -------
I agree the FloatLocateConverter is horribly broken for negative numbers.
But I'm not sure what the code here really should be. The existing code doesn't
make any sense to me. And it doesn't correctly handle things like infinity, NaN,
etc. And the non-locale-aware FloatConverter doesn't do this check anyway.
So I would like to just rip all this out, and return
new Float(number.floatValue());
This is potentially a minor backwards incompatibility - but only in
circumstances where the original code would have thrown a ConversionException.
That's actually another reason for ripping this code out - currently, this class
can throw a ConversionException even when the converter has a default value
defined, which users would expect to suppress all conversion exceptions.
Comments?
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org