pg.ddx.io pgsql-committers@postgresql.org mailing list archive
help / color / mirror / Atom feedpgsql: Add all structured objects passed to pushJsonbValue piecewise.
4+ messages / 3 participants
[nested] [flat]
* pgsql: Add all structured objects passed to pushJsonbValue piecewise.
@ 2015-05-26 15:24 Andrew Dunstan <andrew@dunslane.net>
0 siblings, 1 reply; 4+ messages in thread
From: Andrew Dunstan @ 2015-05-26 15:24 UTC (permalink / raw)
To: pgsql-committers
Add all structured objects passed to pushJsonbValue piecewise.
Commit 9b74f32cdbff8b9be47fc69164eae552050509ff did this for objects of
type jbvBinary, but in trying further to simplify some of the new jsonb
code I discovered that objects of type jbvObject or jbvArray passed as
WJB_ELEM or WJB_VALUE also caused problems. These too are now added
component by component.
Backpatch to 9.4.
Branch
------
master
Details
-------
http://git.postgresql.org/pg/commitdiff/54547bd87f49326d67051254c363e6597d16ffda
Modified Files
--------------
src/backend/utils/adt/jsonb_util.c | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers
^ permalink raw reply [nested|flat] 4+ messages in thread
* pgsql: Add all structured objects passed to pushJsonbValue piecewise.
@ 2015-05-26 15:24 Andrew Dunstan <andrew@dunslane.net>
0 siblings, 0 replies; 4+ messages in thread
From: Andrew Dunstan @ 2015-05-26 15:24 UTC (permalink / raw)
To: pgsql-committers
Add all structured objects passed to pushJsonbValue piecewise.
Commit 9b74f32cdbff8b9be47fc69164eae552050509ff did this for objects of
type jbvBinary, but in trying further to simplify some of the new jsonb
code I discovered that objects of type jbvObject or jbvArray passed as
WJB_ELEM or WJB_VALUE also caused problems. These too are now added
component by component.
Backpatch to 9.4.
Branch
------
REL9_4_STABLE
Details
-------
http://git.postgresql.org/pg/commitdiff/10eb60c2dc9461b56cf90cf05032a078eef7243d
Modified Files
--------------
src/backend/utils/adt/jsonb_util.c | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: pgsql: Add all structured objects passed to pushJsonbValue piecewise.
@ 2015-05-27 00:46 Peter Eisentraut <peter_e@gmx.net>
parent: Andrew Dunstan <andrew@dunslane.net>
0 siblings, 1 reply; 4+ messages in thread
From: Peter Eisentraut @ 2015-05-27 00:46 UTC (permalink / raw)
To: Andrew Dunstan <andrew@dunslane.net>; pgsql-committers
On 5/26/15 11:24 AM, Andrew Dunstan wrote:
> Add all structured objects passed to pushJsonbValue piecewise.
>
> Commit 9b74f32cdbff8b9be47fc69164eae552050509ff did this for objects of
> type jbvBinary, but in trying further to simplify some of the new jsonb
> code I discovered that objects of type jbvObject or jbvArray passed as
> WJB_ELEM or WJB_VALUE also caused problems. These too are now added
> component by component.
>
> Backpatch to 9.4.
This causes a compiler warning:
jsonb_util.c: In function 'pushJsonbValue':
jsonb_util.c:535:3: error: passing argument 1 of 'JsonbIteratorInit'
from incompatible pointer type [-Werror]
it = JsonbIteratorInit(jbval);
^
In file included from jsonb_util.c:20:0:
../../../../src/include/utils/jsonb.h:422:23: note: expected 'struct
JsonbContainer *' but argument is of type 'struct JsonbValue *'
extern JsonbIterator *JsonbIteratorInit(JsonbContainer *container);
^
--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: pgsql: Add all structured objects passed to pushJsonbValue piecewise.
@ 2015-05-27 02:00 Tom Lane <tgl@sss.pgh.pa.us>
parent: Peter Eisentraut <peter_e@gmx.net>
0 siblings, 0 replies; 4+ messages in thread
From: Tom Lane @ 2015-05-27 02:00 UTC (permalink / raw)
To: Andrew Dunstan <andrew@dunslane.net>; +Cc: Peter Eisentraut <peter_e@gmx.net>; pgsql-committers
Peter Eisentraut <peter_e@gmx.net> writes:
> On 5/26/15 11:24 AM, Andrew Dunstan wrote:
>> Add all structured objects passed to pushJsonbValue piecewise.
> This causes a compiler warning:
> jsonb_util.c: In function 'pushJsonbValue':
> jsonb_util.c:535:3: error: passing argument 1 of 'JsonbIteratorInit'
> from incompatible pointer type [-Werror]
I'm getting multiple warnings (probably Peter's build is aborting
after the first one). Please fix.
jsonb_util.c: In function 'pushJsonbValue':
jsonb_util.c:535: warning: passing argument 1 of 'JsonbIteratorInit' from incompatible pointer type
../../../../src/include/utils/jsonb.h:422: note: expected 'struct JsonbContainer *' but argument is of type 'struct JsonbValue *'
jsonfuncs.c: In function 'addJsonbToParseState':
jsonfuncs.c:3257: warning: passing argument 3 of 'pushJsonbValue' from incompatible pointer type
../../../../src/include/utils/jsonb.h:420: note: expected 'struct JsonbValue *' but argument is of type 'struct JsonbContainer *'
jsonfuncs.c:3259: warning: passing argument 3 of 'pushJsonbValue' from incompatible pointer type
../../../../src/include/utils/jsonb.h:420: note: expected 'struct JsonbValue *' but argument is of type 'struct JsonbContainer *'
jsonfuncs.c:3237: warning: unused variable 'type'
regards, tom lane
--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers
^ permalink raw reply [nested|flat] 4+ messages in thread
end of thread, other threads:[~2015-05-27 02:00 UTC | newest]
Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2015-05-26 15:24 pgsql: Add all structured objects passed to pushJsonbValue piecewise. Andrew Dunstan <andrew@dunslane.net>
2015-05-27 00:46 ` Peter Eisentraut <peter_e@gmx.net>
2015-05-27 02:00 ` Tom Lane <tgl@sss.pgh.pa.us>
2015-05-26 15:24 pgsql: Add all structured objects passed to pushJsonbValue piecewise. Andrew Dunstan <andrew@dunslane.net>
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