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

Use literals instead of static fields in java.util.Math: twoToTheDoubleScaleUp, twoToTheDoubleScaleDown

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P5 P5
    • 22
    • None
    • core-libs
    • None
    • b10

      Couple of static fields in Math are used only once and can be replaced with literals 0x1p512/0x1p-512

          // Constants used in scalb
          static double twoToTheDoubleScaleUp = powerOfTwoD(512);
          static double twoToTheDoubleScaleDown = powerOfTwoD(-512);

            aturbanov Andrey Turbanov
            aturbanov Andrey Turbanov
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: