[geos-commits] [SCM] GEOS branch master updated. 531b9e623107a325a87cc5cbf7c6a399217b3fdd

git at osgeo.org git at osgeo.org
Thu Nov 5 12:20:12 PST 2020


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GEOS".

The branch, master has been updated
       via  531b9e623107a325a87cc5cbf7c6a399217b3fdd (commit)
      from  76d7586ea53b2f9796bd4257d1d997fe05f11703 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 531b9e623107a325a87cc5cbf7c6a399217b3fdd
Author: Paul Ramsey <pramsey at cleverelephant.ca>
Date:   Thu Nov 5 12:20:02 2020 -0800

    Remove un-used method

diff --git a/include/geos/math/DD.h b/include/geos/math/DD.h
index 0e94681..dfe5251 100644
--- a/include/geos/math/DD.h
+++ b/include/geos/math/DD.h
@@ -111,7 +111,6 @@ class GEOS_DLL DD {
         double hi;
         double lo;
 
-        int magnitude(double x) const;
         int signum() const;
         DD rint() const;
 
diff --git a/src/math/DD.cpp b/src/math/DD.cpp
index 673e921..c620c1b 100644
--- a/src/math/DD.cpp
+++ b/src/math/DD.cpp
@@ -21,24 +21,6 @@ namespace geos {
 namespace math { // geos.util
 
 
-/* private */
-int
-DD::magnitude(double x) const
-{
-    double xAbs = std::fabs(x);
-    double xLog10 = std::log(xAbs) / std::log(10);
-    int xMag = (int) std::floor(xLog10);
-    /**
-     * Since log computation is inexact, there may be an off-by-one error
-     * in the computed magnitude.
-     * Following tests that magnitude is correct, and adjusts it if not
-     */
-    double xApprox = std::pow(10, xMag);
-    if (xApprox * 10 <= xAbs)
-      xMag += 1;
-
-    return xMag;
-}
 
 /* public */
 bool DD::isNaN() const

-----------------------------------------------------------------------

Summary of changes:
 include/geos/math/DD.h |  1 -
 src/math/DD.cpp        | 18 ------------------
 2 files changed, 19 deletions(-)


hooks/post-receive
-- 
GEOS


More information about the geos-commits mailing list