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

    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
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: