Re: Avoid mix char with bool type in comparisons - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Avoid mix char with bool type in comparisons
Date
Msg-id 3177826.1665157202@sss.pgh.pa.us
Whole thread Raw
In response to Re: Avoid mix char with bool type in comparisons  (Robert Haas <robertmhaas@gmail.com>)
Responses Re: Avoid mix char with bool type in comparisons
Re: Avoid mix char with bool type in comparisons
List pgsql-hackers
Robert Haas <robertmhaas@gmail.com> writes:
> On Thu, Oct 6, 2022 at 8:35 PM Ranier Vilela <ranier.vf@gmail.com> wrote:
>> No Tom, unfortunately I don't have the knowledge to create a test with GIN_MAYBE values.

> Well then don't post.

> Basically what you're saying is that you suspect there might be a
> problem with this code but you don't really know that and you can't
> test it. That's not a good enough reason to take up the time of
> everyone on this list.

FWIW, I did take a look at this code, and I don't see any bug.
The entryRes[] array entries are indeed GinTernaryValue, but it's
obvious by inspection that matchPartialInPendingList only returns
true or false, therefore collectMatchesForHeapRow also only deals
in true or false, never maybe.  I do not think changing
matchPartialInPendingList to return ternary would be an improvement,
because then it'd be less obvious that it doesn't deal in maybe.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: create subscription - improved warning message
Next
From: Robert Haas
Date:
Subject: Re: Avoid mix char with bool type in comparisons