pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Robert Haas <rhaas@postgresql.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Move some code from jsonapi.c to jsonfuncs.c.
Date: Mon, 27 Jan 2020 16:24:29 +0000
Message-ID: <E1iw7Bd-00061o-At@gemulon.postgresql.org> (raw)

Move some code from jsonapi.c to jsonfuncs.c.

Specifically, move those functions that depend on ereport()
from jsonapi.c to jsonfuncs.c, in preparation for allowing
jsonapi.c to be used from frontend code.

A few cases where elog(ERROR, ...) is used for can't-happen
conditions are left alone; we can handle those in some other
way in frontend code.

Reviewed by Mark Dilger and Andrew Dunstan.

Discussion: http://postgr.es/m/CA+TgmoYfOXhd27MUDGioVh6QtpD0C1K-f6ObSA10AWiHBAL5bA@mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/73ce2a03f30b52d6bfb26bc28f1e3e1aa1637577

Modified Files
--------------
src/backend/utils/adt/json.c      |   2 +-
src/backend/utils/adt/jsonapi.c   | 127 +-------------------------------------
src/backend/utils/adt/jsonb.c     |   2 +-
src/backend/utils/adt/jsonfuncs.c | 126 +++++++++++++++++++++++++++++++++++++
src/include/utils/jsonapi.h       |  15 +----
src/include/utils/jsonfuncs.h     |   9 +++
6 files changed, 140 insertions(+), 141 deletions(-)



Message-ID: <E1iw7Bd-00061o-At@gemulon.postgresql.org>
Permalink:  ../E1iw7Bd-00061o-At@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1iw7Bd-00061o-At@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: rhaas@postgresql.org
  Subject: Re: pgsql: Move some code from jsonapi.c to jsonfuncs.c.
  In-Reply-To: <E1iw7Bd-00061o-At@gemulon.postgresql.org>
  References: <E1iw7Bd-00061o-At@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox