Re: use of int4/int32 in C code

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: use of int4/int32 in C code
Дата
Msg-id 22993.1340142147@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: use of int4/int32 in C code  (Robert Haas <robertmhaas@gmail.com>)
Ответы Re: use of int4/int32 in C code  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
Список pgsql-hackers
Robert Haas <robertmhaas@gmail.com> writes:
> On Tue, Jun 19, 2012 at 9:47 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> I thought the general idea was to use int32 most places, but int4 in
>> catalog declarations.  I don't think it's tremendously important if
>> somebody uses the other though.

> I concur with Peter that TMTOWTDI is not the right way to do this.  I
> think we ought to get rid of int4 in code and use int32 everywhere.

I have not looked to see how many places do that.  If it's a reasonably
small number of places, I'm OK with getting rid of int4 at the C level.
(int2/int8 the same of course.)

If we are going to do that, though, we need to actually remove those
typedefs.  Leaving them around on the grounds that third-party code
might be using them will just allow cases to creep back in.
        regards, tom lane


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

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: Backport of fsync queue compaction
Следующее
От: Robert Haas
Дата:
Сообщение: Re: [PATCH 10/16] Introduce the concept that wal has a 'origin' node