]> git.eshelyaron.com Git - emacs.git/commitdiff
* src/floatfns.c (Fftruncate): Simplify via emacs_trunc.
authorPaul Eggert <eggert@cs.ucla.edu>
Sun, 5 Mar 2017 07:14:51 +0000 (23:14 -0800)
committerPaul Eggert <eggert@cs.ucla.edu>
Sun, 5 Mar 2017 07:18:38 +0000 (23:18 -0800)
src/floatfns.c

index 94da22a3ba7fb8768e548d12c47c20f97cbf0a73..9ae810669effcf021b81e445771e3d85c0d1e930 100644 (file)
@@ -534,10 +534,7 @@ Rounds the value toward zero.  */)
   (Lisp_Object arg)
 {
   double d = extract_float (arg);
-  if (d >= 0.0)
-    d = floor (d);
-  else
-    d = ceil (d);
+  d = emacs_trunc (d);
   return make_float (d);
 }
 \f