commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jeremy Lemaire (JIRA)" <j...@apache.org>
Subject [jira] Created: (LANG-300) NumberUtils.createNumber throws NumberFormatException for one digit long
Date Tue, 19 Dec 2006 17:48:23 GMT
NumberUtils.createNumber throws NumberFormatException for one digit long 
-------------------------------------------------------------------------

                 Key: LANG-300
                 URL: http://issues.apache.org/jira/browse/LANG-300
             Project: Commons Lang
          Issue Type: Bug
    Affects Versions: 2.2
            Reporter: Jeremy Lemaire


NumberUtils.createNumber throws a NumberFormatException when parsing "1l", "2l" .. etc...

It works fine if you try to parse "01l" or "02l".  The condition isDigits(numeric.substring(1)),
line 455 return false as numeric.substring(1) is an empty string for "1l"

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message