Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-1191335

Math.round fails for negative numbers

    XMLWordPrintable

    Details

    • Subcomponent:
    • Resolved In Build:
      1.0alpha2
    • CPU:
      sparc
    • OS:
      solaris_2.4
    • Verification:
      Not verified

      Description

      Apparently casting to int does a truncate towards zero which is
      not the correct operation to use for rounding. Math.floor should
      be used instead.

        Attachments

          Activity

            People

            Assignee:
            flar Jim Graham
            Reporter:
            flar Jim Graham
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: