[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: warnings compiling Emacs 22 on amd64
From: |
Stefan Monnier |
Subject: |
Re: warnings compiling Emacs 22 on amd64 |
Date: |
Tue, 12 Dec 2006 11:22:20 -0500 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.91 (gnu/linux) |
>> But since this warning is about something which is not itself a bug, either
>> gcc provides a way to annotate the code to indicate that this is not a bug
>> (like the use of double-parens to turn off the warning about assignment in
>> an `if'), or there's not much we can do about it (other than try to work
>> around it by making the code ugly, less robust, and maybe even less
>> efficient: after all the warning here is output specifically when gcc finds
>> an optimization).
> First I tried to work around it by making the code slightly more
> complex, but still clear. However, I failed.
> I looked at the gcc 4.1 info page, and I found no warnings to turn off
> that are specific for this case (I looked for the string "compar").
Yes, I believe there's no way. Which is why I think the least bad course
is -Wno-foo.
> As far as code annotations are concerned, I don't know where to look: I
> had never heard of the double parenthesis trick, nor was I able to find
> it in the gcc info page.
Can't remember where I saw it, but if you do
if (foo = bar) ...
gcc warns that you may have meant == instead of =, so if you really meant =
you can just write
if ((foo = bar)) ...
and gcc will then keep quiet.
Stefan
- Re: warnings compiling Emacs 22 on amd64, (continued)
- Re: warnings compiling Emacs 22 on amd64, Eli Zaretskii, 2006/12/09
- Re: warnings compiling Emacs 22 on amd64, Francesco Potorti`, 2006/12/11
- Re: warnings compiling Emacs 22 on amd64, Eli Zaretskii, 2006/12/11
- Re: warnings compiling Emacs 22 on amd64, Stefan Monnier, 2006/12/11
- Re: warnings compiling Emacs 22 on amd64, Eli Zaretskii, 2006/12/11
- Re: warnings compiling Emacs 22 on amd64, Stefan Monnier, 2006/12/11
- Re: warnings compiling Emacs 22 on amd64, Eli Zaretskii, 2006/12/12
- Re: warnings compiling Emacs 22 on amd64, Francesco Potorti`, 2006/12/12
- Re: warnings compiling Emacs 22 on amd64, Stefan Monnier, 2006/12/12
- Re: warnings compiling Emacs 22 on amd64, Francesco Potorti`, 2006/12/12
- Re: warnings compiling Emacs 22 on amd64,
Stefan Monnier <=
- Re: warnings compiling Emacs 22 on amd64, Francesco Potorti`, 2006/12/12
- Re: warnings compiling Emacs 22 on amd64, Stefan Monnier, 2006/12/12
- Re: warnings compiling Emacs 22 on amd64, Francesco Potorti`, 2006/12/12