[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 1/2] inet_ntop: silence gcc warning
From: |
Paul Eggert |
Subject: |
Re: [PATCH 1/2] inet_ntop: silence gcc warning |
Date: |
Wed, 11 Jan 2012 15:44:16 -0800 |
User-agent: |
Mozilla/5.0 (X11; Linux i686; rv:8.0) Gecko/20111124 Thunderbird/8.0 |
On 01/11/12 15:24, Eric Blake wrote:
> + best.len = 0;
I have some qualms about adding unnecessary initializations
merely to silence GCC. It's not just that it bloats the
runtime -- it's that it makes the code more confusing, because
later readers might mistakenly assume that the initializations
are necessary, which might cause them to waste time trying to figure
out why the initializations are there.
How about if we put that assignment inside an "#ifdef lint",
or wrap it in IF_LINT, or something like that? That should
make it clearer and avoid the runtime bloat.
- FYI misc compile warnings on Mingw32, Daniel P. Berrange, 2012/01/11
- [PATCH 0/2] silence some mingw warnings, Eric Blake, 2012/01/11
- [PATCH 1/2] inet_ntop: silence gcc warning, Eric Blake, 2012/01/11
- Re: [PATCH 1/2] inet_ntop: silence gcc warning,
Paul Eggert <=
- Re: [PATCH 1/2] inet_ntop: silence gcc warning, Eric Blake, 2012/01/11
- Re: [PATCH 1/2] inet_ntop: silence gcc warning, Eric Blake, 2012/01/11
- Re: [PATCH 1/2] inet_ntop: silence gcc warning, Paul Eggert, 2012/01/11
- Re: [PATCH 1/2] inet_ntop: silence gcc warning, Jim Meyering, 2012/01/12
- Re: [PATCH 1/2] inet_ntop: silence gcc warning, Eric Blake, 2012/01/12