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

java.math.BigDecimal constructor works wrong with negative numbers.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P2 P2
    • 1.1
    • 1.1
    • core-libs
    • 1.1fcs
    • x86, sparc
    • solaris_2.5, windows_95
    • Not verified



      Name: mgC56079 Date: 01/23/97



      ============== Here is the test ==========
      import java.math.BigDecimal;
      public class Ctor {
        public static void main (String[] args) {
          BigDecimal d=new BigDecimal("-0.12345");
          System.out.println("d="+d);
        }
      }
      ============= Here is the output of the test =============
      % java Ctor
      d=0.12345
      ===========================================================
      ======================================================================

            jjb Josh Bloch (Inactive)
            mgorshen Mikhail Gorshenev (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: