Re: Should rand() return a RAND_MAX value for 32 bit target?

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

 



On 2018-09-22 10:17:04 +0200, Vincent Lefevre wrote:
> Thus if one does
> 
>   float a;
>   int b;
> 
>   /* ... */
>   a + b;
> 
> with FLT_EVAL_METHOD = 2, the evaluation type of a is long double, b
> is converted to the semantic type float, but its evaluation type is
> long double, so that its value should not change if representable as
> a long double. That's what FLT_EVAL_METHOD means. The *only* cases
> for which the precision and range need to be reduced to those of the
> semantic type if for assignment and cast, but here one just has an
> implicit conversion.

Bug reported here: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87390
(note that the tests do not involve constants, these are just about
implicit type conversions).

-- 
Vincent Lefèvre <vincent@xxxxxxxxxx> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux