Thread: pgsql: Allow to_timestamp(float8) to convert float infinity to timestam

Allow to_timestamp(float8) to convert float infinity to timestamp infinity.

With the original SQL-function implementation, such cases failed because
we don't support infinite intervals.  Converting the function to C lets
us bypass the interval representation, which should be a bit faster as
well as more flexible.

Vitaly Burovoy, reviewed by Anastasia Lubennikova

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/e511d878f3bbc205cd260a79740e646eea3c1cd3

Modified Files
--------------
doc/src/sgml/func.sgml                    | 50 +++++++++++++-------------
src/backend/utils/adt/timestamp.c         | 58 +++++++++++++++++++++++++++++++
src/include/catalog/catversion.h          |  2 +-
src/include/catalog/pg_proc.h             |  2 +-
src/include/utils/timestamp.h             |  1 +
src/test/regress/expected/timestamptz.out | 47 +++++++++++++++++++++++++
src/test/regress/sql/timestamptz.sql      | 15 ++++++++
7 files changed, 149 insertions(+), 26 deletions(-)