commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ericbarnh...@apache.org
Subject [33/36] commons-numbers git commit: NUMBERS-48: Dead code has been removed
Date Fri, 26 Jan 2018 14:44:53 GMT
NUMBERS-48: Dead code has been removed


Project: http://git-wip-us.apache.org/repos/asf/commons-numbers/repo
Commit: http://git-wip-us.apache.org/repos/asf/commons-numbers/commit/16322d83
Tree: http://git-wip-us.apache.org/repos/asf/commons-numbers/tree/16322d83
Diff: http://git-wip-us.apache.org/repos/asf/commons-numbers/diff/16322d83

Branch: refs/heads/master
Commit: 16322d83ab3092e93a1e2d7f576b185682c16f69
Parents: dc43084
Author: Eric Barnhill <ericbarnhill@apache.org>
Authored: Wed Sep 13 15:16:46 2017 +0200
Committer: Eric Barnhill <ericbarnhill@apache.org>
Committed: Wed Sep 13 15:16:46 2017 +0200

----------------------------------------------------------------------
 .../src/main/java/org/apache/commons/numbers/complex/Complex.java | 3 ---
 1 file changed, 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/commons-numbers/blob/16322d83/commons-numbers-complex/src/main/java/org/apache/commons/numbers/complex/Complex.java
----------------------------------------------------------------------
diff --git a/commons-numbers-complex/src/main/java/org/apache/commons/numbers/complex/Complex.java
b/commons-numbers-complex/src/main/java/org/apache/commons/numbers/complex/Complex.java
index 5470d5e..71a4220 100644
--- a/commons-numbers-complex/src/main/java/org/apache/commons/numbers/complex/Complex.java
+++ b/commons-numbers-complex/src/main/java/org/apache/commons/numbers/complex/Complex.java
@@ -184,9 +184,6 @@ public class Complex implements Serializable  {
      */
     public double abs() {
         if (Math.abs(real) < Math.abs(imaginary)) {
-            if (imaginary == 0.0) {
-                return Math.abs(real);
-            }
             final double q = real / imaginary;
             return Math.abs(imaginary) * Math.sqrt(1 + q * q);
         } else {


Mime
View raw message