From: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
---|---|
To: | pgsql-committers(at)postgresql(dot)org |
Subject: | pgsql: Add location field to DefElem |
Date: | 2016-09-07 02:59:41 |
Message-ID: | E1bhT5R-00082M-Ma@gemulon.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Add location field to DefElem
Add a location field to the DefElem struct, used to parse many utility
commands. Update various error messages to supply error position
information.
To propogate the error position information in a more systematic way,
create a ParseState in standard_ProcessUtility() and pass that to
interested functions implementing the utility commands. This seems
better than passing the query string and then reassembling a parse state
ad hoc, which violates the encapsulation of the ParseState type.
Reviewed-by: Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
Branch
------
master
Details
-------
http://git.postgresql.org/pg/commitdiff/49eb0fd0972d14014dd3533b1f1bf8c94c899883
Modified Files
--------------
contrib/file_fdw/file_fdw.c | 16 +-
src/backend/access/common/reloptions.c | 2 +-
src/backend/catalog/aclchk.c | 8 +-
src/backend/commands/aggregatecmds.c | 7 +-
src/backend/commands/collationcmds.c | 5 +-
src/backend/commands/copy.c | 93 ++++++----
src/backend/commands/dbcommands.c | 61 +++---
src/backend/commands/define.c | 9 -
src/backend/commands/explain.c | 8 +-
src/backend/commands/extension.c | 25 ++-
src/backend/commands/functioncmds.c | 57 +++---
src/backend/commands/sequence.c | 36 ++--
src/backend/commands/tsearchcmds.c | 8 +-
src/backend/commands/typecmds.c | 8 +-
src/backend/commands/user.c | 41 ++--
src/backend/commands/view.c | 4 +-
src/backend/nodes/copyfuncs.c | 1 +
src/backend/nodes/equalfuncs.c | 2 +
src/backend/nodes/makefuncs.c | 6 +-
src/backend/nodes/outfuncs.c | 1 +
src/backend/nodes/readfuncs.c | 1 +
src/backend/parser/gram.y | 248 ++++++++++++-------------
src/backend/parser/parse_utilcmd.c | 5 +-
src/backend/replication/logical/logicalfuncs.c | 2 +-
src/backend/replication/repl_gram.y | 16 +-
src/backend/tcop/utility.c | 64 ++++---
src/include/commands/collationcmds.h | 2 +-
src/include/commands/copy.h | 7 +-
src/include/commands/dbcommands.h | 4 +-
src/include/commands/defrem.h | 13 +-
src/include/commands/explain.h | 3 +-
src/include/commands/extension.h | 4 +-
src/include/commands/sequence.h | 5 +-
src/include/commands/typecmds.h | 2 +-
src/include/commands/user.h | 3 +-
src/include/nodes/makefuncs.h | 4 +-
src/include/nodes/parsenodes.h | 1 +
src/include/utils/acl.h | 3 +-
38 files changed, 438 insertions(+), 347 deletions(-)
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2016-09-07 03:56:06 | pgsql: Add a HINT for client-vs-server COPY failure cases. |
Previous Message | Tom Lane | 2016-09-06 21:51:06 | pgsql: Doc: small improvements for documentation about VACUUM freezing. |