diff options
author | Peter Eisentraut <peter@eisentraut.org> | 2019-06-12 11:29:53 +0200 |
---|---|---|
committer | Peter Eisentraut <peter@eisentraut.org> | 2019-06-30 10:27:35 +0200 |
commit | 666cbae16da46b833f57ef8b12ff0bf215684d9c (patch) | |
tree | c717652ac609b57fae640e04c9500313cdddd0be /src/backend/utils/adt/timestamp.c | |
parent | 54100f5c6052404f68de9ce7310ceb61f1c291f8 (diff) | |
download | postgresql-666cbae16da46b833f57ef8b12ff0bf215684d9c.tar.gz postgresql-666cbae16da46b833f57ef8b12ff0bf215684d9c.zip |
Remove explicit error handling for obsolete date/time values
The date/time values 'current', 'invalid', and 'undefined' were
removed a long time ago, but the code still contains explicit error
handling for the transition. To simplify the code and avoid having to
handle these values everywhere, just remove the recognition of these
tokens altogether now.
Reviewed-by: Michael Paquier <michael@paquier.xyz>
Diffstat (limited to 'src/backend/utils/adt/timestamp.c')
-rw-r--r-- | src/backend/utils/adt/timestamp.c | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/src/backend/utils/adt/timestamp.c b/src/backend/utils/adt/timestamp.c index 853a8dc49a4..5861ffbbc97 100644 --- a/src/backend/utils/adt/timestamp.c +++ b/src/backend/utils/adt/timestamp.c @@ -188,14 +188,6 @@ timestamp_in(PG_FUNCTION_ARGS) TIMESTAMP_NOBEGIN(result); break; - case DTK_INVALID: - ereport(ERROR, - (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), - errmsg("date/time value \"%s\" is no longer supported", str))); - - TIMESTAMP_NOEND(result); - break; - default: elog(ERROR, "unexpected dtype %d while parsing timestamp \"%s\"", dtype, str); @@ -439,14 +431,6 @@ timestamptz_in(PG_FUNCTION_ARGS) TIMESTAMP_NOBEGIN(result); break; - case DTK_INVALID: - ereport(ERROR, - (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), - errmsg("date/time value \"%s\" is no longer supported", str))); - - TIMESTAMP_NOEND(result); - break; - default: elog(ERROR, "unexpected dtype %d while parsing timestamptz \"%s\"", dtype, str); @@ -946,12 +930,6 @@ interval_in(PG_FUNCTION_ARGS) errmsg("interval out of range"))); break; - case DTK_INVALID: - ereport(ERROR, - (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), - errmsg("date/time value \"%s\" is no longer supported", str))); - break; - default: elog(ERROR, "unexpected dtype %d while parsing interval \"%s\"", dtype, str); |