[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] Use "do...while (0)", not "if (1)..else" in macro definition
From: |
Jan Djärv |
Subject: |
Re: [PATCH] Use "do...while (0)", not "if (1)..else" in macro definitions. |
Date: |
Thu, 07 Feb 2008 13:56:54 +0100 |
User-agent: |
Thunderbird 2.0.0.6 (X11/20071022) |
Jim Meyering skrev:
>> 2008-01-28 Jim Meyering <address@hidden>
>>
>> Use "do...while (0)", not "if (1)..else" in macro definitions.
>> The latter provokes a warning from gcc about the empty else, when
>> followed by ";". Also, without that trailing semicolon, it would
>> silently swallow up any following statement.
>> * syntax.h (SETUP_SYNTAX_TABLE):
>> (SETUP_SYNTAX_TABLE_FOR_OBJECT): Likewise.
>> * buffer.h (DECODE_POSITION): Likewise.
>> * charset.h (FETCH_STRING_CHAR_ADVANCE): Likewise.
>> (FETCH_STRING_CHAR_ADVANCE_NO_CHECK): Likewise.
>> (FETCH_CHAR_ADVANCE): Likewise.
>
> Ping?
>
Pong (checked in).
Jan D.