bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: operation of 'round' function


From: Eli Zaretskii
Subject: Re: operation of 'round' function
Date: Fri, 08 Feb 2002 12:00:08 +0200

> From: Francesco Potorti` <pot@gnu.org>
> Newsgroups: gnu.emacs.bug
> Date: 08 Feb 2002 10:29:26 +0100
> 
> but the documentation for rint does not mention even integers anywhere.
> Rather, it makes reference to the current rounding mode:
> 
>  - Function: double rint (double X)
>  - Function: float rintf (float X)
>  - Function: long double rintl (long double X)
>      These functions round X to an integer value according to the
>      current rounding mode.  *Note Floating Point Parameters::, for
>      information about the various rounding modes.  The default
>      rounding mode is to round to the nearest integer; some machines
>      support other modes, but round-to-nearest is always used unless
>      you explicitly select another.
> 
> Which again says nothing about even integers.

You should be able to find that info in the Intel manual (assuming an
x86 CPU).  It says that under the default rounding mode,

   [...] If two values are equally close, the result is the even value
   (that is, the one with the least-significant bit of zero).



reply via email to

[Prev in Thread] Current Thread [Next in Thread]