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

Unused Math.abs call in java.lang.FdLibm.Expm1#compute

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P5 P5
    • 23
    • 23
    • core-libs
    • 21
    • b21

      IntelliJ IDEA highlights that initial assignment of 'y' is unnecessary.

      y = Math.abs(x);

      https://github.com/openjdk/jdk/blob/c9f8d0eff706d9ac59179afbb821367da09c9aae/src/java.base/share/classes/java/lang/FdLibm.java#L3008

      After removing assignment code is still compiles. So it seems unnecessary.

            darcy Joe Darcy
            aturbanov Andrey Turbanov
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: