pg_query 2.2.0 → 6.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +86 -0
- data/README.md +57 -31
- data/Rakefile +5 -6
- data/ext/pg_query/ext_symbols_freebsd.sym +1 -0
- data/ext/pg_query/ext_symbols_freebsd_with_ruby_abi_version.sym +2 -0
- data/ext/pg_query/ext_symbols_openbsd.sym +1 -0
- data/ext/pg_query/ext_symbols_openbsd_with_ruby_abi_version.sym +2 -0
- data/ext/pg_query/ext_symbols_with_ruby_abi_version.sym +2 -0
- data/ext/pg_query/extconf.rb +33 -9
- data/ext/pg_query/include/pg_query.h +30 -4
- data/ext/pg_query/include/pg_query_enum_defs.c +839 -290
- data/ext/pg_query/include/pg_query_fingerprint_conds.c +638 -481
- data/ext/pg_query/include/pg_query_fingerprint_defs.c +6786 -4193
- data/ext/pg_query/include/pg_query_outfuncs_conds.c +450 -330
- data/ext/pg_query/include/pg_query_outfuncs_defs.c +1489 -1044
- data/ext/pg_query/include/pg_query_readfuncs_conds.c +157 -118
- data/ext/pg_query/include/pg_query_readfuncs_defs.c +1933 -1410
- data/ext/pg_query/include/postgres/access/amapi.h +303 -0
- data/ext/pg_query/include/postgres/access/attmap.h +54 -0
- data/ext/pg_query/include/postgres/access/attnum.h +64 -0
- data/ext/pg_query/include/postgres/access/brin_internal.h +116 -0
- data/ext/pg_query/include/postgres/access/brin_tuple.h +112 -0
- data/ext/pg_query/include/postgres/access/clog.h +62 -0
- data/ext/pg_query/include/postgres/access/commit_ts.h +73 -0
- data/ext/pg_query/include/postgres/access/detoast.h +82 -0
- data/ext/pg_query/include/postgres/access/genam.h +246 -0
- data/ext/pg_query/include/postgres/access/gin.h +91 -0
- data/ext/pg_query/include/postgres/access/htup.h +89 -0
- data/ext/pg_query/include/postgres/access/htup_details.h +811 -0
- data/ext/pg_query/include/postgres/access/itup.h +170 -0
- data/ext/pg_query/include/postgres/access/parallel.h +81 -0
- data/ext/pg_query/include/postgres/access/printtup.h +35 -0
- data/ext/pg_query/include/postgres/access/relation.h +28 -0
- data/ext/pg_query/include/postgres/access/relscan.h +191 -0
- data/ext/pg_query/include/postgres/access/rmgr.h +62 -0
- data/ext/pg_query/include/postgres/access/rmgrlist.h +49 -0
- data/ext/pg_query/include/postgres/access/sdir.h +67 -0
- data/ext/pg_query/include/postgres/access/skey.h +151 -0
- data/ext/pg_query/include/postgres/access/slru.h +218 -0
- data/ext/pg_query/include/postgres/access/stratnum.h +85 -0
- data/ext/pg_query/include/postgres/access/sysattr.h +29 -0
- data/ext/pg_query/include/postgres/access/table.h +28 -0
- data/ext/pg_query/include/postgres/access/tableam.h +2110 -0
- data/ext/pg_query/include/postgres/access/tidstore.h +50 -0
- data/ext/pg_query/include/postgres/access/toast_compression.h +73 -0
- data/ext/pg_query/include/postgres/access/transam.h +418 -0
- data/ext/pg_query/include/postgres/access/tsmapi.h +82 -0
- data/ext/pg_query/include/postgres/access/tupconvert.h +54 -0
- data/ext/pg_query/include/postgres/access/tupdesc.h +154 -0
- data/ext/pg_query/include/postgres/access/tupmacs.h +207 -0
- data/ext/pg_query/include/postgres/access/twophase.h +65 -0
- data/ext/pg_query/include/postgres/access/xact.h +530 -0
- data/ext/pg_query/include/postgres/access/xlog.h +310 -0
- data/ext/pg_query/include/postgres/access/xlog_internal.h +405 -0
- data/ext/pg_query/include/postgres/access/xlogbackup.h +43 -0
- data/ext/pg_query/include/postgres/access/xlogdefs.h +82 -0
- data/ext/pg_query/include/postgres/access/xlogprefetcher.h +55 -0
- data/ext/pg_query/include/postgres/access/xlogreader.h +444 -0
- data/ext/pg_query/include/postgres/access/xlogrecord.h +248 -0
- data/ext/pg_query/include/postgres/access/xlogrecovery.h +158 -0
- data/ext/pg_query/include/postgres/archive/archive_module.h +67 -0
- data/ext/pg_query/include/postgres/c.h +1374 -0
- data/ext/pg_query/include/postgres/catalog/catalog.h +47 -0
- data/ext/pg_query/include/postgres/catalog/catversion.h +62 -0
- data/ext/pg_query/include/postgres/catalog/dependency.h +228 -0
- data/ext/pg_query/include/postgres/catalog/genbki.h +149 -0
- data/ext/pg_query/include/postgres/catalog/index.h +218 -0
- data/ext/pg_query/include/postgres/catalog/indexing.h +54 -0
- data/ext/pg_query/include/postgres/catalog/namespace.h +189 -0
- data/ext/pg_query/include/postgres/catalog/objectaccess.h +267 -0
- data/ext/pg_query/include/postgres/catalog/objectaddress.h +93 -0
- data/ext/pg_query/include/postgres/catalog/pg_aggregate.h +182 -0
- data/ext/pg_query/include/postgres/catalog/pg_aggregate_d.h +78 -0
- data/ext/pg_query/include/postgres/catalog/pg_am.h +66 -0
- data/ext/pg_query/include/postgres/catalog/pg_am_d.h +47 -0
- data/ext/pg_query/include/postgres/catalog/pg_attribute.h +240 -0
- data/ext/pg_query/include/postgres/catalog/pg_attribute_d.h +62 -0
- data/ext/pg_query/include/postgres/catalog/pg_authid.h +66 -0
- data/ext/pg_query/include/postgres/catalog/pg_authid_d.h +60 -0
- data/ext/pg_query/include/postgres/catalog/pg_class.h +235 -0
- data/ext/pg_query/include/postgres/catalog/pg_class_d.h +134 -0
- data/ext/pg_query/include/postgres/catalog/pg_collation.h +106 -0
- data/ext/pg_query/include/postgres/catalog/pg_collation_d.h +66 -0
- data/ext/pg_query/include/postgres/catalog/pg_constraint.h +278 -0
- data/ext/pg_query/include/postgres/catalog/pg_constraint_d.h +74 -0
- data/ext/pg_query/include/postgres/catalog/pg_control.h +260 -0
- data/ext/pg_query/include/postgres/catalog/pg_conversion.h +79 -0
- data/ext/pg_query/include/postgres/catalog/pg_conversion_d.h +38 -0
- data/ext/pg_query/include/postgres/catalog/pg_database.h +129 -0
- data/ext/pg_query/include/postgres/catalog/pg_database_d.h +53 -0
- data/ext/pg_query/include/postgres/catalog/pg_depend.h +77 -0
- data/ext/pg_query/include/postgres/catalog/pg_depend_d.h +36 -0
- data/ext/pg_query/include/postgres/catalog/pg_event_trigger.h +60 -0
- data/ext/pg_query/include/postgres/catalog/pg_event_trigger_d.h +36 -0
- data/ext/pg_query/include/postgres/catalog/pg_index.h +92 -0
- data/ext/pg_query/include/postgres/catalog/pg_index_d.h +59 -0
- data/ext/pg_query/include/postgres/catalog/pg_language.h +75 -0
- data/ext/pg_query/include/postgres/catalog/pg_language_d.h +41 -0
- data/ext/pg_query/include/postgres/catalog/pg_namespace.h +67 -0
- data/ext/pg_query/include/postgres/catalog/pg_namespace_d.h +36 -0
- data/ext/pg_query/include/postgres/catalog/pg_opclass.h +91 -0
- data/ext/pg_query/include/postgres/catalog/pg_opclass_d.h +51 -0
- data/ext/pg_query/include/postgres/catalog/pg_operator.h +124 -0
- data/ext/pg_query/include/postgres/catalog/pg_operator_d.h +142 -0
- data/ext/pg_query/include/postgres/catalog/pg_opfamily.h +67 -0
- data/ext/pg_query/include/postgres/catalog/pg_opfamily_d.h +51 -0
- data/ext/pg_query/include/postgres/catalog/pg_partitioned_table.h +76 -0
- data/ext/pg_query/include/postgres/catalog/pg_partitioned_table_d.h +36 -0
- data/ext/pg_query/include/postgres/catalog/pg_proc.h +223 -0
- data/ext/pg_query/include/postgres/catalog/pg_proc_d.h +101 -0
- data/ext/pg_query/include/postgres/catalog/pg_publication.h +161 -0
- data/ext/pg_query/include/postgres/catalog/pg_publication_d.h +38 -0
- data/ext/pg_query/include/postgres/catalog/pg_replication_origin.h +65 -0
- data/ext/pg_query/include/postgres/catalog/pg_replication_origin_d.h +33 -0
- data/ext/pg_query/include/postgres/catalog/pg_statistic.h +288 -0
- data/ext/pg_query/include/postgres/catalog/pg_statistic_d.h +199 -0
- data/ext/pg_query/include/postgres/catalog/pg_statistic_ext.h +91 -0
- data/ext/pg_query/include/postgres/catalog/pg_statistic_ext_d.h +45 -0
- data/ext/pg_query/include/postgres/catalog/pg_transform.h +51 -0
- data/ext/pg_query/include/postgres/catalog/pg_transform_d.h +34 -0
- data/ext/pg_query/include/postgres/catalog/pg_trigger.h +153 -0
- data/ext/pg_query/include/postgres/catalog/pg_trigger_d.h +109 -0
- data/ext/pg_query/include/postgres/catalog/pg_ts_config.h +56 -0
- data/ext/pg_query/include/postgres/catalog/pg_ts_config_d.h +34 -0
- data/ext/pg_query/include/postgres/catalog/pg_ts_dict.h +62 -0
- data/ext/pg_query/include/postgres/catalog/pg_ts_dict_d.h +35 -0
- data/ext/pg_query/include/postgres/catalog/pg_ts_parser.h +63 -0
- data/ext/pg_query/include/postgres/catalog/pg_ts_parser_d.h +37 -0
- data/ext/pg_query/include/postgres/catalog/pg_ts_template.h +54 -0
- data/ext/pg_query/include/postgres/catalog/pg_ts_template_d.h +34 -0
- data/ext/pg_query/include/postgres/catalog/pg_type.h +407 -0
- data/ext/pg_query/include/postgres/catalog/pg_type_d.h +324 -0
- data/ext/pg_query/include/postgres/catalog/storage.h +50 -0
- data/ext/pg_query/include/postgres/catalog/syscache_ids.h +104 -0
- data/ext/pg_query/include/postgres/commands/async.h +49 -0
- data/ext/pg_query/include/postgres/commands/dbcommands.h +37 -0
- data/ext/pg_query/include/postgres/commands/defrem.h +161 -0
- data/ext/pg_query/include/postgres/commands/event_trigger.h +97 -0
- data/ext/pg_query/include/postgres/commands/explain.h +145 -0
- data/ext/pg_query/include/postgres/commands/prepare.h +61 -0
- data/ext/pg_query/include/postgres/commands/tablespace.h +69 -0
- data/ext/pg_query/include/postgres/commands/trigger.h +288 -0
- data/ext/pg_query/include/postgres/commands/user.h +43 -0
- data/ext/pg_query/include/postgres/commands/vacuum.h +388 -0
- data/ext/pg_query/include/postgres/common/cryptohash.h +39 -0
- data/ext/pg_query/include/postgres/common/file_perm.h +56 -0
- data/ext/pg_query/include/postgres/common/file_utils.h +65 -0
- data/ext/pg_query/include/postgres/common/hashfn.h +119 -0
- data/ext/pg_query/include/postgres/common/hashfn_unstable.h +407 -0
- data/ext/pg_query/include/postgres/common/int.h +512 -0
- data/ext/pg_query/include/postgres/common/keywords.h +29 -0
- data/ext/pg_query/include/postgres/common/kwlookup.h +44 -0
- data/ext/pg_query/include/postgres/common/pg_prng.h +62 -0
- data/ext/pg_query/include/postgres/common/relpath.h +97 -0
- data/ext/pg_query/include/postgres/common/scram-common.h +70 -0
- data/ext/pg_query/include/postgres/common/sha2.h +32 -0
- data/ext/pg_query/include/postgres/common/string.h +44 -0
- data/ext/pg_query/include/postgres/common/unicode_east_asian_fw_table.h +124 -0
- data/ext/pg_query/include/postgres/common/unicode_nonspacing_table.h +326 -0
- data/ext/pg_query/include/postgres/copyfuncs.funcs.c +5261 -0
- data/ext/pg_query/include/postgres/copyfuncs.switch.c +989 -0
- data/ext/pg_query/include/postgres/datatype/timestamp.h +269 -0
- data/ext/pg_query/include/postgres/equalfuncs.funcs.c +3310 -0
- data/ext/pg_query/include/postgres/equalfuncs.switch.c +836 -0
- data/ext/pg_query/include/postgres/executor/execdesc.h +70 -0
- data/ext/pg_query/include/postgres/executor/executor.h +681 -0
- data/ext/pg_query/include/postgres/executor/functions.h +56 -0
- data/ext/pg_query/include/postgres/executor/instrument.h +120 -0
- data/ext/pg_query/include/postgres/executor/spi.h +207 -0
- data/ext/pg_query/include/postgres/executor/tablefunc.h +67 -0
- data/ext/pg_query/include/postgres/executor/tuptable.h +523 -0
- data/ext/pg_query/include/postgres/fmgr.h +800 -0
- data/ext/pg_query/include/postgres/foreign/fdwapi.h +294 -0
- data/ext/pg_query/include/postgres/funcapi.h +360 -0
- data/ext/pg_query/include/postgres/gram.h +1168 -0
- data/ext/pg_query/include/postgres/gramparse.h +75 -0
- data/ext/pg_query/include/postgres/jit/jit.h +106 -0
- data/ext/pg_query/include/postgres/kwlist_d.h +1164 -0
- data/ext/pg_query/include/postgres/lib/dshash.h +130 -0
- data/ext/pg_query/include/postgres/lib/ilist.h +1159 -0
- data/ext/pg_query/include/postgres/lib/pairingheap.h +102 -0
- data/ext/pg_query/include/postgres/lib/simplehash.h +1206 -0
- data/ext/pg_query/include/postgres/lib/sort_template.h +445 -0
- data/ext/pg_query/include/postgres/lib/stringinfo.h +243 -0
- data/ext/pg_query/include/postgres/libpq/auth.h +37 -0
- data/ext/pg_query/include/postgres/libpq/crypt.h +47 -0
- data/ext/pg_query/include/postgres/libpq/hba.h +186 -0
- data/ext/pg_query/include/postgres/libpq/libpq-be.h +361 -0
- data/ext/pg_query/include/postgres/libpq/libpq.h +143 -0
- data/ext/pg_query/include/postgres/libpq/pqcomm.h +169 -0
- data/ext/pg_query/include/postgres/libpq/pqformat.h +209 -0
- data/ext/pg_query/include/postgres/libpq/pqsignal.h +54 -0
- data/ext/pg_query/include/postgres/libpq/protocol.h +89 -0
- data/ext/pg_query/include/postgres/libpq/sasl.h +136 -0
- data/ext/pg_query/include/postgres/libpq/scram.h +37 -0
- data/ext/pg_query/include/postgres/mb/pg_wchar.h +793 -0
- data/ext/pg_query/include/postgres/mb/stringinfo_mb.h +24 -0
- data/ext/pg_query/include/postgres/miscadmin.h +527 -0
- data/ext/pg_query/include/postgres/nodes/bitmapset.h +140 -0
- data/ext/pg_query/include/postgres/nodes/execnodes.h +2855 -0
- data/ext/pg_query/include/postgres/nodes/extensible.h +164 -0
- data/ext/pg_query/include/postgres/nodes/lockoptions.h +61 -0
- data/ext/pg_query/include/postgres/nodes/makefuncs.h +127 -0
- data/ext/pg_query/include/postgres/nodes/memnodes.h +152 -0
- data/ext/pg_query/include/postgres/nodes/miscnodes.h +56 -0
- data/ext/pg_query/include/postgres/nodes/nodeFuncs.h +222 -0
- data/ext/pg_query/include/postgres/nodes/nodes.h +435 -0
- data/ext/pg_query/include/postgres/nodes/nodetags.h +491 -0
- data/ext/pg_query/include/postgres/nodes/params.h +170 -0
- data/ext/pg_query/include/postgres/nodes/parsenodes.h +4233 -0
- data/ext/pg_query/include/postgres/nodes/pathnodes.h +3438 -0
- data/ext/pg_query/include/postgres/nodes/pg_list.h +686 -0
- data/ext/pg_query/include/postgres/nodes/plannodes.h +1593 -0
- data/ext/pg_query/include/postgres/nodes/primnodes.h +2339 -0
- data/ext/pg_query/include/postgres/nodes/print.h +34 -0
- data/ext/pg_query/include/postgres/nodes/queryjumble.h +86 -0
- data/ext/pg_query/include/postgres/nodes/replnodes.h +132 -0
- data/ext/pg_query/include/postgres/nodes/supportnodes.h +346 -0
- data/ext/pg_query/include/postgres/nodes/tidbitmap.h +75 -0
- data/ext/pg_query/include/postgres/nodes/value.h +90 -0
- data/ext/pg_query/include/postgres/optimizer/cost.h +216 -0
- data/ext/pg_query/include/postgres/optimizer/geqo.h +90 -0
- data/ext/pg_query/include/postgres/optimizer/geqo_gene.h +45 -0
- data/ext/pg_query/include/postgres/optimizer/optimizer.h +205 -0
- data/ext/pg_query/include/postgres/optimizer/paths.h +271 -0
- data/ext/pg_query/include/postgres/optimizer/planmain.h +123 -0
- data/ext/pg_query/include/postgres/parser/analyze.h +66 -0
- data/ext/pg_query/include/postgres/parser/kwlist.h +518 -0
- data/ext/pg_query/include/postgres/parser/parse_agg.h +65 -0
- data/ext/pg_query/include/postgres/parser/parse_coerce.h +105 -0
- data/ext/pg_query/include/postgres/parser/parse_expr.h +25 -0
- data/ext/pg_query/include/postgres/parser/parse_func.h +74 -0
- data/ext/pg_query/include/postgres/parser/parse_node.h +358 -0
- data/ext/pg_query/include/postgres/parser/parse_oper.h +68 -0
- data/ext/pg_query/include/postgres/parser/parse_relation.h +129 -0
- data/ext/pg_query/include/postgres/parser/parse_type.h +61 -0
- data/ext/pg_query/include/postgres/parser/parser.h +68 -0
- data/ext/pg_query/include/postgres/parser/parsetree.h +61 -0
- data/ext/pg_query/include/postgres/parser/scanner.h +152 -0
- data/ext/pg_query/include/postgres/parser/scansup.h +27 -0
- data/ext/pg_query/include/postgres/partitioning/partdefs.h +26 -0
- data/ext/pg_query/include/postgres/pg_config.h +985 -0
- data/ext/pg_query/include/postgres/pg_config_manual.h +385 -0
- data/ext/pg_query/include/postgres/pg_config_os.h +8 -0
- data/ext/pg_query/include/postgres/pg_getopt.h +56 -0
- data/ext/pg_query/include/postgres/pg_trace.h +17 -0
- data/ext/pg_query/include/postgres/pgstat.h +780 -0
- data/ext/pg_query/include/postgres/pgtime.h +94 -0
- data/ext/pg_query/include/postgres/pl_gram.h +385 -0
- data/ext/pg_query/include/postgres/pl_reserved_kwlist.h +52 -0
- data/ext/pg_query/include/postgres/pl_reserved_kwlist_d.h +114 -0
- data/ext/pg_query/include/postgres/pl_unreserved_kwlist.h +112 -0
- data/ext/pg_query/include/postgres/pl_unreserved_kwlist_d.h +246 -0
- data/ext/pg_query/include/postgres/plerrcodes.h +998 -0
- data/ext/pg_query/include/postgres/plpgsql.h +1342 -0
- data/ext/pg_query/include/postgres/port/atomics/arch-arm.h +32 -0
- data/ext/pg_query/include/postgres/port/atomics/arch-hppa.h +17 -0
- data/ext/pg_query/include/postgres/port/atomics/arch-ppc.h +256 -0
- data/ext/pg_query/include/postgres/port/atomics/arch-x86.h +254 -0
- data/ext/pg_query/include/postgres/port/atomics/fallback.h +170 -0
- data/ext/pg_query/include/postgres/port/atomics/generic-gcc.h +323 -0
- data/ext/pg_query/include/postgres/port/atomics/generic-msvc.h +119 -0
- data/ext/pg_query/include/postgres/port/atomics/generic-sunpro.h +121 -0
- data/ext/pg_query/include/postgres/port/atomics/generic.h +437 -0
- data/ext/pg_query/include/postgres/port/atomics.h +606 -0
- data/ext/pg_query/include/postgres/port/pg_bitutils.h +421 -0
- data/ext/pg_query/include/postgres/port/pg_bswap.h +161 -0
- data/ext/pg_query/include/postgres/port/pg_crc32c.h +110 -0
- data/ext/pg_query/include/postgres/port/pg_iovec.h +117 -0
- data/ext/pg_query/include/postgres/port/simd.h +422 -0
- data/ext/pg_query/include/postgres/port/win32/arpa/inet.h +3 -0
- data/ext/pg_query/include/postgres/port/win32/dlfcn.h +1 -0
- data/ext/pg_query/include/postgres/port/win32/grp.h +1 -0
- data/ext/pg_query/include/postgres/port/win32/netdb.h +7 -0
- data/ext/pg_query/include/postgres/port/win32/netinet/in.h +3 -0
- data/ext/pg_query/include/postgres/port/win32/netinet/tcp.h +7 -0
- data/ext/pg_query/include/postgres/port/win32/pwd.h +3 -0
- data/ext/pg_query/include/postgres/port/win32/sys/resource.h +20 -0
- data/ext/pg_query/include/postgres/port/win32/sys/select.h +3 -0
- data/ext/pg_query/include/postgres/port/win32/sys/socket.h +34 -0
- data/ext/pg_query/include/postgres/port/win32/sys/un.h +17 -0
- data/ext/pg_query/include/postgres/port/win32/sys/wait.h +3 -0
- data/ext/pg_query/include/postgres/port/win32.h +59 -0
- data/ext/pg_query/include/postgres/port/win32_msvc/dirent.h +34 -0
- data/ext/pg_query/include/postgres/port/win32_msvc/sys/file.h +1 -0
- data/ext/pg_query/include/postgres/port/win32_msvc/sys/param.h +1 -0
- data/ext/pg_query/include/postgres/port/win32_msvc/sys/time.h +1 -0
- data/ext/pg_query/include/postgres/port/win32_msvc/unistd.h +9 -0
- data/ext/pg_query/include/postgres/port/win32_msvc/utime.h +3 -0
- data/ext/pg_query/include/postgres/port/win32_port.h +582 -0
- data/ext/pg_query/include/postgres/port.h +555 -0
- data/ext/pg_query/include/postgres/portability/instr_time.h +197 -0
- data/ext/pg_query/include/postgres/postgres.h +579 -0
- data/ext/pg_query/include/postgres/postgres_ext.h +73 -0
- data/ext/pg_query/include/postgres/postmaster/autovacuum.h +69 -0
- data/ext/pg_query/include/postgres/postmaster/bgworker.h +164 -0
- data/ext/pg_query/include/postgres/postmaster/bgworker_internals.h +60 -0
- data/ext/pg_query/include/postgres/postmaster/bgwriter.h +45 -0
- data/ext/pg_query/include/postgres/postmaster/interrupt.h +32 -0
- data/ext/pg_query/include/postgres/postmaster/pgarch.h +36 -0
- data/ext/pg_query/include/postgres/postmaster/postmaster.h +101 -0
- data/ext/pg_query/include/postgres/postmaster/startup.h +41 -0
- data/ext/pg_query/include/postgres/postmaster/syslogger.h +101 -0
- data/ext/pg_query/include/postgres/postmaster/walsummarizer.h +35 -0
- data/ext/pg_query/include/postgres/postmaster/walwriter.h +23 -0
- data/ext/pg_query/include/postgres/regex/regex.h +272 -0
- data/ext/pg_query/include/postgres/replication/logicallauncher.h +34 -0
- data/ext/pg_query/include/postgres/replication/logicalproto.h +274 -0
- data/ext/pg_query/include/postgres/replication/logicalworker.h +33 -0
- data/ext/pg_query/include/postgres/replication/origin.h +73 -0
- data/ext/pg_query/include/postgres/replication/reorderbuffer.h +734 -0
- data/ext/pg_query/include/postgres/replication/slot.h +289 -0
- data/ext/pg_query/include/postgres/replication/slotsync.h +38 -0
- data/ext/pg_query/include/postgres/replication/syncrep.h +109 -0
- data/ext/pg_query/include/postgres/replication/walreceiver.h +504 -0
- data/ext/pg_query/include/postgres/replication/walsender.h +76 -0
- data/ext/pg_query/include/postgres/rewrite/prs2lock.h +46 -0
- data/ext/pg_query/include/postgres/rewrite/rewriteHandler.h +41 -0
- data/ext/pg_query/include/postgres/rewrite/rewriteManip.h +96 -0
- data/ext/pg_query/include/postgres/rewrite/rewriteSupport.h +26 -0
- data/ext/pg_query/include/postgres/storage/block.h +108 -0
- data/ext/pg_query/include/postgres/storage/buf.h +46 -0
- data/ext/pg_query/include/postgres/storage/bufmgr.h +411 -0
- data/ext/pg_query/include/postgres/storage/bufpage.h +510 -0
- data/ext/pg_query/include/postgres/storage/condition_variable.h +73 -0
- data/ext/pg_query/include/postgres/storage/dsm.h +61 -0
- data/ext/pg_query/include/postgres/storage/dsm_impl.h +79 -0
- data/ext/pg_query/include/postgres/storage/fd.h +219 -0
- data/ext/pg_query/include/postgres/storage/fileset.h +40 -0
- data/ext/pg_query/include/postgres/storage/ipc.h +87 -0
- data/ext/pg_query/include/postgres/storage/item.h +19 -0
- data/ext/pg_query/include/postgres/storage/itemid.h +184 -0
- data/ext/pg_query/include/postgres/storage/itemptr.h +245 -0
- data/ext/pg_query/include/postgres/storage/large_object.h +100 -0
- data/ext/pg_query/include/postgres/storage/latch.h +196 -0
- data/ext/pg_query/include/postgres/storage/lmgr.h +126 -0
- data/ext/pg_query/include/postgres/storage/lock.h +624 -0
- data/ext/pg_query/include/postgres/storage/lockdefs.h +61 -0
- data/ext/pg_query/include/postgres/storage/lwlock.h +228 -0
- data/ext/pg_query/include/postgres/storage/lwlocknames.h +47 -0
- data/ext/pg_query/include/postgres/storage/off.h +57 -0
- data/ext/pg_query/include/postgres/storage/pg_sema.h +61 -0
- data/ext/pg_query/include/postgres/storage/pg_shmem.h +93 -0
- data/ext/pg_query/include/postgres/storage/pmsignal.h +105 -0
- data/ext/pg_query/include/postgres/storage/predicate.h +83 -0
- data/ext/pg_query/include/postgres/storage/proc.h +488 -0
- data/ext/pg_query/include/postgres/storage/procarray.h +103 -0
- data/ext/pg_query/include/postgres/storage/proclist_types.h +53 -0
- data/ext/pg_query/include/postgres/storage/procnumber.h +43 -0
- data/ext/pg_query/include/postgres/storage/procsignal.h +75 -0
- data/ext/pg_query/include/postgres/storage/read_stream.h +65 -0
- data/ext/pg_query/include/postgres/storage/relfilelocator.h +100 -0
- data/ext/pg_query/include/postgres/storage/s_lock.h +847 -0
- data/ext/pg_query/include/postgres/storage/sharedfileset.h +37 -0
- data/ext/pg_query/include/postgres/storage/shm_mq.h +86 -0
- data/ext/pg_query/include/postgres/storage/shm_toc.h +58 -0
- data/ext/pg_query/include/postgres/storage/shmem.h +59 -0
- data/ext/pg_query/include/postgres/storage/sinval.h +153 -0
- data/ext/pg_query/include/postgres/storage/smgr.h +130 -0
- data/ext/pg_query/include/postgres/storage/spin.h +77 -0
- data/ext/pg_query/include/postgres/storage/standby.h +109 -0
- data/ext/pg_query/include/postgres/storage/standbydefs.h +74 -0
- data/ext/pg_query/include/postgres/storage/sync.h +66 -0
- data/ext/pg_query/include/postgres/tcop/cmdtag.h +62 -0
- data/ext/pg_query/include/postgres/tcop/cmdtaglist.h +219 -0
- data/ext/pg_query/include/postgres/tcop/deparse_utility.h +108 -0
- data/ext/pg_query/include/postgres/tcop/dest.h +148 -0
- data/ext/pg_query/include/postgres/tcop/fastpath.h +20 -0
- data/ext/pg_query/include/postgres/tcop/pquery.h +51 -0
- data/ext/pg_query/include/postgres/tcop/tcopprot.h +98 -0
- data/ext/pg_query/include/postgres/tcop/utility.h +112 -0
- data/ext/pg_query/include/postgres/tsearch/ts_cache.h +96 -0
- data/ext/pg_query/include/postgres/utils/acl.h +290 -0
- data/ext/pg_query/include/postgres/utils/aclchk_internal.h +45 -0
- data/ext/pg_query/include/postgres/utils/array.h +481 -0
- data/ext/pg_query/include/postgres/utils/ascii.h +84 -0
- data/ext/pg_query/include/postgres/utils/backend_progress.h +46 -0
- data/ext/pg_query/include/postgres/utils/backend_status.h +340 -0
- data/ext/pg_query/include/postgres/utils/builtins.h +139 -0
- data/ext/pg_query/include/postgres/utils/bytea.h +28 -0
- data/ext/pg_query/include/postgres/utils/catcache.h +231 -0
- data/ext/pg_query/include/postgres/utils/date.h +118 -0
- data/ext/pg_query/include/postgres/utils/datetime.h +367 -0
- data/ext/pg_query/include/postgres/utils/datum.h +76 -0
- data/ext/pg_query/include/postgres/utils/dsa.h +166 -0
- data/ext/pg_query/include/postgres/utils/elog.h +540 -0
- data/ext/pg_query/include/postgres/utils/errcodes.h +352 -0
- data/ext/pg_query/include/postgres/utils/expandeddatum.h +170 -0
- data/ext/pg_query/include/postgres/utils/expandedrecord.h +241 -0
- data/ext/pg_query/include/postgres/utils/float.h +357 -0
- data/ext/pg_query/include/postgres/utils/fmgroids.h +3347 -0
- data/ext/pg_query/include/postgres/utils/fmgrprotos.h +2904 -0
- data/ext/pg_query/include/postgres/utils/fmgrtab.h +49 -0
- data/ext/pg_query/include/postgres/utils/guc.h +456 -0
- data/ext/pg_query/include/postgres/utils/guc_hooks.h +184 -0
- data/ext/pg_query/include/postgres/utils/guc_tables.h +323 -0
- data/ext/pg_query/include/postgres/utils/hsearch.h +153 -0
- data/ext/pg_query/include/postgres/utils/injection_point.h +44 -0
- data/ext/pg_query/include/postgres/utils/inval.h +68 -0
- data/ext/pg_query/include/postgres/utils/logtape.h +77 -0
- data/ext/pg_query/include/postgres/utils/lsyscache.h +215 -0
- data/ext/pg_query/include/postgres/utils/memdebug.h +82 -0
- data/ext/pg_query/include/postgres/utils/memutils.h +193 -0
- data/ext/pg_query/include/postgres/utils/memutils_internal.h +176 -0
- data/ext/pg_query/include/postgres/utils/memutils_memorychunk.h +253 -0
- data/ext/pg_query/include/postgres/utils/numeric.h +110 -0
- data/ext/pg_query/include/postgres/utils/palloc.h +151 -0
- data/ext/pg_query/include/postgres/utils/partcache.h +103 -0
- data/ext/pg_query/include/postgres/utils/pg_locale.h +136 -0
- data/ext/pg_query/include/postgres/utils/pgstat_internal.h +827 -0
- data/ext/pg_query/include/postgres/utils/plancache.h +238 -0
- data/ext/pg_query/include/postgres/utils/portal.h +252 -0
- data/ext/pg_query/include/postgres/utils/probes.h +114 -0
- data/ext/pg_query/include/postgres/utils/ps_status.h +47 -0
- data/ext/pg_query/include/postgres/utils/queryenvironment.h +74 -0
- data/ext/pg_query/include/postgres/utils/regproc.h +39 -0
- data/ext/pg_query/include/postgres/utils/rel.h +711 -0
- data/ext/pg_query/include/postgres/utils/relcache.h +155 -0
- data/ext/pg_query/include/postgres/utils/reltrigger.h +81 -0
- data/ext/pg_query/include/postgres/utils/resowner.h +167 -0
- data/ext/pg_query/include/postgres/utils/ruleutils.h +52 -0
- data/ext/pg_query/include/postgres/utils/sharedtuplestore.h +61 -0
- data/ext/pg_query/include/postgres/utils/snapmgr.h +130 -0
- data/ext/pg_query/include/postgres/utils/snapshot.h +219 -0
- data/ext/pg_query/include/postgres/utils/sortsupport.h +391 -0
- data/ext/pg_query/include/postgres/utils/syscache.h +136 -0
- data/ext/pg_query/include/postgres/utils/timeout.h +96 -0
- data/ext/pg_query/include/postgres/utils/timestamp.h +147 -0
- data/ext/pg_query/include/postgres/utils/tuplesort.h +472 -0
- data/ext/pg_query/include/postgres/utils/tuplestore.h +88 -0
- data/ext/pg_query/include/postgres/utils/typcache.h +210 -0
- data/ext/pg_query/include/postgres/utils/varlena.h +53 -0
- data/ext/pg_query/include/postgres/utils/wait_event.h +108 -0
- data/ext/pg_query/include/postgres/utils/wait_event_types.h +218 -0
- data/ext/pg_query/include/postgres/utils/xml.h +94 -0
- data/ext/pg_query/include/postgres/varatt.h +358 -0
- data/ext/pg_query/include/protobuf/pg_query.pb-c.h +8077 -6217
- data/ext/pg_query/include/protobuf/pg_query.pb.h +132024 -88124
- data/ext/pg_query/pg_query.c +10 -1
- data/ext/pg_query/pg_query.pb-c.c +24028 -17173
- data/ext/pg_query/pg_query_deparse.c +1 -9902
- data/ext/pg_query/pg_query_fingerprint.c +42 -18
- data/ext/pg_query/pg_query_fingerprint.h +1 -1
- data/ext/pg_query/pg_query_internal.h +1 -1
- data/ext/pg_query/pg_query_json_plpgsql.c +1 -25
- data/ext/pg_query/pg_query_normalize.c +44 -3
- data/ext/pg_query/pg_query_outfuncs_json.c +62 -16
- data/ext/pg_query/pg_query_outfuncs_protobuf.c +73 -12
- data/ext/pg_query/pg_query_parse.c +47 -5
- data/ext/pg_query/pg_query_parse_plpgsql.c +19 -18
- data/ext/pg_query/pg_query_readfuncs_protobuf.c +45 -10
- data/ext/pg_query/pg_query_ruby.c +5 -0
- data/ext/pg_query/pg_query_scan.c +4 -3
- data/ext/pg_query/pg_query_split.c +6 -5
- data/ext/pg_query/postgres_deparse.c +11496 -0
- data/ext/pg_query/postgres_deparse.h +9 -0
- data/ext/pg_query/src_backend_catalog_namespace.c +262 -71
- data/ext/pg_query/src_backend_catalog_pg_proc.c +3 -2
- data/ext/pg_query/src_backend_commands_define.c +12 -3
- data/ext/pg_query/src_backend_nodes_bitmapset.c +142 -156
- data/ext/pg_query/src_backend_nodes_copyfuncs.c +100 -5881
- data/ext/pg_query/src_backend_nodes_equalfuncs.c +102 -3831
- data/ext/pg_query/src_backend_nodes_extensible.c +6 -29
- data/ext/pg_query/src_backend_nodes_list.c +89 -18
- data/ext/pg_query/src_backend_nodes_makefuncs.c +138 -4
- data/ext/pg_query/src_backend_nodes_nodeFuncs.c +433 -132
- data/ext/pg_query/src_backend_nodes_value.c +28 -19
- data/ext/pg_query/src_backend_parser_gram.c +45255 -38885
- data/ext/pg_query/src_backend_parser_parser.c +53 -8
- data/ext/pg_query/src_backend_parser_scan.c +6999 -3438
- data/ext/pg_query/src_backend_parser_scansup.c +5 -28
- data/ext/pg_query/src_backend_storage_ipc_ipc.c +13 -4
- data/ext/pg_query/src_backend_tcop_postgres.c +156 -114
- data/ext/pg_query/src_backend_utils_activity_pgstat_database.c +140 -0
- data/ext/pg_query/src_backend_utils_adt_datum.c +14 -2
- data/ext/pg_query/src_backend_utils_adt_expandeddatum.c +1 -1
- data/ext/pg_query/src_backend_utils_adt_format_type.c +6 -2
- data/ext/pg_query/src_backend_utils_adt_numutils.c +488 -0
- data/ext/pg_query/src_backend_utils_adt_ruleutils.c +247 -34
- data/ext/pg_query/src_backend_utils_error_assert.c +17 -18
- data/ext/pg_query/src_backend_utils_error_elog.c +543 -343
- data/ext/pg_query/src_backend_utils_fmgr_fmgr.c +47 -18
- data/ext/pg_query/src_backend_utils_init_globals.c +22 -7
- data/ext/pg_query/src_backend_utils_mb_mbutils.c +84 -148
- data/ext/pg_query/src_backend_utils_misc_guc_tables.c +502 -0
- data/ext/pg_query/src_backend_utils_mmgr_alignedalloc.c +166 -0
- data/ext/pg_query/src_backend_utils_mmgr_aset.c +708 -499
- data/ext/pg_query/src_backend_utils_mmgr_bump.c +728 -0
- data/ext/pg_query/src_backend_utils_mmgr_generation.c +1115 -0
- data/ext/pg_query/src_backend_utils_mmgr_mcxt.c +710 -218
- data/ext/pg_query/src_backend_utils_mmgr_slab.c +1079 -0
- data/ext/pg_query/src_common_encnames.c +46 -44
- data/ext/pg_query/src_common_hashfn.c +3 -3
- data/ext/pg_query/src_common_keywords.c +15 -2
- data/ext/pg_query/src_common_kwlist_d.h +602 -510
- data/ext/pg_query/src_common_kwlookup.c +1 -1
- data/ext/pg_query/src_common_psprintf.c +3 -3
- data/ext/pg_query/src_common_stringinfo.c +21 -4
- data/ext/pg_query/src_common_wchar.c +754 -178
- data/ext/pg_query/src_pl_plpgsql_src_pl_comp.c +143 -24
- data/ext/pg_query/src_pl_plpgsql_src_pl_funcs.c +3 -18
- data/ext/pg_query/src_pl_plpgsql_src_pl_gram.c +1295 -1255
- data/ext/pg_query/src_pl_plpgsql_src_pl_handler.c +1 -1
- data/ext/pg_query/src_pl_plpgsql_src_pl_reserved_kwlist_d.h +10 -10
- data/ext/pg_query/src_pl_plpgsql_src_pl_scanner.c +20 -2
- data/ext/pg_query/src_pl_plpgsql_src_pl_unreserved_kwlist_d.h +60 -60
- data/ext/pg_query/src_port_pg_bitutils.c +283 -54
- data/ext/pg_query/src_port_pgstrcasecmp.c +57 -1
- data/ext/pg_query/src_port_qsort.c +12 -224
- data/ext/pg_query/src_port_snprintf.c +56 -39
- data/ext/pg_query/src_port_strerror.c +9 -21
- data/ext/pg_query/src_port_strlcpy.c +79 -0
- data/lib/pg_query/filter_columns.rb +1 -1
- data/lib/pg_query/fingerprint.rb +10 -9
- data/lib/pg_query/node.rb +18 -13
- data/lib/pg_query/param_refs.rb +3 -3
- data/lib/pg_query/parse.rb +25 -15
- data/lib/pg_query/parse_error.rb +1 -0
- data/lib/pg_query/pg_query_pb.rb +181 -3038
- data/lib/pg_query/scan.rb +1 -0
- data/lib/pg_query/treewalker.rb +55 -8
- data/lib/pg_query/truncate.rb +19 -21
- data/lib/pg_query/version.rb +1 -1
- metadata +447 -436
- data/ext/pg_query/guc-file.c +0 -0
- data/ext/pg_query/include/access/amapi.h +0 -246
- data/ext/pg_query/include/access/attmap.h +0 -52
- data/ext/pg_query/include/access/attnum.h +0 -64
- data/ext/pg_query/include/access/clog.h +0 -61
- data/ext/pg_query/include/access/commit_ts.h +0 -77
- data/ext/pg_query/include/access/detoast.h +0 -92
- data/ext/pg_query/include/access/genam.h +0 -228
- data/ext/pg_query/include/access/gin.h +0 -78
- data/ext/pg_query/include/access/htup.h +0 -89
- data/ext/pg_query/include/access/htup_details.h +0 -819
- data/ext/pg_query/include/access/itup.h +0 -161
- data/ext/pg_query/include/access/parallel.h +0 -82
- data/ext/pg_query/include/access/printtup.h +0 -35
- data/ext/pg_query/include/access/relation.h +0 -28
- data/ext/pg_query/include/access/relscan.h +0 -176
- data/ext/pg_query/include/access/rmgr.h +0 -35
- data/ext/pg_query/include/access/rmgrlist.h +0 -49
- data/ext/pg_query/include/access/sdir.h +0 -58
- data/ext/pg_query/include/access/skey.h +0 -151
- data/ext/pg_query/include/access/stratnum.h +0 -83
- data/ext/pg_query/include/access/sysattr.h +0 -29
- data/ext/pg_query/include/access/table.h +0 -27
- data/ext/pg_query/include/access/tableam.h +0 -1825
- data/ext/pg_query/include/access/transam.h +0 -265
- data/ext/pg_query/include/access/tupconvert.h +0 -51
- data/ext/pg_query/include/access/tupdesc.h +0 -154
- data/ext/pg_query/include/access/tupmacs.h +0 -247
- data/ext/pg_query/include/access/twophase.h +0 -63
- data/ext/pg_query/include/access/xact.h +0 -469
- data/ext/pg_query/include/access/xlog.h +0 -398
- data/ext/pg_query/include/access/xlog_internal.h +0 -339
- data/ext/pg_query/include/access/xlogdefs.h +0 -109
- data/ext/pg_query/include/access/xloginsert.h +0 -64
- data/ext/pg_query/include/access/xlogreader.h +0 -337
- data/ext/pg_query/include/access/xlogrecord.h +0 -227
- data/ext/pg_query/include/bootstrap/bootstrap.h +0 -62
- data/ext/pg_query/include/c.h +0 -1334
- data/ext/pg_query/include/catalog/catalog.h +0 -42
- data/ext/pg_query/include/catalog/catversion.h +0 -58
- data/ext/pg_query/include/catalog/dependency.h +0 -277
- data/ext/pg_query/include/catalog/genbki.h +0 -64
- data/ext/pg_query/include/catalog/index.h +0 -199
- data/ext/pg_query/include/catalog/indexing.h +0 -366
- data/ext/pg_query/include/catalog/namespace.h +0 -188
- data/ext/pg_query/include/catalog/objectaccess.h +0 -197
- data/ext/pg_query/include/catalog/objectaddress.h +0 -84
- data/ext/pg_query/include/catalog/pg_aggregate.h +0 -176
- data/ext/pg_query/include/catalog/pg_aggregate_d.h +0 -77
- data/ext/pg_query/include/catalog/pg_am.h +0 -60
- data/ext/pg_query/include/catalog/pg_am_d.h +0 -45
- data/ext/pg_query/include/catalog/pg_attribute.h +0 -204
- data/ext/pg_query/include/catalog/pg_attribute_d.h +0 -59
- data/ext/pg_query/include/catalog/pg_authid.h +0 -58
- data/ext/pg_query/include/catalog/pg_authid_d.h +0 -49
- data/ext/pg_query/include/catalog/pg_class.h +0 -200
- data/ext/pg_query/include/catalog/pg_class_d.h +0 -103
- data/ext/pg_query/include/catalog/pg_collation.h +0 -73
- data/ext/pg_query/include/catalog/pg_collation_d.h +0 -45
- data/ext/pg_query/include/catalog/pg_constraint.h +0 -247
- data/ext/pg_query/include/catalog/pg_constraint_d.h +0 -67
- data/ext/pg_query/include/catalog/pg_control.h +0 -252
- data/ext/pg_query/include/catalog/pg_conversion.h +0 -72
- data/ext/pg_query/include/catalog/pg_conversion_d.h +0 -35
- data/ext/pg_query/include/catalog/pg_depend.h +0 -73
- data/ext/pg_query/include/catalog/pg_depend_d.h +0 -34
- data/ext/pg_query/include/catalog/pg_event_trigger.h +0 -51
- data/ext/pg_query/include/catalog/pg_event_trigger_d.h +0 -34
- data/ext/pg_query/include/catalog/pg_index.h +0 -80
- data/ext/pg_query/include/catalog/pg_index_d.h +0 -56
- data/ext/pg_query/include/catalog/pg_language.h +0 -67
- data/ext/pg_query/include/catalog/pg_language_d.h +0 -39
- data/ext/pg_query/include/catalog/pg_namespace.h +0 -59
- data/ext/pg_query/include/catalog/pg_namespace_d.h +0 -34
- data/ext/pg_query/include/catalog/pg_opclass.h +0 -85
- data/ext/pg_query/include/catalog/pg_opclass_d.h +0 -49
- data/ext/pg_query/include/catalog/pg_operator.h +0 -104
- data/ext/pg_query/include/catalog/pg_operator_d.h +0 -106
- data/ext/pg_query/include/catalog/pg_opfamily.h +0 -60
- data/ext/pg_query/include/catalog/pg_opfamily_d.h +0 -47
- data/ext/pg_query/include/catalog/pg_partitioned_table.h +0 -63
- data/ext/pg_query/include/catalog/pg_partitioned_table_d.h +0 -35
- data/ext/pg_query/include/catalog/pg_proc.h +0 -211
- data/ext/pg_query/include/catalog/pg_proc_d.h +0 -99
- data/ext/pg_query/include/catalog/pg_publication.h +0 -118
- data/ext/pg_query/include/catalog/pg_publication_d.h +0 -36
- data/ext/pg_query/include/catalog/pg_replication_origin.h +0 -57
- data/ext/pg_query/include/catalog/pg_replication_origin_d.h +0 -29
- data/ext/pg_query/include/catalog/pg_statistic.h +0 -275
- data/ext/pg_query/include/catalog/pg_statistic_d.h +0 -194
- data/ext/pg_query/include/catalog/pg_statistic_ext.h +0 -74
- data/ext/pg_query/include/catalog/pg_statistic_ext_d.h +0 -40
- data/ext/pg_query/include/catalog/pg_transform.h +0 -45
- data/ext/pg_query/include/catalog/pg_transform_d.h +0 -32
- data/ext/pg_query/include/catalog/pg_trigger.h +0 -137
- data/ext/pg_query/include/catalog/pg_trigger_d.h +0 -106
- data/ext/pg_query/include/catalog/pg_ts_config.h +0 -50
- data/ext/pg_query/include/catalog/pg_ts_config_d.h +0 -32
- data/ext/pg_query/include/catalog/pg_ts_dict.h +0 -54
- data/ext/pg_query/include/catalog/pg_ts_dict_d.h +0 -33
- data/ext/pg_query/include/catalog/pg_ts_parser.h +0 -57
- data/ext/pg_query/include/catalog/pg_ts_parser_d.h +0 -35
- data/ext/pg_query/include/catalog/pg_ts_template.h +0 -48
- data/ext/pg_query/include/catalog/pg_ts_template_d.h +0 -32
- data/ext/pg_query/include/catalog/pg_type.h +0 -373
- data/ext/pg_query/include/catalog/pg_type_d.h +0 -285
- data/ext/pg_query/include/catalog/storage.h +0 -48
- data/ext/pg_query/include/commands/async.h +0 -54
- data/ext/pg_query/include/commands/dbcommands.h +0 -35
- data/ext/pg_query/include/commands/defrem.h +0 -173
- data/ext/pg_query/include/commands/event_trigger.h +0 -88
- data/ext/pg_query/include/commands/explain.h +0 -127
- data/ext/pg_query/include/commands/prepare.h +0 -61
- data/ext/pg_query/include/commands/tablespace.h +0 -69
- data/ext/pg_query/include/commands/trigger.h +0 -285
- data/ext/pg_query/include/commands/user.h +0 -37
- data/ext/pg_query/include/commands/vacuum.h +0 -293
- data/ext/pg_query/include/commands/variable.h +0 -38
- data/ext/pg_query/include/common/file_perm.h +0 -56
- data/ext/pg_query/include/common/hashfn.h +0 -104
- data/ext/pg_query/include/common/ip.h +0 -37
- data/ext/pg_query/include/common/keywords.h +0 -33
- data/ext/pg_query/include/common/kwlookup.h +0 -44
- data/ext/pg_query/include/common/relpath.h +0 -90
- data/ext/pg_query/include/common/string.h +0 -19
- data/ext/pg_query/include/common/unicode_combining_table.h +0 -196
- data/ext/pg_query/include/datatype/timestamp.h +0 -197
- data/ext/pg_query/include/executor/execdesc.h +0 -70
- data/ext/pg_query/include/executor/executor.h +0 -620
- data/ext/pg_query/include/executor/functions.h +0 -41
- data/ext/pg_query/include/executor/instrument.h +0 -101
- data/ext/pg_query/include/executor/spi.h +0 -175
- data/ext/pg_query/include/executor/tablefunc.h +0 -67
- data/ext/pg_query/include/executor/tuptable.h +0 -487
- data/ext/pg_query/include/fmgr.h +0 -775
- data/ext/pg_query/include/funcapi.h +0 -348
- data/ext/pg_query/include/getaddrinfo.h +0 -162
- data/ext/pg_query/include/jit/jit.h +0 -105
- data/ext/pg_query/include/kwlist_d.h +0 -1072
- data/ext/pg_query/include/lib/ilist.h +0 -727
- data/ext/pg_query/include/lib/pairingheap.h +0 -102
- data/ext/pg_query/include/lib/simplehash.h +0 -1059
- data/ext/pg_query/include/lib/stringinfo.h +0 -161
- data/ext/pg_query/include/libpq/auth.h +0 -29
- data/ext/pg_query/include/libpq/crypt.h +0 -46
- data/ext/pg_query/include/libpq/hba.h +0 -140
- data/ext/pg_query/include/libpq/libpq-be.h +0 -326
- data/ext/pg_query/include/libpq/libpq.h +0 -134
- data/ext/pg_query/include/libpq/pqcomm.h +0 -208
- data/ext/pg_query/include/libpq/pqformat.h +0 -210
- data/ext/pg_query/include/libpq/pqsignal.h +0 -42
- data/ext/pg_query/include/mb/pg_wchar.h +0 -673
- data/ext/pg_query/include/mb/stringinfo_mb.h +0 -24
- data/ext/pg_query/include/miscadmin.h +0 -489
- data/ext/pg_query/include/nodes/bitmapset.h +0 -122
- data/ext/pg_query/include/nodes/execnodes.h +0 -2523
- data/ext/pg_query/include/nodes/extensible.h +0 -160
- data/ext/pg_query/include/nodes/lockoptions.h +0 -61
- data/ext/pg_query/include/nodes/makefuncs.h +0 -108
- data/ext/pg_query/include/nodes/memnodes.h +0 -108
- data/ext/pg_query/include/nodes/nodeFuncs.h +0 -162
- data/ext/pg_query/include/nodes/nodes.h +0 -842
- data/ext/pg_query/include/nodes/params.h +0 -170
- data/ext/pg_query/include/nodes/parsenodes.h +0 -3580
- data/ext/pg_query/include/nodes/pathnodes.h +0 -2557
- data/ext/pg_query/include/nodes/pg_list.h +0 -606
- data/ext/pg_query/include/nodes/plannodes.h +0 -1266
- data/ext/pg_query/include/nodes/primnodes.h +0 -1541
- data/ext/pg_query/include/nodes/print.h +0 -34
- data/ext/pg_query/include/nodes/tidbitmap.h +0 -75
- data/ext/pg_query/include/nodes/value.h +0 -61
- data/ext/pg_query/include/optimizer/cost.h +0 -206
- data/ext/pg_query/include/optimizer/geqo.h +0 -88
- data/ext/pg_query/include/optimizer/geqo_gene.h +0 -45
- data/ext/pg_query/include/optimizer/optimizer.h +0 -194
- data/ext/pg_query/include/optimizer/paths.h +0 -257
- data/ext/pg_query/include/optimizer/planmain.h +0 -119
- data/ext/pg_query/include/parser/analyze.h +0 -49
- data/ext/pg_query/include/parser/gram.h +0 -1067
- data/ext/pg_query/include/parser/gramparse.h +0 -75
- data/ext/pg_query/include/parser/kwlist.h +0 -477
- data/ext/pg_query/include/parser/parse_agg.h +0 -68
- data/ext/pg_query/include/parser/parse_clause.h +0 -54
- data/ext/pg_query/include/parser/parse_coerce.h +0 -98
- data/ext/pg_query/include/parser/parse_collate.h +0 -27
- data/ext/pg_query/include/parser/parse_expr.h +0 -26
- data/ext/pg_query/include/parser/parse_func.h +0 -73
- data/ext/pg_query/include/parser/parse_node.h +0 -327
- data/ext/pg_query/include/parser/parse_oper.h +0 -67
- data/ext/pg_query/include/parser/parse_relation.h +0 -123
- data/ext/pg_query/include/parser/parse_target.h +0 -46
- data/ext/pg_query/include/parser/parse_type.h +0 -60
- data/ext/pg_query/include/parser/parser.h +0 -41
- data/ext/pg_query/include/parser/parsetree.h +0 -61
- data/ext/pg_query/include/parser/scanner.h +0 -152
- data/ext/pg_query/include/parser/scansup.h +0 -30
- data/ext/pg_query/include/partitioning/partdefs.h +0 -26
- data/ext/pg_query/include/pg_config.h +0 -995
- data/ext/pg_query/include/pg_config_manual.h +0 -357
- data/ext/pg_query/include/pg_config_os.h +0 -8
- data/ext/pg_query/include/pg_getopt.h +0 -56
- data/ext/pg_query/include/pg_trace.h +0 -17
- data/ext/pg_query/include/pgstat.h +0 -1488
- data/ext/pg_query/include/pgtime.h +0 -84
- data/ext/pg_query/include/pl_gram.h +0 -385
- data/ext/pg_query/include/pl_reserved_kwlist.h +0 -52
- data/ext/pg_query/include/pl_reserved_kwlist_d.h +0 -114
- data/ext/pg_query/include/pl_unreserved_kwlist.h +0 -112
- data/ext/pg_query/include/pl_unreserved_kwlist_d.h +0 -246
- data/ext/pg_query/include/plerrcodes.h +0 -990
- data/ext/pg_query/include/plpgsql.h +0 -1347
- data/ext/pg_query/include/port/atomics/arch-arm.h +0 -26
- data/ext/pg_query/include/port/atomics/arch-ppc.h +0 -254
- data/ext/pg_query/include/port/atomics/arch-x86.h +0 -252
- data/ext/pg_query/include/port/atomics/fallback.h +0 -170
- data/ext/pg_query/include/port/atomics/generic-gcc.h +0 -286
- data/ext/pg_query/include/port/atomics/generic.h +0 -401
- data/ext/pg_query/include/port/atomics.h +0 -524
- data/ext/pg_query/include/port/pg_bitutils.h +0 -272
- data/ext/pg_query/include/port/pg_bswap.h +0 -161
- data/ext/pg_query/include/port/pg_crc32c.h +0 -101
- data/ext/pg_query/include/port.h +0 -528
- data/ext/pg_query/include/portability/instr_time.h +0 -256
- data/ext/pg_query/include/postgres.h +0 -764
- data/ext/pg_query/include/postgres_ext.h +0 -74
- data/ext/pg_query/include/postmaster/autovacuum.h +0 -83
- data/ext/pg_query/include/postmaster/bgworker.h +0 -161
- data/ext/pg_query/include/postmaster/bgworker_internals.h +0 -64
- data/ext/pg_query/include/postmaster/bgwriter.h +0 -45
- data/ext/pg_query/include/postmaster/fork_process.h +0 -17
- data/ext/pg_query/include/postmaster/interrupt.h +0 -32
- data/ext/pg_query/include/postmaster/pgarch.h +0 -39
- data/ext/pg_query/include/postmaster/postmaster.h +0 -77
- data/ext/pg_query/include/postmaster/syslogger.h +0 -98
- data/ext/pg_query/include/postmaster/walwriter.h +0 -21
- data/ext/pg_query/include/regex/regex.h +0 -184
- data/ext/pg_query/include/replication/logicallauncher.h +0 -31
- data/ext/pg_query/include/replication/logicalproto.h +0 -110
- data/ext/pg_query/include/replication/logicalworker.h +0 -19
- data/ext/pg_query/include/replication/origin.h +0 -73
- data/ext/pg_query/include/replication/reorderbuffer.h +0 -468
- data/ext/pg_query/include/replication/slot.h +0 -219
- data/ext/pg_query/include/replication/syncrep.h +0 -115
- data/ext/pg_query/include/replication/walreceiver.h +0 -340
- data/ext/pg_query/include/replication/walsender.h +0 -74
- data/ext/pg_query/include/rewrite/prs2lock.h +0 -46
- data/ext/pg_query/include/rewrite/rewriteHandler.h +0 -40
- data/ext/pg_query/include/rewrite/rewriteManip.h +0 -87
- data/ext/pg_query/include/rewrite/rewriteSupport.h +0 -26
- data/ext/pg_query/include/storage/backendid.h +0 -37
- data/ext/pg_query/include/storage/block.h +0 -121
- data/ext/pg_query/include/storage/buf.h +0 -46
- data/ext/pg_query/include/storage/bufmgr.h +0 -292
- data/ext/pg_query/include/storage/bufpage.h +0 -459
- data/ext/pg_query/include/storage/condition_variable.h +0 -62
- data/ext/pg_query/include/storage/dsm.h +0 -61
- data/ext/pg_query/include/storage/dsm_impl.h +0 -75
- data/ext/pg_query/include/storage/fd.h +0 -168
- data/ext/pg_query/include/storage/ipc.h +0 -81
- data/ext/pg_query/include/storage/item.h +0 -19
- data/ext/pg_query/include/storage/itemid.h +0 -184
- data/ext/pg_query/include/storage/itemptr.h +0 -206
- data/ext/pg_query/include/storage/large_object.h +0 -100
- data/ext/pg_query/include/storage/latch.h +0 -190
- data/ext/pg_query/include/storage/lmgr.h +0 -114
- data/ext/pg_query/include/storage/lock.h +0 -613
- data/ext/pg_query/include/storage/lockdefs.h +0 -59
- data/ext/pg_query/include/storage/lwlock.h +0 -233
- data/ext/pg_query/include/storage/lwlocknames.h +0 -51
- data/ext/pg_query/include/storage/off.h +0 -57
- data/ext/pg_query/include/storage/pg_sema.h +0 -61
- data/ext/pg_query/include/storage/pg_shmem.h +0 -90
- data/ext/pg_query/include/storage/pmsignal.h +0 -94
- data/ext/pg_query/include/storage/predicate.h +0 -87
- data/ext/pg_query/include/storage/proc.h +0 -347
- data/ext/pg_query/include/storage/proclist_types.h +0 -51
- data/ext/pg_query/include/storage/procsignal.h +0 -75
- data/ext/pg_query/include/storage/relfilenode.h +0 -99
- data/ext/pg_query/include/storage/s_lock.h +0 -1071
- data/ext/pg_query/include/storage/sharedfileset.h +0 -45
- data/ext/pg_query/include/storage/shm_mq.h +0 -85
- data/ext/pg_query/include/storage/shm_toc.h +0 -58
- data/ext/pg_query/include/storage/shmem.h +0 -81
- data/ext/pg_query/include/storage/sinval.h +0 -153
- data/ext/pg_query/include/storage/sinvaladt.h +0 -43
- data/ext/pg_query/include/storage/smgr.h +0 -109
- data/ext/pg_query/include/storage/spin.h +0 -77
- data/ext/pg_query/include/storage/standby.h +0 -91
- data/ext/pg_query/include/storage/standbydefs.h +0 -74
- data/ext/pg_query/include/storage/sync.h +0 -62
- data/ext/pg_query/include/tcop/cmdtag.h +0 -58
- data/ext/pg_query/include/tcop/cmdtaglist.h +0 -217
- data/ext/pg_query/include/tcop/deparse_utility.h +0 -108
- data/ext/pg_query/include/tcop/dest.h +0 -149
- data/ext/pg_query/include/tcop/fastpath.h +0 -21
- data/ext/pg_query/include/tcop/pquery.h +0 -51
- data/ext/pg_query/include/tcop/tcopprot.h +0 -89
- data/ext/pg_query/include/tcop/utility.h +0 -108
- data/ext/pg_query/include/tsearch/ts_cache.h +0 -98
- data/ext/pg_query/include/utils/acl.h +0 -312
- data/ext/pg_query/include/utils/aclchk_internal.h +0 -45
- data/ext/pg_query/include/utils/array.h +0 -459
- data/ext/pg_query/include/utils/builtins.h +0 -128
- data/ext/pg_query/include/utils/bytea.h +0 -27
- data/ext/pg_query/include/utils/catcache.h +0 -231
- data/ext/pg_query/include/utils/date.h +0 -90
- data/ext/pg_query/include/utils/datetime.h +0 -343
- data/ext/pg_query/include/utils/datum.h +0 -68
- data/ext/pg_query/include/utils/dsa.h +0 -123
- data/ext/pg_query/include/utils/dynahash.h +0 -19
- data/ext/pg_query/include/utils/elog.h +0 -439
- data/ext/pg_query/include/utils/errcodes.h +0 -352
- data/ext/pg_query/include/utils/expandeddatum.h +0 -159
- data/ext/pg_query/include/utils/expandedrecord.h +0 -231
- data/ext/pg_query/include/utils/float.h +0 -356
- data/ext/pg_query/include/utils/fmgroids.h +0 -2657
- data/ext/pg_query/include/utils/fmgrprotos.h +0 -2646
- data/ext/pg_query/include/utils/fmgrtab.h +0 -48
- data/ext/pg_query/include/utils/guc.h +0 -443
- data/ext/pg_query/include/utils/guc_tables.h +0 -272
- data/ext/pg_query/include/utils/hsearch.h +0 -149
- data/ext/pg_query/include/utils/inval.h +0 -65
- data/ext/pg_query/include/utils/lsyscache.h +0 -198
- data/ext/pg_query/include/utils/memdebug.h +0 -82
- data/ext/pg_query/include/utils/memutils.h +0 -225
- data/ext/pg_query/include/utils/numeric.h +0 -76
- data/ext/pg_query/include/utils/palloc.h +0 -136
- data/ext/pg_query/include/utils/partcache.h +0 -102
- data/ext/pg_query/include/utils/pg_locale.h +0 -119
- data/ext/pg_query/include/utils/pg_lsn.h +0 -29
- data/ext/pg_query/include/utils/pidfile.h +0 -56
- data/ext/pg_query/include/utils/plancache.h +0 -235
- data/ext/pg_query/include/utils/portal.h +0 -254
- data/ext/pg_query/include/utils/probes.h +0 -114
- data/ext/pg_query/include/utils/ps_status.h +0 -25
- data/ext/pg_query/include/utils/queryenvironment.h +0 -74
- data/ext/pg_query/include/utils/regproc.h +0 -28
- data/ext/pg_query/include/utils/rel.h +0 -643
- data/ext/pg_query/include/utils/relcache.h +0 -150
- data/ext/pg_query/include/utils/reltrigger.h +0 -81
- data/ext/pg_query/include/utils/resowner.h +0 -86
- data/ext/pg_query/include/utils/rls.h +0 -50
- data/ext/pg_query/include/utils/ruleutils.h +0 -44
- data/ext/pg_query/include/utils/sharedtuplestore.h +0 -61
- data/ext/pg_query/include/utils/snapmgr.h +0 -159
- data/ext/pg_query/include/utils/snapshot.h +0 -206
- data/ext/pg_query/include/utils/sortsupport.h +0 -276
- data/ext/pg_query/include/utils/syscache.h +0 -219
- data/ext/pg_query/include/utils/timeout.h +0 -88
- data/ext/pg_query/include/utils/timestamp.h +0 -116
- data/ext/pg_query/include/utils/tuplesort.h +0 -277
- data/ext/pg_query/include/utils/tuplestore.h +0 -91
- data/ext/pg_query/include/utils/typcache.h +0 -202
- data/ext/pg_query/include/utils/tzparser.h +0 -39
- data/ext/pg_query/include/utils/varlena.h +0 -39
- data/ext/pg_query/include/utils/xml.h +0 -84
- data/ext/pg_query/pg_query_ruby_freebsd.sym +0 -2
- data/ext/pg_query/src_backend_libpq_pqcomm.c +0 -659
- data/ext/pg_query/src_backend_parser_parse_expr.c +0 -313
- data/ext/pg_query/src_backend_postmaster_postmaster.c +0 -2230
- data/ext/pg_query/src_backend_storage_lmgr_s_lock.c +0 -370
- data/ext/pg_query/src_backend_utils_hash_dynahash.c +0 -1086
- data/ext/pg_query/src_backend_utils_misc_guc.c +0 -1832
- data/ext/pg_query/src_common_string.c +0 -86
- data/ext/pg_query/src_port_erand48.c +0 -127
- data/ext/pg_query/src_port_pgsleep.c +0 -69
- data/ext/pg_query/src_port_random.c +0 -31
- data/ext/pg_query/src_port_strnlen.c +0 -39
- /data/ext/pg_query/{pg_query_ruby.sym → ext_symbols.sym} +0 -0
- /data/ext/pg_query/include/{pg_config_ext.h → postgres/pg_config_ext.h} +0 -0
@@ -0,0 +1,3310 @@
|
|
1
|
+
/*-------------------------------------------------------------------------
|
2
|
+
*
|
3
|
+
* equalfuncs.funcs.c
|
4
|
+
* Generated node infrastructure code
|
5
|
+
*
|
6
|
+
* Portions Copyright (c) 1996-2024, PostgreSQL Global Development Group
|
7
|
+
* Portions Copyright (c) 1994, Regents of the University of California
|
8
|
+
*
|
9
|
+
* NOTES
|
10
|
+
* ******************************
|
11
|
+
* *** DO NOT EDIT THIS FILE! ***
|
12
|
+
* ******************************
|
13
|
+
*
|
14
|
+
* It has been GENERATED by src/backend/nodes/gen_node_support.pl
|
15
|
+
*
|
16
|
+
*-------------------------------------------------------------------------
|
17
|
+
*/
|
18
|
+
#include "access/amapi.h"
|
19
|
+
#include "access/sdir.h"
|
20
|
+
#include "access/tableam.h"
|
21
|
+
#include "access/tsmapi.h"
|
22
|
+
#include "commands/event_trigger.h"
|
23
|
+
#include "commands/trigger.h"
|
24
|
+
#include "executor/tuptable.h"
|
25
|
+
#include "foreign/fdwapi.h"
|
26
|
+
#include "nodes/bitmapset.h"
|
27
|
+
#include "nodes/execnodes.h"
|
28
|
+
#include "nodes/extensible.h"
|
29
|
+
#include "nodes/lockoptions.h"
|
30
|
+
#include "nodes/miscnodes.h"
|
31
|
+
#include "nodes/nodes.h"
|
32
|
+
#include "nodes/parsenodes.h"
|
33
|
+
#include "nodes/pathnodes.h"
|
34
|
+
#include "nodes/plannodes.h"
|
35
|
+
#include "nodes/primnodes.h"
|
36
|
+
#include "nodes/replnodes.h"
|
37
|
+
#include "nodes/supportnodes.h"
|
38
|
+
#include "nodes/value.h"
|
39
|
+
#include "utils/rel.h"
|
40
|
+
|
41
|
+
static bool
|
42
|
+
_equalAlias(const Alias *a, const Alias *b)
|
43
|
+
{
|
44
|
+
COMPARE_STRING_FIELD(aliasname);
|
45
|
+
COMPARE_NODE_FIELD(colnames);
|
46
|
+
|
47
|
+
return true;
|
48
|
+
}
|
49
|
+
|
50
|
+
static bool
|
51
|
+
_equalRangeVar(const RangeVar *a, const RangeVar *b)
|
52
|
+
{
|
53
|
+
COMPARE_STRING_FIELD(catalogname);
|
54
|
+
COMPARE_STRING_FIELD(schemaname);
|
55
|
+
COMPARE_STRING_FIELD(relname);
|
56
|
+
COMPARE_SCALAR_FIELD(inh);
|
57
|
+
COMPARE_SCALAR_FIELD(relpersistence);
|
58
|
+
COMPARE_NODE_FIELD(alias);
|
59
|
+
COMPARE_LOCATION_FIELD(location);
|
60
|
+
|
61
|
+
return true;
|
62
|
+
}
|
63
|
+
|
64
|
+
static bool
|
65
|
+
_equalTableFunc(const TableFunc *a, const TableFunc *b)
|
66
|
+
{
|
67
|
+
COMPARE_SCALAR_FIELD(functype);
|
68
|
+
COMPARE_NODE_FIELD(ns_uris);
|
69
|
+
COMPARE_NODE_FIELD(ns_names);
|
70
|
+
COMPARE_NODE_FIELD(docexpr);
|
71
|
+
COMPARE_NODE_FIELD(rowexpr);
|
72
|
+
COMPARE_NODE_FIELD(colnames);
|
73
|
+
COMPARE_NODE_FIELD(coltypes);
|
74
|
+
COMPARE_NODE_FIELD(coltypmods);
|
75
|
+
COMPARE_NODE_FIELD(colcollations);
|
76
|
+
COMPARE_NODE_FIELD(colexprs);
|
77
|
+
COMPARE_NODE_FIELD(coldefexprs);
|
78
|
+
COMPARE_NODE_FIELD(colvalexprs);
|
79
|
+
COMPARE_NODE_FIELD(passingvalexprs);
|
80
|
+
COMPARE_BITMAPSET_FIELD(notnulls);
|
81
|
+
COMPARE_NODE_FIELD(plan);
|
82
|
+
COMPARE_SCALAR_FIELD(ordinalitycol);
|
83
|
+
COMPARE_LOCATION_FIELD(location);
|
84
|
+
|
85
|
+
return true;
|
86
|
+
}
|
87
|
+
|
88
|
+
static bool
|
89
|
+
_equalIntoClause(const IntoClause *a, const IntoClause *b)
|
90
|
+
{
|
91
|
+
COMPARE_NODE_FIELD(rel);
|
92
|
+
COMPARE_NODE_FIELD(colNames);
|
93
|
+
COMPARE_STRING_FIELD(accessMethod);
|
94
|
+
COMPARE_NODE_FIELD(options);
|
95
|
+
COMPARE_SCALAR_FIELD(onCommit);
|
96
|
+
COMPARE_STRING_FIELD(tableSpaceName);
|
97
|
+
COMPARE_NODE_FIELD(viewQuery);
|
98
|
+
COMPARE_SCALAR_FIELD(skipData);
|
99
|
+
|
100
|
+
return true;
|
101
|
+
}
|
102
|
+
|
103
|
+
static bool
|
104
|
+
_equalVar(const Var *a, const Var *b)
|
105
|
+
{
|
106
|
+
COMPARE_SCALAR_FIELD(varno);
|
107
|
+
COMPARE_SCALAR_FIELD(varattno);
|
108
|
+
COMPARE_SCALAR_FIELD(vartype);
|
109
|
+
COMPARE_SCALAR_FIELD(vartypmod);
|
110
|
+
COMPARE_SCALAR_FIELD(varcollid);
|
111
|
+
COMPARE_BITMAPSET_FIELD(varnullingrels);
|
112
|
+
COMPARE_SCALAR_FIELD(varlevelsup);
|
113
|
+
COMPARE_LOCATION_FIELD(location);
|
114
|
+
|
115
|
+
return true;
|
116
|
+
}
|
117
|
+
|
118
|
+
static bool
|
119
|
+
_equalParam(const Param *a, const Param *b)
|
120
|
+
{
|
121
|
+
COMPARE_SCALAR_FIELD(paramkind);
|
122
|
+
COMPARE_SCALAR_FIELD(paramid);
|
123
|
+
COMPARE_SCALAR_FIELD(paramtype);
|
124
|
+
COMPARE_SCALAR_FIELD(paramtypmod);
|
125
|
+
COMPARE_SCALAR_FIELD(paramcollid);
|
126
|
+
COMPARE_LOCATION_FIELD(location);
|
127
|
+
|
128
|
+
return true;
|
129
|
+
}
|
130
|
+
|
131
|
+
static bool
|
132
|
+
_equalAggref(const Aggref *a, const Aggref *b)
|
133
|
+
{
|
134
|
+
COMPARE_SCALAR_FIELD(aggfnoid);
|
135
|
+
COMPARE_SCALAR_FIELD(aggtype);
|
136
|
+
COMPARE_SCALAR_FIELD(aggcollid);
|
137
|
+
COMPARE_SCALAR_FIELD(inputcollid);
|
138
|
+
COMPARE_NODE_FIELD(aggargtypes);
|
139
|
+
COMPARE_NODE_FIELD(aggdirectargs);
|
140
|
+
COMPARE_NODE_FIELD(args);
|
141
|
+
COMPARE_NODE_FIELD(aggorder);
|
142
|
+
COMPARE_NODE_FIELD(aggdistinct);
|
143
|
+
COMPARE_NODE_FIELD(aggfilter);
|
144
|
+
COMPARE_SCALAR_FIELD(aggstar);
|
145
|
+
COMPARE_SCALAR_FIELD(aggvariadic);
|
146
|
+
COMPARE_SCALAR_FIELD(aggkind);
|
147
|
+
COMPARE_SCALAR_FIELD(agglevelsup);
|
148
|
+
COMPARE_SCALAR_FIELD(aggsplit);
|
149
|
+
COMPARE_SCALAR_FIELD(aggno);
|
150
|
+
COMPARE_SCALAR_FIELD(aggtransno);
|
151
|
+
COMPARE_LOCATION_FIELD(location);
|
152
|
+
|
153
|
+
return true;
|
154
|
+
}
|
155
|
+
|
156
|
+
static bool
|
157
|
+
_equalGroupingFunc(const GroupingFunc *a, const GroupingFunc *b)
|
158
|
+
{
|
159
|
+
COMPARE_NODE_FIELD(args);
|
160
|
+
COMPARE_SCALAR_FIELD(agglevelsup);
|
161
|
+
COMPARE_LOCATION_FIELD(location);
|
162
|
+
|
163
|
+
return true;
|
164
|
+
}
|
165
|
+
|
166
|
+
static bool
|
167
|
+
_equalWindowFunc(const WindowFunc *a, const WindowFunc *b)
|
168
|
+
{
|
169
|
+
COMPARE_SCALAR_FIELD(winfnoid);
|
170
|
+
COMPARE_SCALAR_FIELD(wintype);
|
171
|
+
COMPARE_SCALAR_FIELD(wincollid);
|
172
|
+
COMPARE_SCALAR_FIELD(inputcollid);
|
173
|
+
COMPARE_NODE_FIELD(args);
|
174
|
+
COMPARE_NODE_FIELD(aggfilter);
|
175
|
+
COMPARE_NODE_FIELD(runCondition);
|
176
|
+
COMPARE_SCALAR_FIELD(winref);
|
177
|
+
COMPARE_SCALAR_FIELD(winstar);
|
178
|
+
COMPARE_SCALAR_FIELD(winagg);
|
179
|
+
COMPARE_LOCATION_FIELD(location);
|
180
|
+
|
181
|
+
return true;
|
182
|
+
}
|
183
|
+
|
184
|
+
static bool
|
185
|
+
_equalWindowFuncRunCondition(const WindowFuncRunCondition *a, const WindowFuncRunCondition *b)
|
186
|
+
{
|
187
|
+
COMPARE_SCALAR_FIELD(opno);
|
188
|
+
COMPARE_SCALAR_FIELD(inputcollid);
|
189
|
+
COMPARE_SCALAR_FIELD(wfunc_left);
|
190
|
+
COMPARE_NODE_FIELD(arg);
|
191
|
+
|
192
|
+
return true;
|
193
|
+
}
|
194
|
+
|
195
|
+
static bool
|
196
|
+
_equalMergeSupportFunc(const MergeSupportFunc *a, const MergeSupportFunc *b)
|
197
|
+
{
|
198
|
+
COMPARE_SCALAR_FIELD(msftype);
|
199
|
+
COMPARE_SCALAR_FIELD(msfcollid);
|
200
|
+
COMPARE_LOCATION_FIELD(location);
|
201
|
+
|
202
|
+
return true;
|
203
|
+
}
|
204
|
+
|
205
|
+
static bool
|
206
|
+
_equalSubscriptingRef(const SubscriptingRef *a, const SubscriptingRef *b)
|
207
|
+
{
|
208
|
+
COMPARE_SCALAR_FIELD(refcontainertype);
|
209
|
+
COMPARE_SCALAR_FIELD(refelemtype);
|
210
|
+
COMPARE_SCALAR_FIELD(refrestype);
|
211
|
+
COMPARE_SCALAR_FIELD(reftypmod);
|
212
|
+
COMPARE_SCALAR_FIELD(refcollid);
|
213
|
+
COMPARE_NODE_FIELD(refupperindexpr);
|
214
|
+
COMPARE_NODE_FIELD(reflowerindexpr);
|
215
|
+
COMPARE_NODE_FIELD(refexpr);
|
216
|
+
COMPARE_NODE_FIELD(refassgnexpr);
|
217
|
+
|
218
|
+
return true;
|
219
|
+
}
|
220
|
+
|
221
|
+
static bool
|
222
|
+
_equalFuncExpr(const FuncExpr *a, const FuncExpr *b)
|
223
|
+
{
|
224
|
+
COMPARE_SCALAR_FIELD(funcid);
|
225
|
+
COMPARE_SCALAR_FIELD(funcresulttype);
|
226
|
+
COMPARE_SCALAR_FIELD(funcretset);
|
227
|
+
COMPARE_SCALAR_FIELD(funcvariadic);
|
228
|
+
COMPARE_SCALAR_FIELD(funccollid);
|
229
|
+
COMPARE_SCALAR_FIELD(inputcollid);
|
230
|
+
COMPARE_NODE_FIELD(args);
|
231
|
+
COMPARE_LOCATION_FIELD(location);
|
232
|
+
|
233
|
+
return true;
|
234
|
+
}
|
235
|
+
|
236
|
+
static bool
|
237
|
+
_equalNamedArgExpr(const NamedArgExpr *a, const NamedArgExpr *b)
|
238
|
+
{
|
239
|
+
COMPARE_NODE_FIELD(arg);
|
240
|
+
COMPARE_STRING_FIELD(name);
|
241
|
+
COMPARE_SCALAR_FIELD(argnumber);
|
242
|
+
COMPARE_LOCATION_FIELD(location);
|
243
|
+
|
244
|
+
return true;
|
245
|
+
}
|
246
|
+
|
247
|
+
static bool
|
248
|
+
_equalOpExpr(const OpExpr *a, const OpExpr *b)
|
249
|
+
{
|
250
|
+
COMPARE_SCALAR_FIELD(opno);
|
251
|
+
if (a->opfuncid != b->opfuncid && a->opfuncid != 0 && b->opfuncid != 0)
|
252
|
+
return false;
|
253
|
+
COMPARE_SCALAR_FIELD(opresulttype);
|
254
|
+
COMPARE_SCALAR_FIELD(opretset);
|
255
|
+
COMPARE_SCALAR_FIELD(opcollid);
|
256
|
+
COMPARE_SCALAR_FIELD(inputcollid);
|
257
|
+
COMPARE_NODE_FIELD(args);
|
258
|
+
COMPARE_LOCATION_FIELD(location);
|
259
|
+
|
260
|
+
return true;
|
261
|
+
}
|
262
|
+
|
263
|
+
static bool
|
264
|
+
_equalDistinctExpr(const DistinctExpr *a, const DistinctExpr *b)
|
265
|
+
{
|
266
|
+
COMPARE_SCALAR_FIELD(opno);
|
267
|
+
if (a->opfuncid != b->opfuncid && a->opfuncid != 0 && b->opfuncid != 0)
|
268
|
+
return false;
|
269
|
+
COMPARE_SCALAR_FIELD(opresulttype);
|
270
|
+
COMPARE_SCALAR_FIELD(opretset);
|
271
|
+
COMPARE_SCALAR_FIELD(opcollid);
|
272
|
+
COMPARE_SCALAR_FIELD(inputcollid);
|
273
|
+
COMPARE_NODE_FIELD(args);
|
274
|
+
COMPARE_LOCATION_FIELD(location);
|
275
|
+
|
276
|
+
return true;
|
277
|
+
}
|
278
|
+
|
279
|
+
static bool
|
280
|
+
_equalNullIfExpr(const NullIfExpr *a, const NullIfExpr *b)
|
281
|
+
{
|
282
|
+
COMPARE_SCALAR_FIELD(opno);
|
283
|
+
if (a->opfuncid != b->opfuncid && a->opfuncid != 0 && b->opfuncid != 0)
|
284
|
+
return false;
|
285
|
+
COMPARE_SCALAR_FIELD(opresulttype);
|
286
|
+
COMPARE_SCALAR_FIELD(opretset);
|
287
|
+
COMPARE_SCALAR_FIELD(opcollid);
|
288
|
+
COMPARE_SCALAR_FIELD(inputcollid);
|
289
|
+
COMPARE_NODE_FIELD(args);
|
290
|
+
COMPARE_LOCATION_FIELD(location);
|
291
|
+
|
292
|
+
return true;
|
293
|
+
}
|
294
|
+
|
295
|
+
static bool
|
296
|
+
_equalScalarArrayOpExpr(const ScalarArrayOpExpr *a, const ScalarArrayOpExpr *b)
|
297
|
+
{
|
298
|
+
COMPARE_SCALAR_FIELD(opno);
|
299
|
+
if (a->opfuncid != b->opfuncid && a->opfuncid != 0 && b->opfuncid != 0)
|
300
|
+
return false;
|
301
|
+
if (a->hashfuncid != b->hashfuncid && a->hashfuncid != 0 && b->hashfuncid != 0)
|
302
|
+
return false;
|
303
|
+
if (a->negfuncid != b->negfuncid && a->negfuncid != 0 && b->negfuncid != 0)
|
304
|
+
return false;
|
305
|
+
COMPARE_SCALAR_FIELD(useOr);
|
306
|
+
COMPARE_SCALAR_FIELD(inputcollid);
|
307
|
+
COMPARE_NODE_FIELD(args);
|
308
|
+
COMPARE_LOCATION_FIELD(location);
|
309
|
+
|
310
|
+
return true;
|
311
|
+
}
|
312
|
+
|
313
|
+
static bool
|
314
|
+
_equalBoolExpr(const BoolExpr *a, const BoolExpr *b)
|
315
|
+
{
|
316
|
+
COMPARE_SCALAR_FIELD(boolop);
|
317
|
+
COMPARE_NODE_FIELD(args);
|
318
|
+
COMPARE_LOCATION_FIELD(location);
|
319
|
+
|
320
|
+
return true;
|
321
|
+
}
|
322
|
+
|
323
|
+
static bool
|
324
|
+
_equalSubLink(const SubLink *a, const SubLink *b)
|
325
|
+
{
|
326
|
+
COMPARE_SCALAR_FIELD(subLinkType);
|
327
|
+
COMPARE_SCALAR_FIELD(subLinkId);
|
328
|
+
COMPARE_NODE_FIELD(testexpr);
|
329
|
+
COMPARE_NODE_FIELD(operName);
|
330
|
+
COMPARE_NODE_FIELD(subselect);
|
331
|
+
COMPARE_LOCATION_FIELD(location);
|
332
|
+
|
333
|
+
return true;
|
334
|
+
}
|
335
|
+
|
336
|
+
static bool
|
337
|
+
_equalSubPlan(const SubPlan *a, const SubPlan *b)
|
338
|
+
{
|
339
|
+
COMPARE_SCALAR_FIELD(subLinkType);
|
340
|
+
COMPARE_NODE_FIELD(testexpr);
|
341
|
+
COMPARE_NODE_FIELD(paramIds);
|
342
|
+
COMPARE_SCALAR_FIELD(plan_id);
|
343
|
+
COMPARE_STRING_FIELD(plan_name);
|
344
|
+
COMPARE_SCALAR_FIELD(firstColType);
|
345
|
+
COMPARE_SCALAR_FIELD(firstColTypmod);
|
346
|
+
COMPARE_SCALAR_FIELD(firstColCollation);
|
347
|
+
COMPARE_SCALAR_FIELD(useHashTable);
|
348
|
+
COMPARE_SCALAR_FIELD(unknownEqFalse);
|
349
|
+
COMPARE_SCALAR_FIELD(parallel_safe);
|
350
|
+
COMPARE_NODE_FIELD(setParam);
|
351
|
+
COMPARE_NODE_FIELD(parParam);
|
352
|
+
COMPARE_NODE_FIELD(args);
|
353
|
+
COMPARE_SCALAR_FIELD(startup_cost);
|
354
|
+
COMPARE_SCALAR_FIELD(per_call_cost);
|
355
|
+
|
356
|
+
return true;
|
357
|
+
}
|
358
|
+
|
359
|
+
static bool
|
360
|
+
_equalAlternativeSubPlan(const AlternativeSubPlan *a, const AlternativeSubPlan *b)
|
361
|
+
{
|
362
|
+
COMPARE_NODE_FIELD(subplans);
|
363
|
+
|
364
|
+
return true;
|
365
|
+
}
|
366
|
+
|
367
|
+
static bool
|
368
|
+
_equalFieldSelect(const FieldSelect *a, const FieldSelect *b)
|
369
|
+
{
|
370
|
+
COMPARE_NODE_FIELD(arg);
|
371
|
+
COMPARE_SCALAR_FIELD(fieldnum);
|
372
|
+
COMPARE_SCALAR_FIELD(resulttype);
|
373
|
+
COMPARE_SCALAR_FIELD(resulttypmod);
|
374
|
+
COMPARE_SCALAR_FIELD(resultcollid);
|
375
|
+
|
376
|
+
return true;
|
377
|
+
}
|
378
|
+
|
379
|
+
static bool
|
380
|
+
_equalFieldStore(const FieldStore *a, const FieldStore *b)
|
381
|
+
{
|
382
|
+
COMPARE_NODE_FIELD(arg);
|
383
|
+
COMPARE_NODE_FIELD(newvals);
|
384
|
+
COMPARE_NODE_FIELD(fieldnums);
|
385
|
+
COMPARE_SCALAR_FIELD(resulttype);
|
386
|
+
|
387
|
+
return true;
|
388
|
+
}
|
389
|
+
|
390
|
+
static bool
|
391
|
+
_equalRelabelType(const RelabelType *a, const RelabelType *b)
|
392
|
+
{
|
393
|
+
COMPARE_NODE_FIELD(arg);
|
394
|
+
COMPARE_SCALAR_FIELD(resulttype);
|
395
|
+
COMPARE_SCALAR_FIELD(resulttypmod);
|
396
|
+
COMPARE_SCALAR_FIELD(resultcollid);
|
397
|
+
COMPARE_LOCATION_FIELD(location);
|
398
|
+
|
399
|
+
return true;
|
400
|
+
}
|
401
|
+
|
402
|
+
static bool
|
403
|
+
_equalCoerceViaIO(const CoerceViaIO *a, const CoerceViaIO *b)
|
404
|
+
{
|
405
|
+
COMPARE_NODE_FIELD(arg);
|
406
|
+
COMPARE_SCALAR_FIELD(resulttype);
|
407
|
+
COMPARE_SCALAR_FIELD(resultcollid);
|
408
|
+
COMPARE_LOCATION_FIELD(location);
|
409
|
+
|
410
|
+
return true;
|
411
|
+
}
|
412
|
+
|
413
|
+
static bool
|
414
|
+
_equalArrayCoerceExpr(const ArrayCoerceExpr *a, const ArrayCoerceExpr *b)
|
415
|
+
{
|
416
|
+
COMPARE_NODE_FIELD(arg);
|
417
|
+
COMPARE_NODE_FIELD(elemexpr);
|
418
|
+
COMPARE_SCALAR_FIELD(resulttype);
|
419
|
+
COMPARE_SCALAR_FIELD(resulttypmod);
|
420
|
+
COMPARE_SCALAR_FIELD(resultcollid);
|
421
|
+
COMPARE_LOCATION_FIELD(location);
|
422
|
+
|
423
|
+
return true;
|
424
|
+
}
|
425
|
+
|
426
|
+
static bool
|
427
|
+
_equalConvertRowtypeExpr(const ConvertRowtypeExpr *a, const ConvertRowtypeExpr *b)
|
428
|
+
{
|
429
|
+
COMPARE_NODE_FIELD(arg);
|
430
|
+
COMPARE_SCALAR_FIELD(resulttype);
|
431
|
+
COMPARE_LOCATION_FIELD(location);
|
432
|
+
|
433
|
+
return true;
|
434
|
+
}
|
435
|
+
|
436
|
+
static bool
|
437
|
+
_equalCollateExpr(const CollateExpr *a, const CollateExpr *b)
|
438
|
+
{
|
439
|
+
COMPARE_NODE_FIELD(arg);
|
440
|
+
COMPARE_SCALAR_FIELD(collOid);
|
441
|
+
COMPARE_LOCATION_FIELD(location);
|
442
|
+
|
443
|
+
return true;
|
444
|
+
}
|
445
|
+
|
446
|
+
static bool
|
447
|
+
_equalCaseExpr(const CaseExpr *a, const CaseExpr *b)
|
448
|
+
{
|
449
|
+
COMPARE_SCALAR_FIELD(casetype);
|
450
|
+
COMPARE_SCALAR_FIELD(casecollid);
|
451
|
+
COMPARE_NODE_FIELD(arg);
|
452
|
+
COMPARE_NODE_FIELD(args);
|
453
|
+
COMPARE_NODE_FIELD(defresult);
|
454
|
+
COMPARE_LOCATION_FIELD(location);
|
455
|
+
|
456
|
+
return true;
|
457
|
+
}
|
458
|
+
|
459
|
+
static bool
|
460
|
+
_equalCaseWhen(const CaseWhen *a, const CaseWhen *b)
|
461
|
+
{
|
462
|
+
COMPARE_NODE_FIELD(expr);
|
463
|
+
COMPARE_NODE_FIELD(result);
|
464
|
+
COMPARE_LOCATION_FIELD(location);
|
465
|
+
|
466
|
+
return true;
|
467
|
+
}
|
468
|
+
|
469
|
+
static bool
|
470
|
+
_equalCaseTestExpr(const CaseTestExpr *a, const CaseTestExpr *b)
|
471
|
+
{
|
472
|
+
COMPARE_SCALAR_FIELD(typeId);
|
473
|
+
COMPARE_SCALAR_FIELD(typeMod);
|
474
|
+
COMPARE_SCALAR_FIELD(collation);
|
475
|
+
|
476
|
+
return true;
|
477
|
+
}
|
478
|
+
|
479
|
+
static bool
|
480
|
+
_equalArrayExpr(const ArrayExpr *a, const ArrayExpr *b)
|
481
|
+
{
|
482
|
+
COMPARE_SCALAR_FIELD(array_typeid);
|
483
|
+
COMPARE_SCALAR_FIELD(array_collid);
|
484
|
+
COMPARE_SCALAR_FIELD(element_typeid);
|
485
|
+
COMPARE_NODE_FIELD(elements);
|
486
|
+
COMPARE_SCALAR_FIELD(multidims);
|
487
|
+
COMPARE_LOCATION_FIELD(location);
|
488
|
+
|
489
|
+
return true;
|
490
|
+
}
|
491
|
+
|
492
|
+
static bool
|
493
|
+
_equalRowExpr(const RowExpr *a, const RowExpr *b)
|
494
|
+
{
|
495
|
+
COMPARE_NODE_FIELD(args);
|
496
|
+
COMPARE_SCALAR_FIELD(row_typeid);
|
497
|
+
COMPARE_NODE_FIELD(colnames);
|
498
|
+
COMPARE_LOCATION_FIELD(location);
|
499
|
+
|
500
|
+
return true;
|
501
|
+
}
|
502
|
+
|
503
|
+
static bool
|
504
|
+
_equalRowCompareExpr(const RowCompareExpr *a, const RowCompareExpr *b)
|
505
|
+
{
|
506
|
+
COMPARE_SCALAR_FIELD(rctype);
|
507
|
+
COMPARE_NODE_FIELD(opnos);
|
508
|
+
COMPARE_NODE_FIELD(opfamilies);
|
509
|
+
COMPARE_NODE_FIELD(inputcollids);
|
510
|
+
COMPARE_NODE_FIELD(largs);
|
511
|
+
COMPARE_NODE_FIELD(rargs);
|
512
|
+
|
513
|
+
return true;
|
514
|
+
}
|
515
|
+
|
516
|
+
static bool
|
517
|
+
_equalCoalesceExpr(const CoalesceExpr *a, const CoalesceExpr *b)
|
518
|
+
{
|
519
|
+
COMPARE_SCALAR_FIELD(coalescetype);
|
520
|
+
COMPARE_SCALAR_FIELD(coalescecollid);
|
521
|
+
COMPARE_NODE_FIELD(args);
|
522
|
+
COMPARE_LOCATION_FIELD(location);
|
523
|
+
|
524
|
+
return true;
|
525
|
+
}
|
526
|
+
|
527
|
+
static bool
|
528
|
+
_equalMinMaxExpr(const MinMaxExpr *a, const MinMaxExpr *b)
|
529
|
+
{
|
530
|
+
COMPARE_SCALAR_FIELD(minmaxtype);
|
531
|
+
COMPARE_SCALAR_FIELD(minmaxcollid);
|
532
|
+
COMPARE_SCALAR_FIELD(inputcollid);
|
533
|
+
COMPARE_SCALAR_FIELD(op);
|
534
|
+
COMPARE_NODE_FIELD(args);
|
535
|
+
COMPARE_LOCATION_FIELD(location);
|
536
|
+
|
537
|
+
return true;
|
538
|
+
}
|
539
|
+
|
540
|
+
static bool
|
541
|
+
_equalSQLValueFunction(const SQLValueFunction *a, const SQLValueFunction *b)
|
542
|
+
{
|
543
|
+
COMPARE_SCALAR_FIELD(op);
|
544
|
+
COMPARE_SCALAR_FIELD(type);
|
545
|
+
COMPARE_SCALAR_FIELD(typmod);
|
546
|
+
COMPARE_LOCATION_FIELD(location);
|
547
|
+
|
548
|
+
return true;
|
549
|
+
}
|
550
|
+
|
551
|
+
static bool
|
552
|
+
_equalXmlExpr(const XmlExpr *a, const XmlExpr *b)
|
553
|
+
{
|
554
|
+
COMPARE_SCALAR_FIELD(op);
|
555
|
+
COMPARE_STRING_FIELD(name);
|
556
|
+
COMPARE_NODE_FIELD(named_args);
|
557
|
+
COMPARE_NODE_FIELD(arg_names);
|
558
|
+
COMPARE_NODE_FIELD(args);
|
559
|
+
COMPARE_SCALAR_FIELD(xmloption);
|
560
|
+
COMPARE_SCALAR_FIELD(indent);
|
561
|
+
COMPARE_SCALAR_FIELD(type);
|
562
|
+
COMPARE_SCALAR_FIELD(typmod);
|
563
|
+
COMPARE_LOCATION_FIELD(location);
|
564
|
+
|
565
|
+
return true;
|
566
|
+
}
|
567
|
+
|
568
|
+
static bool
|
569
|
+
_equalJsonFormat(const JsonFormat *a, const JsonFormat *b)
|
570
|
+
{
|
571
|
+
COMPARE_SCALAR_FIELD(format_type);
|
572
|
+
COMPARE_SCALAR_FIELD(encoding);
|
573
|
+
COMPARE_LOCATION_FIELD(location);
|
574
|
+
|
575
|
+
return true;
|
576
|
+
}
|
577
|
+
|
578
|
+
static bool
|
579
|
+
_equalJsonReturning(const JsonReturning *a, const JsonReturning *b)
|
580
|
+
{
|
581
|
+
COMPARE_NODE_FIELD(format);
|
582
|
+
COMPARE_SCALAR_FIELD(typid);
|
583
|
+
COMPARE_SCALAR_FIELD(typmod);
|
584
|
+
|
585
|
+
return true;
|
586
|
+
}
|
587
|
+
|
588
|
+
static bool
|
589
|
+
_equalJsonValueExpr(const JsonValueExpr *a, const JsonValueExpr *b)
|
590
|
+
{
|
591
|
+
COMPARE_NODE_FIELD(raw_expr);
|
592
|
+
COMPARE_NODE_FIELD(formatted_expr);
|
593
|
+
COMPARE_NODE_FIELD(format);
|
594
|
+
|
595
|
+
return true;
|
596
|
+
}
|
597
|
+
|
598
|
+
static bool
|
599
|
+
_equalJsonConstructorExpr(const JsonConstructorExpr *a, const JsonConstructorExpr *b)
|
600
|
+
{
|
601
|
+
COMPARE_SCALAR_FIELD(type);
|
602
|
+
COMPARE_NODE_FIELD(args);
|
603
|
+
COMPARE_NODE_FIELD(func);
|
604
|
+
COMPARE_NODE_FIELD(coercion);
|
605
|
+
COMPARE_NODE_FIELD(returning);
|
606
|
+
COMPARE_SCALAR_FIELD(absent_on_null);
|
607
|
+
COMPARE_SCALAR_FIELD(unique);
|
608
|
+
COMPARE_LOCATION_FIELD(location);
|
609
|
+
|
610
|
+
return true;
|
611
|
+
}
|
612
|
+
|
613
|
+
static bool
|
614
|
+
_equalJsonIsPredicate(const JsonIsPredicate *a, const JsonIsPredicate *b)
|
615
|
+
{
|
616
|
+
COMPARE_NODE_FIELD(expr);
|
617
|
+
COMPARE_NODE_FIELD(format);
|
618
|
+
COMPARE_SCALAR_FIELD(item_type);
|
619
|
+
COMPARE_SCALAR_FIELD(unique_keys);
|
620
|
+
COMPARE_LOCATION_FIELD(location);
|
621
|
+
|
622
|
+
return true;
|
623
|
+
}
|
624
|
+
|
625
|
+
static bool
|
626
|
+
_equalJsonBehavior(const JsonBehavior *a, const JsonBehavior *b)
|
627
|
+
{
|
628
|
+
COMPARE_SCALAR_FIELD(btype);
|
629
|
+
COMPARE_NODE_FIELD(expr);
|
630
|
+
COMPARE_SCALAR_FIELD(coerce);
|
631
|
+
COMPARE_LOCATION_FIELD(location);
|
632
|
+
|
633
|
+
return true;
|
634
|
+
}
|
635
|
+
|
636
|
+
static bool
|
637
|
+
_equalJsonExpr(const JsonExpr *a, const JsonExpr *b)
|
638
|
+
{
|
639
|
+
COMPARE_SCALAR_FIELD(op);
|
640
|
+
COMPARE_STRING_FIELD(column_name);
|
641
|
+
COMPARE_NODE_FIELD(formatted_expr);
|
642
|
+
COMPARE_NODE_FIELD(format);
|
643
|
+
COMPARE_NODE_FIELD(path_spec);
|
644
|
+
COMPARE_NODE_FIELD(returning);
|
645
|
+
COMPARE_NODE_FIELD(passing_names);
|
646
|
+
COMPARE_NODE_FIELD(passing_values);
|
647
|
+
COMPARE_NODE_FIELD(on_empty);
|
648
|
+
COMPARE_NODE_FIELD(on_error);
|
649
|
+
COMPARE_SCALAR_FIELD(use_io_coercion);
|
650
|
+
COMPARE_SCALAR_FIELD(use_json_coercion);
|
651
|
+
COMPARE_SCALAR_FIELD(wrapper);
|
652
|
+
COMPARE_SCALAR_FIELD(omit_quotes);
|
653
|
+
COMPARE_SCALAR_FIELD(collation);
|
654
|
+
COMPARE_LOCATION_FIELD(location);
|
655
|
+
|
656
|
+
return true;
|
657
|
+
}
|
658
|
+
|
659
|
+
static bool
|
660
|
+
_equalJsonTablePath(const JsonTablePath *a, const JsonTablePath *b)
|
661
|
+
{
|
662
|
+
COMPARE_NODE_FIELD(value);
|
663
|
+
COMPARE_STRING_FIELD(name);
|
664
|
+
|
665
|
+
return true;
|
666
|
+
}
|
667
|
+
|
668
|
+
static bool
|
669
|
+
_equalJsonTablePathScan(const JsonTablePathScan *a, const JsonTablePathScan *b)
|
670
|
+
{
|
671
|
+
COMPARE_NODE_FIELD(path);
|
672
|
+
COMPARE_SCALAR_FIELD(errorOnError);
|
673
|
+
COMPARE_NODE_FIELD(child);
|
674
|
+
COMPARE_SCALAR_FIELD(colMin);
|
675
|
+
COMPARE_SCALAR_FIELD(colMax);
|
676
|
+
|
677
|
+
return true;
|
678
|
+
}
|
679
|
+
|
680
|
+
static bool
|
681
|
+
_equalJsonTableSiblingJoin(const JsonTableSiblingJoin *a, const JsonTableSiblingJoin *b)
|
682
|
+
{
|
683
|
+
COMPARE_NODE_FIELD(lplan);
|
684
|
+
COMPARE_NODE_FIELD(rplan);
|
685
|
+
|
686
|
+
return true;
|
687
|
+
}
|
688
|
+
|
689
|
+
static bool
|
690
|
+
_equalNullTest(const NullTest *a, const NullTest *b)
|
691
|
+
{
|
692
|
+
COMPARE_NODE_FIELD(arg);
|
693
|
+
COMPARE_SCALAR_FIELD(nulltesttype);
|
694
|
+
COMPARE_SCALAR_FIELD(argisrow);
|
695
|
+
COMPARE_LOCATION_FIELD(location);
|
696
|
+
|
697
|
+
return true;
|
698
|
+
}
|
699
|
+
|
700
|
+
static bool
|
701
|
+
_equalBooleanTest(const BooleanTest *a, const BooleanTest *b)
|
702
|
+
{
|
703
|
+
COMPARE_NODE_FIELD(arg);
|
704
|
+
COMPARE_SCALAR_FIELD(booltesttype);
|
705
|
+
COMPARE_LOCATION_FIELD(location);
|
706
|
+
|
707
|
+
return true;
|
708
|
+
}
|
709
|
+
|
710
|
+
static bool
|
711
|
+
_equalMergeAction(const MergeAction *a, const MergeAction *b)
|
712
|
+
{
|
713
|
+
COMPARE_SCALAR_FIELD(matchKind);
|
714
|
+
COMPARE_SCALAR_FIELD(commandType);
|
715
|
+
COMPARE_SCALAR_FIELD(override);
|
716
|
+
COMPARE_NODE_FIELD(qual);
|
717
|
+
COMPARE_NODE_FIELD(targetList);
|
718
|
+
COMPARE_NODE_FIELD(updateColnos);
|
719
|
+
|
720
|
+
return true;
|
721
|
+
}
|
722
|
+
|
723
|
+
static bool
|
724
|
+
_equalCoerceToDomain(const CoerceToDomain *a, const CoerceToDomain *b)
|
725
|
+
{
|
726
|
+
COMPARE_NODE_FIELD(arg);
|
727
|
+
COMPARE_SCALAR_FIELD(resulttype);
|
728
|
+
COMPARE_SCALAR_FIELD(resulttypmod);
|
729
|
+
COMPARE_SCALAR_FIELD(resultcollid);
|
730
|
+
COMPARE_LOCATION_FIELD(location);
|
731
|
+
|
732
|
+
return true;
|
733
|
+
}
|
734
|
+
|
735
|
+
static bool
|
736
|
+
_equalCoerceToDomainValue(const CoerceToDomainValue *a, const CoerceToDomainValue *b)
|
737
|
+
{
|
738
|
+
COMPARE_SCALAR_FIELD(typeId);
|
739
|
+
COMPARE_SCALAR_FIELD(typeMod);
|
740
|
+
COMPARE_SCALAR_FIELD(collation);
|
741
|
+
COMPARE_LOCATION_FIELD(location);
|
742
|
+
|
743
|
+
return true;
|
744
|
+
}
|
745
|
+
|
746
|
+
static bool
|
747
|
+
_equalSetToDefault(const SetToDefault *a, const SetToDefault *b)
|
748
|
+
{
|
749
|
+
COMPARE_SCALAR_FIELD(typeId);
|
750
|
+
COMPARE_SCALAR_FIELD(typeMod);
|
751
|
+
COMPARE_SCALAR_FIELD(collation);
|
752
|
+
COMPARE_LOCATION_FIELD(location);
|
753
|
+
|
754
|
+
return true;
|
755
|
+
}
|
756
|
+
|
757
|
+
static bool
|
758
|
+
_equalCurrentOfExpr(const CurrentOfExpr *a, const CurrentOfExpr *b)
|
759
|
+
{
|
760
|
+
COMPARE_SCALAR_FIELD(cvarno);
|
761
|
+
COMPARE_STRING_FIELD(cursor_name);
|
762
|
+
COMPARE_SCALAR_FIELD(cursor_param);
|
763
|
+
|
764
|
+
return true;
|
765
|
+
}
|
766
|
+
|
767
|
+
static bool
|
768
|
+
_equalNextValueExpr(const NextValueExpr *a, const NextValueExpr *b)
|
769
|
+
{
|
770
|
+
COMPARE_SCALAR_FIELD(seqid);
|
771
|
+
COMPARE_SCALAR_FIELD(typeId);
|
772
|
+
|
773
|
+
return true;
|
774
|
+
}
|
775
|
+
|
776
|
+
static bool
|
777
|
+
_equalInferenceElem(const InferenceElem *a, const InferenceElem *b)
|
778
|
+
{
|
779
|
+
COMPARE_NODE_FIELD(expr);
|
780
|
+
COMPARE_SCALAR_FIELD(infercollid);
|
781
|
+
COMPARE_SCALAR_FIELD(inferopclass);
|
782
|
+
|
783
|
+
return true;
|
784
|
+
}
|
785
|
+
|
786
|
+
static bool
|
787
|
+
_equalTargetEntry(const TargetEntry *a, const TargetEntry *b)
|
788
|
+
{
|
789
|
+
COMPARE_NODE_FIELD(expr);
|
790
|
+
COMPARE_SCALAR_FIELD(resno);
|
791
|
+
COMPARE_STRING_FIELD(resname);
|
792
|
+
COMPARE_SCALAR_FIELD(ressortgroupref);
|
793
|
+
COMPARE_SCALAR_FIELD(resorigtbl);
|
794
|
+
COMPARE_SCALAR_FIELD(resorigcol);
|
795
|
+
COMPARE_SCALAR_FIELD(resjunk);
|
796
|
+
|
797
|
+
return true;
|
798
|
+
}
|
799
|
+
|
800
|
+
static bool
|
801
|
+
_equalRangeTblRef(const RangeTblRef *a, const RangeTblRef *b)
|
802
|
+
{
|
803
|
+
COMPARE_SCALAR_FIELD(rtindex);
|
804
|
+
|
805
|
+
return true;
|
806
|
+
}
|
807
|
+
|
808
|
+
static bool
|
809
|
+
_equalJoinExpr(const JoinExpr *a, const JoinExpr *b)
|
810
|
+
{
|
811
|
+
COMPARE_SCALAR_FIELD(jointype);
|
812
|
+
COMPARE_SCALAR_FIELD(isNatural);
|
813
|
+
COMPARE_NODE_FIELD(larg);
|
814
|
+
COMPARE_NODE_FIELD(rarg);
|
815
|
+
COMPARE_NODE_FIELD(usingClause);
|
816
|
+
COMPARE_NODE_FIELD(join_using_alias);
|
817
|
+
COMPARE_NODE_FIELD(quals);
|
818
|
+
COMPARE_NODE_FIELD(alias);
|
819
|
+
COMPARE_SCALAR_FIELD(rtindex);
|
820
|
+
|
821
|
+
return true;
|
822
|
+
}
|
823
|
+
|
824
|
+
static bool
|
825
|
+
_equalFromExpr(const FromExpr *a, const FromExpr *b)
|
826
|
+
{
|
827
|
+
COMPARE_NODE_FIELD(fromlist);
|
828
|
+
COMPARE_NODE_FIELD(quals);
|
829
|
+
|
830
|
+
return true;
|
831
|
+
}
|
832
|
+
|
833
|
+
static bool
|
834
|
+
_equalOnConflictExpr(const OnConflictExpr *a, const OnConflictExpr *b)
|
835
|
+
{
|
836
|
+
COMPARE_SCALAR_FIELD(action);
|
837
|
+
COMPARE_NODE_FIELD(arbiterElems);
|
838
|
+
COMPARE_NODE_FIELD(arbiterWhere);
|
839
|
+
COMPARE_SCALAR_FIELD(constraint);
|
840
|
+
COMPARE_NODE_FIELD(onConflictSet);
|
841
|
+
COMPARE_NODE_FIELD(onConflictWhere);
|
842
|
+
COMPARE_SCALAR_FIELD(exclRelIndex);
|
843
|
+
COMPARE_NODE_FIELD(exclRelTlist);
|
844
|
+
|
845
|
+
return true;
|
846
|
+
}
|
847
|
+
|
848
|
+
static bool
|
849
|
+
_equalQuery(const Query *a, const Query *b)
|
850
|
+
{
|
851
|
+
COMPARE_SCALAR_FIELD(commandType);
|
852
|
+
COMPARE_SCALAR_FIELD(querySource);
|
853
|
+
COMPARE_SCALAR_FIELD(canSetTag);
|
854
|
+
COMPARE_NODE_FIELD(utilityStmt);
|
855
|
+
COMPARE_SCALAR_FIELD(resultRelation);
|
856
|
+
COMPARE_SCALAR_FIELD(hasAggs);
|
857
|
+
COMPARE_SCALAR_FIELD(hasWindowFuncs);
|
858
|
+
COMPARE_SCALAR_FIELD(hasTargetSRFs);
|
859
|
+
COMPARE_SCALAR_FIELD(hasSubLinks);
|
860
|
+
COMPARE_SCALAR_FIELD(hasDistinctOn);
|
861
|
+
COMPARE_SCALAR_FIELD(hasRecursive);
|
862
|
+
COMPARE_SCALAR_FIELD(hasModifyingCTE);
|
863
|
+
COMPARE_SCALAR_FIELD(hasForUpdate);
|
864
|
+
COMPARE_SCALAR_FIELD(hasRowSecurity);
|
865
|
+
COMPARE_SCALAR_FIELD(isReturn);
|
866
|
+
COMPARE_NODE_FIELD(cteList);
|
867
|
+
COMPARE_NODE_FIELD(rtable);
|
868
|
+
COMPARE_NODE_FIELD(rteperminfos);
|
869
|
+
COMPARE_NODE_FIELD(jointree);
|
870
|
+
COMPARE_NODE_FIELD(mergeActionList);
|
871
|
+
COMPARE_SCALAR_FIELD(mergeTargetRelation);
|
872
|
+
COMPARE_NODE_FIELD(mergeJoinCondition);
|
873
|
+
COMPARE_NODE_FIELD(targetList);
|
874
|
+
COMPARE_SCALAR_FIELD(override);
|
875
|
+
COMPARE_NODE_FIELD(onConflict);
|
876
|
+
COMPARE_NODE_FIELD(returningList);
|
877
|
+
COMPARE_NODE_FIELD(groupClause);
|
878
|
+
COMPARE_SCALAR_FIELD(groupDistinct);
|
879
|
+
COMPARE_NODE_FIELD(groupingSets);
|
880
|
+
COMPARE_NODE_FIELD(havingQual);
|
881
|
+
COMPARE_NODE_FIELD(windowClause);
|
882
|
+
COMPARE_NODE_FIELD(distinctClause);
|
883
|
+
COMPARE_NODE_FIELD(sortClause);
|
884
|
+
COMPARE_NODE_FIELD(limitOffset);
|
885
|
+
COMPARE_NODE_FIELD(limitCount);
|
886
|
+
COMPARE_SCALAR_FIELD(limitOption);
|
887
|
+
COMPARE_NODE_FIELD(rowMarks);
|
888
|
+
COMPARE_NODE_FIELD(setOperations);
|
889
|
+
COMPARE_NODE_FIELD(constraintDeps);
|
890
|
+
COMPARE_NODE_FIELD(withCheckOptions);
|
891
|
+
COMPARE_LOCATION_FIELD(stmt_location);
|
892
|
+
COMPARE_LOCATION_FIELD(stmt_len);
|
893
|
+
|
894
|
+
return true;
|
895
|
+
}
|
896
|
+
|
897
|
+
static bool
|
898
|
+
_equalTypeName(const TypeName *a, const TypeName *b)
|
899
|
+
{
|
900
|
+
COMPARE_NODE_FIELD(names);
|
901
|
+
COMPARE_SCALAR_FIELD(typeOid);
|
902
|
+
COMPARE_SCALAR_FIELD(setof);
|
903
|
+
COMPARE_SCALAR_FIELD(pct_type);
|
904
|
+
COMPARE_NODE_FIELD(typmods);
|
905
|
+
COMPARE_SCALAR_FIELD(typemod);
|
906
|
+
COMPARE_NODE_FIELD(arrayBounds);
|
907
|
+
COMPARE_LOCATION_FIELD(location);
|
908
|
+
|
909
|
+
return true;
|
910
|
+
}
|
911
|
+
|
912
|
+
static bool
|
913
|
+
_equalColumnRef(const ColumnRef *a, const ColumnRef *b)
|
914
|
+
{
|
915
|
+
COMPARE_NODE_FIELD(fields);
|
916
|
+
COMPARE_LOCATION_FIELD(location);
|
917
|
+
|
918
|
+
return true;
|
919
|
+
}
|
920
|
+
|
921
|
+
static bool
|
922
|
+
_equalParamRef(const ParamRef *a, const ParamRef *b)
|
923
|
+
{
|
924
|
+
COMPARE_SCALAR_FIELD(number);
|
925
|
+
COMPARE_LOCATION_FIELD(location);
|
926
|
+
|
927
|
+
return true;
|
928
|
+
}
|
929
|
+
|
930
|
+
static bool
|
931
|
+
_equalA_Expr(const A_Expr *a, const A_Expr *b)
|
932
|
+
{
|
933
|
+
COMPARE_SCALAR_FIELD(kind);
|
934
|
+
COMPARE_NODE_FIELD(name);
|
935
|
+
COMPARE_NODE_FIELD(lexpr);
|
936
|
+
COMPARE_NODE_FIELD(rexpr);
|
937
|
+
COMPARE_LOCATION_FIELD(location);
|
938
|
+
|
939
|
+
return true;
|
940
|
+
}
|
941
|
+
|
942
|
+
static bool
|
943
|
+
_equalTypeCast(const TypeCast *a, const TypeCast *b)
|
944
|
+
{
|
945
|
+
COMPARE_NODE_FIELD(arg);
|
946
|
+
COMPARE_NODE_FIELD(typeName);
|
947
|
+
COMPARE_LOCATION_FIELD(location);
|
948
|
+
|
949
|
+
return true;
|
950
|
+
}
|
951
|
+
|
952
|
+
static bool
|
953
|
+
_equalCollateClause(const CollateClause *a, const CollateClause *b)
|
954
|
+
{
|
955
|
+
COMPARE_NODE_FIELD(arg);
|
956
|
+
COMPARE_NODE_FIELD(collname);
|
957
|
+
COMPARE_LOCATION_FIELD(location);
|
958
|
+
|
959
|
+
return true;
|
960
|
+
}
|
961
|
+
|
962
|
+
static bool
|
963
|
+
_equalRoleSpec(const RoleSpec *a, const RoleSpec *b)
|
964
|
+
{
|
965
|
+
COMPARE_SCALAR_FIELD(roletype);
|
966
|
+
COMPARE_STRING_FIELD(rolename);
|
967
|
+
COMPARE_LOCATION_FIELD(location);
|
968
|
+
|
969
|
+
return true;
|
970
|
+
}
|
971
|
+
|
972
|
+
static bool
|
973
|
+
_equalFuncCall(const FuncCall *a, const FuncCall *b)
|
974
|
+
{
|
975
|
+
COMPARE_NODE_FIELD(funcname);
|
976
|
+
COMPARE_NODE_FIELD(args);
|
977
|
+
COMPARE_NODE_FIELD(agg_order);
|
978
|
+
COMPARE_NODE_FIELD(agg_filter);
|
979
|
+
COMPARE_NODE_FIELD(over);
|
980
|
+
COMPARE_SCALAR_FIELD(agg_within_group);
|
981
|
+
COMPARE_SCALAR_FIELD(agg_star);
|
982
|
+
COMPARE_SCALAR_FIELD(agg_distinct);
|
983
|
+
COMPARE_SCALAR_FIELD(func_variadic);
|
984
|
+
COMPARE_LOCATION_FIELD(location);
|
985
|
+
|
986
|
+
return true;
|
987
|
+
}
|
988
|
+
|
989
|
+
static bool
|
990
|
+
_equalA_Star(const A_Star *a, const A_Star *b)
|
991
|
+
{
|
992
|
+
|
993
|
+
return true;
|
994
|
+
}
|
995
|
+
|
996
|
+
static bool
|
997
|
+
_equalA_Indices(const A_Indices *a, const A_Indices *b)
|
998
|
+
{
|
999
|
+
COMPARE_SCALAR_FIELD(is_slice);
|
1000
|
+
COMPARE_NODE_FIELD(lidx);
|
1001
|
+
COMPARE_NODE_FIELD(uidx);
|
1002
|
+
|
1003
|
+
return true;
|
1004
|
+
}
|
1005
|
+
|
1006
|
+
static bool
|
1007
|
+
_equalA_Indirection(const A_Indirection *a, const A_Indirection *b)
|
1008
|
+
{
|
1009
|
+
COMPARE_NODE_FIELD(arg);
|
1010
|
+
COMPARE_NODE_FIELD(indirection);
|
1011
|
+
|
1012
|
+
return true;
|
1013
|
+
}
|
1014
|
+
|
1015
|
+
static bool
|
1016
|
+
_equalA_ArrayExpr(const A_ArrayExpr *a, const A_ArrayExpr *b)
|
1017
|
+
{
|
1018
|
+
COMPARE_NODE_FIELD(elements);
|
1019
|
+
COMPARE_LOCATION_FIELD(location);
|
1020
|
+
|
1021
|
+
return true;
|
1022
|
+
}
|
1023
|
+
|
1024
|
+
static bool
|
1025
|
+
_equalResTarget(const ResTarget *a, const ResTarget *b)
|
1026
|
+
{
|
1027
|
+
COMPARE_STRING_FIELD(name);
|
1028
|
+
COMPARE_NODE_FIELD(indirection);
|
1029
|
+
COMPARE_NODE_FIELD(val);
|
1030
|
+
COMPARE_LOCATION_FIELD(location);
|
1031
|
+
|
1032
|
+
return true;
|
1033
|
+
}
|
1034
|
+
|
1035
|
+
static bool
|
1036
|
+
_equalMultiAssignRef(const MultiAssignRef *a, const MultiAssignRef *b)
|
1037
|
+
{
|
1038
|
+
COMPARE_NODE_FIELD(source);
|
1039
|
+
COMPARE_SCALAR_FIELD(colno);
|
1040
|
+
COMPARE_SCALAR_FIELD(ncolumns);
|
1041
|
+
|
1042
|
+
return true;
|
1043
|
+
}
|
1044
|
+
|
1045
|
+
static bool
|
1046
|
+
_equalSortBy(const SortBy *a, const SortBy *b)
|
1047
|
+
{
|
1048
|
+
COMPARE_NODE_FIELD(node);
|
1049
|
+
COMPARE_SCALAR_FIELD(sortby_dir);
|
1050
|
+
COMPARE_SCALAR_FIELD(sortby_nulls);
|
1051
|
+
COMPARE_NODE_FIELD(useOp);
|
1052
|
+
COMPARE_LOCATION_FIELD(location);
|
1053
|
+
|
1054
|
+
return true;
|
1055
|
+
}
|
1056
|
+
|
1057
|
+
static bool
|
1058
|
+
_equalWindowDef(const WindowDef *a, const WindowDef *b)
|
1059
|
+
{
|
1060
|
+
COMPARE_STRING_FIELD(name);
|
1061
|
+
COMPARE_STRING_FIELD(refname);
|
1062
|
+
COMPARE_NODE_FIELD(partitionClause);
|
1063
|
+
COMPARE_NODE_FIELD(orderClause);
|
1064
|
+
COMPARE_SCALAR_FIELD(frameOptions);
|
1065
|
+
COMPARE_NODE_FIELD(startOffset);
|
1066
|
+
COMPARE_NODE_FIELD(endOffset);
|
1067
|
+
COMPARE_LOCATION_FIELD(location);
|
1068
|
+
|
1069
|
+
return true;
|
1070
|
+
}
|
1071
|
+
|
1072
|
+
static bool
|
1073
|
+
_equalRangeSubselect(const RangeSubselect *a, const RangeSubselect *b)
|
1074
|
+
{
|
1075
|
+
COMPARE_SCALAR_FIELD(lateral);
|
1076
|
+
COMPARE_NODE_FIELD(subquery);
|
1077
|
+
COMPARE_NODE_FIELD(alias);
|
1078
|
+
|
1079
|
+
return true;
|
1080
|
+
}
|
1081
|
+
|
1082
|
+
static bool
|
1083
|
+
_equalRangeFunction(const RangeFunction *a, const RangeFunction *b)
|
1084
|
+
{
|
1085
|
+
COMPARE_SCALAR_FIELD(lateral);
|
1086
|
+
COMPARE_SCALAR_FIELD(ordinality);
|
1087
|
+
COMPARE_SCALAR_FIELD(is_rowsfrom);
|
1088
|
+
COMPARE_NODE_FIELD(functions);
|
1089
|
+
COMPARE_NODE_FIELD(alias);
|
1090
|
+
COMPARE_NODE_FIELD(coldeflist);
|
1091
|
+
|
1092
|
+
return true;
|
1093
|
+
}
|
1094
|
+
|
1095
|
+
static bool
|
1096
|
+
_equalRangeTableFunc(const RangeTableFunc *a, const RangeTableFunc *b)
|
1097
|
+
{
|
1098
|
+
COMPARE_SCALAR_FIELD(lateral);
|
1099
|
+
COMPARE_NODE_FIELD(docexpr);
|
1100
|
+
COMPARE_NODE_FIELD(rowexpr);
|
1101
|
+
COMPARE_NODE_FIELD(namespaces);
|
1102
|
+
COMPARE_NODE_FIELD(columns);
|
1103
|
+
COMPARE_NODE_FIELD(alias);
|
1104
|
+
COMPARE_LOCATION_FIELD(location);
|
1105
|
+
|
1106
|
+
return true;
|
1107
|
+
}
|
1108
|
+
|
1109
|
+
static bool
|
1110
|
+
_equalRangeTableFuncCol(const RangeTableFuncCol *a, const RangeTableFuncCol *b)
|
1111
|
+
{
|
1112
|
+
COMPARE_STRING_FIELD(colname);
|
1113
|
+
COMPARE_NODE_FIELD(typeName);
|
1114
|
+
COMPARE_SCALAR_FIELD(for_ordinality);
|
1115
|
+
COMPARE_SCALAR_FIELD(is_not_null);
|
1116
|
+
COMPARE_NODE_FIELD(colexpr);
|
1117
|
+
COMPARE_NODE_FIELD(coldefexpr);
|
1118
|
+
COMPARE_LOCATION_FIELD(location);
|
1119
|
+
|
1120
|
+
return true;
|
1121
|
+
}
|
1122
|
+
|
1123
|
+
static bool
|
1124
|
+
_equalRangeTableSample(const RangeTableSample *a, const RangeTableSample *b)
|
1125
|
+
{
|
1126
|
+
COMPARE_NODE_FIELD(relation);
|
1127
|
+
COMPARE_NODE_FIELD(method);
|
1128
|
+
COMPARE_NODE_FIELD(args);
|
1129
|
+
COMPARE_NODE_FIELD(repeatable);
|
1130
|
+
COMPARE_LOCATION_FIELD(location);
|
1131
|
+
|
1132
|
+
return true;
|
1133
|
+
}
|
1134
|
+
|
1135
|
+
static bool
|
1136
|
+
_equalColumnDef(const ColumnDef *a, const ColumnDef *b)
|
1137
|
+
{
|
1138
|
+
COMPARE_STRING_FIELD(colname);
|
1139
|
+
COMPARE_NODE_FIELD(typeName);
|
1140
|
+
COMPARE_STRING_FIELD(compression);
|
1141
|
+
COMPARE_SCALAR_FIELD(inhcount);
|
1142
|
+
COMPARE_SCALAR_FIELD(is_local);
|
1143
|
+
COMPARE_SCALAR_FIELD(is_not_null);
|
1144
|
+
COMPARE_SCALAR_FIELD(is_from_type);
|
1145
|
+
COMPARE_SCALAR_FIELD(storage);
|
1146
|
+
COMPARE_STRING_FIELD(storage_name);
|
1147
|
+
COMPARE_NODE_FIELD(raw_default);
|
1148
|
+
COMPARE_NODE_FIELD(cooked_default);
|
1149
|
+
COMPARE_SCALAR_FIELD(identity);
|
1150
|
+
COMPARE_NODE_FIELD(identitySequence);
|
1151
|
+
COMPARE_SCALAR_FIELD(generated);
|
1152
|
+
COMPARE_NODE_FIELD(collClause);
|
1153
|
+
COMPARE_SCALAR_FIELD(collOid);
|
1154
|
+
COMPARE_NODE_FIELD(constraints);
|
1155
|
+
COMPARE_NODE_FIELD(fdwoptions);
|
1156
|
+
COMPARE_LOCATION_FIELD(location);
|
1157
|
+
|
1158
|
+
return true;
|
1159
|
+
}
|
1160
|
+
|
1161
|
+
static bool
|
1162
|
+
_equalTableLikeClause(const TableLikeClause *a, const TableLikeClause *b)
|
1163
|
+
{
|
1164
|
+
COMPARE_NODE_FIELD(relation);
|
1165
|
+
COMPARE_SCALAR_FIELD(options);
|
1166
|
+
COMPARE_SCALAR_FIELD(relationOid);
|
1167
|
+
|
1168
|
+
return true;
|
1169
|
+
}
|
1170
|
+
|
1171
|
+
static bool
|
1172
|
+
_equalIndexElem(const IndexElem *a, const IndexElem *b)
|
1173
|
+
{
|
1174
|
+
COMPARE_STRING_FIELD(name);
|
1175
|
+
COMPARE_NODE_FIELD(expr);
|
1176
|
+
COMPARE_STRING_FIELD(indexcolname);
|
1177
|
+
COMPARE_NODE_FIELD(collation);
|
1178
|
+
COMPARE_NODE_FIELD(opclass);
|
1179
|
+
COMPARE_NODE_FIELD(opclassopts);
|
1180
|
+
COMPARE_SCALAR_FIELD(ordering);
|
1181
|
+
COMPARE_SCALAR_FIELD(nulls_ordering);
|
1182
|
+
|
1183
|
+
return true;
|
1184
|
+
}
|
1185
|
+
|
1186
|
+
static bool
|
1187
|
+
_equalDefElem(const DefElem *a, const DefElem *b)
|
1188
|
+
{
|
1189
|
+
COMPARE_STRING_FIELD(defnamespace);
|
1190
|
+
COMPARE_STRING_FIELD(defname);
|
1191
|
+
COMPARE_NODE_FIELD(arg);
|
1192
|
+
COMPARE_SCALAR_FIELD(defaction);
|
1193
|
+
COMPARE_LOCATION_FIELD(location);
|
1194
|
+
|
1195
|
+
return true;
|
1196
|
+
}
|
1197
|
+
|
1198
|
+
static bool
|
1199
|
+
_equalLockingClause(const LockingClause *a, const LockingClause *b)
|
1200
|
+
{
|
1201
|
+
COMPARE_NODE_FIELD(lockedRels);
|
1202
|
+
COMPARE_SCALAR_FIELD(strength);
|
1203
|
+
COMPARE_SCALAR_FIELD(waitPolicy);
|
1204
|
+
|
1205
|
+
return true;
|
1206
|
+
}
|
1207
|
+
|
1208
|
+
static bool
|
1209
|
+
_equalXmlSerialize(const XmlSerialize *a, const XmlSerialize *b)
|
1210
|
+
{
|
1211
|
+
COMPARE_SCALAR_FIELD(xmloption);
|
1212
|
+
COMPARE_NODE_FIELD(expr);
|
1213
|
+
COMPARE_NODE_FIELD(typeName);
|
1214
|
+
COMPARE_SCALAR_FIELD(indent);
|
1215
|
+
COMPARE_LOCATION_FIELD(location);
|
1216
|
+
|
1217
|
+
return true;
|
1218
|
+
}
|
1219
|
+
|
1220
|
+
static bool
|
1221
|
+
_equalPartitionElem(const PartitionElem *a, const PartitionElem *b)
|
1222
|
+
{
|
1223
|
+
COMPARE_STRING_FIELD(name);
|
1224
|
+
COMPARE_NODE_FIELD(expr);
|
1225
|
+
COMPARE_NODE_FIELD(collation);
|
1226
|
+
COMPARE_NODE_FIELD(opclass);
|
1227
|
+
COMPARE_LOCATION_FIELD(location);
|
1228
|
+
|
1229
|
+
return true;
|
1230
|
+
}
|
1231
|
+
|
1232
|
+
static bool
|
1233
|
+
_equalPartitionSpec(const PartitionSpec *a, const PartitionSpec *b)
|
1234
|
+
{
|
1235
|
+
COMPARE_SCALAR_FIELD(strategy);
|
1236
|
+
COMPARE_NODE_FIELD(partParams);
|
1237
|
+
COMPARE_LOCATION_FIELD(location);
|
1238
|
+
|
1239
|
+
return true;
|
1240
|
+
}
|
1241
|
+
|
1242
|
+
static bool
|
1243
|
+
_equalPartitionBoundSpec(const PartitionBoundSpec *a, const PartitionBoundSpec *b)
|
1244
|
+
{
|
1245
|
+
COMPARE_SCALAR_FIELD(strategy);
|
1246
|
+
COMPARE_SCALAR_FIELD(is_default);
|
1247
|
+
COMPARE_SCALAR_FIELD(modulus);
|
1248
|
+
COMPARE_SCALAR_FIELD(remainder);
|
1249
|
+
COMPARE_NODE_FIELD(listdatums);
|
1250
|
+
COMPARE_NODE_FIELD(lowerdatums);
|
1251
|
+
COMPARE_NODE_FIELD(upperdatums);
|
1252
|
+
COMPARE_LOCATION_FIELD(location);
|
1253
|
+
|
1254
|
+
return true;
|
1255
|
+
}
|
1256
|
+
|
1257
|
+
static bool
|
1258
|
+
_equalPartitionRangeDatum(const PartitionRangeDatum *a, const PartitionRangeDatum *b)
|
1259
|
+
{
|
1260
|
+
COMPARE_SCALAR_FIELD(kind);
|
1261
|
+
COMPARE_NODE_FIELD(value);
|
1262
|
+
COMPARE_LOCATION_FIELD(location);
|
1263
|
+
|
1264
|
+
return true;
|
1265
|
+
}
|
1266
|
+
|
1267
|
+
static bool
|
1268
|
+
_equalSinglePartitionSpec(const SinglePartitionSpec *a, const SinglePartitionSpec *b)
|
1269
|
+
{
|
1270
|
+
|
1271
|
+
return true;
|
1272
|
+
}
|
1273
|
+
|
1274
|
+
static bool
|
1275
|
+
_equalPartitionCmd(const PartitionCmd *a, const PartitionCmd *b)
|
1276
|
+
{
|
1277
|
+
COMPARE_NODE_FIELD(name);
|
1278
|
+
COMPARE_NODE_FIELD(bound);
|
1279
|
+
COMPARE_SCALAR_FIELD(concurrent);
|
1280
|
+
|
1281
|
+
return true;
|
1282
|
+
}
|
1283
|
+
|
1284
|
+
static bool
|
1285
|
+
_equalRangeTblEntry(const RangeTblEntry *a, const RangeTblEntry *b)
|
1286
|
+
{
|
1287
|
+
COMPARE_NODE_FIELD(alias);
|
1288
|
+
COMPARE_NODE_FIELD(eref);
|
1289
|
+
COMPARE_SCALAR_FIELD(rtekind);
|
1290
|
+
COMPARE_SCALAR_FIELD(relid);
|
1291
|
+
COMPARE_SCALAR_FIELD(inh);
|
1292
|
+
COMPARE_SCALAR_FIELD(relkind);
|
1293
|
+
COMPARE_SCALAR_FIELD(rellockmode);
|
1294
|
+
COMPARE_SCALAR_FIELD(perminfoindex);
|
1295
|
+
COMPARE_NODE_FIELD(tablesample);
|
1296
|
+
COMPARE_NODE_FIELD(subquery);
|
1297
|
+
COMPARE_SCALAR_FIELD(security_barrier);
|
1298
|
+
COMPARE_SCALAR_FIELD(jointype);
|
1299
|
+
COMPARE_SCALAR_FIELD(joinmergedcols);
|
1300
|
+
COMPARE_NODE_FIELD(joinaliasvars);
|
1301
|
+
COMPARE_NODE_FIELD(joinleftcols);
|
1302
|
+
COMPARE_NODE_FIELD(joinrightcols);
|
1303
|
+
COMPARE_NODE_FIELD(join_using_alias);
|
1304
|
+
COMPARE_NODE_FIELD(functions);
|
1305
|
+
COMPARE_SCALAR_FIELD(funcordinality);
|
1306
|
+
COMPARE_NODE_FIELD(tablefunc);
|
1307
|
+
COMPARE_NODE_FIELD(values_lists);
|
1308
|
+
COMPARE_STRING_FIELD(ctename);
|
1309
|
+
COMPARE_SCALAR_FIELD(ctelevelsup);
|
1310
|
+
COMPARE_SCALAR_FIELD(self_reference);
|
1311
|
+
COMPARE_NODE_FIELD(coltypes);
|
1312
|
+
COMPARE_NODE_FIELD(coltypmods);
|
1313
|
+
COMPARE_NODE_FIELD(colcollations);
|
1314
|
+
COMPARE_STRING_FIELD(enrname);
|
1315
|
+
COMPARE_SCALAR_FIELD(enrtuples);
|
1316
|
+
COMPARE_SCALAR_FIELD(lateral);
|
1317
|
+
COMPARE_SCALAR_FIELD(inFromCl);
|
1318
|
+
COMPARE_NODE_FIELD(securityQuals);
|
1319
|
+
|
1320
|
+
return true;
|
1321
|
+
}
|
1322
|
+
|
1323
|
+
static bool
|
1324
|
+
_equalRTEPermissionInfo(const RTEPermissionInfo *a, const RTEPermissionInfo *b)
|
1325
|
+
{
|
1326
|
+
COMPARE_SCALAR_FIELD(relid);
|
1327
|
+
COMPARE_SCALAR_FIELD(inh);
|
1328
|
+
COMPARE_SCALAR_FIELD(requiredPerms);
|
1329
|
+
COMPARE_SCALAR_FIELD(checkAsUser);
|
1330
|
+
COMPARE_BITMAPSET_FIELD(selectedCols);
|
1331
|
+
COMPARE_BITMAPSET_FIELD(insertedCols);
|
1332
|
+
COMPARE_BITMAPSET_FIELD(updatedCols);
|
1333
|
+
|
1334
|
+
return true;
|
1335
|
+
}
|
1336
|
+
|
1337
|
+
static bool
|
1338
|
+
_equalRangeTblFunction(const RangeTblFunction *a, const RangeTblFunction *b)
|
1339
|
+
{
|
1340
|
+
COMPARE_NODE_FIELD(funcexpr);
|
1341
|
+
COMPARE_SCALAR_FIELD(funccolcount);
|
1342
|
+
COMPARE_NODE_FIELD(funccolnames);
|
1343
|
+
COMPARE_NODE_FIELD(funccoltypes);
|
1344
|
+
COMPARE_NODE_FIELD(funccoltypmods);
|
1345
|
+
COMPARE_NODE_FIELD(funccolcollations);
|
1346
|
+
COMPARE_BITMAPSET_FIELD(funcparams);
|
1347
|
+
|
1348
|
+
return true;
|
1349
|
+
}
|
1350
|
+
|
1351
|
+
static bool
|
1352
|
+
_equalTableSampleClause(const TableSampleClause *a, const TableSampleClause *b)
|
1353
|
+
{
|
1354
|
+
COMPARE_SCALAR_FIELD(tsmhandler);
|
1355
|
+
COMPARE_NODE_FIELD(args);
|
1356
|
+
COMPARE_NODE_FIELD(repeatable);
|
1357
|
+
|
1358
|
+
return true;
|
1359
|
+
}
|
1360
|
+
|
1361
|
+
static bool
|
1362
|
+
_equalWithCheckOption(const WithCheckOption *a, const WithCheckOption *b)
|
1363
|
+
{
|
1364
|
+
COMPARE_SCALAR_FIELD(kind);
|
1365
|
+
COMPARE_STRING_FIELD(relname);
|
1366
|
+
COMPARE_STRING_FIELD(polname);
|
1367
|
+
COMPARE_NODE_FIELD(qual);
|
1368
|
+
COMPARE_SCALAR_FIELD(cascaded);
|
1369
|
+
|
1370
|
+
return true;
|
1371
|
+
}
|
1372
|
+
|
1373
|
+
static bool
|
1374
|
+
_equalSortGroupClause(const SortGroupClause *a, const SortGroupClause *b)
|
1375
|
+
{
|
1376
|
+
COMPARE_SCALAR_FIELD(tleSortGroupRef);
|
1377
|
+
COMPARE_SCALAR_FIELD(eqop);
|
1378
|
+
COMPARE_SCALAR_FIELD(sortop);
|
1379
|
+
COMPARE_SCALAR_FIELD(nulls_first);
|
1380
|
+
COMPARE_SCALAR_FIELD(hashable);
|
1381
|
+
|
1382
|
+
return true;
|
1383
|
+
}
|
1384
|
+
|
1385
|
+
static bool
|
1386
|
+
_equalGroupingSet(const GroupingSet *a, const GroupingSet *b)
|
1387
|
+
{
|
1388
|
+
COMPARE_SCALAR_FIELD(kind);
|
1389
|
+
COMPARE_NODE_FIELD(content);
|
1390
|
+
COMPARE_LOCATION_FIELD(location);
|
1391
|
+
|
1392
|
+
return true;
|
1393
|
+
}
|
1394
|
+
|
1395
|
+
static bool
|
1396
|
+
_equalWindowClause(const WindowClause *a, const WindowClause *b)
|
1397
|
+
{
|
1398
|
+
COMPARE_STRING_FIELD(name);
|
1399
|
+
COMPARE_STRING_FIELD(refname);
|
1400
|
+
COMPARE_NODE_FIELD(partitionClause);
|
1401
|
+
COMPARE_NODE_FIELD(orderClause);
|
1402
|
+
COMPARE_SCALAR_FIELD(frameOptions);
|
1403
|
+
COMPARE_NODE_FIELD(startOffset);
|
1404
|
+
COMPARE_NODE_FIELD(endOffset);
|
1405
|
+
COMPARE_SCALAR_FIELD(startInRangeFunc);
|
1406
|
+
COMPARE_SCALAR_FIELD(endInRangeFunc);
|
1407
|
+
COMPARE_SCALAR_FIELD(inRangeColl);
|
1408
|
+
COMPARE_SCALAR_FIELD(inRangeAsc);
|
1409
|
+
COMPARE_SCALAR_FIELD(inRangeNullsFirst);
|
1410
|
+
COMPARE_SCALAR_FIELD(winref);
|
1411
|
+
COMPARE_SCALAR_FIELD(copiedOrder);
|
1412
|
+
|
1413
|
+
return true;
|
1414
|
+
}
|
1415
|
+
|
1416
|
+
static bool
|
1417
|
+
_equalRowMarkClause(const RowMarkClause *a, const RowMarkClause *b)
|
1418
|
+
{
|
1419
|
+
COMPARE_SCALAR_FIELD(rti);
|
1420
|
+
COMPARE_SCALAR_FIELD(strength);
|
1421
|
+
COMPARE_SCALAR_FIELD(waitPolicy);
|
1422
|
+
COMPARE_SCALAR_FIELD(pushedDown);
|
1423
|
+
|
1424
|
+
return true;
|
1425
|
+
}
|
1426
|
+
|
1427
|
+
static bool
|
1428
|
+
_equalWithClause(const WithClause *a, const WithClause *b)
|
1429
|
+
{
|
1430
|
+
COMPARE_NODE_FIELD(ctes);
|
1431
|
+
COMPARE_SCALAR_FIELD(recursive);
|
1432
|
+
COMPARE_LOCATION_FIELD(location);
|
1433
|
+
|
1434
|
+
return true;
|
1435
|
+
}
|
1436
|
+
|
1437
|
+
static bool
|
1438
|
+
_equalInferClause(const InferClause *a, const InferClause *b)
|
1439
|
+
{
|
1440
|
+
COMPARE_NODE_FIELD(indexElems);
|
1441
|
+
COMPARE_NODE_FIELD(whereClause);
|
1442
|
+
COMPARE_STRING_FIELD(conname);
|
1443
|
+
COMPARE_LOCATION_FIELD(location);
|
1444
|
+
|
1445
|
+
return true;
|
1446
|
+
}
|
1447
|
+
|
1448
|
+
static bool
|
1449
|
+
_equalOnConflictClause(const OnConflictClause *a, const OnConflictClause *b)
|
1450
|
+
{
|
1451
|
+
COMPARE_SCALAR_FIELD(action);
|
1452
|
+
COMPARE_NODE_FIELD(infer);
|
1453
|
+
COMPARE_NODE_FIELD(targetList);
|
1454
|
+
COMPARE_NODE_FIELD(whereClause);
|
1455
|
+
COMPARE_LOCATION_FIELD(location);
|
1456
|
+
|
1457
|
+
return true;
|
1458
|
+
}
|
1459
|
+
|
1460
|
+
static bool
|
1461
|
+
_equalCTESearchClause(const CTESearchClause *a, const CTESearchClause *b)
|
1462
|
+
{
|
1463
|
+
COMPARE_NODE_FIELD(search_col_list);
|
1464
|
+
COMPARE_SCALAR_FIELD(search_breadth_first);
|
1465
|
+
COMPARE_STRING_FIELD(search_seq_column);
|
1466
|
+
COMPARE_LOCATION_FIELD(location);
|
1467
|
+
|
1468
|
+
return true;
|
1469
|
+
}
|
1470
|
+
|
1471
|
+
static bool
|
1472
|
+
_equalCTECycleClause(const CTECycleClause *a, const CTECycleClause *b)
|
1473
|
+
{
|
1474
|
+
COMPARE_NODE_FIELD(cycle_col_list);
|
1475
|
+
COMPARE_STRING_FIELD(cycle_mark_column);
|
1476
|
+
COMPARE_NODE_FIELD(cycle_mark_value);
|
1477
|
+
COMPARE_NODE_FIELD(cycle_mark_default);
|
1478
|
+
COMPARE_STRING_FIELD(cycle_path_column);
|
1479
|
+
COMPARE_LOCATION_FIELD(location);
|
1480
|
+
COMPARE_SCALAR_FIELD(cycle_mark_type);
|
1481
|
+
COMPARE_SCALAR_FIELD(cycle_mark_typmod);
|
1482
|
+
COMPARE_SCALAR_FIELD(cycle_mark_collation);
|
1483
|
+
COMPARE_SCALAR_FIELD(cycle_mark_neop);
|
1484
|
+
|
1485
|
+
return true;
|
1486
|
+
}
|
1487
|
+
|
1488
|
+
static bool
|
1489
|
+
_equalCommonTableExpr(const CommonTableExpr *a, const CommonTableExpr *b)
|
1490
|
+
{
|
1491
|
+
COMPARE_STRING_FIELD(ctename);
|
1492
|
+
COMPARE_NODE_FIELD(aliascolnames);
|
1493
|
+
COMPARE_SCALAR_FIELD(ctematerialized);
|
1494
|
+
COMPARE_NODE_FIELD(ctequery);
|
1495
|
+
COMPARE_NODE_FIELD(search_clause);
|
1496
|
+
COMPARE_NODE_FIELD(cycle_clause);
|
1497
|
+
COMPARE_LOCATION_FIELD(location);
|
1498
|
+
COMPARE_SCALAR_FIELD(cterecursive);
|
1499
|
+
COMPARE_SCALAR_FIELD(cterefcount);
|
1500
|
+
COMPARE_NODE_FIELD(ctecolnames);
|
1501
|
+
COMPARE_NODE_FIELD(ctecoltypes);
|
1502
|
+
COMPARE_NODE_FIELD(ctecoltypmods);
|
1503
|
+
COMPARE_NODE_FIELD(ctecolcollations);
|
1504
|
+
|
1505
|
+
return true;
|
1506
|
+
}
|
1507
|
+
|
1508
|
+
static bool
|
1509
|
+
_equalMergeWhenClause(const MergeWhenClause *a, const MergeWhenClause *b)
|
1510
|
+
{
|
1511
|
+
COMPARE_SCALAR_FIELD(matchKind);
|
1512
|
+
COMPARE_SCALAR_FIELD(commandType);
|
1513
|
+
COMPARE_SCALAR_FIELD(override);
|
1514
|
+
COMPARE_NODE_FIELD(condition);
|
1515
|
+
COMPARE_NODE_FIELD(targetList);
|
1516
|
+
COMPARE_NODE_FIELD(values);
|
1517
|
+
|
1518
|
+
return true;
|
1519
|
+
}
|
1520
|
+
|
1521
|
+
static bool
|
1522
|
+
_equalTriggerTransition(const TriggerTransition *a, const TriggerTransition *b)
|
1523
|
+
{
|
1524
|
+
COMPARE_STRING_FIELD(name);
|
1525
|
+
COMPARE_SCALAR_FIELD(isNew);
|
1526
|
+
COMPARE_SCALAR_FIELD(isTable);
|
1527
|
+
|
1528
|
+
return true;
|
1529
|
+
}
|
1530
|
+
|
1531
|
+
static bool
|
1532
|
+
_equalJsonOutput(const JsonOutput *a, const JsonOutput *b)
|
1533
|
+
{
|
1534
|
+
COMPARE_NODE_FIELD(typeName);
|
1535
|
+
COMPARE_NODE_FIELD(returning);
|
1536
|
+
|
1537
|
+
return true;
|
1538
|
+
}
|
1539
|
+
|
1540
|
+
static bool
|
1541
|
+
_equalJsonArgument(const JsonArgument *a, const JsonArgument *b)
|
1542
|
+
{
|
1543
|
+
COMPARE_NODE_FIELD(val);
|
1544
|
+
COMPARE_STRING_FIELD(name);
|
1545
|
+
|
1546
|
+
return true;
|
1547
|
+
}
|
1548
|
+
|
1549
|
+
static bool
|
1550
|
+
_equalJsonFuncExpr(const JsonFuncExpr *a, const JsonFuncExpr *b)
|
1551
|
+
{
|
1552
|
+
COMPARE_SCALAR_FIELD(op);
|
1553
|
+
COMPARE_STRING_FIELD(column_name);
|
1554
|
+
COMPARE_NODE_FIELD(context_item);
|
1555
|
+
COMPARE_NODE_FIELD(pathspec);
|
1556
|
+
COMPARE_NODE_FIELD(passing);
|
1557
|
+
COMPARE_NODE_FIELD(output);
|
1558
|
+
COMPARE_NODE_FIELD(on_empty);
|
1559
|
+
COMPARE_NODE_FIELD(on_error);
|
1560
|
+
COMPARE_SCALAR_FIELD(wrapper);
|
1561
|
+
COMPARE_SCALAR_FIELD(quotes);
|
1562
|
+
COMPARE_LOCATION_FIELD(location);
|
1563
|
+
|
1564
|
+
return true;
|
1565
|
+
}
|
1566
|
+
|
1567
|
+
static bool
|
1568
|
+
_equalJsonTablePathSpec(const JsonTablePathSpec *a, const JsonTablePathSpec *b)
|
1569
|
+
{
|
1570
|
+
COMPARE_NODE_FIELD(string);
|
1571
|
+
COMPARE_STRING_FIELD(name);
|
1572
|
+
COMPARE_LOCATION_FIELD(name_location);
|
1573
|
+
COMPARE_LOCATION_FIELD(location);
|
1574
|
+
|
1575
|
+
return true;
|
1576
|
+
}
|
1577
|
+
|
1578
|
+
static bool
|
1579
|
+
_equalJsonTable(const JsonTable *a, const JsonTable *b)
|
1580
|
+
{
|
1581
|
+
COMPARE_NODE_FIELD(context_item);
|
1582
|
+
COMPARE_NODE_FIELD(pathspec);
|
1583
|
+
COMPARE_NODE_FIELD(passing);
|
1584
|
+
COMPARE_NODE_FIELD(columns);
|
1585
|
+
COMPARE_NODE_FIELD(on_error);
|
1586
|
+
COMPARE_NODE_FIELD(alias);
|
1587
|
+
COMPARE_SCALAR_FIELD(lateral);
|
1588
|
+
COMPARE_LOCATION_FIELD(location);
|
1589
|
+
|
1590
|
+
return true;
|
1591
|
+
}
|
1592
|
+
|
1593
|
+
static bool
|
1594
|
+
_equalJsonTableColumn(const JsonTableColumn *a, const JsonTableColumn *b)
|
1595
|
+
{
|
1596
|
+
COMPARE_SCALAR_FIELD(coltype);
|
1597
|
+
COMPARE_STRING_FIELD(name);
|
1598
|
+
COMPARE_NODE_FIELD(typeName);
|
1599
|
+
COMPARE_NODE_FIELD(pathspec);
|
1600
|
+
COMPARE_NODE_FIELD(format);
|
1601
|
+
COMPARE_SCALAR_FIELD(wrapper);
|
1602
|
+
COMPARE_SCALAR_FIELD(quotes);
|
1603
|
+
COMPARE_NODE_FIELD(columns);
|
1604
|
+
COMPARE_NODE_FIELD(on_empty);
|
1605
|
+
COMPARE_NODE_FIELD(on_error);
|
1606
|
+
COMPARE_LOCATION_FIELD(location);
|
1607
|
+
|
1608
|
+
return true;
|
1609
|
+
}
|
1610
|
+
|
1611
|
+
static bool
|
1612
|
+
_equalJsonKeyValue(const JsonKeyValue *a, const JsonKeyValue *b)
|
1613
|
+
{
|
1614
|
+
COMPARE_NODE_FIELD(key);
|
1615
|
+
COMPARE_NODE_FIELD(value);
|
1616
|
+
|
1617
|
+
return true;
|
1618
|
+
}
|
1619
|
+
|
1620
|
+
static bool
|
1621
|
+
_equalJsonParseExpr(const JsonParseExpr *a, const JsonParseExpr *b)
|
1622
|
+
{
|
1623
|
+
COMPARE_NODE_FIELD(expr);
|
1624
|
+
COMPARE_NODE_FIELD(output);
|
1625
|
+
COMPARE_SCALAR_FIELD(unique_keys);
|
1626
|
+
COMPARE_LOCATION_FIELD(location);
|
1627
|
+
|
1628
|
+
return true;
|
1629
|
+
}
|
1630
|
+
|
1631
|
+
static bool
|
1632
|
+
_equalJsonScalarExpr(const JsonScalarExpr *a, const JsonScalarExpr *b)
|
1633
|
+
{
|
1634
|
+
COMPARE_NODE_FIELD(expr);
|
1635
|
+
COMPARE_NODE_FIELD(output);
|
1636
|
+
COMPARE_LOCATION_FIELD(location);
|
1637
|
+
|
1638
|
+
return true;
|
1639
|
+
}
|
1640
|
+
|
1641
|
+
static bool
|
1642
|
+
_equalJsonSerializeExpr(const JsonSerializeExpr *a, const JsonSerializeExpr *b)
|
1643
|
+
{
|
1644
|
+
COMPARE_NODE_FIELD(expr);
|
1645
|
+
COMPARE_NODE_FIELD(output);
|
1646
|
+
COMPARE_LOCATION_FIELD(location);
|
1647
|
+
|
1648
|
+
return true;
|
1649
|
+
}
|
1650
|
+
|
1651
|
+
static bool
|
1652
|
+
_equalJsonObjectConstructor(const JsonObjectConstructor *a, const JsonObjectConstructor *b)
|
1653
|
+
{
|
1654
|
+
COMPARE_NODE_FIELD(exprs);
|
1655
|
+
COMPARE_NODE_FIELD(output);
|
1656
|
+
COMPARE_SCALAR_FIELD(absent_on_null);
|
1657
|
+
COMPARE_SCALAR_FIELD(unique);
|
1658
|
+
COMPARE_LOCATION_FIELD(location);
|
1659
|
+
|
1660
|
+
return true;
|
1661
|
+
}
|
1662
|
+
|
1663
|
+
static bool
|
1664
|
+
_equalJsonArrayConstructor(const JsonArrayConstructor *a, const JsonArrayConstructor *b)
|
1665
|
+
{
|
1666
|
+
COMPARE_NODE_FIELD(exprs);
|
1667
|
+
COMPARE_NODE_FIELD(output);
|
1668
|
+
COMPARE_SCALAR_FIELD(absent_on_null);
|
1669
|
+
COMPARE_LOCATION_FIELD(location);
|
1670
|
+
|
1671
|
+
return true;
|
1672
|
+
}
|
1673
|
+
|
1674
|
+
static bool
|
1675
|
+
_equalJsonArrayQueryConstructor(const JsonArrayQueryConstructor *a, const JsonArrayQueryConstructor *b)
|
1676
|
+
{
|
1677
|
+
COMPARE_NODE_FIELD(query);
|
1678
|
+
COMPARE_NODE_FIELD(output);
|
1679
|
+
COMPARE_NODE_FIELD(format);
|
1680
|
+
COMPARE_SCALAR_FIELD(absent_on_null);
|
1681
|
+
COMPARE_LOCATION_FIELD(location);
|
1682
|
+
|
1683
|
+
return true;
|
1684
|
+
}
|
1685
|
+
|
1686
|
+
static bool
|
1687
|
+
_equalJsonAggConstructor(const JsonAggConstructor *a, const JsonAggConstructor *b)
|
1688
|
+
{
|
1689
|
+
COMPARE_NODE_FIELD(output);
|
1690
|
+
COMPARE_NODE_FIELD(agg_filter);
|
1691
|
+
COMPARE_NODE_FIELD(agg_order);
|
1692
|
+
COMPARE_NODE_FIELD(over);
|
1693
|
+
COMPARE_LOCATION_FIELD(location);
|
1694
|
+
|
1695
|
+
return true;
|
1696
|
+
}
|
1697
|
+
|
1698
|
+
static bool
|
1699
|
+
_equalJsonObjectAgg(const JsonObjectAgg *a, const JsonObjectAgg *b)
|
1700
|
+
{
|
1701
|
+
COMPARE_NODE_FIELD(constructor);
|
1702
|
+
COMPARE_NODE_FIELD(arg);
|
1703
|
+
COMPARE_SCALAR_FIELD(absent_on_null);
|
1704
|
+
COMPARE_SCALAR_FIELD(unique);
|
1705
|
+
|
1706
|
+
return true;
|
1707
|
+
}
|
1708
|
+
|
1709
|
+
static bool
|
1710
|
+
_equalJsonArrayAgg(const JsonArrayAgg *a, const JsonArrayAgg *b)
|
1711
|
+
{
|
1712
|
+
COMPARE_NODE_FIELD(constructor);
|
1713
|
+
COMPARE_NODE_FIELD(arg);
|
1714
|
+
COMPARE_SCALAR_FIELD(absent_on_null);
|
1715
|
+
|
1716
|
+
return true;
|
1717
|
+
}
|
1718
|
+
|
1719
|
+
static bool
|
1720
|
+
_equalRawStmt(const RawStmt *a, const RawStmt *b)
|
1721
|
+
{
|
1722
|
+
COMPARE_NODE_FIELD(stmt);
|
1723
|
+
COMPARE_LOCATION_FIELD(stmt_location);
|
1724
|
+
COMPARE_LOCATION_FIELD(stmt_len);
|
1725
|
+
|
1726
|
+
return true;
|
1727
|
+
}
|
1728
|
+
|
1729
|
+
static bool
|
1730
|
+
_equalInsertStmt(const InsertStmt *a, const InsertStmt *b)
|
1731
|
+
{
|
1732
|
+
COMPARE_NODE_FIELD(relation);
|
1733
|
+
COMPARE_NODE_FIELD(cols);
|
1734
|
+
COMPARE_NODE_FIELD(selectStmt);
|
1735
|
+
COMPARE_NODE_FIELD(onConflictClause);
|
1736
|
+
COMPARE_NODE_FIELD(returningList);
|
1737
|
+
COMPARE_NODE_FIELD(withClause);
|
1738
|
+
COMPARE_SCALAR_FIELD(override);
|
1739
|
+
|
1740
|
+
return true;
|
1741
|
+
}
|
1742
|
+
|
1743
|
+
static bool
|
1744
|
+
_equalDeleteStmt(const DeleteStmt *a, const DeleteStmt *b)
|
1745
|
+
{
|
1746
|
+
COMPARE_NODE_FIELD(relation);
|
1747
|
+
COMPARE_NODE_FIELD(usingClause);
|
1748
|
+
COMPARE_NODE_FIELD(whereClause);
|
1749
|
+
COMPARE_NODE_FIELD(returningList);
|
1750
|
+
COMPARE_NODE_FIELD(withClause);
|
1751
|
+
|
1752
|
+
return true;
|
1753
|
+
}
|
1754
|
+
|
1755
|
+
static bool
|
1756
|
+
_equalUpdateStmt(const UpdateStmt *a, const UpdateStmt *b)
|
1757
|
+
{
|
1758
|
+
COMPARE_NODE_FIELD(relation);
|
1759
|
+
COMPARE_NODE_FIELD(targetList);
|
1760
|
+
COMPARE_NODE_FIELD(whereClause);
|
1761
|
+
COMPARE_NODE_FIELD(fromClause);
|
1762
|
+
COMPARE_NODE_FIELD(returningList);
|
1763
|
+
COMPARE_NODE_FIELD(withClause);
|
1764
|
+
|
1765
|
+
return true;
|
1766
|
+
}
|
1767
|
+
|
1768
|
+
static bool
|
1769
|
+
_equalMergeStmt(const MergeStmt *a, const MergeStmt *b)
|
1770
|
+
{
|
1771
|
+
COMPARE_NODE_FIELD(relation);
|
1772
|
+
COMPARE_NODE_FIELD(sourceRelation);
|
1773
|
+
COMPARE_NODE_FIELD(joinCondition);
|
1774
|
+
COMPARE_NODE_FIELD(mergeWhenClauses);
|
1775
|
+
COMPARE_NODE_FIELD(returningList);
|
1776
|
+
COMPARE_NODE_FIELD(withClause);
|
1777
|
+
|
1778
|
+
return true;
|
1779
|
+
}
|
1780
|
+
|
1781
|
+
static bool
|
1782
|
+
_equalSelectStmt(const SelectStmt *a, const SelectStmt *b)
|
1783
|
+
{
|
1784
|
+
COMPARE_NODE_FIELD(distinctClause);
|
1785
|
+
COMPARE_NODE_FIELD(intoClause);
|
1786
|
+
COMPARE_NODE_FIELD(targetList);
|
1787
|
+
COMPARE_NODE_FIELD(fromClause);
|
1788
|
+
COMPARE_NODE_FIELD(whereClause);
|
1789
|
+
COMPARE_NODE_FIELD(groupClause);
|
1790
|
+
COMPARE_SCALAR_FIELD(groupDistinct);
|
1791
|
+
COMPARE_NODE_FIELD(havingClause);
|
1792
|
+
COMPARE_NODE_FIELD(windowClause);
|
1793
|
+
COMPARE_NODE_FIELD(valuesLists);
|
1794
|
+
COMPARE_NODE_FIELD(sortClause);
|
1795
|
+
COMPARE_NODE_FIELD(limitOffset);
|
1796
|
+
COMPARE_NODE_FIELD(limitCount);
|
1797
|
+
COMPARE_SCALAR_FIELD(limitOption);
|
1798
|
+
COMPARE_NODE_FIELD(lockingClause);
|
1799
|
+
COMPARE_NODE_FIELD(withClause);
|
1800
|
+
COMPARE_SCALAR_FIELD(op);
|
1801
|
+
COMPARE_SCALAR_FIELD(all);
|
1802
|
+
COMPARE_NODE_FIELD(larg);
|
1803
|
+
COMPARE_NODE_FIELD(rarg);
|
1804
|
+
|
1805
|
+
return true;
|
1806
|
+
}
|
1807
|
+
|
1808
|
+
static bool
|
1809
|
+
_equalSetOperationStmt(const SetOperationStmt *a, const SetOperationStmt *b)
|
1810
|
+
{
|
1811
|
+
COMPARE_SCALAR_FIELD(op);
|
1812
|
+
COMPARE_SCALAR_FIELD(all);
|
1813
|
+
COMPARE_NODE_FIELD(larg);
|
1814
|
+
COMPARE_NODE_FIELD(rarg);
|
1815
|
+
COMPARE_NODE_FIELD(colTypes);
|
1816
|
+
COMPARE_NODE_FIELD(colTypmods);
|
1817
|
+
COMPARE_NODE_FIELD(colCollations);
|
1818
|
+
COMPARE_NODE_FIELD(groupClauses);
|
1819
|
+
|
1820
|
+
return true;
|
1821
|
+
}
|
1822
|
+
|
1823
|
+
static bool
|
1824
|
+
_equalReturnStmt(const ReturnStmt *a, const ReturnStmt *b)
|
1825
|
+
{
|
1826
|
+
COMPARE_NODE_FIELD(returnval);
|
1827
|
+
|
1828
|
+
return true;
|
1829
|
+
}
|
1830
|
+
|
1831
|
+
static bool
|
1832
|
+
_equalPLAssignStmt(const PLAssignStmt *a, const PLAssignStmt *b)
|
1833
|
+
{
|
1834
|
+
COMPARE_STRING_FIELD(name);
|
1835
|
+
COMPARE_NODE_FIELD(indirection);
|
1836
|
+
COMPARE_SCALAR_FIELD(nnames);
|
1837
|
+
COMPARE_NODE_FIELD(val);
|
1838
|
+
COMPARE_LOCATION_FIELD(location);
|
1839
|
+
|
1840
|
+
return true;
|
1841
|
+
}
|
1842
|
+
|
1843
|
+
static bool
|
1844
|
+
_equalCreateSchemaStmt(const CreateSchemaStmt *a, const CreateSchemaStmt *b)
|
1845
|
+
{
|
1846
|
+
COMPARE_STRING_FIELD(schemaname);
|
1847
|
+
COMPARE_NODE_FIELD(authrole);
|
1848
|
+
COMPARE_NODE_FIELD(schemaElts);
|
1849
|
+
COMPARE_SCALAR_FIELD(if_not_exists);
|
1850
|
+
|
1851
|
+
return true;
|
1852
|
+
}
|
1853
|
+
|
1854
|
+
static bool
|
1855
|
+
_equalAlterTableStmt(const AlterTableStmt *a, const AlterTableStmt *b)
|
1856
|
+
{
|
1857
|
+
COMPARE_NODE_FIELD(relation);
|
1858
|
+
COMPARE_NODE_FIELD(cmds);
|
1859
|
+
COMPARE_SCALAR_FIELD(objtype);
|
1860
|
+
COMPARE_SCALAR_FIELD(missing_ok);
|
1861
|
+
|
1862
|
+
return true;
|
1863
|
+
}
|
1864
|
+
|
1865
|
+
static bool
|
1866
|
+
_equalReplicaIdentityStmt(const ReplicaIdentityStmt *a, const ReplicaIdentityStmt *b)
|
1867
|
+
{
|
1868
|
+
COMPARE_SCALAR_FIELD(identity_type);
|
1869
|
+
COMPARE_STRING_FIELD(name);
|
1870
|
+
|
1871
|
+
return true;
|
1872
|
+
}
|
1873
|
+
|
1874
|
+
static bool
|
1875
|
+
_equalAlterTableCmd(const AlterTableCmd *a, const AlterTableCmd *b)
|
1876
|
+
{
|
1877
|
+
COMPARE_SCALAR_FIELD(subtype);
|
1878
|
+
COMPARE_STRING_FIELD(name);
|
1879
|
+
COMPARE_SCALAR_FIELD(num);
|
1880
|
+
COMPARE_NODE_FIELD(newowner);
|
1881
|
+
COMPARE_NODE_FIELD(def);
|
1882
|
+
COMPARE_SCALAR_FIELD(behavior);
|
1883
|
+
COMPARE_SCALAR_FIELD(missing_ok);
|
1884
|
+
COMPARE_SCALAR_FIELD(recurse);
|
1885
|
+
|
1886
|
+
return true;
|
1887
|
+
}
|
1888
|
+
|
1889
|
+
static bool
|
1890
|
+
_equalAlterCollationStmt(const AlterCollationStmt *a, const AlterCollationStmt *b)
|
1891
|
+
{
|
1892
|
+
COMPARE_NODE_FIELD(collname);
|
1893
|
+
|
1894
|
+
return true;
|
1895
|
+
}
|
1896
|
+
|
1897
|
+
static bool
|
1898
|
+
_equalAlterDomainStmt(const AlterDomainStmt *a, const AlterDomainStmt *b)
|
1899
|
+
{
|
1900
|
+
COMPARE_SCALAR_FIELD(subtype);
|
1901
|
+
COMPARE_NODE_FIELD(typeName);
|
1902
|
+
COMPARE_STRING_FIELD(name);
|
1903
|
+
COMPARE_NODE_FIELD(def);
|
1904
|
+
COMPARE_SCALAR_FIELD(behavior);
|
1905
|
+
COMPARE_SCALAR_FIELD(missing_ok);
|
1906
|
+
|
1907
|
+
return true;
|
1908
|
+
}
|
1909
|
+
|
1910
|
+
static bool
|
1911
|
+
_equalGrantStmt(const GrantStmt *a, const GrantStmt *b)
|
1912
|
+
{
|
1913
|
+
COMPARE_SCALAR_FIELD(is_grant);
|
1914
|
+
COMPARE_SCALAR_FIELD(targtype);
|
1915
|
+
COMPARE_SCALAR_FIELD(objtype);
|
1916
|
+
COMPARE_NODE_FIELD(objects);
|
1917
|
+
COMPARE_NODE_FIELD(privileges);
|
1918
|
+
COMPARE_NODE_FIELD(grantees);
|
1919
|
+
COMPARE_SCALAR_FIELD(grant_option);
|
1920
|
+
COMPARE_NODE_FIELD(grantor);
|
1921
|
+
COMPARE_SCALAR_FIELD(behavior);
|
1922
|
+
|
1923
|
+
return true;
|
1924
|
+
}
|
1925
|
+
|
1926
|
+
static bool
|
1927
|
+
_equalObjectWithArgs(const ObjectWithArgs *a, const ObjectWithArgs *b)
|
1928
|
+
{
|
1929
|
+
COMPARE_NODE_FIELD(objname);
|
1930
|
+
COMPARE_NODE_FIELD(objargs);
|
1931
|
+
COMPARE_NODE_FIELD(objfuncargs);
|
1932
|
+
COMPARE_SCALAR_FIELD(args_unspecified);
|
1933
|
+
|
1934
|
+
return true;
|
1935
|
+
}
|
1936
|
+
|
1937
|
+
static bool
|
1938
|
+
_equalAccessPriv(const AccessPriv *a, const AccessPriv *b)
|
1939
|
+
{
|
1940
|
+
COMPARE_STRING_FIELD(priv_name);
|
1941
|
+
COMPARE_NODE_FIELD(cols);
|
1942
|
+
|
1943
|
+
return true;
|
1944
|
+
}
|
1945
|
+
|
1946
|
+
static bool
|
1947
|
+
_equalGrantRoleStmt(const GrantRoleStmt *a, const GrantRoleStmt *b)
|
1948
|
+
{
|
1949
|
+
COMPARE_NODE_FIELD(granted_roles);
|
1950
|
+
COMPARE_NODE_FIELD(grantee_roles);
|
1951
|
+
COMPARE_SCALAR_FIELD(is_grant);
|
1952
|
+
COMPARE_NODE_FIELD(opt);
|
1953
|
+
COMPARE_NODE_FIELD(grantor);
|
1954
|
+
COMPARE_SCALAR_FIELD(behavior);
|
1955
|
+
|
1956
|
+
return true;
|
1957
|
+
}
|
1958
|
+
|
1959
|
+
static bool
|
1960
|
+
_equalAlterDefaultPrivilegesStmt(const AlterDefaultPrivilegesStmt *a, const AlterDefaultPrivilegesStmt *b)
|
1961
|
+
{
|
1962
|
+
COMPARE_NODE_FIELD(options);
|
1963
|
+
COMPARE_NODE_FIELD(action);
|
1964
|
+
|
1965
|
+
return true;
|
1966
|
+
}
|
1967
|
+
|
1968
|
+
static bool
|
1969
|
+
_equalCopyStmt(const CopyStmt *a, const CopyStmt *b)
|
1970
|
+
{
|
1971
|
+
COMPARE_NODE_FIELD(relation);
|
1972
|
+
COMPARE_NODE_FIELD(query);
|
1973
|
+
COMPARE_NODE_FIELD(attlist);
|
1974
|
+
COMPARE_SCALAR_FIELD(is_from);
|
1975
|
+
COMPARE_SCALAR_FIELD(is_program);
|
1976
|
+
COMPARE_STRING_FIELD(filename);
|
1977
|
+
COMPARE_NODE_FIELD(options);
|
1978
|
+
COMPARE_NODE_FIELD(whereClause);
|
1979
|
+
|
1980
|
+
return true;
|
1981
|
+
}
|
1982
|
+
|
1983
|
+
static bool
|
1984
|
+
_equalVariableSetStmt(const VariableSetStmt *a, const VariableSetStmt *b)
|
1985
|
+
{
|
1986
|
+
COMPARE_SCALAR_FIELD(kind);
|
1987
|
+
COMPARE_STRING_FIELD(name);
|
1988
|
+
COMPARE_NODE_FIELD(args);
|
1989
|
+
COMPARE_SCALAR_FIELD(is_local);
|
1990
|
+
|
1991
|
+
return true;
|
1992
|
+
}
|
1993
|
+
|
1994
|
+
static bool
|
1995
|
+
_equalVariableShowStmt(const VariableShowStmt *a, const VariableShowStmt *b)
|
1996
|
+
{
|
1997
|
+
COMPARE_STRING_FIELD(name);
|
1998
|
+
|
1999
|
+
return true;
|
2000
|
+
}
|
2001
|
+
|
2002
|
+
static bool
|
2003
|
+
_equalCreateStmt(const CreateStmt *a, const CreateStmt *b)
|
2004
|
+
{
|
2005
|
+
COMPARE_NODE_FIELD(relation);
|
2006
|
+
COMPARE_NODE_FIELD(tableElts);
|
2007
|
+
COMPARE_NODE_FIELD(inhRelations);
|
2008
|
+
COMPARE_NODE_FIELD(partbound);
|
2009
|
+
COMPARE_NODE_FIELD(partspec);
|
2010
|
+
COMPARE_NODE_FIELD(ofTypename);
|
2011
|
+
COMPARE_NODE_FIELD(constraints);
|
2012
|
+
COMPARE_NODE_FIELD(options);
|
2013
|
+
COMPARE_SCALAR_FIELD(oncommit);
|
2014
|
+
COMPARE_STRING_FIELD(tablespacename);
|
2015
|
+
COMPARE_STRING_FIELD(accessMethod);
|
2016
|
+
COMPARE_SCALAR_FIELD(if_not_exists);
|
2017
|
+
|
2018
|
+
return true;
|
2019
|
+
}
|
2020
|
+
|
2021
|
+
static bool
|
2022
|
+
_equalConstraint(const Constraint *a, const Constraint *b)
|
2023
|
+
{
|
2024
|
+
COMPARE_SCALAR_FIELD(contype);
|
2025
|
+
COMPARE_STRING_FIELD(conname);
|
2026
|
+
COMPARE_SCALAR_FIELD(deferrable);
|
2027
|
+
COMPARE_SCALAR_FIELD(initdeferred);
|
2028
|
+
COMPARE_SCALAR_FIELD(skip_validation);
|
2029
|
+
COMPARE_SCALAR_FIELD(initially_valid);
|
2030
|
+
COMPARE_SCALAR_FIELD(is_no_inherit);
|
2031
|
+
COMPARE_NODE_FIELD(raw_expr);
|
2032
|
+
COMPARE_STRING_FIELD(cooked_expr);
|
2033
|
+
COMPARE_SCALAR_FIELD(generated_when);
|
2034
|
+
COMPARE_SCALAR_FIELD(inhcount);
|
2035
|
+
COMPARE_SCALAR_FIELD(nulls_not_distinct);
|
2036
|
+
COMPARE_NODE_FIELD(keys);
|
2037
|
+
COMPARE_NODE_FIELD(including);
|
2038
|
+
COMPARE_NODE_FIELD(exclusions);
|
2039
|
+
COMPARE_NODE_FIELD(options);
|
2040
|
+
COMPARE_STRING_FIELD(indexname);
|
2041
|
+
COMPARE_STRING_FIELD(indexspace);
|
2042
|
+
COMPARE_SCALAR_FIELD(reset_default_tblspc);
|
2043
|
+
COMPARE_STRING_FIELD(access_method);
|
2044
|
+
COMPARE_NODE_FIELD(where_clause);
|
2045
|
+
COMPARE_NODE_FIELD(pktable);
|
2046
|
+
COMPARE_NODE_FIELD(fk_attrs);
|
2047
|
+
COMPARE_NODE_FIELD(pk_attrs);
|
2048
|
+
COMPARE_SCALAR_FIELD(fk_matchtype);
|
2049
|
+
COMPARE_SCALAR_FIELD(fk_upd_action);
|
2050
|
+
COMPARE_SCALAR_FIELD(fk_del_action);
|
2051
|
+
COMPARE_NODE_FIELD(fk_del_set_cols);
|
2052
|
+
COMPARE_NODE_FIELD(old_conpfeqop);
|
2053
|
+
COMPARE_SCALAR_FIELD(old_pktable_oid);
|
2054
|
+
COMPARE_LOCATION_FIELD(location);
|
2055
|
+
|
2056
|
+
return true;
|
2057
|
+
}
|
2058
|
+
|
2059
|
+
static bool
|
2060
|
+
_equalCreateTableSpaceStmt(const CreateTableSpaceStmt *a, const CreateTableSpaceStmt *b)
|
2061
|
+
{
|
2062
|
+
COMPARE_STRING_FIELD(tablespacename);
|
2063
|
+
COMPARE_NODE_FIELD(owner);
|
2064
|
+
COMPARE_STRING_FIELD(location);
|
2065
|
+
COMPARE_NODE_FIELD(options);
|
2066
|
+
|
2067
|
+
return true;
|
2068
|
+
}
|
2069
|
+
|
2070
|
+
static bool
|
2071
|
+
_equalDropTableSpaceStmt(const DropTableSpaceStmt *a, const DropTableSpaceStmt *b)
|
2072
|
+
{
|
2073
|
+
COMPARE_STRING_FIELD(tablespacename);
|
2074
|
+
COMPARE_SCALAR_FIELD(missing_ok);
|
2075
|
+
|
2076
|
+
return true;
|
2077
|
+
}
|
2078
|
+
|
2079
|
+
static bool
|
2080
|
+
_equalAlterTableSpaceOptionsStmt(const AlterTableSpaceOptionsStmt *a, const AlterTableSpaceOptionsStmt *b)
|
2081
|
+
{
|
2082
|
+
COMPARE_STRING_FIELD(tablespacename);
|
2083
|
+
COMPARE_NODE_FIELD(options);
|
2084
|
+
COMPARE_SCALAR_FIELD(isReset);
|
2085
|
+
|
2086
|
+
return true;
|
2087
|
+
}
|
2088
|
+
|
2089
|
+
static bool
|
2090
|
+
_equalAlterTableMoveAllStmt(const AlterTableMoveAllStmt *a, const AlterTableMoveAllStmt *b)
|
2091
|
+
{
|
2092
|
+
COMPARE_STRING_FIELD(orig_tablespacename);
|
2093
|
+
COMPARE_SCALAR_FIELD(objtype);
|
2094
|
+
COMPARE_NODE_FIELD(roles);
|
2095
|
+
COMPARE_STRING_FIELD(new_tablespacename);
|
2096
|
+
COMPARE_SCALAR_FIELD(nowait);
|
2097
|
+
|
2098
|
+
return true;
|
2099
|
+
}
|
2100
|
+
|
2101
|
+
static bool
|
2102
|
+
_equalCreateExtensionStmt(const CreateExtensionStmt *a, const CreateExtensionStmt *b)
|
2103
|
+
{
|
2104
|
+
COMPARE_STRING_FIELD(extname);
|
2105
|
+
COMPARE_SCALAR_FIELD(if_not_exists);
|
2106
|
+
COMPARE_NODE_FIELD(options);
|
2107
|
+
|
2108
|
+
return true;
|
2109
|
+
}
|
2110
|
+
|
2111
|
+
static bool
|
2112
|
+
_equalAlterExtensionStmt(const AlterExtensionStmt *a, const AlterExtensionStmt *b)
|
2113
|
+
{
|
2114
|
+
COMPARE_STRING_FIELD(extname);
|
2115
|
+
COMPARE_NODE_FIELD(options);
|
2116
|
+
|
2117
|
+
return true;
|
2118
|
+
}
|
2119
|
+
|
2120
|
+
static bool
|
2121
|
+
_equalAlterExtensionContentsStmt(const AlterExtensionContentsStmt *a, const AlterExtensionContentsStmt *b)
|
2122
|
+
{
|
2123
|
+
COMPARE_STRING_FIELD(extname);
|
2124
|
+
COMPARE_SCALAR_FIELD(action);
|
2125
|
+
COMPARE_SCALAR_FIELD(objtype);
|
2126
|
+
COMPARE_NODE_FIELD(object);
|
2127
|
+
|
2128
|
+
return true;
|
2129
|
+
}
|
2130
|
+
|
2131
|
+
static bool
|
2132
|
+
_equalCreateFdwStmt(const CreateFdwStmt *a, const CreateFdwStmt *b)
|
2133
|
+
{
|
2134
|
+
COMPARE_STRING_FIELD(fdwname);
|
2135
|
+
COMPARE_NODE_FIELD(func_options);
|
2136
|
+
COMPARE_NODE_FIELD(options);
|
2137
|
+
|
2138
|
+
return true;
|
2139
|
+
}
|
2140
|
+
|
2141
|
+
static bool
|
2142
|
+
_equalAlterFdwStmt(const AlterFdwStmt *a, const AlterFdwStmt *b)
|
2143
|
+
{
|
2144
|
+
COMPARE_STRING_FIELD(fdwname);
|
2145
|
+
COMPARE_NODE_FIELD(func_options);
|
2146
|
+
COMPARE_NODE_FIELD(options);
|
2147
|
+
|
2148
|
+
return true;
|
2149
|
+
}
|
2150
|
+
|
2151
|
+
static bool
|
2152
|
+
_equalCreateForeignServerStmt(const CreateForeignServerStmt *a, const CreateForeignServerStmt *b)
|
2153
|
+
{
|
2154
|
+
COMPARE_STRING_FIELD(servername);
|
2155
|
+
COMPARE_STRING_FIELD(servertype);
|
2156
|
+
COMPARE_STRING_FIELD(version);
|
2157
|
+
COMPARE_STRING_FIELD(fdwname);
|
2158
|
+
COMPARE_SCALAR_FIELD(if_not_exists);
|
2159
|
+
COMPARE_NODE_FIELD(options);
|
2160
|
+
|
2161
|
+
return true;
|
2162
|
+
}
|
2163
|
+
|
2164
|
+
static bool
|
2165
|
+
_equalAlterForeignServerStmt(const AlterForeignServerStmt *a, const AlterForeignServerStmt *b)
|
2166
|
+
{
|
2167
|
+
COMPARE_STRING_FIELD(servername);
|
2168
|
+
COMPARE_STRING_FIELD(version);
|
2169
|
+
COMPARE_NODE_FIELD(options);
|
2170
|
+
COMPARE_SCALAR_FIELD(has_version);
|
2171
|
+
|
2172
|
+
return true;
|
2173
|
+
}
|
2174
|
+
|
2175
|
+
static bool
|
2176
|
+
_equalCreateForeignTableStmt(const CreateForeignTableStmt *a, const CreateForeignTableStmt *b)
|
2177
|
+
{
|
2178
|
+
COMPARE_NODE_FIELD(base.relation);
|
2179
|
+
COMPARE_NODE_FIELD(base.tableElts);
|
2180
|
+
COMPARE_NODE_FIELD(base.inhRelations);
|
2181
|
+
COMPARE_NODE_FIELD(base.partbound);
|
2182
|
+
COMPARE_NODE_FIELD(base.partspec);
|
2183
|
+
COMPARE_NODE_FIELD(base.ofTypename);
|
2184
|
+
COMPARE_NODE_FIELD(base.constraints);
|
2185
|
+
COMPARE_NODE_FIELD(base.options);
|
2186
|
+
COMPARE_SCALAR_FIELD(base.oncommit);
|
2187
|
+
COMPARE_STRING_FIELD(base.tablespacename);
|
2188
|
+
COMPARE_STRING_FIELD(base.accessMethod);
|
2189
|
+
COMPARE_SCALAR_FIELD(base.if_not_exists);
|
2190
|
+
COMPARE_STRING_FIELD(servername);
|
2191
|
+
COMPARE_NODE_FIELD(options);
|
2192
|
+
|
2193
|
+
return true;
|
2194
|
+
}
|
2195
|
+
|
2196
|
+
static bool
|
2197
|
+
_equalCreateUserMappingStmt(const CreateUserMappingStmt *a, const CreateUserMappingStmt *b)
|
2198
|
+
{
|
2199
|
+
COMPARE_NODE_FIELD(user);
|
2200
|
+
COMPARE_STRING_FIELD(servername);
|
2201
|
+
COMPARE_SCALAR_FIELD(if_not_exists);
|
2202
|
+
COMPARE_NODE_FIELD(options);
|
2203
|
+
|
2204
|
+
return true;
|
2205
|
+
}
|
2206
|
+
|
2207
|
+
static bool
|
2208
|
+
_equalAlterUserMappingStmt(const AlterUserMappingStmt *a, const AlterUserMappingStmt *b)
|
2209
|
+
{
|
2210
|
+
COMPARE_NODE_FIELD(user);
|
2211
|
+
COMPARE_STRING_FIELD(servername);
|
2212
|
+
COMPARE_NODE_FIELD(options);
|
2213
|
+
|
2214
|
+
return true;
|
2215
|
+
}
|
2216
|
+
|
2217
|
+
static bool
|
2218
|
+
_equalDropUserMappingStmt(const DropUserMappingStmt *a, const DropUserMappingStmt *b)
|
2219
|
+
{
|
2220
|
+
COMPARE_NODE_FIELD(user);
|
2221
|
+
COMPARE_STRING_FIELD(servername);
|
2222
|
+
COMPARE_SCALAR_FIELD(missing_ok);
|
2223
|
+
|
2224
|
+
return true;
|
2225
|
+
}
|
2226
|
+
|
2227
|
+
static bool
|
2228
|
+
_equalImportForeignSchemaStmt(const ImportForeignSchemaStmt *a, const ImportForeignSchemaStmt *b)
|
2229
|
+
{
|
2230
|
+
COMPARE_STRING_FIELD(server_name);
|
2231
|
+
COMPARE_STRING_FIELD(remote_schema);
|
2232
|
+
COMPARE_STRING_FIELD(local_schema);
|
2233
|
+
COMPARE_SCALAR_FIELD(list_type);
|
2234
|
+
COMPARE_NODE_FIELD(table_list);
|
2235
|
+
COMPARE_NODE_FIELD(options);
|
2236
|
+
|
2237
|
+
return true;
|
2238
|
+
}
|
2239
|
+
|
2240
|
+
static bool
|
2241
|
+
_equalCreatePolicyStmt(const CreatePolicyStmt *a, const CreatePolicyStmt *b)
|
2242
|
+
{
|
2243
|
+
COMPARE_STRING_FIELD(policy_name);
|
2244
|
+
COMPARE_NODE_FIELD(table);
|
2245
|
+
COMPARE_STRING_FIELD(cmd_name);
|
2246
|
+
COMPARE_SCALAR_FIELD(permissive);
|
2247
|
+
COMPARE_NODE_FIELD(roles);
|
2248
|
+
COMPARE_NODE_FIELD(qual);
|
2249
|
+
COMPARE_NODE_FIELD(with_check);
|
2250
|
+
|
2251
|
+
return true;
|
2252
|
+
}
|
2253
|
+
|
2254
|
+
static bool
|
2255
|
+
_equalAlterPolicyStmt(const AlterPolicyStmt *a, const AlterPolicyStmt *b)
|
2256
|
+
{
|
2257
|
+
COMPARE_STRING_FIELD(policy_name);
|
2258
|
+
COMPARE_NODE_FIELD(table);
|
2259
|
+
COMPARE_NODE_FIELD(roles);
|
2260
|
+
COMPARE_NODE_FIELD(qual);
|
2261
|
+
COMPARE_NODE_FIELD(with_check);
|
2262
|
+
|
2263
|
+
return true;
|
2264
|
+
}
|
2265
|
+
|
2266
|
+
static bool
|
2267
|
+
_equalCreateAmStmt(const CreateAmStmt *a, const CreateAmStmt *b)
|
2268
|
+
{
|
2269
|
+
COMPARE_STRING_FIELD(amname);
|
2270
|
+
COMPARE_NODE_FIELD(handler_name);
|
2271
|
+
COMPARE_SCALAR_FIELD(amtype);
|
2272
|
+
|
2273
|
+
return true;
|
2274
|
+
}
|
2275
|
+
|
2276
|
+
static bool
|
2277
|
+
_equalCreateTrigStmt(const CreateTrigStmt *a, const CreateTrigStmt *b)
|
2278
|
+
{
|
2279
|
+
COMPARE_SCALAR_FIELD(replace);
|
2280
|
+
COMPARE_SCALAR_FIELD(isconstraint);
|
2281
|
+
COMPARE_STRING_FIELD(trigname);
|
2282
|
+
COMPARE_NODE_FIELD(relation);
|
2283
|
+
COMPARE_NODE_FIELD(funcname);
|
2284
|
+
COMPARE_NODE_FIELD(args);
|
2285
|
+
COMPARE_SCALAR_FIELD(row);
|
2286
|
+
COMPARE_SCALAR_FIELD(timing);
|
2287
|
+
COMPARE_SCALAR_FIELD(events);
|
2288
|
+
COMPARE_NODE_FIELD(columns);
|
2289
|
+
COMPARE_NODE_FIELD(whenClause);
|
2290
|
+
COMPARE_NODE_FIELD(transitionRels);
|
2291
|
+
COMPARE_SCALAR_FIELD(deferrable);
|
2292
|
+
COMPARE_SCALAR_FIELD(initdeferred);
|
2293
|
+
COMPARE_NODE_FIELD(constrrel);
|
2294
|
+
|
2295
|
+
return true;
|
2296
|
+
}
|
2297
|
+
|
2298
|
+
static bool
|
2299
|
+
_equalCreateEventTrigStmt(const CreateEventTrigStmt *a, const CreateEventTrigStmt *b)
|
2300
|
+
{
|
2301
|
+
COMPARE_STRING_FIELD(trigname);
|
2302
|
+
COMPARE_STRING_FIELD(eventname);
|
2303
|
+
COMPARE_NODE_FIELD(whenclause);
|
2304
|
+
COMPARE_NODE_FIELD(funcname);
|
2305
|
+
|
2306
|
+
return true;
|
2307
|
+
}
|
2308
|
+
|
2309
|
+
static bool
|
2310
|
+
_equalAlterEventTrigStmt(const AlterEventTrigStmt *a, const AlterEventTrigStmt *b)
|
2311
|
+
{
|
2312
|
+
COMPARE_STRING_FIELD(trigname);
|
2313
|
+
COMPARE_SCALAR_FIELD(tgenabled);
|
2314
|
+
|
2315
|
+
return true;
|
2316
|
+
}
|
2317
|
+
|
2318
|
+
static bool
|
2319
|
+
_equalCreatePLangStmt(const CreatePLangStmt *a, const CreatePLangStmt *b)
|
2320
|
+
{
|
2321
|
+
COMPARE_SCALAR_FIELD(replace);
|
2322
|
+
COMPARE_STRING_FIELD(plname);
|
2323
|
+
COMPARE_NODE_FIELD(plhandler);
|
2324
|
+
COMPARE_NODE_FIELD(plinline);
|
2325
|
+
COMPARE_NODE_FIELD(plvalidator);
|
2326
|
+
COMPARE_SCALAR_FIELD(pltrusted);
|
2327
|
+
|
2328
|
+
return true;
|
2329
|
+
}
|
2330
|
+
|
2331
|
+
static bool
|
2332
|
+
_equalCreateRoleStmt(const CreateRoleStmt *a, const CreateRoleStmt *b)
|
2333
|
+
{
|
2334
|
+
COMPARE_SCALAR_FIELD(stmt_type);
|
2335
|
+
COMPARE_STRING_FIELD(role);
|
2336
|
+
COMPARE_NODE_FIELD(options);
|
2337
|
+
|
2338
|
+
return true;
|
2339
|
+
}
|
2340
|
+
|
2341
|
+
static bool
|
2342
|
+
_equalAlterRoleStmt(const AlterRoleStmt *a, const AlterRoleStmt *b)
|
2343
|
+
{
|
2344
|
+
COMPARE_NODE_FIELD(role);
|
2345
|
+
COMPARE_NODE_FIELD(options);
|
2346
|
+
COMPARE_SCALAR_FIELD(action);
|
2347
|
+
|
2348
|
+
return true;
|
2349
|
+
}
|
2350
|
+
|
2351
|
+
static bool
|
2352
|
+
_equalAlterRoleSetStmt(const AlterRoleSetStmt *a, const AlterRoleSetStmt *b)
|
2353
|
+
{
|
2354
|
+
COMPARE_NODE_FIELD(role);
|
2355
|
+
COMPARE_STRING_FIELD(database);
|
2356
|
+
COMPARE_NODE_FIELD(setstmt);
|
2357
|
+
|
2358
|
+
return true;
|
2359
|
+
}
|
2360
|
+
|
2361
|
+
static bool
|
2362
|
+
_equalDropRoleStmt(const DropRoleStmt *a, const DropRoleStmt *b)
|
2363
|
+
{
|
2364
|
+
COMPARE_NODE_FIELD(roles);
|
2365
|
+
COMPARE_SCALAR_FIELD(missing_ok);
|
2366
|
+
|
2367
|
+
return true;
|
2368
|
+
}
|
2369
|
+
|
2370
|
+
static bool
|
2371
|
+
_equalCreateSeqStmt(const CreateSeqStmt *a, const CreateSeqStmt *b)
|
2372
|
+
{
|
2373
|
+
COMPARE_NODE_FIELD(sequence);
|
2374
|
+
COMPARE_NODE_FIELD(options);
|
2375
|
+
COMPARE_SCALAR_FIELD(ownerId);
|
2376
|
+
COMPARE_SCALAR_FIELD(for_identity);
|
2377
|
+
COMPARE_SCALAR_FIELD(if_not_exists);
|
2378
|
+
|
2379
|
+
return true;
|
2380
|
+
}
|
2381
|
+
|
2382
|
+
static bool
|
2383
|
+
_equalAlterSeqStmt(const AlterSeqStmt *a, const AlterSeqStmt *b)
|
2384
|
+
{
|
2385
|
+
COMPARE_NODE_FIELD(sequence);
|
2386
|
+
COMPARE_NODE_FIELD(options);
|
2387
|
+
COMPARE_SCALAR_FIELD(for_identity);
|
2388
|
+
COMPARE_SCALAR_FIELD(missing_ok);
|
2389
|
+
|
2390
|
+
return true;
|
2391
|
+
}
|
2392
|
+
|
2393
|
+
static bool
|
2394
|
+
_equalDefineStmt(const DefineStmt *a, const DefineStmt *b)
|
2395
|
+
{
|
2396
|
+
COMPARE_SCALAR_FIELD(kind);
|
2397
|
+
COMPARE_SCALAR_FIELD(oldstyle);
|
2398
|
+
COMPARE_NODE_FIELD(defnames);
|
2399
|
+
COMPARE_NODE_FIELD(args);
|
2400
|
+
COMPARE_NODE_FIELD(definition);
|
2401
|
+
COMPARE_SCALAR_FIELD(if_not_exists);
|
2402
|
+
COMPARE_SCALAR_FIELD(replace);
|
2403
|
+
|
2404
|
+
return true;
|
2405
|
+
}
|
2406
|
+
|
2407
|
+
static bool
|
2408
|
+
_equalCreateDomainStmt(const CreateDomainStmt *a, const CreateDomainStmt *b)
|
2409
|
+
{
|
2410
|
+
COMPARE_NODE_FIELD(domainname);
|
2411
|
+
COMPARE_NODE_FIELD(typeName);
|
2412
|
+
COMPARE_NODE_FIELD(collClause);
|
2413
|
+
COMPARE_NODE_FIELD(constraints);
|
2414
|
+
|
2415
|
+
return true;
|
2416
|
+
}
|
2417
|
+
|
2418
|
+
static bool
|
2419
|
+
_equalCreateOpClassStmt(const CreateOpClassStmt *a, const CreateOpClassStmt *b)
|
2420
|
+
{
|
2421
|
+
COMPARE_NODE_FIELD(opclassname);
|
2422
|
+
COMPARE_NODE_FIELD(opfamilyname);
|
2423
|
+
COMPARE_STRING_FIELD(amname);
|
2424
|
+
COMPARE_NODE_FIELD(datatype);
|
2425
|
+
COMPARE_NODE_FIELD(items);
|
2426
|
+
COMPARE_SCALAR_FIELD(isDefault);
|
2427
|
+
|
2428
|
+
return true;
|
2429
|
+
}
|
2430
|
+
|
2431
|
+
static bool
|
2432
|
+
_equalCreateOpClassItem(const CreateOpClassItem *a, const CreateOpClassItem *b)
|
2433
|
+
{
|
2434
|
+
COMPARE_SCALAR_FIELD(itemtype);
|
2435
|
+
COMPARE_NODE_FIELD(name);
|
2436
|
+
COMPARE_SCALAR_FIELD(number);
|
2437
|
+
COMPARE_NODE_FIELD(order_family);
|
2438
|
+
COMPARE_NODE_FIELD(class_args);
|
2439
|
+
COMPARE_NODE_FIELD(storedtype);
|
2440
|
+
|
2441
|
+
return true;
|
2442
|
+
}
|
2443
|
+
|
2444
|
+
static bool
|
2445
|
+
_equalCreateOpFamilyStmt(const CreateOpFamilyStmt *a, const CreateOpFamilyStmt *b)
|
2446
|
+
{
|
2447
|
+
COMPARE_NODE_FIELD(opfamilyname);
|
2448
|
+
COMPARE_STRING_FIELD(amname);
|
2449
|
+
|
2450
|
+
return true;
|
2451
|
+
}
|
2452
|
+
|
2453
|
+
static bool
|
2454
|
+
_equalAlterOpFamilyStmt(const AlterOpFamilyStmt *a, const AlterOpFamilyStmt *b)
|
2455
|
+
{
|
2456
|
+
COMPARE_NODE_FIELD(opfamilyname);
|
2457
|
+
COMPARE_STRING_FIELD(amname);
|
2458
|
+
COMPARE_SCALAR_FIELD(isDrop);
|
2459
|
+
COMPARE_NODE_FIELD(items);
|
2460
|
+
|
2461
|
+
return true;
|
2462
|
+
}
|
2463
|
+
|
2464
|
+
static bool
|
2465
|
+
_equalDropStmt(const DropStmt *a, const DropStmt *b)
|
2466
|
+
{
|
2467
|
+
COMPARE_NODE_FIELD(objects);
|
2468
|
+
COMPARE_SCALAR_FIELD(removeType);
|
2469
|
+
COMPARE_SCALAR_FIELD(behavior);
|
2470
|
+
COMPARE_SCALAR_FIELD(missing_ok);
|
2471
|
+
COMPARE_SCALAR_FIELD(concurrent);
|
2472
|
+
|
2473
|
+
return true;
|
2474
|
+
}
|
2475
|
+
|
2476
|
+
static bool
|
2477
|
+
_equalTruncateStmt(const TruncateStmt *a, const TruncateStmt *b)
|
2478
|
+
{
|
2479
|
+
COMPARE_NODE_FIELD(relations);
|
2480
|
+
COMPARE_SCALAR_FIELD(restart_seqs);
|
2481
|
+
COMPARE_SCALAR_FIELD(behavior);
|
2482
|
+
|
2483
|
+
return true;
|
2484
|
+
}
|
2485
|
+
|
2486
|
+
static bool
|
2487
|
+
_equalCommentStmt(const CommentStmt *a, const CommentStmt *b)
|
2488
|
+
{
|
2489
|
+
COMPARE_SCALAR_FIELD(objtype);
|
2490
|
+
COMPARE_NODE_FIELD(object);
|
2491
|
+
COMPARE_STRING_FIELD(comment);
|
2492
|
+
|
2493
|
+
return true;
|
2494
|
+
}
|
2495
|
+
|
2496
|
+
static bool
|
2497
|
+
_equalSecLabelStmt(const SecLabelStmt *a, const SecLabelStmt *b)
|
2498
|
+
{
|
2499
|
+
COMPARE_SCALAR_FIELD(objtype);
|
2500
|
+
COMPARE_NODE_FIELD(object);
|
2501
|
+
COMPARE_STRING_FIELD(provider);
|
2502
|
+
COMPARE_STRING_FIELD(label);
|
2503
|
+
|
2504
|
+
return true;
|
2505
|
+
}
|
2506
|
+
|
2507
|
+
static bool
|
2508
|
+
_equalDeclareCursorStmt(const DeclareCursorStmt *a, const DeclareCursorStmt *b)
|
2509
|
+
{
|
2510
|
+
COMPARE_STRING_FIELD(portalname);
|
2511
|
+
COMPARE_SCALAR_FIELD(options);
|
2512
|
+
COMPARE_NODE_FIELD(query);
|
2513
|
+
|
2514
|
+
return true;
|
2515
|
+
}
|
2516
|
+
|
2517
|
+
static bool
|
2518
|
+
_equalClosePortalStmt(const ClosePortalStmt *a, const ClosePortalStmt *b)
|
2519
|
+
{
|
2520
|
+
COMPARE_STRING_FIELD(portalname);
|
2521
|
+
|
2522
|
+
return true;
|
2523
|
+
}
|
2524
|
+
|
2525
|
+
static bool
|
2526
|
+
_equalFetchStmt(const FetchStmt *a, const FetchStmt *b)
|
2527
|
+
{
|
2528
|
+
COMPARE_SCALAR_FIELD(direction);
|
2529
|
+
COMPARE_SCALAR_FIELD(howMany);
|
2530
|
+
COMPARE_STRING_FIELD(portalname);
|
2531
|
+
COMPARE_SCALAR_FIELD(ismove);
|
2532
|
+
|
2533
|
+
return true;
|
2534
|
+
}
|
2535
|
+
|
2536
|
+
static bool
|
2537
|
+
_equalIndexStmt(const IndexStmt *a, const IndexStmt *b)
|
2538
|
+
{
|
2539
|
+
COMPARE_STRING_FIELD(idxname);
|
2540
|
+
COMPARE_NODE_FIELD(relation);
|
2541
|
+
COMPARE_STRING_FIELD(accessMethod);
|
2542
|
+
COMPARE_STRING_FIELD(tableSpace);
|
2543
|
+
COMPARE_NODE_FIELD(indexParams);
|
2544
|
+
COMPARE_NODE_FIELD(indexIncludingParams);
|
2545
|
+
COMPARE_NODE_FIELD(options);
|
2546
|
+
COMPARE_NODE_FIELD(whereClause);
|
2547
|
+
COMPARE_NODE_FIELD(excludeOpNames);
|
2548
|
+
COMPARE_STRING_FIELD(idxcomment);
|
2549
|
+
COMPARE_SCALAR_FIELD(indexOid);
|
2550
|
+
COMPARE_SCALAR_FIELD(oldNumber);
|
2551
|
+
COMPARE_SCALAR_FIELD(oldCreateSubid);
|
2552
|
+
COMPARE_SCALAR_FIELD(oldFirstRelfilelocatorSubid);
|
2553
|
+
COMPARE_SCALAR_FIELD(unique);
|
2554
|
+
COMPARE_SCALAR_FIELD(nulls_not_distinct);
|
2555
|
+
COMPARE_SCALAR_FIELD(primary);
|
2556
|
+
COMPARE_SCALAR_FIELD(isconstraint);
|
2557
|
+
COMPARE_SCALAR_FIELD(deferrable);
|
2558
|
+
COMPARE_SCALAR_FIELD(initdeferred);
|
2559
|
+
COMPARE_SCALAR_FIELD(transformed);
|
2560
|
+
COMPARE_SCALAR_FIELD(concurrent);
|
2561
|
+
COMPARE_SCALAR_FIELD(if_not_exists);
|
2562
|
+
COMPARE_SCALAR_FIELD(reset_default_tblspc);
|
2563
|
+
|
2564
|
+
return true;
|
2565
|
+
}
|
2566
|
+
|
2567
|
+
static bool
|
2568
|
+
_equalCreateStatsStmt(const CreateStatsStmt *a, const CreateStatsStmt *b)
|
2569
|
+
{
|
2570
|
+
COMPARE_NODE_FIELD(defnames);
|
2571
|
+
COMPARE_NODE_FIELD(stat_types);
|
2572
|
+
COMPARE_NODE_FIELD(exprs);
|
2573
|
+
COMPARE_NODE_FIELD(relations);
|
2574
|
+
COMPARE_STRING_FIELD(stxcomment);
|
2575
|
+
COMPARE_SCALAR_FIELD(transformed);
|
2576
|
+
COMPARE_SCALAR_FIELD(if_not_exists);
|
2577
|
+
|
2578
|
+
return true;
|
2579
|
+
}
|
2580
|
+
|
2581
|
+
static bool
|
2582
|
+
_equalStatsElem(const StatsElem *a, const StatsElem *b)
|
2583
|
+
{
|
2584
|
+
COMPARE_STRING_FIELD(name);
|
2585
|
+
COMPARE_NODE_FIELD(expr);
|
2586
|
+
|
2587
|
+
return true;
|
2588
|
+
}
|
2589
|
+
|
2590
|
+
static bool
|
2591
|
+
_equalAlterStatsStmt(const AlterStatsStmt *a, const AlterStatsStmt *b)
|
2592
|
+
{
|
2593
|
+
COMPARE_NODE_FIELD(defnames);
|
2594
|
+
COMPARE_NODE_FIELD(stxstattarget);
|
2595
|
+
COMPARE_SCALAR_FIELD(missing_ok);
|
2596
|
+
|
2597
|
+
return true;
|
2598
|
+
}
|
2599
|
+
|
2600
|
+
static bool
|
2601
|
+
_equalCreateFunctionStmt(const CreateFunctionStmt *a, const CreateFunctionStmt *b)
|
2602
|
+
{
|
2603
|
+
COMPARE_SCALAR_FIELD(is_procedure);
|
2604
|
+
COMPARE_SCALAR_FIELD(replace);
|
2605
|
+
COMPARE_NODE_FIELD(funcname);
|
2606
|
+
COMPARE_NODE_FIELD(parameters);
|
2607
|
+
COMPARE_NODE_FIELD(returnType);
|
2608
|
+
COMPARE_NODE_FIELD(options);
|
2609
|
+
COMPARE_NODE_FIELD(sql_body);
|
2610
|
+
|
2611
|
+
return true;
|
2612
|
+
}
|
2613
|
+
|
2614
|
+
static bool
|
2615
|
+
_equalFunctionParameter(const FunctionParameter *a, const FunctionParameter *b)
|
2616
|
+
{
|
2617
|
+
COMPARE_STRING_FIELD(name);
|
2618
|
+
COMPARE_NODE_FIELD(argType);
|
2619
|
+
COMPARE_SCALAR_FIELD(mode);
|
2620
|
+
COMPARE_NODE_FIELD(defexpr);
|
2621
|
+
|
2622
|
+
return true;
|
2623
|
+
}
|
2624
|
+
|
2625
|
+
static bool
|
2626
|
+
_equalAlterFunctionStmt(const AlterFunctionStmt *a, const AlterFunctionStmt *b)
|
2627
|
+
{
|
2628
|
+
COMPARE_SCALAR_FIELD(objtype);
|
2629
|
+
COMPARE_NODE_FIELD(func);
|
2630
|
+
COMPARE_NODE_FIELD(actions);
|
2631
|
+
|
2632
|
+
return true;
|
2633
|
+
}
|
2634
|
+
|
2635
|
+
static bool
|
2636
|
+
_equalDoStmt(const DoStmt *a, const DoStmt *b)
|
2637
|
+
{
|
2638
|
+
COMPARE_NODE_FIELD(args);
|
2639
|
+
|
2640
|
+
return true;
|
2641
|
+
}
|
2642
|
+
|
2643
|
+
static bool
|
2644
|
+
_equalCallStmt(const CallStmt *a, const CallStmt *b)
|
2645
|
+
{
|
2646
|
+
COMPARE_NODE_FIELD(funccall);
|
2647
|
+
COMPARE_NODE_FIELD(funcexpr);
|
2648
|
+
COMPARE_NODE_FIELD(outargs);
|
2649
|
+
|
2650
|
+
return true;
|
2651
|
+
}
|
2652
|
+
|
2653
|
+
static bool
|
2654
|
+
_equalRenameStmt(const RenameStmt *a, const RenameStmt *b)
|
2655
|
+
{
|
2656
|
+
COMPARE_SCALAR_FIELD(renameType);
|
2657
|
+
COMPARE_SCALAR_FIELD(relationType);
|
2658
|
+
COMPARE_NODE_FIELD(relation);
|
2659
|
+
COMPARE_NODE_FIELD(object);
|
2660
|
+
COMPARE_STRING_FIELD(subname);
|
2661
|
+
COMPARE_STRING_FIELD(newname);
|
2662
|
+
COMPARE_SCALAR_FIELD(behavior);
|
2663
|
+
COMPARE_SCALAR_FIELD(missing_ok);
|
2664
|
+
|
2665
|
+
return true;
|
2666
|
+
}
|
2667
|
+
|
2668
|
+
static bool
|
2669
|
+
_equalAlterObjectDependsStmt(const AlterObjectDependsStmt *a, const AlterObjectDependsStmt *b)
|
2670
|
+
{
|
2671
|
+
COMPARE_SCALAR_FIELD(objectType);
|
2672
|
+
COMPARE_NODE_FIELD(relation);
|
2673
|
+
COMPARE_NODE_FIELD(object);
|
2674
|
+
COMPARE_NODE_FIELD(extname);
|
2675
|
+
COMPARE_SCALAR_FIELD(remove);
|
2676
|
+
|
2677
|
+
return true;
|
2678
|
+
}
|
2679
|
+
|
2680
|
+
static bool
|
2681
|
+
_equalAlterObjectSchemaStmt(const AlterObjectSchemaStmt *a, const AlterObjectSchemaStmt *b)
|
2682
|
+
{
|
2683
|
+
COMPARE_SCALAR_FIELD(objectType);
|
2684
|
+
COMPARE_NODE_FIELD(relation);
|
2685
|
+
COMPARE_NODE_FIELD(object);
|
2686
|
+
COMPARE_STRING_FIELD(newschema);
|
2687
|
+
COMPARE_SCALAR_FIELD(missing_ok);
|
2688
|
+
|
2689
|
+
return true;
|
2690
|
+
}
|
2691
|
+
|
2692
|
+
static bool
|
2693
|
+
_equalAlterOwnerStmt(const AlterOwnerStmt *a, const AlterOwnerStmt *b)
|
2694
|
+
{
|
2695
|
+
COMPARE_SCALAR_FIELD(objectType);
|
2696
|
+
COMPARE_NODE_FIELD(relation);
|
2697
|
+
COMPARE_NODE_FIELD(object);
|
2698
|
+
COMPARE_NODE_FIELD(newowner);
|
2699
|
+
|
2700
|
+
return true;
|
2701
|
+
}
|
2702
|
+
|
2703
|
+
static bool
|
2704
|
+
_equalAlterOperatorStmt(const AlterOperatorStmt *a, const AlterOperatorStmt *b)
|
2705
|
+
{
|
2706
|
+
COMPARE_NODE_FIELD(opername);
|
2707
|
+
COMPARE_NODE_FIELD(options);
|
2708
|
+
|
2709
|
+
return true;
|
2710
|
+
}
|
2711
|
+
|
2712
|
+
static bool
|
2713
|
+
_equalAlterTypeStmt(const AlterTypeStmt *a, const AlterTypeStmt *b)
|
2714
|
+
{
|
2715
|
+
COMPARE_NODE_FIELD(typeName);
|
2716
|
+
COMPARE_NODE_FIELD(options);
|
2717
|
+
|
2718
|
+
return true;
|
2719
|
+
}
|
2720
|
+
|
2721
|
+
static bool
|
2722
|
+
_equalRuleStmt(const RuleStmt *a, const RuleStmt *b)
|
2723
|
+
{
|
2724
|
+
COMPARE_NODE_FIELD(relation);
|
2725
|
+
COMPARE_STRING_FIELD(rulename);
|
2726
|
+
COMPARE_NODE_FIELD(whereClause);
|
2727
|
+
COMPARE_SCALAR_FIELD(event);
|
2728
|
+
COMPARE_SCALAR_FIELD(instead);
|
2729
|
+
COMPARE_NODE_FIELD(actions);
|
2730
|
+
COMPARE_SCALAR_FIELD(replace);
|
2731
|
+
|
2732
|
+
return true;
|
2733
|
+
}
|
2734
|
+
|
2735
|
+
static bool
|
2736
|
+
_equalNotifyStmt(const NotifyStmt *a, const NotifyStmt *b)
|
2737
|
+
{
|
2738
|
+
COMPARE_STRING_FIELD(conditionname);
|
2739
|
+
COMPARE_STRING_FIELD(payload);
|
2740
|
+
|
2741
|
+
return true;
|
2742
|
+
}
|
2743
|
+
|
2744
|
+
static bool
|
2745
|
+
_equalListenStmt(const ListenStmt *a, const ListenStmt *b)
|
2746
|
+
{
|
2747
|
+
COMPARE_STRING_FIELD(conditionname);
|
2748
|
+
|
2749
|
+
return true;
|
2750
|
+
}
|
2751
|
+
|
2752
|
+
static bool
|
2753
|
+
_equalUnlistenStmt(const UnlistenStmt *a, const UnlistenStmt *b)
|
2754
|
+
{
|
2755
|
+
COMPARE_STRING_FIELD(conditionname);
|
2756
|
+
|
2757
|
+
return true;
|
2758
|
+
}
|
2759
|
+
|
2760
|
+
static bool
|
2761
|
+
_equalTransactionStmt(const TransactionStmt *a, const TransactionStmt *b)
|
2762
|
+
{
|
2763
|
+
COMPARE_SCALAR_FIELD(kind);
|
2764
|
+
COMPARE_NODE_FIELD(options);
|
2765
|
+
COMPARE_STRING_FIELD(savepoint_name);
|
2766
|
+
COMPARE_STRING_FIELD(gid);
|
2767
|
+
COMPARE_SCALAR_FIELD(chain);
|
2768
|
+
COMPARE_LOCATION_FIELD(location);
|
2769
|
+
|
2770
|
+
return true;
|
2771
|
+
}
|
2772
|
+
|
2773
|
+
static bool
|
2774
|
+
_equalCompositeTypeStmt(const CompositeTypeStmt *a, const CompositeTypeStmt *b)
|
2775
|
+
{
|
2776
|
+
COMPARE_NODE_FIELD(typevar);
|
2777
|
+
COMPARE_NODE_FIELD(coldeflist);
|
2778
|
+
|
2779
|
+
return true;
|
2780
|
+
}
|
2781
|
+
|
2782
|
+
static bool
|
2783
|
+
_equalCreateEnumStmt(const CreateEnumStmt *a, const CreateEnumStmt *b)
|
2784
|
+
{
|
2785
|
+
COMPARE_NODE_FIELD(typeName);
|
2786
|
+
COMPARE_NODE_FIELD(vals);
|
2787
|
+
|
2788
|
+
return true;
|
2789
|
+
}
|
2790
|
+
|
2791
|
+
static bool
|
2792
|
+
_equalCreateRangeStmt(const CreateRangeStmt *a, const CreateRangeStmt *b)
|
2793
|
+
{
|
2794
|
+
COMPARE_NODE_FIELD(typeName);
|
2795
|
+
COMPARE_NODE_FIELD(params);
|
2796
|
+
|
2797
|
+
return true;
|
2798
|
+
}
|
2799
|
+
|
2800
|
+
static bool
|
2801
|
+
_equalAlterEnumStmt(const AlterEnumStmt *a, const AlterEnumStmt *b)
|
2802
|
+
{
|
2803
|
+
COMPARE_NODE_FIELD(typeName);
|
2804
|
+
COMPARE_STRING_FIELD(oldVal);
|
2805
|
+
COMPARE_STRING_FIELD(newVal);
|
2806
|
+
COMPARE_STRING_FIELD(newValNeighbor);
|
2807
|
+
COMPARE_SCALAR_FIELD(newValIsAfter);
|
2808
|
+
COMPARE_SCALAR_FIELD(skipIfNewValExists);
|
2809
|
+
|
2810
|
+
return true;
|
2811
|
+
}
|
2812
|
+
|
2813
|
+
static bool
|
2814
|
+
_equalViewStmt(const ViewStmt *a, const ViewStmt *b)
|
2815
|
+
{
|
2816
|
+
COMPARE_NODE_FIELD(view);
|
2817
|
+
COMPARE_NODE_FIELD(aliases);
|
2818
|
+
COMPARE_NODE_FIELD(query);
|
2819
|
+
COMPARE_SCALAR_FIELD(replace);
|
2820
|
+
COMPARE_NODE_FIELD(options);
|
2821
|
+
COMPARE_SCALAR_FIELD(withCheckOption);
|
2822
|
+
|
2823
|
+
return true;
|
2824
|
+
}
|
2825
|
+
|
2826
|
+
static bool
|
2827
|
+
_equalLoadStmt(const LoadStmt *a, const LoadStmt *b)
|
2828
|
+
{
|
2829
|
+
COMPARE_STRING_FIELD(filename);
|
2830
|
+
|
2831
|
+
return true;
|
2832
|
+
}
|
2833
|
+
|
2834
|
+
static bool
|
2835
|
+
_equalCreatedbStmt(const CreatedbStmt *a, const CreatedbStmt *b)
|
2836
|
+
{
|
2837
|
+
COMPARE_STRING_FIELD(dbname);
|
2838
|
+
COMPARE_NODE_FIELD(options);
|
2839
|
+
|
2840
|
+
return true;
|
2841
|
+
}
|
2842
|
+
|
2843
|
+
static bool
|
2844
|
+
_equalAlterDatabaseStmt(const AlterDatabaseStmt *a, const AlterDatabaseStmt *b)
|
2845
|
+
{
|
2846
|
+
COMPARE_STRING_FIELD(dbname);
|
2847
|
+
COMPARE_NODE_FIELD(options);
|
2848
|
+
|
2849
|
+
return true;
|
2850
|
+
}
|
2851
|
+
|
2852
|
+
static bool
|
2853
|
+
_equalAlterDatabaseRefreshCollStmt(const AlterDatabaseRefreshCollStmt *a, const AlterDatabaseRefreshCollStmt *b)
|
2854
|
+
{
|
2855
|
+
COMPARE_STRING_FIELD(dbname);
|
2856
|
+
|
2857
|
+
return true;
|
2858
|
+
}
|
2859
|
+
|
2860
|
+
static bool
|
2861
|
+
_equalAlterDatabaseSetStmt(const AlterDatabaseSetStmt *a, const AlterDatabaseSetStmt *b)
|
2862
|
+
{
|
2863
|
+
COMPARE_STRING_FIELD(dbname);
|
2864
|
+
COMPARE_NODE_FIELD(setstmt);
|
2865
|
+
|
2866
|
+
return true;
|
2867
|
+
}
|
2868
|
+
|
2869
|
+
static bool
|
2870
|
+
_equalDropdbStmt(const DropdbStmt *a, const DropdbStmt *b)
|
2871
|
+
{
|
2872
|
+
COMPARE_STRING_FIELD(dbname);
|
2873
|
+
COMPARE_SCALAR_FIELD(missing_ok);
|
2874
|
+
COMPARE_NODE_FIELD(options);
|
2875
|
+
|
2876
|
+
return true;
|
2877
|
+
}
|
2878
|
+
|
2879
|
+
static bool
|
2880
|
+
_equalAlterSystemStmt(const AlterSystemStmt *a, const AlterSystemStmt *b)
|
2881
|
+
{
|
2882
|
+
COMPARE_NODE_FIELD(setstmt);
|
2883
|
+
|
2884
|
+
return true;
|
2885
|
+
}
|
2886
|
+
|
2887
|
+
static bool
|
2888
|
+
_equalClusterStmt(const ClusterStmt *a, const ClusterStmt *b)
|
2889
|
+
{
|
2890
|
+
COMPARE_NODE_FIELD(relation);
|
2891
|
+
COMPARE_STRING_FIELD(indexname);
|
2892
|
+
COMPARE_NODE_FIELD(params);
|
2893
|
+
|
2894
|
+
return true;
|
2895
|
+
}
|
2896
|
+
|
2897
|
+
static bool
|
2898
|
+
_equalVacuumStmt(const VacuumStmt *a, const VacuumStmt *b)
|
2899
|
+
{
|
2900
|
+
COMPARE_NODE_FIELD(options);
|
2901
|
+
COMPARE_NODE_FIELD(rels);
|
2902
|
+
COMPARE_SCALAR_FIELD(is_vacuumcmd);
|
2903
|
+
|
2904
|
+
return true;
|
2905
|
+
}
|
2906
|
+
|
2907
|
+
static bool
|
2908
|
+
_equalVacuumRelation(const VacuumRelation *a, const VacuumRelation *b)
|
2909
|
+
{
|
2910
|
+
COMPARE_NODE_FIELD(relation);
|
2911
|
+
COMPARE_SCALAR_FIELD(oid);
|
2912
|
+
COMPARE_NODE_FIELD(va_cols);
|
2913
|
+
|
2914
|
+
return true;
|
2915
|
+
}
|
2916
|
+
|
2917
|
+
static bool
|
2918
|
+
_equalExplainStmt(const ExplainStmt *a, const ExplainStmt *b)
|
2919
|
+
{
|
2920
|
+
COMPARE_NODE_FIELD(query);
|
2921
|
+
COMPARE_NODE_FIELD(options);
|
2922
|
+
|
2923
|
+
return true;
|
2924
|
+
}
|
2925
|
+
|
2926
|
+
static bool
|
2927
|
+
_equalCreateTableAsStmt(const CreateTableAsStmt *a, const CreateTableAsStmt *b)
|
2928
|
+
{
|
2929
|
+
COMPARE_NODE_FIELD(query);
|
2930
|
+
COMPARE_NODE_FIELD(into);
|
2931
|
+
COMPARE_SCALAR_FIELD(objtype);
|
2932
|
+
COMPARE_SCALAR_FIELD(is_select_into);
|
2933
|
+
COMPARE_SCALAR_FIELD(if_not_exists);
|
2934
|
+
|
2935
|
+
return true;
|
2936
|
+
}
|
2937
|
+
|
2938
|
+
static bool
|
2939
|
+
_equalRefreshMatViewStmt(const RefreshMatViewStmt *a, const RefreshMatViewStmt *b)
|
2940
|
+
{
|
2941
|
+
COMPARE_SCALAR_FIELD(concurrent);
|
2942
|
+
COMPARE_SCALAR_FIELD(skipData);
|
2943
|
+
COMPARE_NODE_FIELD(relation);
|
2944
|
+
|
2945
|
+
return true;
|
2946
|
+
}
|
2947
|
+
|
2948
|
+
static bool
|
2949
|
+
_equalCheckPointStmt(const CheckPointStmt *a, const CheckPointStmt *b)
|
2950
|
+
{
|
2951
|
+
|
2952
|
+
return true;
|
2953
|
+
}
|
2954
|
+
|
2955
|
+
static bool
|
2956
|
+
_equalDiscardStmt(const DiscardStmt *a, const DiscardStmt *b)
|
2957
|
+
{
|
2958
|
+
COMPARE_SCALAR_FIELD(target);
|
2959
|
+
|
2960
|
+
return true;
|
2961
|
+
}
|
2962
|
+
|
2963
|
+
static bool
|
2964
|
+
_equalLockStmt(const LockStmt *a, const LockStmt *b)
|
2965
|
+
{
|
2966
|
+
COMPARE_NODE_FIELD(relations);
|
2967
|
+
COMPARE_SCALAR_FIELD(mode);
|
2968
|
+
COMPARE_SCALAR_FIELD(nowait);
|
2969
|
+
|
2970
|
+
return true;
|
2971
|
+
}
|
2972
|
+
|
2973
|
+
static bool
|
2974
|
+
_equalConstraintsSetStmt(const ConstraintsSetStmt *a, const ConstraintsSetStmt *b)
|
2975
|
+
{
|
2976
|
+
COMPARE_NODE_FIELD(constraints);
|
2977
|
+
COMPARE_SCALAR_FIELD(deferred);
|
2978
|
+
|
2979
|
+
return true;
|
2980
|
+
}
|
2981
|
+
|
2982
|
+
static bool
|
2983
|
+
_equalReindexStmt(const ReindexStmt *a, const ReindexStmt *b)
|
2984
|
+
{
|
2985
|
+
COMPARE_SCALAR_FIELD(kind);
|
2986
|
+
COMPARE_NODE_FIELD(relation);
|
2987
|
+
COMPARE_STRING_FIELD(name);
|
2988
|
+
COMPARE_NODE_FIELD(params);
|
2989
|
+
|
2990
|
+
return true;
|
2991
|
+
}
|
2992
|
+
|
2993
|
+
static bool
|
2994
|
+
_equalCreateConversionStmt(const CreateConversionStmt *a, const CreateConversionStmt *b)
|
2995
|
+
{
|
2996
|
+
COMPARE_NODE_FIELD(conversion_name);
|
2997
|
+
COMPARE_STRING_FIELD(for_encoding_name);
|
2998
|
+
COMPARE_STRING_FIELD(to_encoding_name);
|
2999
|
+
COMPARE_NODE_FIELD(func_name);
|
3000
|
+
COMPARE_SCALAR_FIELD(def);
|
3001
|
+
|
3002
|
+
return true;
|
3003
|
+
}
|
3004
|
+
|
3005
|
+
static bool
|
3006
|
+
_equalCreateCastStmt(const CreateCastStmt *a, const CreateCastStmt *b)
|
3007
|
+
{
|
3008
|
+
COMPARE_NODE_FIELD(sourcetype);
|
3009
|
+
COMPARE_NODE_FIELD(targettype);
|
3010
|
+
COMPARE_NODE_FIELD(func);
|
3011
|
+
COMPARE_SCALAR_FIELD(context);
|
3012
|
+
COMPARE_SCALAR_FIELD(inout);
|
3013
|
+
|
3014
|
+
return true;
|
3015
|
+
}
|
3016
|
+
|
3017
|
+
static bool
|
3018
|
+
_equalCreateTransformStmt(const CreateTransformStmt *a, const CreateTransformStmt *b)
|
3019
|
+
{
|
3020
|
+
COMPARE_SCALAR_FIELD(replace);
|
3021
|
+
COMPARE_NODE_FIELD(type_name);
|
3022
|
+
COMPARE_STRING_FIELD(lang);
|
3023
|
+
COMPARE_NODE_FIELD(fromsql);
|
3024
|
+
COMPARE_NODE_FIELD(tosql);
|
3025
|
+
|
3026
|
+
return true;
|
3027
|
+
}
|
3028
|
+
|
3029
|
+
static bool
|
3030
|
+
_equalPrepareStmt(const PrepareStmt *a, const PrepareStmt *b)
|
3031
|
+
{
|
3032
|
+
COMPARE_STRING_FIELD(name);
|
3033
|
+
COMPARE_NODE_FIELD(argtypes);
|
3034
|
+
COMPARE_NODE_FIELD(query);
|
3035
|
+
|
3036
|
+
return true;
|
3037
|
+
}
|
3038
|
+
|
3039
|
+
static bool
|
3040
|
+
_equalExecuteStmt(const ExecuteStmt *a, const ExecuteStmt *b)
|
3041
|
+
{
|
3042
|
+
COMPARE_STRING_FIELD(name);
|
3043
|
+
COMPARE_NODE_FIELD(params);
|
3044
|
+
|
3045
|
+
return true;
|
3046
|
+
}
|
3047
|
+
|
3048
|
+
static bool
|
3049
|
+
_equalDeallocateStmt(const DeallocateStmt *a, const DeallocateStmt *b)
|
3050
|
+
{
|
3051
|
+
COMPARE_STRING_FIELD(name);
|
3052
|
+
COMPARE_SCALAR_FIELD(isall);
|
3053
|
+
COMPARE_LOCATION_FIELD(location);
|
3054
|
+
|
3055
|
+
return true;
|
3056
|
+
}
|
3057
|
+
|
3058
|
+
static bool
|
3059
|
+
_equalDropOwnedStmt(const DropOwnedStmt *a, const DropOwnedStmt *b)
|
3060
|
+
{
|
3061
|
+
COMPARE_NODE_FIELD(roles);
|
3062
|
+
COMPARE_SCALAR_FIELD(behavior);
|
3063
|
+
|
3064
|
+
return true;
|
3065
|
+
}
|
3066
|
+
|
3067
|
+
static bool
|
3068
|
+
_equalReassignOwnedStmt(const ReassignOwnedStmt *a, const ReassignOwnedStmt *b)
|
3069
|
+
{
|
3070
|
+
COMPARE_NODE_FIELD(roles);
|
3071
|
+
COMPARE_NODE_FIELD(newrole);
|
3072
|
+
|
3073
|
+
return true;
|
3074
|
+
}
|
3075
|
+
|
3076
|
+
static bool
|
3077
|
+
_equalAlterTSDictionaryStmt(const AlterTSDictionaryStmt *a, const AlterTSDictionaryStmt *b)
|
3078
|
+
{
|
3079
|
+
COMPARE_NODE_FIELD(dictname);
|
3080
|
+
COMPARE_NODE_FIELD(options);
|
3081
|
+
|
3082
|
+
return true;
|
3083
|
+
}
|
3084
|
+
|
3085
|
+
static bool
|
3086
|
+
_equalAlterTSConfigurationStmt(const AlterTSConfigurationStmt *a, const AlterTSConfigurationStmt *b)
|
3087
|
+
{
|
3088
|
+
COMPARE_SCALAR_FIELD(kind);
|
3089
|
+
COMPARE_NODE_FIELD(cfgname);
|
3090
|
+
COMPARE_NODE_FIELD(tokentype);
|
3091
|
+
COMPARE_NODE_FIELD(dicts);
|
3092
|
+
COMPARE_SCALAR_FIELD(override);
|
3093
|
+
COMPARE_SCALAR_FIELD(replace);
|
3094
|
+
COMPARE_SCALAR_FIELD(missing_ok);
|
3095
|
+
|
3096
|
+
return true;
|
3097
|
+
}
|
3098
|
+
|
3099
|
+
static bool
|
3100
|
+
_equalPublicationTable(const PublicationTable *a, const PublicationTable *b)
|
3101
|
+
{
|
3102
|
+
COMPARE_NODE_FIELD(relation);
|
3103
|
+
COMPARE_NODE_FIELD(whereClause);
|
3104
|
+
COMPARE_NODE_FIELD(columns);
|
3105
|
+
|
3106
|
+
return true;
|
3107
|
+
}
|
3108
|
+
|
3109
|
+
static bool
|
3110
|
+
_equalPublicationObjSpec(const PublicationObjSpec *a, const PublicationObjSpec *b)
|
3111
|
+
{
|
3112
|
+
COMPARE_SCALAR_FIELD(pubobjtype);
|
3113
|
+
COMPARE_STRING_FIELD(name);
|
3114
|
+
COMPARE_NODE_FIELD(pubtable);
|
3115
|
+
COMPARE_LOCATION_FIELD(location);
|
3116
|
+
|
3117
|
+
return true;
|
3118
|
+
}
|
3119
|
+
|
3120
|
+
static bool
|
3121
|
+
_equalCreatePublicationStmt(const CreatePublicationStmt *a, const CreatePublicationStmt *b)
|
3122
|
+
{
|
3123
|
+
COMPARE_STRING_FIELD(pubname);
|
3124
|
+
COMPARE_NODE_FIELD(options);
|
3125
|
+
COMPARE_NODE_FIELD(pubobjects);
|
3126
|
+
COMPARE_SCALAR_FIELD(for_all_tables);
|
3127
|
+
|
3128
|
+
return true;
|
3129
|
+
}
|
3130
|
+
|
3131
|
+
static bool
|
3132
|
+
_equalAlterPublicationStmt(const AlterPublicationStmt *a, const AlterPublicationStmt *b)
|
3133
|
+
{
|
3134
|
+
COMPARE_STRING_FIELD(pubname);
|
3135
|
+
COMPARE_NODE_FIELD(options);
|
3136
|
+
COMPARE_NODE_FIELD(pubobjects);
|
3137
|
+
COMPARE_SCALAR_FIELD(for_all_tables);
|
3138
|
+
COMPARE_SCALAR_FIELD(action);
|
3139
|
+
|
3140
|
+
return true;
|
3141
|
+
}
|
3142
|
+
|
3143
|
+
static bool
|
3144
|
+
_equalCreateSubscriptionStmt(const CreateSubscriptionStmt *a, const CreateSubscriptionStmt *b)
|
3145
|
+
{
|
3146
|
+
COMPARE_STRING_FIELD(subname);
|
3147
|
+
COMPARE_STRING_FIELD(conninfo);
|
3148
|
+
COMPARE_NODE_FIELD(publication);
|
3149
|
+
COMPARE_NODE_FIELD(options);
|
3150
|
+
|
3151
|
+
return true;
|
3152
|
+
}
|
3153
|
+
|
3154
|
+
static bool
|
3155
|
+
_equalAlterSubscriptionStmt(const AlterSubscriptionStmt *a, const AlterSubscriptionStmt *b)
|
3156
|
+
{
|
3157
|
+
COMPARE_SCALAR_FIELD(kind);
|
3158
|
+
COMPARE_STRING_FIELD(subname);
|
3159
|
+
COMPARE_STRING_FIELD(conninfo);
|
3160
|
+
COMPARE_NODE_FIELD(publication);
|
3161
|
+
COMPARE_NODE_FIELD(options);
|
3162
|
+
|
3163
|
+
return true;
|
3164
|
+
}
|
3165
|
+
|
3166
|
+
static bool
|
3167
|
+
_equalDropSubscriptionStmt(const DropSubscriptionStmt *a, const DropSubscriptionStmt *b)
|
3168
|
+
{
|
3169
|
+
COMPARE_STRING_FIELD(subname);
|
3170
|
+
COMPARE_SCALAR_FIELD(missing_ok);
|
3171
|
+
COMPARE_SCALAR_FIELD(behavior);
|
3172
|
+
|
3173
|
+
return true;
|
3174
|
+
}
|
3175
|
+
|
3176
|
+
static bool
|
3177
|
+
_equalPathKey(const PathKey *a, const PathKey *b)
|
3178
|
+
{
|
3179
|
+
COMPARE_SCALAR_FIELD(pk_eclass);
|
3180
|
+
COMPARE_SCALAR_FIELD(pk_opfamily);
|
3181
|
+
COMPARE_SCALAR_FIELD(pk_strategy);
|
3182
|
+
COMPARE_SCALAR_FIELD(pk_nulls_first);
|
3183
|
+
|
3184
|
+
return true;
|
3185
|
+
}
|
3186
|
+
|
3187
|
+
static bool
|
3188
|
+
_equalGroupByOrdering(const GroupByOrdering *a, const GroupByOrdering *b)
|
3189
|
+
{
|
3190
|
+
COMPARE_NODE_FIELD(pathkeys);
|
3191
|
+
COMPARE_NODE_FIELD(clauses);
|
3192
|
+
|
3193
|
+
return true;
|
3194
|
+
}
|
3195
|
+
|
3196
|
+
static bool
|
3197
|
+
_equalRestrictInfo(const RestrictInfo *a, const RestrictInfo *b)
|
3198
|
+
{
|
3199
|
+
COMPARE_NODE_FIELD(clause);
|
3200
|
+
COMPARE_SCALAR_FIELD(is_pushed_down);
|
3201
|
+
COMPARE_SCALAR_FIELD(has_clone);
|
3202
|
+
COMPARE_SCALAR_FIELD(is_clone);
|
3203
|
+
COMPARE_SCALAR_FIELD(security_level);
|
3204
|
+
COMPARE_BITMAPSET_FIELD(required_relids);
|
3205
|
+
COMPARE_BITMAPSET_FIELD(incompatible_relids);
|
3206
|
+
COMPARE_BITMAPSET_FIELD(outer_relids);
|
3207
|
+
COMPARE_SCALAR_FIELD(rinfo_serial);
|
3208
|
+
|
3209
|
+
return true;
|
3210
|
+
}
|
3211
|
+
|
3212
|
+
static bool
|
3213
|
+
_equalPlaceHolderVar(const PlaceHolderVar *a, const PlaceHolderVar *b)
|
3214
|
+
{
|
3215
|
+
COMPARE_BITMAPSET_FIELD(phnullingrels);
|
3216
|
+
COMPARE_SCALAR_FIELD(phid);
|
3217
|
+
COMPARE_SCALAR_FIELD(phlevelsup);
|
3218
|
+
|
3219
|
+
return true;
|
3220
|
+
}
|
3221
|
+
|
3222
|
+
static bool
|
3223
|
+
_equalSpecialJoinInfo(const SpecialJoinInfo *a, const SpecialJoinInfo *b)
|
3224
|
+
{
|
3225
|
+
COMPARE_BITMAPSET_FIELD(min_lefthand);
|
3226
|
+
COMPARE_BITMAPSET_FIELD(min_righthand);
|
3227
|
+
COMPARE_BITMAPSET_FIELD(syn_lefthand);
|
3228
|
+
COMPARE_BITMAPSET_FIELD(syn_righthand);
|
3229
|
+
COMPARE_SCALAR_FIELD(jointype);
|
3230
|
+
COMPARE_SCALAR_FIELD(ojrelid);
|
3231
|
+
COMPARE_BITMAPSET_FIELD(commute_above_l);
|
3232
|
+
COMPARE_BITMAPSET_FIELD(commute_above_r);
|
3233
|
+
COMPARE_BITMAPSET_FIELD(commute_below_l);
|
3234
|
+
COMPARE_BITMAPSET_FIELD(commute_below_r);
|
3235
|
+
COMPARE_SCALAR_FIELD(lhs_strict);
|
3236
|
+
COMPARE_SCALAR_FIELD(semi_can_btree);
|
3237
|
+
COMPARE_SCALAR_FIELD(semi_can_hash);
|
3238
|
+
COMPARE_NODE_FIELD(semi_operators);
|
3239
|
+
COMPARE_NODE_FIELD(semi_rhs_exprs);
|
3240
|
+
|
3241
|
+
return true;
|
3242
|
+
}
|
3243
|
+
|
3244
|
+
static bool
|
3245
|
+
_equalAppendRelInfo(const AppendRelInfo *a, const AppendRelInfo *b)
|
3246
|
+
{
|
3247
|
+
COMPARE_SCALAR_FIELD(parent_relid);
|
3248
|
+
COMPARE_SCALAR_FIELD(child_relid);
|
3249
|
+
COMPARE_SCALAR_FIELD(parent_reltype);
|
3250
|
+
COMPARE_SCALAR_FIELD(child_reltype);
|
3251
|
+
COMPARE_NODE_FIELD(translated_vars);
|
3252
|
+
COMPARE_SCALAR_FIELD(num_child_cols);
|
3253
|
+
COMPARE_POINTER_FIELD(parent_colnos, a->num_child_cols * sizeof(AttrNumber));
|
3254
|
+
COMPARE_SCALAR_FIELD(parent_reloid);
|
3255
|
+
|
3256
|
+
return true;
|
3257
|
+
}
|
3258
|
+
|
3259
|
+
static bool
|
3260
|
+
_equalPlaceHolderInfo(const PlaceHolderInfo *a, const PlaceHolderInfo *b)
|
3261
|
+
{
|
3262
|
+
COMPARE_SCALAR_FIELD(phid);
|
3263
|
+
COMPARE_NODE_FIELD(ph_var);
|
3264
|
+
COMPARE_BITMAPSET_FIELD(ph_eval_at);
|
3265
|
+
COMPARE_BITMAPSET_FIELD(ph_lateral);
|
3266
|
+
COMPARE_BITMAPSET_FIELD(ph_needed);
|
3267
|
+
COMPARE_SCALAR_FIELD(ph_width);
|
3268
|
+
|
3269
|
+
return true;
|
3270
|
+
}
|
3271
|
+
|
3272
|
+
static bool
|
3273
|
+
_equalInteger(const Integer *a, const Integer *b)
|
3274
|
+
{
|
3275
|
+
COMPARE_SCALAR_FIELD(ival);
|
3276
|
+
|
3277
|
+
return true;
|
3278
|
+
}
|
3279
|
+
|
3280
|
+
static bool
|
3281
|
+
_equalFloat(const Float *a, const Float *b)
|
3282
|
+
{
|
3283
|
+
COMPARE_STRING_FIELD(fval);
|
3284
|
+
|
3285
|
+
return true;
|
3286
|
+
}
|
3287
|
+
|
3288
|
+
static bool
|
3289
|
+
_equalBoolean(const Boolean *a, const Boolean *b)
|
3290
|
+
{
|
3291
|
+
COMPARE_SCALAR_FIELD(boolval);
|
3292
|
+
|
3293
|
+
return true;
|
3294
|
+
}
|
3295
|
+
|
3296
|
+
static bool
|
3297
|
+
_equalString(const String *a, const String *b)
|
3298
|
+
{
|
3299
|
+
COMPARE_STRING_FIELD(sval);
|
3300
|
+
|
3301
|
+
return true;
|
3302
|
+
}
|
3303
|
+
|
3304
|
+
static bool
|
3305
|
+
_equalBitString(const BitString *a, const BitString *b)
|
3306
|
+
{
|
3307
|
+
COMPARE_STRING_FIELD(bsval);
|
3308
|
+
|
3309
|
+
return true;
|
3310
|
+
}
|