Re: [COMMITTERS] pgsql: Add configure infrastructure to detect support for C99's restric

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [COMMITTERS] pgsql: Add configure infrastructure to detect support for C99's restric
Дата
Msg-id 2656.1507830907@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: [COMMITTERS] pgsql: Add configure infrastructure to detectsupport for C99's restric  (Andres Freund <andres@anarazel.de>)
Ответы Re: [COMMITTERS] pgsql: Add configure infrastructure to detectsupport for C99's restric
Список pgsql-committers
Andres Freund <andres@anarazel.de> writes:
> On 2017-10-12 11:30:00 -0400, Tom Lane wrote:
>> I don't actually see why you need a #define at all --- "restrict" is the
>> standard spelling of the keyword no?

> It is, but a lot of compilers name it differently, e.g. __restrict in
> the case of msvc.

It's 2017 and they're still not C99 compliant?  Oh well.

TBH, I really doubt that restrict buys us enough performance to justify
dealing with this.  I'd just revert that change altogether.

Or, if you insist on having it, we're going to have to go the pg_restrict
route.  I don't see why that means duplicating any configure logic: on
non-Windows we can use the autoconf probe and then write
"#define pg_restrict restrict".
        regards, tom lane


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers

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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: [COMMITTERS] pgsql: Add configure infrastructure to detectsupport for C99's restric
Следующее
От: Andres Freund
Дата:
Сообщение: Re: [COMMITTERS] pgsql: Add configure infrastructure to detectsupport for C99's restric