Re: [HACKERS] taking stdbool.h into use

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: [HACKERS] taking stdbool.h into use
Дата
Msg-id ddb90046-364a-94f1-893c-7bec8c931ae7@2ndquadrant.com
обсуждение исходный текст
Ответ на Re: [HACKERS] taking stdbool.h into use  (Michael Paquier <michael@paquier.xyz>)
Ответы Re: [HACKERS] taking stdbool.h into use  (Michael Paquier <michael@paquier.xyz>)
Список pgsql-hackers
On 3/1/18 23:34, Michael Paquier wrote:
> Indeed, this is wrong.  Peter, why did you switch suddendly this patch
> as ready for committer?  The patch is waiting for your input as you
> mentioned that the GIN portion of this patch series is not completely
> baked yet.  So I have switched the patch in this state.

After more digging, there are more problems with having a bool that is
not 1 byte.  For example, pg_control has a bool field, so with a
different bool size, pg_control would be laid out differently.  That
would require changing all the mentions of bool to bool8 where the end
up on disk somehow, as I had already done for the system catalog
structures, but we don't know all the other places that would be affected.

So I'm going back to my proposal from December, to just use stdbool.h
when sizeof(bool) == 1, and add a static assertion to prevent other
configurations.

-- 
Peter Eisentraut              http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

Вложения

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: JIT compiling with LLVM v11
Следующее
От: Laurenz Albe
Дата:
Сообщение: Re: [submit code] I develop a tool for pgsql, how can I submit it