Re: GCC 6 warning fixes

Поиск
Список
Период
Сортировка
От Thomas Munro
Тема Re: GCC 6 warning fixes
Дата
Msg-id CAEepm=0nnp5z7Tz6jXfJtoZUUA5i62_8t9vKzs6WzUAb_ZrPiQ@mail.gmail.com
обсуждение исходный текст
Ответ на GCC 6 warning fixes  (Peter Eisentraut <peter_e@gmx.net>)
Ответы Re: GCC 6 warning fixes
Список pgsql-hackers
On Sat, Feb 20, 2016 at 5:14 PM, Peter Eisentraut <peter_e@gmx.net> wrote:
> Here are three patches to fix new warnings in GCC 6.
>
> 0001 is apparently a typo.

Right, looks like it.  Builds and tests OK with this change (though I
didn't get any warning from GCC6.0.0 -Wall for this one).

> 0002 was just (my?) stupid code to begin with.

Right, it makes sense to define QL_HELP in just one translation unit
with external linkage.  Builds and works fine.  I got the 'defined but
not used' warning from GCC6 and it went away with this patch.

> 0003 is more of a workaround.  There could be other ways address this, too.

This way seems fine to me (you probably want the function to continue
to exist rather than, say, becoming a macro evaluating to false on
non-WIN32, if this gets backpatched).  I got this warning from GCC6
and it went away with this patch.

-- 
Thomas Munro
http://www.enterprisedb.com



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: Patch to install config/missing
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: [PATCH] Logical decoding support for sequence advances