Re: CREATE CAST allows creation of binary-coercible cast to range over domain - Mailing list pgsql-bugs

From Richard Guo
Subject Re: CREATE CAST allows creation of binary-coercible cast to range over domain
Date
Msg-id CAMbWs4_NfUheqvfnjgM9DatOB9sO0==a5js=QUfF9Z_0OxhPLA@mail.gmail.com
Whole thread Raw
In response to Re: CREATE CAST allows creation of binary-coercible cast to range over domain  (Peter Eisentraut <peter@eisentraut.org>)
Responses Re: CREATE CAST allows creation of binary-coercible cast to range over domain
List pgsql-bugs
On Wed, Aug 21, 2024 at 2:14 PM Peter Eisentraut <peter@eisentraut.org> wrote:
> On 20.08.24 19:30, Tom Lane wrote:
> > In short, more or less as attached.  (I didn't bother with a
> > regression test, since none of the adjacent error checks are
> > covered either.)
>
> This patch looks right.

This patch also looks good to me.  To nitpick:

-    * We know that composite, enum and array types are never binary-
-    * compatible with each other.  They all have OIDs embedded in them.
+    * We know that composite, array, range and enum types are never
+    * binary-compatible with each other.  They all have OIDs embedded in
+    * them.

I wonder if it would be better for readability to list these types in
the order we check them in the code, as we did previously, i.e.:

    * We know that composite, range, enum and array types are never
    * ...

Thanks
Richard



pgsql-bugs by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: CREATE CAST allows creation of binary-coercible cast to range over domain
Next
From: PG Bug reporting form
Date:
Subject: BUG #18586: Process (and transaction) is stuck in IPC when the DB is under high load