Re: Is it really such a good thing for newNode() to be a macro?

Поиск
Список
Период
Сортировка
От Stephen R. van den Berg
Тема Re: Is it really such a good thing for newNode() to be a macro?
Дата
Msg-id 20080830100240.GA27541@cuci.nl
обсуждение исходный текст
Ответ на Re: Is it really such a good thing for newNode() to be a macro?  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Is it really such a good thing for newNode() to be a macro?  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Tom Lane wrote:
>Accordingly, I'm going to go ahead with this:

>#ifdef __GNUC__

>/* With GCC, we can use a compound statement within an expression */
>#define newNode(size, tag) \
>({    Node   *__result__; \

Please avoid identifiers starting with __ .
ANSI reserves those for the implementation (the compiler and lib).
Either use the old global name or something like newMode_result.
-- 
Sincerely,          Stephen R. van den Berg.
Several ways to kill a programmer:  kill -15, fair trial; kill -1, death by
hanging; kill -2, suicide; kill -3, euthanasia; kill -9, execution.


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Is it really such a good thing for newNode() to be a macro?
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Is it really such a good thing for newNode() to be a macro?