Re: Wrong results from in_range() tests with infinite offset - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Wrong results from in_range() tests with infinite offset
Date
Msg-id 794665.1595297192@sss.pgh.pa.us
Whole thread Raw
In response to Re: Wrong results from in_range() tests with infinite offset  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Wrong results from in_range() tests with infinite offset
List pgsql-hackers
I wrote:
> The other three cases where we'd hit NaNs are likewise symmetric with
> non-NaN cases that'd return TRUE.  Hence, I'm forced to the conclusion
> that you've got it right above.  I might write the code a little
> differently, but const-TRUE-for-NaN-cases seems like the right behavior.
> So I withdraw my objection to defining it this way.  Unless somebody
> else weighs in, I'll commit it like that in a day or two.

Pushed, but I chickened out of back-patching.  The improvement in what
happens for finite comparison values seems somewhat counterbalanced by
the possibility that someone might not like the definition we arrived
at for infinities.  So, it's not quite an open-and-shut bug fix, so
I just put it in HEAD (for now anyway).

            regards, tom lane



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: NaN divided by zero should yield NaN
Next
From: "k.jamison@fujitsu.com"
Date:
Subject: RE: Parallel Seq Scan vs kernel read ahead