summaryrefslogtreecommitdiff
path: root/numpy/core
diff options
context:
space:
mode:
authorCharles Harris <charlesr.harris@gmail.com>2017-09-23 10:01:21 -0500
committerGitHub <noreply@github.com>2017-09-23 10:01:21 -0500
commite413b8f2568dcb6912f107bd68caaa27a85fc2da (patch)
tree33b14950bea21874d68e6953e8c4762cf959f6c6 /numpy/core
parentede8c80f52e040e6481bce43237c708954b7b91f (diff)
parenta82a67ba3f2f7ce701c871e1cd30d5b3cb51073b (diff)
downloadnumpy-e413b8f2568dcb6912f107bd68caaa27a85fc2da.tar.gz
Merge pull request #9749 from eric-wieser/divmod-longdouble
BUG: Fix loss of precision for large values in long double divmod
Diffstat (limited to 'numpy/core')
-rw-r--r--numpy/core/src/npymath/npy_math_internal.h.src2
1 files changed, 1 insertions, 1 deletions
diff --git a/numpy/core/src/npymath/npy_math_internal.h.src b/numpy/core/src/npymath/npy_math_internal.h.src
index 44d6f915f..093e51b2d 100644
--- a/numpy/core/src/npymath/npy_math_internal.h.src
+++ b/numpy/core/src/npymath/npy_math_internal.h.src
@@ -659,7 +659,7 @@ npy_divmod@c@(@type@ a, @type@ b, @type@ *modulus)
/* snap quotient to nearest integral value */
if (div) {
- floordiv = npy_floor(div);
+ floordiv = npy_floor@c@(div);
if (div - floordiv > 0.5@c@)
floordiv += 1.0@c@;
}