On Sun, 10 Nov 2024, 08:26 Sad Clouds via Gcc, wrote:
> On Sat, 9 Nov 2024 11:49:56 -0800
> Andrew Pinski wrote:
>
> > You can use the diagnostic pragma to disable it directly for the
> statement.
>
> Thanks for the tip. After a quick search, I came across this page,
> which explains it:
> https
On Sun, 10 Nov 2024 09:45:41 +
Jonathan Wakely wrote:
> Does clang only have a special case for 0.0, or for any literal value?
>
It looks like clang can detect which floating point literals can be
represented exactly and does not generate any warnings for those.
$ cat test.c
#include
int
On Sun, 10 Nov 2024, Jonathan Wakely via Gcc wrote:
> But 1 - (10 * 0.1) won't, and so the warning is pointing out that any exact
> equality comparisons can be affected by this kind of problem. If you don't
> like the warning, don't enable it.
I think OP's questions are in good faith and your l
On Sun, 10 Nov 2024, 11:13 Alexander Monakov, wrote:
>
> On Sun, 10 Nov 2024, Jonathan Wakely via Gcc wrote:
>
> > But 1 - (10 * 0.1) won't, and so the warning is pointing out that any
> exact
> > equality comparisons can be affected by this kind of problem. If you
> don't
> > like the warning, d
On Sat, 9 Nov 2024 11:49:56 -0800
Andrew Pinski wrote:
> You can use the diagnostic pragma to disable it directly for the statement.
Thanks for the tip. After a quick search, I came across this page,
which explains it:
https://gcc.gnu.org/onlinedocs/gcc/Diagnostic-Pragmas.html
> But I will not
Snapshot gcc-15-20241110 is now available on
https://gcc.gnu.org/pub/gcc/snapshots/15-20241110/
and on various mirrors, see https://gcc.gnu.org/mirrors.html for details.
This snapshot has been generated from the GCC 15 git branch
with the following options: git://gcc.gnu.org/git/gcc.git branch