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

Method createNumber from NumberUtils doesn't work for floating point numbers other than Float

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Duplicate
    • Affects Version/s: 3.4
    • Fix Version/s: None
    • Component/s: lang.math.*
    • Labels:
      None

      Description

      demo:

      Number n = org.apache.commons.lang3.math.NumberUtils.createNumber("6264583.33");
      System.out.println("lang3_createNumber_6264583.33---->" + n);

      while n will be 6264583.5. not 6264583.33

        Attachments

        Issue Links

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              leizhiyuan leizhiyuan

              Dates

              • Created:
                Updated:
                Resolved:

                Issue deployment