Clean up handling of unknown-type inputs in json_build_object and friends.

Tom Lane <tgl@sss.pgh.pa.us>

Commit: 2591e623f5fc80a49347fb5e106aa1e03f713429
Author: Tom Lane <tgl@sss.pgh.pa.us>
Date: 2014-08-09T21:31:16Z
Releases: 9.4.0
Clean up handling of unknown-type inputs in json_build_object and friends.

There's actually no need for any special case for unknown-type literals,
since we only need to push the value through its output function and
unknownout() works fine.  The code that was here was completely bizarre
anyway, and would fail outright in cases that should work, not to mention
suffering from some copy-and-paste bugs.

Files

PathChange+/−
src/backend/utils/adt/json.c modified +73 −95