Uploaded image for project: 'Commons Lang'
  1. Commons Lang
  2. LANG-1484

NumberUtils.isParsable returns false for strings ending with .

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 3.8.1
    • Fix Version/s: None
    • Component/s: lang.math.*
    • Labels:
      None
    • Environment:

      Tested on Linux with OpenJDK 10.0.2 and Windows with Oracle Java 8 Update 201.

      Description

      From the Javadocs:

      Parsable numbers include those Strings understood by ... Double.parseDouble(String).

      Double.parseDouble("100.") returns a valid double (it does not throw a NumberFormatException); however, NumberUtils.isParsable("100.") returns false.

       

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                seniorquico Kyle Dodson
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 1.5h
                  1.5h