Mercurial > hg > xemacs-beta
diff src/floatfns.c @ 4931:8a08cf0b7583
merge
| author | Ben Wing <ben@xemacs.org> |
|---|---|
| date | Thu, 21 Jan 2010 00:46:37 -0600 |
| parents | 6c0bb4d2c23a |
| children | 6ef8256a020a 19a72041c5ed |
line wrap: on
line diff
--- a/src/floatfns.c Wed Jan 20 04:20:49 2010 -0600 +++ b/src/floatfns.c Thu Jan 21 00:46:37 2010 -0600 @@ -26,7 +26,6 @@ Define HAVE_INVERSE_HYPERBOLIC if you have acosh, asinh, and atanh. Define HAVE_CBRT if you have cbrt(). - Define HAVE_RINT if you have rint(). If you don't define these, then the appropriate routines will be simulated. Define HAVE_MATHERR if on a system supporting the SysV matherr() callback. @@ -50,11 +49,8 @@ #include "syssignal.h" #include "sysfloat.h" -/* The code uses emacs_rint, so that it works to undefine HAVE_RINT - if `rint' exists but does not work right. */ -#ifdef HAVE_RINT -#define emacs_rint rint -#else +/* An implementation of rint that always rounds towards the even number in + the case of ambiguity. */ static double emacs_rint (double x) { @@ -65,7 +61,6 @@ r += r < x ? 1.0 : -1.0; return r; } -#endif /* Nonzero while executing in floating point. This tells float_error what to do. */
