| From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
|---|---|
| To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
| Cc: | Álvaro Herrera <alvherre(at)kurilemu(dot)de>, Nathan Bossart <nathandbossart(at)gmail(dot)com>, Andres Freund <andres(at)anarazel(dot)de>, Pg Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
| Subject: | Re: remove bits* types |
| Date: | 2026-03-18 23:15:29 |
| Message-ID: | CA+TgmobL-dx2na5pV+5vb82txf-tQQLMkaEYyE50CgKymEUk6w@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Wed, Mar 18, 2026 at 6:41 PM Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> In short: maybe we don't want to go in the direction Nathan suggests,
> but if we keep these types we should make an effort to use them
> more consistently, so there's work to be done in that direction too.
I'm definitely -1 on trying to use them more consistently. This is a
261 line patch. The reverse patch to use these types everywhere that
we use integers as a collection of bits is probably 100 times that
size. If you took that idea to its logical conclusion, every flags
variable in the backend would end up getting converted.
I'm not entirely sure that this is worth standardizing at all; if
someone thinks that using bits8 or whatever makes the code more rather
than less clear in a certain context, who am I to argue? If someone
else prefers uint8 in another context, also fine.
But if we are going to standardize, I think the only sensible choice
is what Nathan's done here. The reverse would be an insane amount of
code churn.
--
Robert Haas
EDB: http://www.enterprisedb.com
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Robert Haas | 2026-03-18 23:17:38 | Re: Feature freeze timezone change request |
| Previous Message | Jelte Fennema-Nio | 2026-03-18 23:07:29 | Feature freeze timezone change request |