From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | pgsql-committers(at)lists(dot)postgresql(dot)org |
Subject: | pgsql: Make floating-point "NaN / 0" return NaN instead of raising an e |
Date: | 2020-07-20 23:44:54 |
Message-ID: | E1jxfSo-0004Y5-8Y@gemulon.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Make floating-point "NaN / 0" return NaN instead of raising an error.
This is more consistent with the IEEE 754 spec and our treatment of
NaNs elsewhere; in particular, the case has always acted that way in
"numeric" arithmetic.
Noted by Dean Rasheed.
Discussion: https://postgr.es/m/3421746.1594927785@sss.pgh.pa.us
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/4fb6aeb4f6e807c8ce3e140d2d2281f50eb6fb1a
Modified Files
--------------
src/include/utils/float.h | 4 ++--
src/test/regress/expected/float4-misrounded-input.out | 6 ++++++
src/test/regress/expected/float4.out | 6 ++++++
src/test/regress/expected/float8.out | 6 ++++++
src/test/regress/sql/float4.sql | 1 +
src/test/regress/sql/float8.sql | 1 +
6 files changed, 22 insertions(+), 2 deletions(-)
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2020-07-21 02:03:27 | pgsql: Fix some corner cases for window ranges with infinite offsets. |
Previous Message | Peter Geoghegan | 2020-07-20 23:06:16 | pgsql: Assert that buffer is pinned in LockBuffer(). |