Re: [PATCH] ternary reloption type

From: Nikolay Shaplov <dhyan(at)nataraj(dot)su>
To: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Álvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>, Chris Travers <chris(dot)travers(at)gmail(dot)com>, Timur Magomedov <t(dot)magomedov(at)postgrespro(dot)ru>
Subject: Re: [PATCH] ternary reloption type
Date: 2025-09-14 08:49:34
Message-ID: 4047390.3Lj2Plt8kZ@thinkpad-pgpro
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

В письме от пятница, 12 сентября 2025 г. 16:46:19 MSK пользователь Timur
Magomedov написал:
> Hello Nikolay!
>
> Found a typo in reloptions.h, treaed -> treated.
Oups. Fixed that in the attached version.

> Can ternary enum be added in a separate header file, say,
> src/include/ternary.h instead of adding it to c.h? I'm just not sure if
> c.h is it the right place for relation-options-specific code.
> Of course, I can be wrong.

I am not sure either. But my guess is that spamming into c.h is lesser crime
then adding another useless header file.

Moreover, ternary value is not relation-options-specific, it is actually
relation specific, if you think about it thoroughly. Relation code uses it, and
there is no way to avoid that.

Are there any other notions about the code?

I tried to make thongs more neat and more consistent here. Did I succeed?

--
Nikolay Shaplov aka Nataraj
Fuzzing Engineer at Postgres Professional
Matrix IM: @dhyan:nataraj.su

Attachment Content-Type Size
v2a-0001-Add-ternary-reloption-type.patch text/x-patch 4.8 KB
v2a-0002-Introduce-ternary-reloptions.patch text/x-patch 11.7 KB
v2a-0003-Add-alias-to-be-used-as-unset-state.patch text/x-patch 12.0 KB
v2a-0004-Extra-tests.patch text/x-patch 12.3 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Konstantin Knizhnik 2025-09-14 13:40:54 Re: Orphan page in _bt_split
Previous Message Dilip Kumar 2025-09-14 08:09:51 Re: Incorrect logic in XLogNeedsFlush()