Line data Source code
1 : /*-------------------------------------------------------------------------
2 : *
3 : * equalfuncs.funcs.c
4 : * Generated node infrastructure code
5 : *
6 : * Portions Copyright (c) 1996-2023, 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 2045462 : _equalAlias(const Alias *a, const Alias *b)
43 : {
44 2045462 : COMPARE_STRING_FIELD(aliasname);
45 2045462 : COMPARE_NODE_FIELD(colnames);
46 :
47 2045462 : return true;
48 : }
49 :
50 : static bool
51 1343798 : _equalRangeVar(const RangeVar *a, const RangeVar *b)
52 : {
53 1343798 : COMPARE_STRING_FIELD(catalogname);
54 1343798 : COMPARE_STRING_FIELD(schemaname);
55 1343762 : COMPARE_STRING_FIELD(relname);
56 1342958 : COMPARE_SCALAR_FIELD(inh);
57 1342958 : COMPARE_SCALAR_FIELD(relpersistence);
58 1342958 : COMPARE_NODE_FIELD(alias);
59 : COMPARE_LOCATION_FIELD(location);
60 :
61 1342958 : return true;
62 : }
63 :
64 : static bool
65 408 : _equalTableFunc(const TableFunc *a, const TableFunc *b)
66 : {
67 408 : COMPARE_NODE_FIELD(ns_uris);
68 408 : COMPARE_NODE_FIELD(ns_names);
69 408 : COMPARE_NODE_FIELD(docexpr);
70 408 : COMPARE_NODE_FIELD(rowexpr);
71 408 : COMPARE_NODE_FIELD(colnames);
72 408 : COMPARE_NODE_FIELD(coltypes);
73 408 : COMPARE_NODE_FIELD(coltypmods);
74 408 : COMPARE_NODE_FIELD(colcollations);
75 408 : COMPARE_NODE_FIELD(colexprs);
76 408 : COMPARE_NODE_FIELD(coldefexprs);
77 408 : COMPARE_BITMAPSET_FIELD(notnulls);
78 408 : COMPARE_SCALAR_FIELD(ordinalitycol);
79 : COMPARE_LOCATION_FIELD(location);
80 :
81 408 : return true;
82 : }
83 :
84 : static bool
85 7372 : _equalIntoClause(const IntoClause *a, const IntoClause *b)
86 : {
87 7372 : COMPARE_NODE_FIELD(rel);
88 7372 : COMPARE_NODE_FIELD(colNames);
89 7372 : COMPARE_STRING_FIELD(accessMethod);
90 7372 : COMPARE_NODE_FIELD(options);
91 7372 : COMPARE_SCALAR_FIELD(onCommit);
92 7372 : COMPARE_STRING_FIELD(tableSpaceName);
93 7372 : COMPARE_NODE_FIELD(viewQuery);
94 7372 : COMPARE_SCALAR_FIELD(skipData);
95 :
96 7372 : return true;
97 : }
98 :
99 : static bool
100 12849158 : _equalVar(const Var *a, const Var *b)
101 : {
102 12849158 : COMPARE_SCALAR_FIELD(varno);
103 10807770 : COMPARE_SCALAR_FIELD(varattno);
104 9924564 : COMPARE_SCALAR_FIELD(vartype);
105 9924564 : COMPARE_SCALAR_FIELD(vartypmod);
106 9924564 : COMPARE_SCALAR_FIELD(varcollid);
107 9924564 : COMPARE_BITMAPSET_FIELD(varnullingrels);
108 9910304 : COMPARE_SCALAR_FIELD(varlevelsup);
109 : COMPARE_LOCATION_FIELD(location);
110 :
111 9910298 : return true;
112 : }
113 :
114 : static bool
115 283880 : _equalParam(const Param *a, const Param *b)
116 : {
117 283880 : COMPARE_SCALAR_FIELD(paramkind);
118 281216 : COMPARE_SCALAR_FIELD(paramid);
119 270792 : COMPARE_SCALAR_FIELD(paramtype);
120 270792 : COMPARE_SCALAR_FIELD(paramtypmod);
121 270792 : COMPARE_SCALAR_FIELD(paramcollid);
122 : COMPARE_LOCATION_FIELD(location);
123 :
124 270792 : return true;
125 : }
126 :
127 : static bool
128 91564 : _equalAggref(const Aggref *a, const Aggref *b)
129 : {
130 91564 : COMPARE_SCALAR_FIELD(aggfnoid);
131 83006 : COMPARE_SCALAR_FIELD(aggtype);
132 82494 : COMPARE_SCALAR_FIELD(aggcollid);
133 82494 : COMPARE_SCALAR_FIELD(inputcollid);
134 82494 : COMPARE_NODE_FIELD(aggargtypes);
135 82494 : COMPARE_NODE_FIELD(aggdirectargs);
136 82494 : COMPARE_NODE_FIELD(args);
137 80902 : COMPARE_NODE_FIELD(aggorder);
138 80902 : COMPARE_NODE_FIELD(aggdistinct);
139 80902 : COMPARE_NODE_FIELD(aggfilter);
140 80884 : COMPARE_SCALAR_FIELD(aggstar);
141 80884 : COMPARE_SCALAR_FIELD(aggvariadic);
142 80884 : COMPARE_SCALAR_FIELD(aggkind);
143 80884 : COMPARE_SCALAR_FIELD(agglevelsup);
144 80884 : COMPARE_SCALAR_FIELD(aggsplit);
145 80848 : COMPARE_SCALAR_FIELD(aggno);
146 80848 : COMPARE_SCALAR_FIELD(aggtransno);
147 : COMPARE_LOCATION_FIELD(location);
148 :
149 80848 : return true;
150 : }
151 :
152 : static bool
153 1340 : _equalGroupingFunc(const GroupingFunc *a, const GroupingFunc *b)
154 : {
155 1340 : COMPARE_NODE_FIELD(args);
156 1340 : COMPARE_SCALAR_FIELD(agglevelsup);
157 : COMPARE_LOCATION_FIELD(location);
158 :
159 1340 : return true;
160 : }
161 :
162 : static bool
163 8568 : _equalWindowFunc(const WindowFunc *a, const WindowFunc *b)
164 : {
165 8568 : COMPARE_SCALAR_FIELD(winfnoid);
166 6714 : COMPARE_SCALAR_FIELD(wintype);
167 6714 : COMPARE_SCALAR_FIELD(wincollid);
168 6714 : COMPARE_SCALAR_FIELD(inputcollid);
169 6714 : COMPARE_NODE_FIELD(args);
170 6648 : COMPARE_NODE_FIELD(aggfilter);
171 6630 : COMPARE_SCALAR_FIELD(winref);
172 6582 : COMPARE_SCALAR_FIELD(winstar);
173 6582 : COMPARE_SCALAR_FIELD(winagg);
174 : COMPARE_LOCATION_FIELD(location);
175 :
176 6582 : return true;
177 : }
178 :
179 : static bool
180 18444 : _equalSubscriptingRef(const SubscriptingRef *a, const SubscriptingRef *b)
181 : {
182 18444 : COMPARE_SCALAR_FIELD(refcontainertype);
183 18444 : COMPARE_SCALAR_FIELD(refelemtype);
184 18444 : COMPARE_SCALAR_FIELD(refrestype);
185 18444 : COMPARE_SCALAR_FIELD(reftypmod);
186 18444 : COMPARE_SCALAR_FIELD(refcollid);
187 18444 : COMPARE_NODE_FIELD(refupperindexpr);
188 18336 : COMPARE_NODE_FIELD(reflowerindexpr);
189 18336 : COMPARE_NODE_FIELD(refexpr);
190 18096 : COMPARE_NODE_FIELD(refassgnexpr);
191 :
192 18096 : return true;
193 : }
194 :
195 : static bool
196 669008 : _equalFuncExpr(const FuncExpr *a, const FuncExpr *b)
197 : {
198 669008 : COMPARE_SCALAR_FIELD(funcid);
199 667054 : COMPARE_SCALAR_FIELD(funcresulttype);
200 666910 : COMPARE_SCALAR_FIELD(funcretset);
201 666910 : COMPARE_SCALAR_FIELD(funcvariadic);
202 666910 : COMPARE_SCALAR_FIELD(funccollid);
203 666910 : COMPARE_SCALAR_FIELD(inputcollid);
204 666910 : COMPARE_NODE_FIELD(args);
205 : COMPARE_LOCATION_FIELD(location);
206 :
207 664604 : return true;
208 : }
209 :
210 : static bool
211 195040 : _equalNamedArgExpr(const NamedArgExpr *a, const NamedArgExpr *b)
212 : {
213 195040 : COMPARE_NODE_FIELD(arg);
214 195040 : COMPARE_STRING_FIELD(name);
215 195040 : COMPARE_SCALAR_FIELD(argnumber);
216 : COMPARE_LOCATION_FIELD(location);
217 :
218 195040 : return true;
219 : }
220 :
221 : static bool
222 1153038 : _equalOpExpr(const OpExpr *a, const OpExpr *b)
223 : {
224 1153038 : COMPARE_SCALAR_FIELD(opno);
225 1060778 : if (a->opfuncid != b->opfuncid && a->opfuncid != 0 && b->opfuncid != 0)
226 0 : return false;
227 1060778 : COMPARE_SCALAR_FIELD(opresulttype);
228 1060778 : COMPARE_SCALAR_FIELD(opretset);
229 1060778 : COMPARE_SCALAR_FIELD(opcollid);
230 1060778 : COMPARE_SCALAR_FIELD(inputcollid);
231 1060776 : COMPARE_NODE_FIELD(args);
232 : COMPARE_LOCATION_FIELD(location);
233 :
234 981658 : return true;
235 : }
236 :
237 : static bool
238 1492 : _equalDistinctExpr(const DistinctExpr *a, const DistinctExpr *b)
239 : {
240 1492 : COMPARE_SCALAR_FIELD(opno);
241 1492 : if (a->opfuncid != b->opfuncid && a->opfuncid != 0 && b->opfuncid != 0)
242 0 : return false;
243 1492 : COMPARE_SCALAR_FIELD(opresulttype);
244 1492 : COMPARE_SCALAR_FIELD(opretset);
245 1492 : COMPARE_SCALAR_FIELD(opcollid);
246 1492 : COMPARE_SCALAR_FIELD(inputcollid);
247 1492 : COMPARE_NODE_FIELD(args);
248 : COMPARE_LOCATION_FIELD(location);
249 :
250 1492 : return true;
251 : }
252 :
253 : static bool
254 266 : _equalNullIfExpr(const NullIfExpr *a, const NullIfExpr *b)
255 : {
256 266 : COMPARE_SCALAR_FIELD(opno);
257 266 : if (a->opfuncid != b->opfuncid && a->opfuncid != 0 && b->opfuncid != 0)
258 0 : return false;
259 266 : COMPARE_SCALAR_FIELD(opresulttype);
260 266 : COMPARE_SCALAR_FIELD(opretset);
261 266 : COMPARE_SCALAR_FIELD(opcollid);
262 266 : COMPARE_SCALAR_FIELD(inputcollid);
263 266 : COMPARE_NODE_FIELD(args);
264 : COMPARE_LOCATION_FIELD(location);
265 :
266 266 : return true;
267 : }
268 :
269 : static bool
270 49200 : _equalScalarArrayOpExpr(const ScalarArrayOpExpr *a, const ScalarArrayOpExpr *b)
271 : {
272 49200 : COMPARE_SCALAR_FIELD(opno);
273 48732 : if (a->opfuncid != b->opfuncid && a->opfuncid != 0 && b->opfuncid != 0)
274 0 : return false;
275 48732 : if (a->hashfuncid != b->hashfuncid && a->hashfuncid != 0 && b->hashfuncid != 0)
276 0 : return false;
277 48732 : if (a->negfuncid != b->negfuncid && a->negfuncid != 0 && b->negfuncid != 0)
278 0 : return false;
279 48732 : COMPARE_SCALAR_FIELD(useOr);
280 48732 : COMPARE_SCALAR_FIELD(inputcollid);
281 48732 : COMPARE_NODE_FIELD(args);
282 : COMPARE_LOCATION_FIELD(location);
283 :
284 48660 : return true;
285 : }
286 :
287 : static bool
288 496876 : _equalBoolExpr(const BoolExpr *a, const BoolExpr *b)
289 : {
290 496876 : COMPARE_SCALAR_FIELD(boolop);
291 496876 : COMPARE_NODE_FIELD(args);
292 : COMPARE_LOCATION_FIELD(location);
293 :
294 496674 : return true;
295 : }
296 :
297 : static bool
298 133862 : _equalSubLink(const SubLink *a, const SubLink *b)
299 : {
300 133862 : COMPARE_SCALAR_FIELD(subLinkType);
301 133862 : COMPARE_SCALAR_FIELD(subLinkId);
302 133862 : COMPARE_NODE_FIELD(testexpr);
303 133850 : COMPARE_NODE_FIELD(operName);
304 133850 : COMPARE_NODE_FIELD(subselect);
305 : COMPARE_LOCATION_FIELD(location);
306 :
307 133844 : return true;
308 : }
309 :
310 : static bool
311 216 : _equalSubPlan(const SubPlan *a, const SubPlan *b)
312 : {
313 216 : COMPARE_SCALAR_FIELD(subLinkType);
314 216 : COMPARE_NODE_FIELD(testexpr);
315 216 : COMPARE_NODE_FIELD(paramIds);
316 216 : COMPARE_SCALAR_FIELD(plan_id);
317 96 : COMPARE_STRING_FIELD(plan_name);
318 96 : COMPARE_SCALAR_FIELD(firstColType);
319 96 : COMPARE_SCALAR_FIELD(firstColTypmod);
320 96 : COMPARE_SCALAR_FIELD(firstColCollation);
321 96 : COMPARE_SCALAR_FIELD(useHashTable);
322 96 : COMPARE_SCALAR_FIELD(unknownEqFalse);
323 96 : COMPARE_SCALAR_FIELD(parallel_safe);
324 96 : COMPARE_NODE_FIELD(setParam);
325 96 : COMPARE_NODE_FIELD(parParam);
326 96 : COMPARE_NODE_FIELD(args);
327 96 : COMPARE_SCALAR_FIELD(startup_cost);
328 96 : COMPARE_SCALAR_FIELD(per_call_cost);
329 :
330 96 : return true;
331 : }
332 :
333 : static bool
334 0 : _equalAlternativeSubPlan(const AlternativeSubPlan *a, const AlternativeSubPlan *b)
335 : {
336 0 : COMPARE_NODE_FIELD(subplans);
337 :
338 0 : return true;
339 : }
340 :
341 : static bool
342 8166 : _equalFieldSelect(const FieldSelect *a, const FieldSelect *b)
343 : {
344 8166 : COMPARE_NODE_FIELD(arg);
345 8160 : COMPARE_SCALAR_FIELD(fieldnum);
346 8160 : COMPARE_SCALAR_FIELD(resulttype);
347 8160 : COMPARE_SCALAR_FIELD(resulttypmod);
348 8160 : COMPARE_SCALAR_FIELD(resultcollid);
349 :
350 8160 : return true;
351 : }
352 :
353 : static bool
354 572 : _equalFieldStore(const FieldStore *a, const FieldStore *b)
355 : {
356 572 : COMPARE_NODE_FIELD(arg);
357 572 : COMPARE_NODE_FIELD(newvals);
358 572 : COMPARE_NODE_FIELD(fieldnums);
359 572 : COMPARE_SCALAR_FIELD(resulttype);
360 :
361 572 : return true;
362 : }
363 :
364 : static bool
365 238882 : _equalRelabelType(const RelabelType *a, const RelabelType *b)
366 : {
367 238882 : COMPARE_NODE_FIELD(arg);
368 235786 : COMPARE_SCALAR_FIELD(resulttype);
369 235786 : COMPARE_SCALAR_FIELD(resulttypmod);
370 235786 : COMPARE_SCALAR_FIELD(resultcollid);
371 : COMPARE_LOCATION_FIELD(location);
372 :
373 235786 : return true;
374 : }
375 :
376 : static bool
377 43868 : _equalCoerceViaIO(const CoerceViaIO *a, const CoerceViaIO *b)
378 : {
379 43868 : COMPARE_NODE_FIELD(arg);
380 43794 : COMPARE_SCALAR_FIELD(resulttype);
381 43794 : COMPARE_SCALAR_FIELD(resultcollid);
382 : COMPARE_LOCATION_FIELD(location);
383 :
384 43794 : return true;
385 : }
386 :
387 : static bool
388 8380 : _equalArrayCoerceExpr(const ArrayCoerceExpr *a, const ArrayCoerceExpr *b)
389 : {
390 8380 : COMPARE_NODE_FIELD(arg);
391 8380 : COMPARE_NODE_FIELD(elemexpr);
392 8380 : COMPARE_SCALAR_FIELD(resulttype);
393 8380 : COMPARE_SCALAR_FIELD(resulttypmod);
394 8380 : COMPARE_SCALAR_FIELD(resultcollid);
395 : COMPARE_LOCATION_FIELD(location);
396 :
397 8380 : return true;
398 : }
399 :
400 : static bool
401 132 : _equalConvertRowtypeExpr(const ConvertRowtypeExpr *a, const ConvertRowtypeExpr *b)
402 : {
403 132 : COMPARE_NODE_FIELD(arg);
404 132 : COMPARE_SCALAR_FIELD(resulttype);
405 : COMPARE_LOCATION_FIELD(location);
406 :
407 132 : return true;
408 : }
409 :
410 : static bool
411 13406 : _equalCollateExpr(const CollateExpr *a, const CollateExpr *b)
412 : {
413 13406 : COMPARE_NODE_FIELD(arg);
414 13394 : COMPARE_SCALAR_FIELD(collOid);
415 : COMPARE_LOCATION_FIELD(location);
416 :
417 13394 : return true;
418 : }
419 :
420 : static bool
421 190490 : _equalCaseExpr(const CaseExpr *a, const CaseExpr *b)
422 : {
423 190490 : COMPARE_SCALAR_FIELD(casetype);
424 190490 : COMPARE_SCALAR_FIELD(casecollid);
425 190478 : COMPARE_NODE_FIELD(arg);
426 190448 : COMPARE_NODE_FIELD(args);
427 190372 : COMPARE_NODE_FIELD(defresult);
428 : COMPARE_LOCATION_FIELD(location);
429 :
430 190372 : return true;
431 : }
432 :
433 : static bool
434 333870 : _equalCaseWhen(const CaseWhen *a, const CaseWhen *b)
435 : {
436 333870 : COMPARE_NODE_FIELD(expr);
437 333794 : COMPARE_NODE_FIELD(result);
438 : COMPARE_LOCATION_FIELD(location);
439 :
440 333794 : return true;
441 : }
442 :
443 : static bool
444 37578 : _equalCaseTestExpr(const CaseTestExpr *a, const CaseTestExpr *b)
445 : {
446 37578 : COMPARE_SCALAR_FIELD(typeId);
447 37578 : COMPARE_SCALAR_FIELD(typeMod);
448 37578 : COMPARE_SCALAR_FIELD(collation);
449 :
450 37578 : return true;
451 : }
452 :
453 : static bool
454 41222 : _equalArrayExpr(const ArrayExpr *a, const ArrayExpr *b)
455 : {
456 41222 : COMPARE_SCALAR_FIELD(array_typeid);
457 41222 : COMPARE_SCALAR_FIELD(array_collid);
458 41222 : COMPARE_SCALAR_FIELD(element_typeid);
459 41222 : COMPARE_NODE_FIELD(elements);
460 41222 : COMPARE_SCALAR_FIELD(multidims);
461 : COMPARE_LOCATION_FIELD(location);
462 :
463 41222 : return true;
464 : }
465 :
466 : static bool
467 19460 : _equalRowExpr(const RowExpr *a, const RowExpr *b)
468 : {
469 19460 : COMPARE_NODE_FIELD(args);
470 19460 : COMPARE_SCALAR_FIELD(row_typeid);
471 19460 : COMPARE_NODE_FIELD(colnames);
472 : COMPARE_LOCATION_FIELD(location);
473 :
474 19460 : return true;
475 : }
476 :
477 : static bool
478 372 : _equalRowCompareExpr(const RowCompareExpr *a, const RowCompareExpr *b)
479 : {
480 372 : COMPARE_SCALAR_FIELD(rctype);
481 312 : COMPARE_NODE_FIELD(opnos);
482 312 : COMPARE_NODE_FIELD(opfamilies);
483 312 : COMPARE_NODE_FIELD(inputcollids);
484 312 : COMPARE_NODE_FIELD(largs);
485 312 : COMPARE_NODE_FIELD(rargs);
486 :
487 312 : return true;
488 : }
489 :
490 : static bool
491 13910 : _equalCoalesceExpr(const CoalesceExpr *a, const CoalesceExpr *b)
492 : {
493 13910 : COMPARE_SCALAR_FIELD(coalescetype);
494 13878 : COMPARE_SCALAR_FIELD(coalescecollid);
495 13878 : COMPARE_NODE_FIELD(args);
496 : COMPARE_LOCATION_FIELD(location);
497 :
498 12946 : return true;
499 : }
500 :
501 : static bool
502 962 : _equalMinMaxExpr(const MinMaxExpr *a, const MinMaxExpr *b)
503 : {
504 962 : COMPARE_SCALAR_FIELD(minmaxtype);
505 962 : COMPARE_SCALAR_FIELD(minmaxcollid);
506 962 : COMPARE_SCALAR_FIELD(inputcollid);
507 962 : COMPARE_SCALAR_FIELD(op);
508 962 : COMPARE_NODE_FIELD(args);
509 : COMPARE_LOCATION_FIELD(location);
510 :
511 962 : return true;
512 : }
513 :
514 : static bool
515 12012 : _equalSQLValueFunction(const SQLValueFunction *a, const SQLValueFunction *b)
516 : {
517 12012 : COMPARE_SCALAR_FIELD(op);
518 12012 : COMPARE_SCALAR_FIELD(type);
519 12012 : COMPARE_SCALAR_FIELD(typmod);
520 : COMPARE_LOCATION_FIELD(location);
521 :
522 12012 : return true;
523 : }
524 :
525 : static bool
526 2684 : _equalXmlExpr(const XmlExpr *a, const XmlExpr *b)
527 : {
528 2684 : COMPARE_SCALAR_FIELD(op);
529 2684 : COMPARE_STRING_FIELD(name);
530 2684 : COMPARE_NODE_FIELD(named_args);
531 2684 : COMPARE_NODE_FIELD(arg_names);
532 2684 : COMPARE_NODE_FIELD(args);
533 2684 : COMPARE_SCALAR_FIELD(xmloption);
534 2684 : COMPARE_SCALAR_FIELD(indent);
535 2684 : COMPARE_SCALAR_FIELD(type);
536 2684 : COMPARE_SCALAR_FIELD(typmod);
537 : COMPARE_LOCATION_FIELD(location);
538 :
539 2684 : return true;
540 : }
541 :
542 : static bool
543 7544 : _equalJsonFormat(const JsonFormat *a, const JsonFormat *b)
544 : {
545 7544 : COMPARE_SCALAR_FIELD(format_type);
546 7544 : COMPARE_SCALAR_FIELD(encoding);
547 : COMPARE_LOCATION_FIELD(location);
548 :
549 7544 : return true;
550 : }
551 :
552 : static bool
553 3364 : _equalJsonReturning(const JsonReturning *a, const JsonReturning *b)
554 : {
555 3364 : COMPARE_NODE_FIELD(format);
556 3364 : COMPARE_SCALAR_FIELD(typid);
557 3364 : COMPARE_SCALAR_FIELD(typmod);
558 :
559 3364 : return true;
560 : }
561 :
562 : static bool
563 3324 : _equalJsonValueExpr(const JsonValueExpr *a, const JsonValueExpr *b)
564 : {
565 3324 : COMPARE_NODE_FIELD(raw_expr);
566 3324 : COMPARE_NODE_FIELD(formatted_expr);
567 3324 : COMPARE_NODE_FIELD(format);
568 :
569 3324 : return true;
570 : }
571 :
572 : static bool
573 2324 : _equalJsonConstructorExpr(const JsonConstructorExpr *a, const JsonConstructorExpr *b)
574 : {
575 2324 : COMPARE_SCALAR_FIELD(type);
576 2324 : COMPARE_NODE_FIELD(args);
577 2324 : COMPARE_NODE_FIELD(func);
578 2324 : COMPARE_NODE_FIELD(coercion);
579 2324 : COMPARE_NODE_FIELD(returning);
580 2324 : COMPARE_SCALAR_FIELD(absent_on_null);
581 2324 : COMPARE_SCALAR_FIELD(unique);
582 : COMPARE_LOCATION_FIELD(location);
583 :
584 2324 : return true;
585 : }
586 :
587 : static bool
588 1364 : _equalJsonIsPredicate(const JsonIsPredicate *a, const JsonIsPredicate *b)
589 : {
590 1364 : COMPARE_NODE_FIELD(expr);
591 1364 : COMPARE_NODE_FIELD(format);
592 1364 : COMPARE_SCALAR_FIELD(item_type);
593 1364 : COMPARE_SCALAR_FIELD(unique_keys);
594 : COMPARE_LOCATION_FIELD(location);
595 :
596 1364 : return true;
597 : }
598 :
599 : static bool
600 54322 : _equalNullTest(const NullTest *a, const NullTest *b)
601 : {
602 54322 : COMPARE_NODE_FIELD(arg);
603 53068 : COMPARE_SCALAR_FIELD(nulltesttype);
604 52920 : COMPARE_SCALAR_FIELD(argisrow);
605 : COMPARE_LOCATION_FIELD(location);
606 :
607 52920 : return true;
608 : }
609 :
610 : static bool
611 3188 : _equalBooleanTest(const BooleanTest *a, const BooleanTest *b)
612 : {
613 3188 : COMPARE_NODE_FIELD(arg);
614 3188 : COMPARE_SCALAR_FIELD(booltesttype);
615 : COMPARE_LOCATION_FIELD(location);
616 :
617 3164 : return true;
618 : }
619 :
620 : static bool
621 3136 : _equalMergeAction(const MergeAction *a, const MergeAction *b)
622 : {
623 3136 : COMPARE_SCALAR_FIELD(matched);
624 3136 : COMPARE_SCALAR_FIELD(commandType);
625 3136 : COMPARE_SCALAR_FIELD(override);
626 3136 : COMPARE_NODE_FIELD(qual);
627 3136 : COMPARE_NODE_FIELD(targetList);
628 3136 : COMPARE_NODE_FIELD(updateColnos);
629 :
630 3136 : return true;
631 : }
632 :
633 : static bool
634 55062 : _equalCoerceToDomain(const CoerceToDomain *a, const CoerceToDomain *b)
635 : {
636 55062 : COMPARE_NODE_FIELD(arg);
637 54558 : COMPARE_SCALAR_FIELD(resulttype);
638 54558 : COMPARE_SCALAR_FIELD(resulttypmod);
639 54558 : COMPARE_SCALAR_FIELD(resultcollid);
640 : COMPARE_LOCATION_FIELD(location);
641 :
642 54558 : return true;
643 : }
644 :
645 : static bool
646 0 : _equalCoerceToDomainValue(const CoerceToDomainValue *a, const CoerceToDomainValue *b)
647 : {
648 0 : COMPARE_SCALAR_FIELD(typeId);
649 0 : COMPARE_SCALAR_FIELD(typeMod);
650 0 : COMPARE_SCALAR_FIELD(collation);
651 : COMPARE_LOCATION_FIELD(location);
652 :
653 0 : return true;
654 : }
655 :
656 : static bool
657 2640 : _equalSetToDefault(const SetToDefault *a, const SetToDefault *b)
658 : {
659 2640 : COMPARE_SCALAR_FIELD(typeId);
660 2640 : COMPARE_SCALAR_FIELD(typeMod);
661 2640 : COMPARE_SCALAR_FIELD(collation);
662 : COMPARE_LOCATION_FIELD(location);
663 :
664 2640 : return true;
665 : }
666 :
667 : static bool
668 944 : _equalCurrentOfExpr(const CurrentOfExpr *a, const CurrentOfExpr *b)
669 : {
670 944 : COMPARE_SCALAR_FIELD(cvarno);
671 944 : COMPARE_STRING_FIELD(cursor_name);
672 944 : COMPARE_SCALAR_FIELD(cursor_param);
673 :
674 944 : return true;
675 : }
676 :
677 : static bool
678 640 : _equalNextValueExpr(const NextValueExpr *a, const NextValueExpr *b)
679 : {
680 640 : COMPARE_SCALAR_FIELD(seqid);
681 640 : COMPARE_SCALAR_FIELD(typeId);
682 :
683 640 : return true;
684 : }
685 :
686 : static bool
687 3036 : _equalInferenceElem(const InferenceElem *a, const InferenceElem *b)
688 : {
689 3036 : COMPARE_NODE_FIELD(expr);
690 3036 : COMPARE_SCALAR_FIELD(infercollid);
691 3036 : COMPARE_SCALAR_FIELD(inferopclass);
692 :
693 3036 : return true;
694 : }
695 :
696 : static bool
697 2440112 : _equalTargetEntry(const TargetEntry *a, const TargetEntry *b)
698 : {
699 2440112 : COMPARE_NODE_FIELD(expr);
700 2436766 : COMPARE_SCALAR_FIELD(resno);
701 2436766 : COMPARE_STRING_FIELD(resname);
702 2436766 : COMPARE_SCALAR_FIELD(ressortgroupref);
703 2436722 : COMPARE_SCALAR_FIELD(resorigtbl);
704 2436722 : COMPARE_SCALAR_FIELD(resorigcol);
705 2436722 : COMPARE_SCALAR_FIELD(resjunk);
706 :
707 2436722 : return true;
708 : }
709 :
710 : static bool
711 803554 : _equalRangeTblRef(const RangeTblRef *a, const RangeTblRef *b)
712 : {
713 803554 : COMPARE_SCALAR_FIELD(rtindex);
714 :
715 803554 : return true;
716 : }
717 :
718 : static bool
719 280978 : _equalJoinExpr(const JoinExpr *a, const JoinExpr *b)
720 : {
721 280978 : COMPARE_SCALAR_FIELD(jointype);
722 280978 : COMPARE_SCALAR_FIELD(isNatural);
723 280978 : COMPARE_NODE_FIELD(larg);
724 280978 : COMPARE_NODE_FIELD(rarg);
725 280978 : COMPARE_NODE_FIELD(usingClause);
726 280978 : COMPARE_NODE_FIELD(join_using_alias);
727 280978 : COMPARE_NODE_FIELD(quals);
728 280978 : COMPARE_NODE_FIELD(alias);
729 280978 : COMPARE_SCALAR_FIELD(rtindex);
730 :
731 280978 : return true;
732 : }
733 :
734 : static bool
735 950566 : _equalFromExpr(const FromExpr *a, const FromExpr *b)
736 : {
737 950566 : COMPARE_NODE_FIELD(fromlist);
738 950566 : COMPARE_NODE_FIELD(quals);
739 :
740 950494 : return true;
741 : }
742 :
743 : static bool
744 2836 : _equalOnConflictExpr(const OnConflictExpr *a, const OnConflictExpr *b)
745 : {
746 2836 : COMPARE_SCALAR_FIELD(action);
747 2836 : COMPARE_NODE_FIELD(arbiterElems);
748 2836 : COMPARE_NODE_FIELD(arbiterWhere);
749 2836 : COMPARE_SCALAR_FIELD(constraint);
750 2836 : COMPARE_NODE_FIELD(onConflictSet);
751 2836 : COMPARE_NODE_FIELD(onConflictWhere);
752 2836 : COMPARE_SCALAR_FIELD(exclRelIndex);
753 2836 : COMPARE_NODE_FIELD(exclRelTlist);
754 :
755 2836 : return true;
756 : }
757 :
758 : static bool
759 1553838 : _equalQuery(const Query *a, const Query *b)
760 : {
761 1553838 : COMPARE_SCALAR_FIELD(commandType);
762 1553838 : COMPARE_SCALAR_FIELD(querySource);
763 1553838 : COMPARE_SCALAR_FIELD(canSetTag);
764 1553838 : COMPARE_NODE_FIELD(utilityStmt);
765 1553838 : COMPARE_SCALAR_FIELD(resultRelation);
766 1553838 : COMPARE_SCALAR_FIELD(hasAggs);
767 1553838 : COMPARE_SCALAR_FIELD(hasWindowFuncs);
768 1553838 : COMPARE_SCALAR_FIELD(hasTargetSRFs);
769 1553838 : COMPARE_SCALAR_FIELD(hasSubLinks);
770 1553832 : COMPARE_SCALAR_FIELD(hasDistinctOn);
771 1553832 : COMPARE_SCALAR_FIELD(hasRecursive);
772 1553832 : COMPARE_SCALAR_FIELD(hasModifyingCTE);
773 1553832 : COMPARE_SCALAR_FIELD(hasForUpdate);
774 1553832 : COMPARE_SCALAR_FIELD(hasRowSecurity);
775 1553832 : COMPARE_SCALAR_FIELD(isReturn);
776 1553832 : COMPARE_NODE_FIELD(cteList);
777 1553826 : COMPARE_NODE_FIELD(rtable);
778 1553780 : COMPARE_NODE_FIELD(rteperminfos);
779 1553728 : COMPARE_NODE_FIELD(jointree);
780 1553656 : COMPARE_NODE_FIELD(mergeActionList);
781 1553656 : COMPARE_SCALAR_FIELD(mergeUseOuterJoin);
782 1553656 : COMPARE_NODE_FIELD(targetList);
783 1553610 : COMPARE_SCALAR_FIELD(override);
784 1553610 : COMPARE_NODE_FIELD(onConflict);
785 1553610 : COMPARE_NODE_FIELD(returningList);
786 1553610 : COMPARE_NODE_FIELD(groupClause);
787 1553610 : COMPARE_SCALAR_FIELD(groupDistinct);
788 1553610 : COMPARE_NODE_FIELD(groupingSets);
789 1553610 : COMPARE_NODE_FIELD(havingQual);
790 1553610 : COMPARE_NODE_FIELD(windowClause);
791 1553580 : COMPARE_NODE_FIELD(distinctClause);
792 1553580 : COMPARE_NODE_FIELD(sortClause);
793 1553580 : COMPARE_NODE_FIELD(limitOffset);
794 1553580 : COMPARE_NODE_FIELD(limitCount);
795 1553580 : COMPARE_SCALAR_FIELD(limitOption);
796 1553580 : COMPARE_NODE_FIELD(rowMarks);
797 1553580 : COMPARE_NODE_FIELD(setOperations);
798 1553580 : COMPARE_NODE_FIELD(constraintDeps);
799 1553580 : COMPARE_NODE_FIELD(withCheckOptions);
800 : COMPARE_LOCATION_FIELD(stmt_location);
801 1553580 : COMPARE_SCALAR_FIELD(stmt_len);
802 :
803 1553574 : return true;
804 : }
805 :
806 : static bool
807 1206302 : _equalTypeName(const TypeName *a, const TypeName *b)
808 : {
809 1206302 : COMPARE_NODE_FIELD(names);
810 1206302 : COMPARE_SCALAR_FIELD(typeOid);
811 1206302 : COMPARE_SCALAR_FIELD(setof);
812 1206302 : COMPARE_SCALAR_FIELD(pct_type);
813 1206302 : COMPARE_NODE_FIELD(typmods);
814 1206302 : COMPARE_SCALAR_FIELD(typemod);
815 1206302 : COMPARE_NODE_FIELD(arrayBounds);
816 : COMPARE_LOCATION_FIELD(location);
817 :
818 1206302 : return true;
819 : }
820 :
821 : static bool
822 3015842 : _equalColumnRef(const ColumnRef *a, const ColumnRef *b)
823 : {
824 3015842 : COMPARE_NODE_FIELD(fields);
825 : COMPARE_LOCATION_FIELD(location);
826 :
827 3015800 : return true;
828 : }
829 :
830 : static bool
831 283960 : _equalParamRef(const ParamRef *a, const ParamRef *b)
832 : {
833 283960 : COMPARE_SCALAR_FIELD(number);
834 : COMPARE_LOCATION_FIELD(location);
835 :
836 283960 : return true;
837 : }
838 :
839 : static bool
840 1075044 : _equalA_Expr(const A_Expr *a, const A_Expr *b)
841 : {
842 1075044 : COMPARE_SCALAR_FIELD(kind);
843 1075044 : COMPARE_NODE_FIELD(name);
844 1075044 : COMPARE_NODE_FIELD(lexpr);
845 1075032 : COMPARE_NODE_FIELD(rexpr);
846 : COMPARE_LOCATION_FIELD(location);
847 :
848 1075032 : return true;
849 : }
850 :
851 : static bool
852 495918 : _equalTypeCast(const TypeCast *a, const TypeCast *b)
853 : {
854 495918 : COMPARE_NODE_FIELD(arg);
855 495918 : COMPARE_NODE_FIELD(typeName);
856 : COMPARE_LOCATION_FIELD(location);
857 :
858 495918 : return true;
859 : }
860 :
861 : static bool
862 15508 : _equalCollateClause(const CollateClause *a, const CollateClause *b)
863 : {
864 15508 : COMPARE_NODE_FIELD(arg);
865 15508 : COMPARE_NODE_FIELD(collname);
866 : COMPARE_LOCATION_FIELD(location);
867 :
868 15508 : return true;
869 : }
870 :
871 : static bool
872 84856 : _equalRoleSpec(const RoleSpec *a, const RoleSpec *b)
873 : {
874 84856 : COMPARE_SCALAR_FIELD(roletype);
875 84856 : COMPARE_STRING_FIELD(rolename);
876 : COMPARE_LOCATION_FIELD(location);
877 :
878 84856 : return true;
879 : }
880 :
881 : static bool
882 672008 : _equalFuncCall(const FuncCall *a, const FuncCall *b)
883 : {
884 672008 : COMPARE_NODE_FIELD(funcname);
885 672004 : COMPARE_NODE_FIELD(args);
886 672004 : COMPARE_NODE_FIELD(agg_order);
887 672004 : COMPARE_NODE_FIELD(agg_filter);
888 672004 : COMPARE_NODE_FIELD(over);
889 672004 : COMPARE_SCALAR_FIELD(agg_within_group);
890 672004 : COMPARE_SCALAR_FIELD(agg_star);
891 672004 : COMPARE_SCALAR_FIELD(agg_distinct);
892 672004 : COMPARE_SCALAR_FIELD(func_variadic);
893 : COMPARE_LOCATION_FIELD(location);
894 :
895 672004 : return true;
896 : }
897 :
898 : static bool
899 104096 : _equalA_Star(const A_Star *a, const A_Star *b)
900 : {
901 :
902 104096 : return true;
903 : }
904 :
905 : static bool
906 23436 : _equalA_Indices(const A_Indices *a, const A_Indices *b)
907 : {
908 23436 : COMPARE_SCALAR_FIELD(is_slice);
909 23436 : COMPARE_NODE_FIELD(lidx);
910 23436 : COMPARE_NODE_FIELD(uidx);
911 :
912 23436 : return true;
913 : }
914 :
915 : static bool
916 49132 : _equalA_Indirection(const A_Indirection *a, const A_Indirection *b)
917 : {
918 49132 : COMPARE_NODE_FIELD(arg);
919 49132 : COMPARE_NODE_FIELD(indirection);
920 :
921 49132 : return true;
922 : }
923 :
924 : static bool
925 13432 : _equalA_ArrayExpr(const A_ArrayExpr *a, const A_ArrayExpr *b)
926 : {
927 13432 : COMPARE_NODE_FIELD(elements);
928 : COMPARE_LOCATION_FIELD(location);
929 :
930 13432 : return true;
931 : }
932 :
933 : static bool
934 1980396 : _equalResTarget(const ResTarget *a, const ResTarget *b)
935 : {
936 1980396 : COMPARE_STRING_FIELD(name);
937 1980396 : COMPARE_NODE_FIELD(indirection);
938 1980396 : COMPARE_NODE_FIELD(val);
939 : COMPARE_LOCATION_FIELD(location);
940 :
941 1980392 : return true;
942 : }
943 :
944 : static bool
945 780 : _equalMultiAssignRef(const MultiAssignRef *a, const MultiAssignRef *b)
946 : {
947 780 : COMPARE_NODE_FIELD(source);
948 780 : COMPARE_SCALAR_FIELD(colno);
949 780 : COMPARE_SCALAR_FIELD(ncolumns);
950 :
951 780 : return true;
952 : }
953 :
954 : static bool
955 158262 : _equalSortBy(const SortBy *a, const SortBy *b)
956 : {
957 158262 : COMPARE_NODE_FIELD(node);
958 158238 : COMPARE_SCALAR_FIELD(sortby_dir);
959 158214 : COMPARE_SCALAR_FIELD(sortby_nulls);
960 158214 : COMPARE_NODE_FIELD(useOp);
961 : COMPARE_LOCATION_FIELD(location);
962 :
963 158214 : return true;
964 : }
965 :
966 : static bool
967 7932 : _equalWindowDef(const WindowDef *a, const WindowDef *b)
968 : {
969 7932 : COMPARE_STRING_FIELD(name);
970 7932 : COMPARE_STRING_FIELD(refname);
971 7932 : COMPARE_NODE_FIELD(partitionClause);
972 7932 : COMPARE_NODE_FIELD(orderClause);
973 7932 : COMPARE_SCALAR_FIELD(frameOptions);
974 7932 : COMPARE_NODE_FIELD(startOffset);
975 7932 : COMPARE_NODE_FIELD(endOffset);
976 : COMPARE_LOCATION_FIELD(location);
977 :
978 7932 : return true;
979 : }
980 :
981 : static bool
982 28008 : _equalRangeSubselect(const RangeSubselect *a, const RangeSubselect *b)
983 : {
984 28008 : COMPARE_SCALAR_FIELD(lateral);
985 28008 : COMPARE_NODE_FIELD(subquery);
986 28008 : COMPARE_NODE_FIELD(alias);
987 :
988 28008 : return true;
989 : }
990 :
991 : static bool
992 79916 : _equalRangeFunction(const RangeFunction *a, const RangeFunction *b)
993 : {
994 79916 : COMPARE_SCALAR_FIELD(lateral);
995 79916 : COMPARE_SCALAR_FIELD(ordinality);
996 79916 : COMPARE_SCALAR_FIELD(is_rowsfrom);
997 79916 : COMPARE_NODE_FIELD(functions);
998 79916 : COMPARE_NODE_FIELD(alias);
999 79916 : COMPARE_NODE_FIELD(coldeflist);
1000 :
1001 79916 : return true;
1002 : }
1003 :
1004 : static bool
1005 472 : _equalRangeTableFunc(const RangeTableFunc *a, const RangeTableFunc *b)
1006 : {
1007 472 : COMPARE_SCALAR_FIELD(lateral);
1008 472 : COMPARE_NODE_FIELD(docexpr);
1009 472 : COMPARE_NODE_FIELD(rowexpr);
1010 472 : COMPARE_NODE_FIELD(namespaces);
1011 472 : COMPARE_NODE_FIELD(columns);
1012 472 : COMPARE_NODE_FIELD(alias);
1013 : COMPARE_LOCATION_FIELD(location);
1014 :
1015 472 : return true;
1016 : }
1017 :
1018 : static bool
1019 1716 : _equalRangeTableFuncCol(const RangeTableFuncCol *a, const RangeTableFuncCol *b)
1020 : {
1021 1716 : COMPARE_STRING_FIELD(colname);
1022 1716 : COMPARE_NODE_FIELD(typeName);
1023 1716 : COMPARE_SCALAR_FIELD(for_ordinality);
1024 1716 : COMPARE_SCALAR_FIELD(is_not_null);
1025 1716 : COMPARE_NODE_FIELD(colexpr);
1026 1716 : COMPARE_NODE_FIELD(coldefexpr);
1027 : COMPARE_LOCATION_FIELD(location);
1028 :
1029 1716 : return true;
1030 : }
1031 :
1032 : static bool
1033 524 : _equalRangeTableSample(const RangeTableSample *a, const RangeTableSample *b)
1034 : {
1035 524 : COMPARE_NODE_FIELD(relation);
1036 524 : COMPARE_NODE_FIELD(method);
1037 524 : COMPARE_NODE_FIELD(args);
1038 524 : COMPARE_NODE_FIELD(repeatable);
1039 : COMPARE_LOCATION_FIELD(location);
1040 :
1041 524 : return true;
1042 : }
1043 :
1044 : static bool
1045 249936 : _equalColumnDef(const ColumnDef *a, const ColumnDef *b)
1046 : {
1047 249936 : COMPARE_STRING_FIELD(colname);
1048 249936 : COMPARE_NODE_FIELD(typeName);
1049 249936 : COMPARE_STRING_FIELD(compression);
1050 249936 : COMPARE_SCALAR_FIELD(inhcount);
1051 249936 : COMPARE_SCALAR_FIELD(is_local);
1052 249936 : COMPARE_SCALAR_FIELD(is_not_null);
1053 249936 : COMPARE_SCALAR_FIELD(is_from_type);
1054 249936 : COMPARE_SCALAR_FIELD(storage);
1055 249936 : COMPARE_STRING_FIELD(storage_name);
1056 249936 : COMPARE_NODE_FIELD(raw_default);
1057 249936 : COMPARE_NODE_FIELD(cooked_default);
1058 249936 : COMPARE_SCALAR_FIELD(identity);
1059 249936 : COMPARE_NODE_FIELD(identitySequence);
1060 249936 : COMPARE_SCALAR_FIELD(generated);
1061 249936 : COMPARE_NODE_FIELD(collClause);
1062 249936 : COMPARE_SCALAR_FIELD(collOid);
1063 249936 : COMPARE_NODE_FIELD(constraints);
1064 249936 : COMPARE_NODE_FIELD(fdwoptions);
1065 : COMPARE_LOCATION_FIELD(location);
1066 :
1067 249936 : return true;
1068 : }
1069 :
1070 : static bool
1071 2768 : _equalTableLikeClause(const TableLikeClause *a, const TableLikeClause *b)
1072 : {
1073 2768 : COMPARE_NODE_FIELD(relation);
1074 2768 : COMPARE_SCALAR_FIELD(options);
1075 2768 : COMPARE_SCALAR_FIELD(relationOid);
1076 :
1077 2768 : return true;
1078 : }
1079 :
1080 : static bool
1081 34728 : _equalIndexElem(const IndexElem *a, const IndexElem *b)
1082 : {
1083 34728 : COMPARE_STRING_FIELD(name);
1084 34620 : COMPARE_NODE_FIELD(expr);
1085 34620 : COMPARE_STRING_FIELD(indexcolname);
1086 34620 : COMPARE_NODE_FIELD(collation);
1087 34620 : COMPARE_NODE_FIELD(opclass);
1088 34620 : COMPARE_NODE_FIELD(opclassopts);
1089 34620 : COMPARE_SCALAR_FIELD(ordering);
1090 34620 : COMPARE_SCALAR_FIELD(nulls_ordering);
1091 :
1092 34620 : return true;
1093 : }
1094 :
1095 : static bool
1096 527668 : _equalDefElem(const DefElem *a, const DefElem *b)
1097 : {
1098 527668 : COMPARE_STRING_FIELD(defnamespace);
1099 527668 : COMPARE_STRING_FIELD(defname);
1100 527668 : COMPARE_NODE_FIELD(arg);
1101 527668 : COMPARE_SCALAR_FIELD(defaction);
1102 : COMPARE_LOCATION_FIELD(location);
1103 :
1104 527668 : return true;
1105 : }
1106 :
1107 : static bool
1108 4180 : _equalLockingClause(const LockingClause *a, const LockingClause *b)
1109 : {
1110 4180 : COMPARE_NODE_FIELD(lockedRels);
1111 4180 : COMPARE_SCALAR_FIELD(strength);
1112 4180 : COMPARE_SCALAR_FIELD(waitPolicy);
1113 :
1114 4180 : return true;
1115 : }
1116 :
1117 : static bool
1118 412 : _equalXmlSerialize(const XmlSerialize *a, const XmlSerialize *b)
1119 : {
1120 412 : COMPARE_SCALAR_FIELD(xmloption);
1121 412 : COMPARE_NODE_FIELD(expr);
1122 412 : COMPARE_NODE_FIELD(typeName);
1123 412 : COMPARE_SCALAR_FIELD(indent);
1124 : COMPARE_LOCATION_FIELD(location);
1125 :
1126 412 : return true;
1127 : }
1128 :
1129 : static bool
1130 19760 : _equalPartitionElem(const PartitionElem *a, const PartitionElem *b)
1131 : {
1132 19760 : COMPARE_STRING_FIELD(name);
1133 19760 : COMPARE_NODE_FIELD(expr);
1134 19760 : COMPARE_NODE_FIELD(collation);
1135 19760 : COMPARE_NODE_FIELD(opclass);
1136 : COMPARE_LOCATION_FIELD(location);
1137 :
1138 19760 : return true;
1139 : }
1140 :
1141 : static bool
1142 18032 : _equalPartitionSpec(const PartitionSpec *a, const PartitionSpec *b)
1143 : {
1144 18032 : COMPARE_SCALAR_FIELD(strategy);
1145 18032 : COMPARE_NODE_FIELD(partParams);
1146 : COMPARE_LOCATION_FIELD(location);
1147 :
1148 18032 : return true;
1149 : }
1150 :
1151 : static bool
1152 37920 : _equalPartitionBoundSpec(const PartitionBoundSpec *a, const PartitionBoundSpec *b)
1153 : {
1154 37920 : COMPARE_SCALAR_FIELD(strategy);
1155 37920 : COMPARE_SCALAR_FIELD(is_default);
1156 37920 : COMPARE_SCALAR_FIELD(modulus);
1157 37920 : COMPARE_SCALAR_FIELD(remainder);
1158 37920 : COMPARE_NODE_FIELD(listdatums);
1159 37920 : COMPARE_NODE_FIELD(lowerdatums);
1160 37920 : COMPARE_NODE_FIELD(upperdatums);
1161 : COMPARE_LOCATION_FIELD(location);
1162 :
1163 37920 : return true;
1164 : }
1165 :
1166 : static bool
1167 0 : _equalPartitionRangeDatum(const PartitionRangeDatum *a, const PartitionRangeDatum *b)
1168 : {
1169 0 : COMPARE_SCALAR_FIELD(kind);
1170 0 : COMPARE_NODE_FIELD(value);
1171 : COMPARE_LOCATION_FIELD(location);
1172 :
1173 0 : return true;
1174 : }
1175 :
1176 : static bool
1177 12180 : _equalPartitionCmd(const PartitionCmd *a, const PartitionCmd *b)
1178 : {
1179 12180 : COMPARE_NODE_FIELD(name);
1180 12180 : COMPARE_NODE_FIELD(bound);
1181 12180 : COMPARE_SCALAR_FIELD(concurrent);
1182 :
1183 12180 : return true;
1184 : }
1185 :
1186 : static bool
1187 1066240 : _equalRangeTblEntry(const RangeTblEntry *a, const RangeTblEntry *b)
1188 : {
1189 1066240 : COMPARE_SCALAR_FIELD(rtekind);
1190 1066240 : COMPARE_SCALAR_FIELD(relid);
1191 1066240 : COMPARE_SCALAR_FIELD(relkind);
1192 1066240 : COMPARE_SCALAR_FIELD(rellockmode);
1193 1066240 : COMPARE_NODE_FIELD(tablesample);
1194 1066240 : COMPARE_SCALAR_FIELD(perminfoindex);
1195 1066240 : COMPARE_NODE_FIELD(subquery);
1196 1066234 : COMPARE_SCALAR_FIELD(security_barrier);
1197 1066234 : COMPARE_SCALAR_FIELD(jointype);
1198 1066234 : COMPARE_SCALAR_FIELD(joinmergedcols);
1199 1066234 : COMPARE_NODE_FIELD(joinaliasvars);
1200 1066234 : COMPARE_NODE_FIELD(joinleftcols);
1201 1066234 : COMPARE_NODE_FIELD(joinrightcols);
1202 1066234 : COMPARE_NODE_FIELD(join_using_alias);
1203 1066234 : COMPARE_NODE_FIELD(functions);
1204 1066234 : COMPARE_SCALAR_FIELD(funcordinality);
1205 1066234 : COMPARE_NODE_FIELD(tablefunc);
1206 1066234 : COMPARE_NODE_FIELD(values_lists);
1207 1066234 : COMPARE_STRING_FIELD(ctename);
1208 1066234 : COMPARE_SCALAR_FIELD(ctelevelsup);
1209 1066234 : COMPARE_SCALAR_FIELD(self_reference);
1210 1066234 : COMPARE_NODE_FIELD(coltypes);
1211 1066234 : COMPARE_NODE_FIELD(coltypmods);
1212 1066234 : COMPARE_NODE_FIELD(colcollations);
1213 1066234 : COMPARE_STRING_FIELD(enrname);
1214 1066234 : COMPARE_SCALAR_FIELD(enrtuples);
1215 1066234 : COMPARE_NODE_FIELD(alias);
1216 1066234 : COMPARE_NODE_FIELD(eref);
1217 1066234 : COMPARE_SCALAR_FIELD(lateral);
1218 1066234 : COMPARE_SCALAR_FIELD(inh);
1219 1066234 : COMPARE_SCALAR_FIELD(inFromCl);
1220 1066234 : COMPARE_NODE_FIELD(securityQuals);
1221 :
1222 1066234 : return true;
1223 : }
1224 :
1225 : static bool
1226 761874 : _equalRTEPermissionInfo(const RTEPermissionInfo *a, const RTEPermissionInfo *b)
1227 : {
1228 761874 : COMPARE_SCALAR_FIELD(relid);
1229 761874 : COMPARE_SCALAR_FIELD(inh);
1230 761874 : COMPARE_SCALAR_FIELD(requiredPerms);
1231 761874 : COMPARE_SCALAR_FIELD(checkAsUser);
1232 761822 : COMPARE_BITMAPSET_FIELD(selectedCols);
1233 761822 : COMPARE_BITMAPSET_FIELD(insertedCols);
1234 761822 : COMPARE_BITMAPSET_FIELD(updatedCols);
1235 :
1236 761822 : return true;
1237 : }
1238 :
1239 : static bool
1240 77598 : _equalRangeTblFunction(const RangeTblFunction *a, const RangeTblFunction *b)
1241 : {
1242 77598 : COMPARE_NODE_FIELD(funcexpr);
1243 77598 : COMPARE_SCALAR_FIELD(funccolcount);
1244 77598 : COMPARE_NODE_FIELD(funccolnames);
1245 77598 : COMPARE_NODE_FIELD(funccoltypes);
1246 77598 : COMPARE_NODE_FIELD(funccoltypmods);
1247 77598 : COMPARE_NODE_FIELD(funccolcollations);
1248 77598 : COMPARE_BITMAPSET_FIELD(funcparams);
1249 :
1250 77598 : return true;
1251 : }
1252 :
1253 : static bool
1254 404 : _equalTableSampleClause(const TableSampleClause *a, const TableSampleClause *b)
1255 : {
1256 404 : COMPARE_SCALAR_FIELD(tsmhandler);
1257 404 : COMPARE_NODE_FIELD(args);
1258 404 : COMPARE_NODE_FIELD(repeatable);
1259 :
1260 404 : return true;
1261 : }
1262 :
1263 : static bool
1264 6866 : _equalWithCheckOption(const WithCheckOption *a, const WithCheckOption *b)
1265 : {
1266 6866 : COMPARE_SCALAR_FIELD(kind);
1267 4952 : COMPARE_STRING_FIELD(relname);
1268 4952 : COMPARE_STRING_FIELD(polname);
1269 4782 : COMPARE_NODE_FIELD(qual);
1270 4386 : COMPARE_SCALAR_FIELD(cascaded);
1271 :
1272 4386 : return true;
1273 : }
1274 :
1275 : static bool
1276 219868 : _equalSortGroupClause(const SortGroupClause *a, const SortGroupClause *b)
1277 : {
1278 219868 : COMPARE_SCALAR_FIELD(tleSortGroupRef);
1279 218308 : COMPARE_SCALAR_FIELD(eqop);
1280 218308 : COMPARE_SCALAR_FIELD(sortop);
1281 218272 : COMPARE_SCALAR_FIELD(nulls_first);
1282 218266 : COMPARE_SCALAR_FIELD(hashable);
1283 :
1284 218266 : return true;
1285 : }
1286 :
1287 : static bool
1288 7328 : _equalGroupingSet(const GroupingSet *a, const GroupingSet *b)
1289 : {
1290 7328 : COMPARE_SCALAR_FIELD(kind);
1291 7328 : COMPARE_NODE_FIELD(content);
1292 : COMPARE_LOCATION_FIELD(location);
1293 :
1294 7328 : return true;
1295 : }
1296 :
1297 : static bool
1298 5076 : _equalWindowClause(const WindowClause *a, const WindowClause *b)
1299 : {
1300 5076 : COMPARE_STRING_FIELD(name);
1301 5076 : COMPARE_STRING_FIELD(refname);
1302 5076 : COMPARE_NODE_FIELD(partitionClause);
1303 5076 : COMPARE_NODE_FIELD(orderClause);
1304 5076 : COMPARE_SCALAR_FIELD(frameOptions);
1305 5046 : COMPARE_NODE_FIELD(startOffset);
1306 5046 : COMPARE_NODE_FIELD(endOffset);
1307 5046 : COMPARE_NODE_FIELD(runCondition);
1308 5046 : COMPARE_SCALAR_FIELD(startInRangeFunc);
1309 5046 : COMPARE_SCALAR_FIELD(endInRangeFunc);
1310 5046 : COMPARE_SCALAR_FIELD(inRangeColl);
1311 5046 : COMPARE_SCALAR_FIELD(inRangeAsc);
1312 5046 : COMPARE_SCALAR_FIELD(inRangeNullsFirst);
1313 5046 : COMPARE_SCALAR_FIELD(winref);
1314 5046 : COMPARE_SCALAR_FIELD(copiedOrder);
1315 :
1316 5046 : return true;
1317 : }
1318 :
1319 : static bool
1320 9564 : _equalRowMarkClause(const RowMarkClause *a, const RowMarkClause *b)
1321 : {
1322 9564 : COMPARE_SCALAR_FIELD(rti);
1323 9564 : COMPARE_SCALAR_FIELD(strength);
1324 9564 : COMPARE_SCALAR_FIELD(waitPolicy);
1325 9564 : COMPARE_SCALAR_FIELD(pushedDown);
1326 :
1327 9564 : return true;
1328 : }
1329 :
1330 : static bool
1331 5260 : _equalWithClause(const WithClause *a, const WithClause *b)
1332 : {
1333 5260 : COMPARE_NODE_FIELD(ctes);
1334 5260 : COMPARE_SCALAR_FIELD(recursive);
1335 : COMPARE_LOCATION_FIELD(location);
1336 :
1337 5260 : return true;
1338 : }
1339 :
1340 : static bool
1341 2632 : _equalInferClause(const InferClause *a, const InferClause *b)
1342 : {
1343 2632 : COMPARE_NODE_FIELD(indexElems);
1344 2632 : COMPARE_NODE_FIELD(whereClause);
1345 2632 : COMPARE_STRING_FIELD(conname);
1346 : COMPARE_LOCATION_FIELD(location);
1347 :
1348 2632 : return true;
1349 : }
1350 :
1351 : static bool
1352 2968 : _equalOnConflictClause(const OnConflictClause *a, const OnConflictClause *b)
1353 : {
1354 2968 : COMPARE_SCALAR_FIELD(action);
1355 2968 : COMPARE_NODE_FIELD(infer);
1356 2968 : COMPARE_NODE_FIELD(targetList);
1357 2968 : COMPARE_NODE_FIELD(whereClause);
1358 : COMPARE_LOCATION_FIELD(location);
1359 :
1360 2968 : return true;
1361 : }
1362 :
1363 : static bool
1364 420 : _equalCTESearchClause(const CTESearchClause *a, const CTESearchClause *b)
1365 : {
1366 420 : COMPARE_NODE_FIELD(search_col_list);
1367 420 : COMPARE_SCALAR_FIELD(search_breadth_first);
1368 420 : COMPARE_STRING_FIELD(search_seq_column);
1369 : COMPARE_LOCATION_FIELD(location);
1370 :
1371 420 : return true;
1372 : }
1373 :
1374 : static bool
1375 420 : _equalCTECycleClause(const CTECycleClause *a, const CTECycleClause *b)
1376 : {
1377 420 : COMPARE_NODE_FIELD(cycle_col_list);
1378 420 : COMPARE_STRING_FIELD(cycle_mark_column);
1379 420 : COMPARE_NODE_FIELD(cycle_mark_value);
1380 420 : COMPARE_NODE_FIELD(cycle_mark_default);
1381 420 : COMPARE_STRING_FIELD(cycle_path_column);
1382 : COMPARE_LOCATION_FIELD(location);
1383 420 : COMPARE_SCALAR_FIELD(cycle_mark_type);
1384 420 : COMPARE_SCALAR_FIELD(cycle_mark_typmod);
1385 420 : COMPARE_SCALAR_FIELD(cycle_mark_collation);
1386 420 : COMPARE_SCALAR_FIELD(cycle_mark_neop);
1387 :
1388 420 : return true;
1389 : }
1390 :
1391 : static bool
1392 13388 : _equalCommonTableExpr(const CommonTableExpr *a, const CommonTableExpr *b)
1393 : {
1394 13388 : COMPARE_STRING_FIELD(ctename);
1395 13388 : COMPARE_NODE_FIELD(aliascolnames);
1396 13388 : COMPARE_SCALAR_FIELD(ctematerialized);
1397 13388 : COMPARE_NODE_FIELD(ctequery);
1398 13382 : COMPARE_NODE_FIELD(search_clause);
1399 13382 : COMPARE_NODE_FIELD(cycle_clause);
1400 : COMPARE_LOCATION_FIELD(location);
1401 13382 : COMPARE_SCALAR_FIELD(cterecursive);
1402 13382 : COMPARE_SCALAR_FIELD(cterefcount);
1403 13382 : COMPARE_NODE_FIELD(ctecolnames);
1404 13382 : COMPARE_NODE_FIELD(ctecoltypes);
1405 13382 : COMPARE_NODE_FIELD(ctecoltypmods);
1406 13382 : COMPARE_NODE_FIELD(ctecolcollations);
1407 :
1408 13382 : return true;
1409 : }
1410 :
1411 : static bool
1412 3352 : _equalMergeWhenClause(const MergeWhenClause *a, const MergeWhenClause *b)
1413 : {
1414 3352 : COMPARE_SCALAR_FIELD(matched);
1415 3352 : COMPARE_SCALAR_FIELD(commandType);
1416 3352 : COMPARE_SCALAR_FIELD(override);
1417 3352 : COMPARE_NODE_FIELD(condition);
1418 3352 : COMPARE_NODE_FIELD(targetList);
1419 3352 : COMPARE_NODE_FIELD(values);
1420 :
1421 3352 : return true;
1422 : }
1423 :
1424 : static bool
1425 2248 : _equalTriggerTransition(const TriggerTransition *a, const TriggerTransition *b)
1426 : {
1427 2248 : COMPARE_STRING_FIELD(name);
1428 2248 : COMPARE_SCALAR_FIELD(isNew);
1429 2248 : COMPARE_SCALAR_FIELD(isTable);
1430 :
1431 2248 : return true;
1432 : }
1433 :
1434 : static bool
1435 1040 : _equalJsonOutput(const JsonOutput *a, const JsonOutput *b)
1436 : {
1437 1040 : COMPARE_NODE_FIELD(typeName);
1438 1040 : COMPARE_NODE_FIELD(returning);
1439 :
1440 1040 : return true;
1441 : }
1442 :
1443 : static bool
1444 1388 : _equalJsonKeyValue(const JsonKeyValue *a, const JsonKeyValue *b)
1445 : {
1446 1388 : COMPARE_NODE_FIELD(key);
1447 1388 : COMPARE_NODE_FIELD(value);
1448 :
1449 1388 : return true;
1450 : }
1451 :
1452 : static bool
1453 328 : _equalJsonParseExpr(const JsonParseExpr *a, const JsonParseExpr *b)
1454 : {
1455 328 : COMPARE_NODE_FIELD(expr);
1456 328 : COMPARE_NODE_FIELD(output);
1457 328 : COMPARE_SCALAR_FIELD(unique_keys);
1458 : COMPARE_LOCATION_FIELD(location);
1459 :
1460 328 : return true;
1461 : }
1462 :
1463 : static bool
1464 224 : _equalJsonScalarExpr(const JsonScalarExpr *a, const JsonScalarExpr *b)
1465 : {
1466 224 : COMPARE_NODE_FIELD(expr);
1467 224 : COMPARE_NODE_FIELD(output);
1468 : COMPARE_LOCATION_FIELD(location);
1469 :
1470 224 : return true;
1471 : }
1472 :
1473 : static bool
1474 180 : _equalJsonSerializeExpr(const JsonSerializeExpr *a, const JsonSerializeExpr *b)
1475 : {
1476 180 : COMPARE_NODE_FIELD(expr);
1477 180 : COMPARE_NODE_FIELD(output);
1478 : COMPARE_LOCATION_FIELD(location);
1479 :
1480 180 : return true;
1481 : }
1482 :
1483 : static bool
1484 760 : _equalJsonObjectConstructor(const JsonObjectConstructor *a, const JsonObjectConstructor *b)
1485 : {
1486 760 : COMPARE_NODE_FIELD(exprs);
1487 760 : COMPARE_NODE_FIELD(output);
1488 760 : COMPARE_SCALAR_FIELD(absent_on_null);
1489 760 : COMPARE_SCALAR_FIELD(unique);
1490 : COMPARE_LOCATION_FIELD(location);
1491 :
1492 760 : return true;
1493 : }
1494 :
1495 : static bool
1496 376 : _equalJsonArrayConstructor(const JsonArrayConstructor *a, const JsonArrayConstructor *b)
1497 : {
1498 376 : COMPARE_NODE_FIELD(exprs);
1499 376 : COMPARE_NODE_FIELD(output);
1500 376 : COMPARE_SCALAR_FIELD(absent_on_null);
1501 : COMPARE_LOCATION_FIELD(location);
1502 :
1503 376 : return true;
1504 : }
1505 :
1506 : static bool
1507 120 : _equalJsonArrayQueryConstructor(const JsonArrayQueryConstructor *a, const JsonArrayQueryConstructor *b)
1508 : {
1509 120 : COMPARE_NODE_FIELD(query);
1510 120 : COMPARE_NODE_FIELD(output);
1511 120 : COMPARE_NODE_FIELD(format);
1512 120 : COMPARE_SCALAR_FIELD(absent_on_null);
1513 : COMPARE_LOCATION_FIELD(location);
1514 :
1515 120 : return true;
1516 : }
1517 :
1518 : static bool
1519 636 : _equalJsonAggConstructor(const JsonAggConstructor *a, const JsonAggConstructor *b)
1520 : {
1521 636 : COMPARE_NODE_FIELD(output);
1522 636 : COMPARE_NODE_FIELD(agg_filter);
1523 636 : COMPARE_NODE_FIELD(agg_order);
1524 636 : COMPARE_NODE_FIELD(over);
1525 : COMPARE_LOCATION_FIELD(location);
1526 :
1527 636 : return true;
1528 : }
1529 :
1530 : static bool
1531 324 : _equalJsonObjectAgg(const JsonObjectAgg *a, const JsonObjectAgg *b)
1532 : {
1533 324 : COMPARE_NODE_FIELD(constructor);
1534 324 : COMPARE_NODE_FIELD(arg);
1535 324 : COMPARE_SCALAR_FIELD(absent_on_null);
1536 324 : COMPARE_SCALAR_FIELD(unique);
1537 :
1538 324 : return true;
1539 : }
1540 :
1541 : static bool
1542 312 : _equalJsonArrayAgg(const JsonArrayAgg *a, const JsonArrayAgg *b)
1543 : {
1544 312 : COMPARE_NODE_FIELD(constructor);
1545 312 : COMPARE_NODE_FIELD(arg);
1546 312 : COMPARE_SCALAR_FIELD(absent_on_null);
1547 :
1548 312 : return true;
1549 : }
1550 :
1551 : static bool
1552 1268560 : _equalRawStmt(const RawStmt *a, const RawStmt *b)
1553 : {
1554 1268560 : COMPARE_NODE_FIELD(stmt);
1555 : COMPARE_LOCATION_FIELD(stmt_location);
1556 1268556 : COMPARE_SCALAR_FIELD(stmt_len);
1557 :
1558 1268556 : return true;
1559 : }
1560 :
1561 : static bool
1562 115540 : _equalInsertStmt(const InsertStmt *a, const InsertStmt *b)
1563 : {
1564 115540 : COMPARE_NODE_FIELD(relation);
1565 115540 : COMPARE_NODE_FIELD(cols);
1566 115540 : COMPARE_NODE_FIELD(selectStmt);
1567 115540 : COMPARE_NODE_FIELD(onConflictClause);
1568 115540 : COMPARE_NODE_FIELD(returningList);
1569 115540 : COMPARE_NODE_FIELD(withClause);
1570 115540 : COMPARE_SCALAR_FIELD(override);
1571 :
1572 115540 : return true;
1573 : }
1574 :
1575 : static bool
1576 8108 : _equalDeleteStmt(const DeleteStmt *a, const DeleteStmt *b)
1577 : {
1578 8108 : COMPARE_NODE_FIELD(relation);
1579 8108 : COMPARE_NODE_FIELD(usingClause);
1580 8108 : COMPARE_NODE_FIELD(whereClause);
1581 8108 : COMPARE_NODE_FIELD(returningList);
1582 8108 : COMPARE_NODE_FIELD(withClause);
1583 :
1584 8108 : return true;
1585 : }
1586 :
1587 : static bool
1588 24888 : _equalUpdateStmt(const UpdateStmt *a, const UpdateStmt *b)
1589 : {
1590 24888 : COMPARE_NODE_FIELD(relation);
1591 24888 : COMPARE_NODE_FIELD(targetList);
1592 24888 : COMPARE_NODE_FIELD(whereClause);
1593 24888 : COMPARE_NODE_FIELD(fromClause);
1594 24888 : COMPARE_NODE_FIELD(returningList);
1595 24888 : COMPARE_NODE_FIELD(withClause);
1596 :
1597 24888 : return true;
1598 : }
1599 :
1600 : static bool
1601 2084 : _equalMergeStmt(const MergeStmt *a, const MergeStmt *b)
1602 : {
1603 2084 : COMPARE_NODE_FIELD(relation);
1604 2084 : COMPARE_NODE_FIELD(sourceRelation);
1605 2084 : COMPARE_NODE_FIELD(joinCondition);
1606 2084 : COMPARE_NODE_FIELD(mergeWhenClauses);
1607 2084 : COMPARE_NODE_FIELD(withClause);
1608 :
1609 2084 : return true;
1610 : }
1611 :
1612 : static bool
1613 901584 : _equalSelectStmt(const SelectStmt *a, const SelectStmt *b)
1614 : {
1615 901584 : COMPARE_NODE_FIELD(distinctClause);
1616 901584 : COMPARE_NODE_FIELD(intoClause);
1617 901584 : COMPARE_NODE_FIELD(targetList);
1618 901580 : COMPARE_NODE_FIELD(fromClause);
1619 901580 : COMPARE_NODE_FIELD(whereClause);
1620 901580 : COMPARE_NODE_FIELD(groupClause);
1621 901580 : COMPARE_SCALAR_FIELD(groupDistinct);
1622 901580 : COMPARE_NODE_FIELD(havingClause);
1623 901580 : COMPARE_NODE_FIELD(windowClause);
1624 901580 : COMPARE_NODE_FIELD(valuesLists);
1625 901580 : COMPARE_NODE_FIELD(sortClause);
1626 901580 : COMPARE_NODE_FIELD(limitOffset);
1627 901580 : COMPARE_NODE_FIELD(limitCount);
1628 901580 : COMPARE_SCALAR_FIELD(limitOption);
1629 901580 : COMPARE_NODE_FIELD(lockingClause);
1630 901580 : COMPARE_NODE_FIELD(withClause);
1631 901580 : COMPARE_SCALAR_FIELD(op);
1632 901580 : COMPARE_SCALAR_FIELD(all);
1633 901580 : COMPARE_NODE_FIELD(larg);
1634 901580 : COMPARE_NODE_FIELD(rarg);
1635 :
1636 901580 : return true;
1637 : }
1638 :
1639 : static bool
1640 19940 : _equalSetOperationStmt(const SetOperationStmt *a, const SetOperationStmt *b)
1641 : {
1642 19940 : COMPARE_SCALAR_FIELD(op);
1643 19940 : COMPARE_SCALAR_FIELD(all);
1644 19940 : COMPARE_NODE_FIELD(larg);
1645 19940 : COMPARE_NODE_FIELD(rarg);
1646 19940 : COMPARE_NODE_FIELD(colTypes);
1647 19940 : COMPARE_NODE_FIELD(colTypmods);
1648 19940 : COMPARE_NODE_FIELD(colCollations);
1649 19940 : COMPARE_NODE_FIELD(groupClauses);
1650 :
1651 19940 : return true;
1652 : }
1653 :
1654 : static bool
1655 12088 : _equalReturnStmt(const ReturnStmt *a, const ReturnStmt *b)
1656 : {
1657 12088 : COMPARE_NODE_FIELD(returnval);
1658 :
1659 12088 : return true;
1660 : }
1661 :
1662 : static bool
1663 0 : _equalPLAssignStmt(const PLAssignStmt *a, const PLAssignStmt *b)
1664 : {
1665 0 : COMPARE_STRING_FIELD(name);
1666 0 : COMPARE_NODE_FIELD(indirection);
1667 0 : COMPARE_SCALAR_FIELD(nnames);
1668 0 : COMPARE_NODE_FIELD(val);
1669 : COMPARE_LOCATION_FIELD(location);
1670 :
1671 0 : return true;
1672 : }
1673 :
1674 : static bool
1675 3640 : _equalCreateSchemaStmt(const CreateSchemaStmt *a, const CreateSchemaStmt *b)
1676 : {
1677 3640 : COMPARE_STRING_FIELD(schemaname);
1678 3640 : COMPARE_NODE_FIELD(authrole);
1679 3640 : COMPARE_NODE_FIELD(schemaElts);
1680 3640 : COMPARE_SCALAR_FIELD(if_not_exists);
1681 :
1682 3640 : return true;
1683 : }
1684 :
1685 : static bool
1686 92984 : _equalAlterTableStmt(const AlterTableStmt *a, const AlterTableStmt *b)
1687 : {
1688 92984 : COMPARE_NODE_FIELD(relation);
1689 92984 : COMPARE_NODE_FIELD(cmds);
1690 92984 : COMPARE_SCALAR_FIELD(objtype);
1691 92984 : COMPARE_SCALAR_FIELD(missing_ok);
1692 :
1693 92984 : return true;
1694 : }
1695 :
1696 : static bool
1697 1672 : _equalReplicaIdentityStmt(const ReplicaIdentityStmt *a, const ReplicaIdentityStmt *b)
1698 : {
1699 1672 : COMPARE_SCALAR_FIELD(identity_type);
1700 1672 : COMPARE_STRING_FIELD(name);
1701 :
1702 1672 : return true;
1703 : }
1704 :
1705 : static bool
1706 96200 : _equalAlterTableCmd(const AlterTableCmd *a, const AlterTableCmd *b)
1707 : {
1708 96200 : COMPARE_SCALAR_FIELD(subtype);
1709 96200 : COMPARE_STRING_FIELD(name);
1710 96200 : COMPARE_SCALAR_FIELD(num);
1711 96200 : COMPARE_NODE_FIELD(newowner);
1712 96200 : COMPARE_NODE_FIELD(def);
1713 96200 : COMPARE_SCALAR_FIELD(behavior);
1714 96200 : COMPARE_SCALAR_FIELD(missing_ok);
1715 96200 : COMPARE_SCALAR_FIELD(recurse);
1716 :
1717 96200 : return true;
1718 : }
1719 :
1720 : static bool
1721 8 : _equalAlterCollationStmt(const AlterCollationStmt *a, const AlterCollationStmt *b)
1722 : {
1723 8 : COMPARE_NODE_FIELD(collname);
1724 :
1725 8 : return true;
1726 : }
1727 :
1728 : static bool
1729 960 : _equalAlterDomainStmt(const AlterDomainStmt *a, const AlterDomainStmt *b)
1730 : {
1731 960 : COMPARE_SCALAR_FIELD(subtype);
1732 960 : COMPARE_NODE_FIELD(typeName);
1733 960 : COMPARE_STRING_FIELD(name);
1734 960 : COMPARE_NODE_FIELD(def);
1735 960 : COMPARE_SCALAR_FIELD(behavior);
1736 960 : COMPARE_SCALAR_FIELD(missing_ok);
1737 :
1738 960 : return true;
1739 : }
1740 :
1741 : static bool
1742 51204 : _equalGrantStmt(const GrantStmt *a, const GrantStmt *b)
1743 : {
1744 51204 : COMPARE_SCALAR_FIELD(is_grant);
1745 51204 : COMPARE_SCALAR_FIELD(targtype);
1746 51204 : COMPARE_SCALAR_FIELD(objtype);
1747 51204 : COMPARE_NODE_FIELD(objects);
1748 51204 : COMPARE_NODE_FIELD(privileges);
1749 51204 : COMPARE_NODE_FIELD(grantees);
1750 51204 : COMPARE_SCALAR_FIELD(grant_option);
1751 51204 : COMPARE_NODE_FIELD(grantor);
1752 51204 : COMPARE_SCALAR_FIELD(behavior);
1753 :
1754 51204 : return true;
1755 : }
1756 :
1757 : static bool
1758 61364 : _equalObjectWithArgs(const ObjectWithArgs *a, const ObjectWithArgs *b)
1759 : {
1760 61364 : COMPARE_NODE_FIELD(objname);
1761 61364 : COMPARE_NODE_FIELD(objargs);
1762 61364 : COMPARE_NODE_FIELD(objfuncargs);
1763 61364 : COMPARE_SCALAR_FIELD(args_unspecified);
1764 :
1765 61364 : return true;
1766 : }
1767 :
1768 : static bool
1769 48572 : _equalAccessPriv(const AccessPriv *a, const AccessPriv *b)
1770 : {
1771 48572 : COMPARE_STRING_FIELD(priv_name);
1772 48572 : COMPARE_NODE_FIELD(cols);
1773 :
1774 48572 : return true;
1775 : }
1776 :
1777 : static bool
1778 3240 : _equalGrantRoleStmt(const GrantRoleStmt *a, const GrantRoleStmt *b)
1779 : {
1780 3240 : COMPARE_NODE_FIELD(granted_roles);
1781 3240 : COMPARE_NODE_FIELD(grantee_roles);
1782 3240 : COMPARE_SCALAR_FIELD(is_grant);
1783 3240 : COMPARE_NODE_FIELD(opt);
1784 3240 : COMPARE_NODE_FIELD(grantor);
1785 3240 : COMPARE_SCALAR_FIELD(behavior);
1786 :
1787 3240 : return true;
1788 : }
1789 :
1790 : static bool
1791 640 : _equalAlterDefaultPrivilegesStmt(const AlterDefaultPrivilegesStmt *a, const AlterDefaultPrivilegesStmt *b)
1792 : {
1793 640 : COMPARE_NODE_FIELD(options);
1794 640 : COMPARE_NODE_FIELD(action);
1795 :
1796 640 : return true;
1797 : }
1798 :
1799 : static bool
1800 35128 : _equalCopyStmt(const CopyStmt *a, const CopyStmt *b)
1801 : {
1802 35128 : COMPARE_NODE_FIELD(relation);
1803 35128 : COMPARE_NODE_FIELD(query);
1804 35128 : COMPARE_NODE_FIELD(attlist);
1805 35128 : COMPARE_SCALAR_FIELD(is_from);
1806 35128 : COMPARE_SCALAR_FIELD(is_program);
1807 35128 : COMPARE_STRING_FIELD(filename);
1808 35128 : COMPARE_NODE_FIELD(options);
1809 35128 : COMPARE_NODE_FIELD(whereClause);
1810 :
1811 35128 : return true;
1812 : }
1813 :
1814 : static bool
1815 90768 : _equalVariableSetStmt(const VariableSetStmt *a, const VariableSetStmt *b)
1816 : {
1817 90768 : COMPARE_SCALAR_FIELD(kind);
1818 90768 : COMPARE_STRING_FIELD(name);
1819 90768 : COMPARE_NODE_FIELD(args);
1820 90768 : COMPARE_SCALAR_FIELD(is_local);
1821 :
1822 90768 : return true;
1823 : }
1824 :
1825 : static bool
1826 3264 : _equalVariableShowStmt(const VariableShowStmt *a, const VariableShowStmt *b)
1827 : {
1828 3264 : COMPARE_STRING_FIELD(name);
1829 :
1830 3264 : return true;
1831 : }
1832 :
1833 : static bool
1834 130904 : _equalCreateStmt(const CreateStmt *a, const CreateStmt *b)
1835 : {
1836 130904 : COMPARE_NODE_FIELD(relation);
1837 130904 : COMPARE_NODE_FIELD(tableElts);
1838 130904 : COMPARE_NODE_FIELD(inhRelations);
1839 130904 : COMPARE_NODE_FIELD(partbound);
1840 130904 : COMPARE_NODE_FIELD(partspec);
1841 130904 : COMPARE_NODE_FIELD(ofTypename);
1842 130904 : COMPARE_NODE_FIELD(constraints);
1843 130904 : COMPARE_NODE_FIELD(nnconstraints);
1844 130904 : COMPARE_NODE_FIELD(options);
1845 130904 : COMPARE_SCALAR_FIELD(oncommit);
1846 130904 : COMPARE_STRING_FIELD(tablespacename);
1847 130904 : COMPARE_STRING_FIELD(accessMethod);
1848 130904 : COMPARE_SCALAR_FIELD(if_not_exists);
1849 :
1850 130904 : return true;
1851 : }
1852 :
1853 : static bool
1854 107588 : _equalConstraint(const Constraint *a, const Constraint *b)
1855 : {
1856 107588 : COMPARE_SCALAR_FIELD(contype);
1857 107588 : COMPARE_STRING_FIELD(conname);
1858 107588 : COMPARE_SCALAR_FIELD(deferrable);
1859 107588 : COMPARE_SCALAR_FIELD(initdeferred);
1860 : COMPARE_LOCATION_FIELD(location);
1861 107588 : COMPARE_SCALAR_FIELD(is_no_inherit);
1862 107588 : COMPARE_NODE_FIELD(raw_expr);
1863 107588 : COMPARE_STRING_FIELD(cooked_expr);
1864 107588 : COMPARE_SCALAR_FIELD(generated_when);
1865 107588 : COMPARE_SCALAR_FIELD(inhcount);
1866 107588 : COMPARE_SCALAR_FIELD(nulls_not_distinct);
1867 107588 : COMPARE_NODE_FIELD(keys);
1868 107588 : COMPARE_NODE_FIELD(including);
1869 107588 : COMPARE_NODE_FIELD(exclusions);
1870 107588 : COMPARE_NODE_FIELD(options);
1871 107588 : COMPARE_STRING_FIELD(indexname);
1872 107588 : COMPARE_STRING_FIELD(indexspace);
1873 107588 : COMPARE_SCALAR_FIELD(reset_default_tblspc);
1874 107588 : COMPARE_STRING_FIELD(access_method);
1875 107588 : COMPARE_NODE_FIELD(where_clause);
1876 107588 : COMPARE_NODE_FIELD(pktable);
1877 107588 : COMPARE_NODE_FIELD(fk_attrs);
1878 107588 : COMPARE_NODE_FIELD(pk_attrs);
1879 107588 : COMPARE_SCALAR_FIELD(fk_matchtype);
1880 107588 : COMPARE_SCALAR_FIELD(fk_upd_action);
1881 107588 : COMPARE_SCALAR_FIELD(fk_del_action);
1882 107588 : COMPARE_NODE_FIELD(fk_del_set_cols);
1883 107588 : COMPARE_NODE_FIELD(old_conpfeqop);
1884 107588 : COMPARE_SCALAR_FIELD(old_pktable_oid);
1885 107588 : COMPARE_SCALAR_FIELD(skip_validation);
1886 107588 : COMPARE_SCALAR_FIELD(initially_valid);
1887 :
1888 107588 : return true;
1889 : }
1890 :
1891 : static bool
1892 432 : _equalCreateTableSpaceStmt(const CreateTableSpaceStmt *a, const CreateTableSpaceStmt *b)
1893 : {
1894 432 : COMPARE_STRING_FIELD(tablespacename);
1895 432 : COMPARE_NODE_FIELD(owner);
1896 432 : COMPARE_STRING_FIELD(location);
1897 432 : COMPARE_NODE_FIELD(options);
1898 :
1899 432 : return true;
1900 : }
1901 :
1902 : static bool
1903 248 : _equalDropTableSpaceStmt(const DropTableSpaceStmt *a, const DropTableSpaceStmt *b)
1904 : {
1905 248 : COMPARE_STRING_FIELD(tablespacename);
1906 248 : COMPARE_SCALAR_FIELD(missing_ok);
1907 :
1908 248 : return true;
1909 : }
1910 :
1911 : static bool
1912 96 : _equalAlterTableSpaceOptionsStmt(const AlterTableSpaceOptionsStmt *a, const AlterTableSpaceOptionsStmt *b)
1913 : {
1914 96 : COMPARE_STRING_FIELD(tablespacename);
1915 96 : COMPARE_NODE_FIELD(options);
1916 96 : COMPARE_SCALAR_FIELD(isReset);
1917 :
1918 96 : return true;
1919 : }
1920 :
1921 : static bool
1922 120 : _equalAlterTableMoveAllStmt(const AlterTableMoveAllStmt *a, const AlterTableMoveAllStmt *b)
1923 : {
1924 120 : COMPARE_STRING_FIELD(orig_tablespacename);
1925 120 : COMPARE_SCALAR_FIELD(objtype);
1926 120 : COMPARE_NODE_FIELD(roles);
1927 120 : COMPARE_STRING_FIELD(new_tablespacename);
1928 120 : COMPARE_SCALAR_FIELD(nowait);
1929 :
1930 120 : return true;
1931 : }
1932 :
1933 : static bool
1934 1504 : _equalCreateExtensionStmt(const CreateExtensionStmt *a, const CreateExtensionStmt *b)
1935 : {
1936 1504 : COMPARE_STRING_FIELD(extname);
1937 1504 : COMPARE_SCALAR_FIELD(if_not_exists);
1938 1504 : COMPARE_NODE_FIELD(options);
1939 :
1940 1504 : return true;
1941 : }
1942 :
1943 : static bool
1944 100 : _equalAlterExtensionStmt(const AlterExtensionStmt *a, const AlterExtensionStmt *b)
1945 : {
1946 100 : COMPARE_STRING_FIELD(extname);
1947 100 : COMPARE_NODE_FIELD(options);
1948 :
1949 100 : return true;
1950 : }
1951 :
1952 : static bool
1953 712 : _equalAlterExtensionContentsStmt(const AlterExtensionContentsStmt *a, const AlterExtensionContentsStmt *b)
1954 : {
1955 712 : COMPARE_STRING_FIELD(extname);
1956 712 : COMPARE_SCALAR_FIELD(action);
1957 712 : COMPARE_SCALAR_FIELD(objtype);
1958 712 : COMPARE_NODE_FIELD(object);
1959 :
1960 712 : return true;
1961 : }
1962 :
1963 : static bool
1964 744 : _equalCreateFdwStmt(const CreateFdwStmt *a, const CreateFdwStmt *b)
1965 : {
1966 744 : COMPARE_STRING_FIELD(fdwname);
1967 744 : COMPARE_NODE_FIELD(func_options);
1968 744 : COMPARE_NODE_FIELD(options);
1969 :
1970 744 : return true;
1971 : }
1972 :
1973 : static bool
1974 488 : _equalAlterFdwStmt(const AlterFdwStmt *a, const AlterFdwStmt *b)
1975 : {
1976 488 : COMPARE_STRING_FIELD(fdwname);
1977 488 : COMPARE_NODE_FIELD(func_options);
1978 488 : COMPARE_NODE_FIELD(options);
1979 :
1980 488 : return true;
1981 : }
1982 :
1983 : static bool
1984 1052 : _equalCreateForeignServerStmt(const CreateForeignServerStmt *a, const CreateForeignServerStmt *b)
1985 : {
1986 1052 : COMPARE_STRING_FIELD(servername);
1987 1052 : COMPARE_STRING_FIELD(servertype);
1988 1052 : COMPARE_STRING_FIELD(version);
1989 1052 : COMPARE_STRING_FIELD(fdwname);
1990 1052 : COMPARE_SCALAR_FIELD(if_not_exists);
1991 1052 : COMPARE_NODE_FIELD(options);
1992 :
1993 1052 : return true;
1994 : }
1995 :
1996 : static bool
1997 852 : _equalAlterForeignServerStmt(const AlterForeignServerStmt *a, const AlterForeignServerStmt *b)
1998 : {
1999 852 : COMPARE_STRING_FIELD(servername);
2000 852 : COMPARE_STRING_FIELD(version);
2001 852 : COMPARE_NODE_FIELD(options);
2002 852 : COMPARE_SCALAR_FIELD(has_version);
2003 :
2004 852 : return true;
2005 : }
2006 :
2007 : static bool
2008 1640 : _equalCreateForeignTableStmt(const CreateForeignTableStmt *a, const CreateForeignTableStmt *b)
2009 : {
2010 1640 : COMPARE_NODE_FIELD(base.relation);
2011 1640 : COMPARE_NODE_FIELD(base.tableElts);
2012 1640 : COMPARE_NODE_FIELD(base.inhRelations);
2013 1640 : COMPARE_NODE_FIELD(base.partbound);
2014 1640 : COMPARE_NODE_FIELD(base.partspec);
2015 1640 : COMPARE_NODE_FIELD(base.ofTypename);
2016 1640 : COMPARE_NODE_FIELD(base.constraints);
2017 1640 : COMPARE_NODE_FIELD(base.nnconstraints);
2018 1640 : COMPARE_NODE_FIELD(base.options);
2019 1640 : COMPARE_SCALAR_FIELD(base.oncommit);
2020 1640 : COMPARE_STRING_FIELD(base.tablespacename);
2021 1640 : COMPARE_STRING_FIELD(base.accessMethod);
2022 1640 : COMPARE_SCALAR_FIELD(base.if_not_exists);
2023 1640 : COMPARE_STRING_FIELD(servername);
2024 1640 : COMPARE_NODE_FIELD(options);
2025 :
2026 1640 : return true;
2027 : }
2028 :
2029 : static bool
2030 952 : _equalCreateUserMappingStmt(const CreateUserMappingStmt *a, const CreateUserMappingStmt *b)
2031 : {
2032 952 : COMPARE_NODE_FIELD(user);
2033 952 : COMPARE_STRING_FIELD(servername);
2034 952 : COMPARE_SCALAR_FIELD(if_not_exists);
2035 952 : COMPARE_NODE_FIELD(options);
2036 :
2037 952 : return true;
2038 : }
2039 :
2040 : static bool
2041 440 : _equalAlterUserMappingStmt(const AlterUserMappingStmt *a, const AlterUserMappingStmt *b)
2042 : {
2043 440 : COMPARE_NODE_FIELD(user);
2044 440 : COMPARE_STRING_FIELD(servername);
2045 440 : COMPARE_NODE_FIELD(options);
2046 :
2047 440 : return true;
2048 : }
2049 :
2050 : static bool
2051 504 : _equalDropUserMappingStmt(const DropUserMappingStmt *a, const DropUserMappingStmt *b)
2052 : {
2053 504 : COMPARE_NODE_FIELD(user);
2054 504 : COMPARE_STRING_FIELD(servername);
2055 504 : COMPARE_SCALAR_FIELD(missing_ok);
2056 :
2057 504 : return true;
2058 : }
2059 :
2060 : static bool
2061 176 : _equalImportForeignSchemaStmt(const ImportForeignSchemaStmt *a, const ImportForeignSchemaStmt *b)
2062 : {
2063 176 : COMPARE_STRING_FIELD(server_name);
2064 176 : COMPARE_STRING_FIELD(remote_schema);
2065 176 : COMPARE_STRING_FIELD(local_schema);
2066 176 : COMPARE_SCALAR_FIELD(list_type);
2067 176 : COMPARE_NODE_FIELD(table_list);
2068 176 : COMPARE_NODE_FIELD(options);
2069 :
2070 176 : return true;
2071 : }
2072 :
2073 : static bool
2074 2608 : _equalCreatePolicyStmt(const CreatePolicyStmt *a, const CreatePolicyStmt *b)
2075 : {
2076 2608 : COMPARE_STRING_FIELD(policy_name);
2077 2608 : COMPARE_NODE_FIELD(table);
2078 2608 : COMPARE_STRING_FIELD(cmd_name);
2079 2608 : COMPARE_SCALAR_FIELD(permissive);
2080 2608 : COMPARE_NODE_FIELD(roles);
2081 2608 : COMPARE_NODE_FIELD(qual);
2082 2608 : COMPARE_NODE_FIELD(with_check);
2083 :
2084 2608 : return true;
2085 : }
2086 :
2087 : static bool
2088 336 : _equalAlterPolicyStmt(const AlterPolicyStmt *a, const AlterPolicyStmt *b)
2089 : {
2090 336 : COMPARE_STRING_FIELD(policy_name);
2091 336 : COMPARE_NODE_FIELD(table);
2092 336 : COMPARE_NODE_FIELD(roles);
2093 336 : COMPARE_NODE_FIELD(qual);
2094 336 : COMPARE_NODE_FIELD(with_check);
2095 :
2096 336 : return true;
2097 : }
2098 :
2099 : static bool
2100 240 : _equalCreateAmStmt(const CreateAmStmt *a, const CreateAmStmt *b)
2101 : {
2102 240 : COMPARE_STRING_FIELD(amname);
2103 240 : COMPARE_NODE_FIELD(handler_name);
2104 240 : COMPARE_SCALAR_FIELD(amtype);
2105 :
2106 240 : return true;
2107 : }
2108 :
2109 : static bool
2110 12328 : _equalCreateTrigStmt(const CreateTrigStmt *a, const CreateTrigStmt *b)
2111 : {
2112 12328 : COMPARE_SCALAR_FIELD(replace);
2113 12328 : COMPARE_SCALAR_FIELD(isconstraint);
2114 12328 : COMPARE_STRING_FIELD(trigname);
2115 12328 : COMPARE_NODE_FIELD(relation);
2116 12328 : COMPARE_NODE_FIELD(funcname);
2117 12328 : COMPARE_NODE_FIELD(args);
2118 12328 : COMPARE_SCALAR_FIELD(row);
2119 12328 : COMPARE_SCALAR_FIELD(timing);
2120 12328 : COMPARE_SCALAR_FIELD(events);
2121 12328 : COMPARE_NODE_FIELD(columns);
2122 12328 : COMPARE_NODE_FIELD(whenClause);
2123 12328 : COMPARE_NODE_FIELD(transitionRels);
2124 12328 : COMPARE_SCALAR_FIELD(deferrable);
2125 12328 : COMPARE_SCALAR_FIELD(initdeferred);
2126 12328 : COMPARE_NODE_FIELD(constrrel);
2127 :
2128 12328 : return true;
2129 : }
2130 :
2131 : static bool
2132 712 : _equalCreateEventTrigStmt(const CreateEventTrigStmt *a, const CreateEventTrigStmt *b)
2133 : {
2134 712 : COMPARE_STRING_FIELD(trigname);
2135 712 : COMPARE_STRING_FIELD(eventname);
2136 712 : COMPARE_NODE_FIELD(whenclause);
2137 712 : COMPARE_NODE_FIELD(funcname);
2138 :
2139 712 : return true;
2140 : }
2141 :
2142 : static bool
2143 168 : _equalAlterEventTrigStmt(const AlterEventTrigStmt *a, const AlterEventTrigStmt *b)
2144 : {
2145 168 : COMPARE_STRING_FIELD(trigname);
2146 168 : COMPARE_SCALAR_FIELD(tgenabled);
2147 :
2148 168 : return true;
2149 : }
2150 :
2151 : static bool
2152 424 : _equalCreatePLangStmt(const CreatePLangStmt *a, const CreatePLangStmt *b)
2153 : {
2154 424 : COMPARE_SCALAR_FIELD(replace);
2155 424 : COMPARE_STRING_FIELD(plname);
2156 424 : COMPARE_NODE_FIELD(plhandler);
2157 424 : COMPARE_NODE_FIELD(plinline);
2158 424 : COMPARE_NODE_FIELD(plvalidator);
2159 424 : COMPARE_SCALAR_FIELD(pltrusted);
2160 :
2161 424 : return true;
2162 : }
2163 :
2164 : static bool
2165 6576 : _equalCreateRoleStmt(const CreateRoleStmt *a, const CreateRoleStmt *b)
2166 : {
2167 6576 : COMPARE_SCALAR_FIELD(stmt_type);
2168 6576 : COMPARE_STRING_FIELD(role);
2169 6576 : COMPARE_NODE_FIELD(options);
2170 :
2171 6576 : return true;
2172 : }
2173 :
2174 : static bool
2175 1680 : _equalAlterRoleStmt(const AlterRoleStmt *a, const AlterRoleStmt *b)
2176 : {
2177 1680 : COMPARE_NODE_FIELD(role);
2178 1680 : COMPARE_NODE_FIELD(options);
2179 1680 : COMPARE_SCALAR_FIELD(action);
2180 :
2181 1680 : return true;
2182 : }
2183 :
2184 : static bool
2185 312 : _equalAlterRoleSetStmt(const AlterRoleSetStmt *a, const AlterRoleSetStmt *b)
2186 : {
2187 312 : COMPARE_NODE_FIELD(role);
2188 312 : COMPARE_STRING_FIELD(database);
2189 312 : COMPARE_NODE_FIELD(setstmt);
2190 :
2191 312 : return true;
2192 : }
2193 :
2194 : static bool
2195 6424 : _equalDropRoleStmt(const DropRoleStmt *a, const DropRoleStmt *b)
2196 : {
2197 6424 : COMPARE_NODE_FIELD(roles);
2198 6424 : COMPARE_SCALAR_FIELD(missing_ok);
2199 :
2200 6424 : return true;
2201 : }
2202 :
2203 : static bool
2204 2536 : _equalCreateSeqStmt(const CreateSeqStmt *a, const CreateSeqStmt *b)
2205 : {
2206 2536 : COMPARE_NODE_FIELD(sequence);
2207 2536 : COMPARE_NODE_FIELD(options);
2208 2536 : COMPARE_SCALAR_FIELD(ownerId);
2209 2536 : COMPARE_SCALAR_FIELD(for_identity);
2210 2536 : COMPARE_SCALAR_FIELD(if_not_exists);
2211 :
2212 2536 : return true;
2213 : }
2214 :
2215 : static bool
2216 784 : _equalAlterSeqStmt(const AlterSeqStmt *a, const AlterSeqStmt *b)
2217 : {
2218 784 : COMPARE_NODE_FIELD(sequence);
2219 784 : COMPARE_NODE_FIELD(options);
2220 784 : COMPARE_SCALAR_FIELD(for_identity);
2221 784 : COMPARE_SCALAR_FIELD(missing_ok);
2222 :
2223 784 : return true;
2224 : }
2225 :
2226 : static bool
2227 27000 : _equalDefineStmt(const DefineStmt *a, const DefineStmt *b)
2228 : {
2229 27000 : COMPARE_SCALAR_FIELD(kind);
2230 27000 : COMPARE_SCALAR_FIELD(oldstyle);
2231 27000 : COMPARE_NODE_FIELD(defnames);
2232 27000 : COMPARE_NODE_FIELD(args);
2233 27000 : COMPARE_NODE_FIELD(definition);
2234 27000 : COMPARE_SCALAR_FIELD(if_not_exists);
2235 27000 : COMPARE_SCALAR_FIELD(replace);
2236 :
2237 27000 : return true;
2238 : }
2239 :
2240 : static bool
2241 3840 : _equalCreateDomainStmt(const CreateDomainStmt *a, const CreateDomainStmt *b)
2242 : {
2243 3840 : COMPARE_NODE_FIELD(domainname);
2244 3840 : COMPARE_NODE_FIELD(typeName);
2245 3840 : COMPARE_NODE_FIELD(collClause);
2246 3840 : COMPARE_NODE_FIELD(constraints);
2247 :
2248 3840 : return true;
2249 : }
2250 :
2251 : static bool
2252 1512 : _equalCreateOpClassStmt(const CreateOpClassStmt *a, const CreateOpClassStmt *b)
2253 : {
2254 1512 : COMPARE_NODE_FIELD(opclassname);
2255 1512 : COMPARE_NODE_FIELD(opfamilyname);
2256 1512 : COMPARE_STRING_FIELD(amname);
2257 1512 : COMPARE_NODE_FIELD(datatype);
2258 1512 : COMPARE_NODE_FIELD(items);
2259 1512 : COMPARE_SCALAR_FIELD(isDefault);
2260 :
2261 1512 : return true;
2262 : }
2263 :
2264 : static bool
2265 15632 : _equalCreateOpClassItem(const CreateOpClassItem *a, const CreateOpClassItem *b)
2266 : {
2267 15632 : COMPARE_SCALAR_FIELD(itemtype);
2268 15632 : COMPARE_NODE_FIELD(name);
2269 15632 : COMPARE_SCALAR_FIELD(number);
2270 15632 : COMPARE_NODE_FIELD(order_family);
2271 15632 : COMPARE_NODE_FIELD(class_args);
2272 15632 : COMPARE_NODE_FIELD(storedtype);
2273 :
2274 15632 : return true;
2275 : }
2276 :
2277 : static bool
2278 592 : _equalCreateOpFamilyStmt(const CreateOpFamilyStmt *a, const CreateOpFamilyStmt *b)
2279 : {
2280 592 : COMPARE_NODE_FIELD(opfamilyname);
2281 592 : COMPARE_STRING_FIELD(amname);
2282 :
2283 592 : return true;
2284 : }
2285 :
2286 : static bool
2287 1800 : _equalAlterOpFamilyStmt(const AlterOpFamilyStmt *a, const AlterOpFamilyStmt *b)
2288 : {
2289 1800 : COMPARE_NODE_FIELD(opfamilyname);
2290 1800 : COMPARE_STRING_FIELD(amname);
2291 1800 : COMPARE_SCALAR_FIELD(isDrop);
2292 1800 : COMPARE_NODE_FIELD(items);
2293 :
2294 1800 : return true;
2295 : }
2296 :
2297 : static bool
2298 91620 : _equalDropStmt(const DropStmt *a, const DropStmt *b)
2299 : {
2300 91620 : COMPARE_NODE_FIELD(objects);
2301 91620 : COMPARE_SCALAR_FIELD(removeType);
2302 91620 : COMPARE_SCALAR_FIELD(behavior);
2303 91620 : COMPARE_SCALAR_FIELD(missing_ok);
2304 91620 : COMPARE_SCALAR_FIELD(concurrent);
2305 :
2306 91620 : return true;
2307 : }
2308 :
2309 : static bool
2310 5396 : _equalTruncateStmt(const TruncateStmt *a, const TruncateStmt *b)
2311 : {
2312 5396 : COMPARE_NODE_FIELD(relations);
2313 5396 : COMPARE_SCALAR_FIELD(restart_seqs);
2314 5396 : COMPARE_SCALAR_FIELD(behavior);
2315 :
2316 5396 : return true;
2317 : }
2318 :
2319 : static bool
2320 18256 : _equalCommentStmt(const CommentStmt *a, const CommentStmt *b)
2321 : {
2322 18256 : COMPARE_SCALAR_FIELD(objtype);
2323 18256 : COMPARE_NODE_FIELD(object);
2324 18256 : COMPARE_STRING_FIELD(comment);
2325 :
2326 18256 : return true;
2327 : }
2328 :
2329 : static bool
2330 400 : _equalSecLabelStmt(const SecLabelStmt *a, const SecLabelStmt *b)
2331 : {
2332 400 : COMPARE_SCALAR_FIELD(objtype);
2333 400 : COMPARE_NODE_FIELD(object);
2334 400 : COMPARE_STRING_FIELD(provider);
2335 400 : COMPARE_STRING_FIELD(label);
2336 :
2337 400 : return true;
2338 : }
2339 :
2340 : static bool
2341 11316 : _equalDeclareCursorStmt(const DeclareCursorStmt *a, const DeclareCursorStmt *b)
2342 : {
2343 11316 : COMPARE_STRING_FIELD(portalname);
2344 11316 : COMPARE_SCALAR_FIELD(options);
2345 11316 : COMPARE_NODE_FIELD(query);
2346 :
2347 11316 : return true;
2348 : }
2349 :
2350 : static bool
2351 8736 : _equalClosePortalStmt(const ClosePortalStmt *a, const ClosePortalStmt *b)
2352 : {
2353 8736 : COMPARE_STRING_FIELD(portalname);
2354 :
2355 8736 : return true;
2356 : }
2357 :
2358 : static bool
2359 23832 : _equalFetchStmt(const FetchStmt *a, const FetchStmt *b)
2360 : {
2361 23832 : COMPARE_SCALAR_FIELD(direction);
2362 23832 : COMPARE_SCALAR_FIELD(howMany);
2363 23832 : COMPARE_STRING_FIELD(portalname);
2364 23832 : COMPARE_SCALAR_FIELD(ismove);
2365 :
2366 23832 : return true;
2367 : }
2368 :
2369 : static bool
2370 22584 : _equalIndexStmt(const IndexStmt *a, const IndexStmt *b)
2371 : {
2372 22584 : COMPARE_STRING_FIELD(idxname);
2373 22584 : COMPARE_NODE_FIELD(relation);
2374 22584 : COMPARE_STRING_FIELD(accessMethod);
2375 22584 : COMPARE_STRING_FIELD(tableSpace);
2376 22584 : COMPARE_NODE_FIELD(indexParams);
2377 22584 : COMPARE_NODE_FIELD(indexIncludingParams);
2378 22584 : COMPARE_NODE_FIELD(options);
2379 22584 : COMPARE_NODE_FIELD(whereClause);
2380 22584 : COMPARE_NODE_FIELD(excludeOpNames);
2381 22584 : COMPARE_STRING_FIELD(idxcomment);
2382 22584 : COMPARE_SCALAR_FIELD(indexOid);
2383 22584 : COMPARE_SCALAR_FIELD(oldNumber);
2384 22584 : COMPARE_SCALAR_FIELD(oldCreateSubid);
2385 22584 : COMPARE_SCALAR_FIELD(oldFirstRelfilelocatorSubid);
2386 22584 : COMPARE_SCALAR_FIELD(unique);
2387 22584 : COMPARE_SCALAR_FIELD(nulls_not_distinct);
2388 22584 : COMPARE_SCALAR_FIELD(primary);
2389 22584 : COMPARE_SCALAR_FIELD(isconstraint);
2390 22584 : COMPARE_SCALAR_FIELD(deferrable);
2391 22584 : COMPARE_SCALAR_FIELD(initdeferred);
2392 22584 : COMPARE_SCALAR_FIELD(transformed);
2393 22584 : COMPARE_SCALAR_FIELD(concurrent);
2394 22584 : COMPARE_SCALAR_FIELD(if_not_exists);
2395 22584 : COMPARE_SCALAR_FIELD(reset_default_tblspc);
2396 :
2397 22584 : return true;
2398 : }
2399 :
2400 : static bool
2401 2172 : _equalCreateStatsStmt(const CreateStatsStmt *a, const CreateStatsStmt *b)
2402 : {
2403 2172 : COMPARE_NODE_FIELD(defnames);
2404 2172 : COMPARE_NODE_FIELD(stat_types);
2405 2172 : COMPARE_NODE_FIELD(exprs);
2406 2172 : COMPARE_NODE_FIELD(relations);
2407 2172 : COMPARE_STRING_FIELD(stxcomment);
2408 2172 : COMPARE_SCALAR_FIELD(transformed);
2409 2172 : COMPARE_SCALAR_FIELD(if_not_exists);
2410 :
2411 2172 : return true;
2412 : }
2413 :
2414 : static bool
2415 5696 : _equalStatsElem(const StatsElem *a, const StatsElem *b)
2416 : {
2417 5696 : COMPARE_STRING_FIELD(name);
2418 5696 : COMPARE_NODE_FIELD(expr);
2419 :
2420 5696 : return true;
2421 : }
2422 :
2423 : static bool
2424 104 : _equalAlterStatsStmt(const AlterStatsStmt *a, const AlterStatsStmt *b)
2425 : {
2426 104 : COMPARE_NODE_FIELD(defnames);
2427 104 : COMPARE_SCALAR_FIELD(stxstattarget);
2428 104 : COMPARE_SCALAR_FIELD(missing_ok);
2429 :
2430 104 : return true;
2431 : }
2432 :
2433 : static bool
2434 74920 : _equalCreateFunctionStmt(const CreateFunctionStmt *a, const CreateFunctionStmt *b)
2435 : {
2436 74920 : COMPARE_SCALAR_FIELD(is_procedure);
2437 74920 : COMPARE_SCALAR_FIELD(replace);
2438 74920 : COMPARE_NODE_FIELD(funcname);
2439 74920 : COMPARE_NODE_FIELD(parameters);
2440 74920 : COMPARE_NODE_FIELD(returnType);
2441 74920 : COMPARE_NODE_FIELD(options);
2442 74920 : COMPARE_NODE_FIELD(sql_body);
2443 :
2444 74920 : return true;
2445 : }
2446 :
2447 : static bool
2448 218808 : _equalFunctionParameter(const FunctionParameter *a, const FunctionParameter *b)
2449 : {
2450 218808 : COMPARE_STRING_FIELD(name);
2451 218808 : COMPARE_NODE_FIELD(argType);
2452 218808 : COMPARE_SCALAR_FIELD(mode);
2453 218808 : COMPARE_NODE_FIELD(defexpr);
2454 :
2455 218808 : return true;
2456 : }
2457 :
2458 : static bool
2459 2528 : _equalAlterFunctionStmt(const AlterFunctionStmt *a, const AlterFunctionStmt *b)
2460 : {
2461 2528 : COMPARE_SCALAR_FIELD(objtype);
2462 2528 : COMPARE_NODE_FIELD(func);
2463 2528 : COMPARE_NODE_FIELD(actions);
2464 :
2465 2528 : return true;
2466 : }
2467 :
2468 : static bool
2469 3896 : _equalDoStmt(const DoStmt *a, const DoStmt *b)
2470 : {
2471 3896 : COMPARE_NODE_FIELD(args);
2472 :
2473 3896 : return true;
2474 : }
2475 :
2476 : static bool
2477 1504 : _equalCallStmt(const CallStmt *a, const CallStmt *b)
2478 : {
2479 1504 : COMPARE_NODE_FIELD(funccall);
2480 1504 : COMPARE_NODE_FIELD(funcexpr);
2481 1504 : COMPARE_NODE_FIELD(outargs);
2482 :
2483 1504 : return true;
2484 : }
2485 :
2486 : static bool
2487 5400 : _equalRenameStmt(const RenameStmt *a, const RenameStmt *b)
2488 : {
2489 5400 : COMPARE_SCALAR_FIELD(renameType);
2490 5400 : COMPARE_SCALAR_FIELD(relationType);
2491 5400 : COMPARE_NODE_FIELD(relation);
2492 5400 : COMPARE_NODE_FIELD(object);
2493 5400 : COMPARE_STRING_FIELD(subname);
2494 5400 : COMPARE_STRING_FIELD(newname);
2495 5400 : COMPARE_SCALAR_FIELD(behavior);
2496 5400 : COMPARE_SCALAR_FIELD(missing_ok);
2497 :
2498 5400 : return true;
2499 : }
2500 :
2501 : static bool
2502 184 : _equalAlterObjectDependsStmt(const AlterObjectDependsStmt *a, const AlterObjectDependsStmt *b)
2503 : {
2504 184 : COMPARE_SCALAR_FIELD(objectType);
2505 184 : COMPARE_NODE_FIELD(relation);
2506 184 : COMPARE_NODE_FIELD(object);
2507 184 : COMPARE_NODE_FIELD(extname);
2508 184 : COMPARE_SCALAR_FIELD(remove);
2509 :
2510 184 : return true;
2511 : }
2512 :
2513 : static bool
2514 1544 : _equalAlterObjectSchemaStmt(const AlterObjectSchemaStmt *a, const AlterObjectSchemaStmt *b)
2515 : {
2516 1544 : COMPARE_SCALAR_FIELD(objectType);
2517 1544 : COMPARE_NODE_FIELD(relation);
2518 1544 : COMPARE_NODE_FIELD(object);
2519 1544 : COMPARE_STRING_FIELD(newschema);
2520 1544 : COMPARE_SCALAR_FIELD(missing_ok);
2521 :
2522 1544 : return true;
2523 : }
2524 :
2525 : static bool
2526 5900 : _equalAlterOwnerStmt(const AlterOwnerStmt *a, const AlterOwnerStmt *b)
2527 : {
2528 5900 : COMPARE_SCALAR_FIELD(objectType);
2529 5900 : COMPARE_NODE_FIELD(relation);
2530 5900 : COMPARE_NODE_FIELD(object);
2531 5900 : COMPARE_NODE_FIELD(newowner);
2532 :
2533 5900 : return true;
2534 : }
2535 :
2536 : static bool
2537 2392 : _equalAlterOperatorStmt(const AlterOperatorStmt *a, const AlterOperatorStmt *b)
2538 : {
2539 2392 : COMPARE_NODE_FIELD(opername);
2540 2392 : COMPARE_NODE_FIELD(options);
2541 :
2542 2392 : return true;
2543 : }
2544 :
2545 : static bool
2546 240 : _equalAlterTypeStmt(const AlterTypeStmt *a, const AlterTypeStmt *b)
2547 : {
2548 240 : COMPARE_NODE_FIELD(typeName);
2549 240 : COMPARE_NODE_FIELD(options);
2550 :
2551 240 : return true;
2552 : }
2553 :
2554 : static bool
2555 3936 : _equalRuleStmt(const RuleStmt *a, const RuleStmt *b)
2556 : {
2557 3936 : COMPARE_NODE_FIELD(relation);
2558 3936 : COMPARE_STRING_FIELD(rulename);
2559 3936 : COMPARE_NODE_FIELD(whereClause);
2560 3936 : COMPARE_SCALAR_FIELD(event);
2561 3936 : COMPARE_SCALAR_FIELD(instead);
2562 3936 : COMPARE_NODE_FIELD(actions);
2563 3936 : COMPARE_SCALAR_FIELD(replace);
2564 :
2565 3936 : return true;
2566 : }
2567 :
2568 : static bool
2569 502 : _equalNotifyStmt(const NotifyStmt *a, const NotifyStmt *b)
2570 : {
2571 502 : COMPARE_STRING_FIELD(conditionname);
2572 502 : COMPARE_STRING_FIELD(payload);
2573 :
2574 502 : return true;
2575 : }
2576 :
2577 : static bool
2578 296 : _equalListenStmt(const ListenStmt *a, const ListenStmt *b)
2579 : {
2580 296 : COMPARE_STRING_FIELD(conditionname);
2581 :
2582 296 : return true;
2583 : }
2584 :
2585 : static bool
2586 152 : _equalUnlistenStmt(const UnlistenStmt *a, const UnlistenStmt *b)
2587 : {
2588 152 : COMPARE_STRING_FIELD(conditionname);
2589 :
2590 152 : return true;
2591 : }
2592 :
2593 : static bool
2594 134340 : _equalTransactionStmt(const TransactionStmt *a, const TransactionStmt *b)
2595 : {
2596 134340 : COMPARE_SCALAR_FIELD(kind);
2597 134340 : COMPARE_NODE_FIELD(options);
2598 134340 : COMPARE_STRING_FIELD(savepoint_name);
2599 134340 : COMPARE_STRING_FIELD(gid);
2600 134340 : COMPARE_SCALAR_FIELD(chain);
2601 : COMPARE_LOCATION_FIELD(location);
2602 :
2603 134340 : return true;
2604 : }
2605 :
2606 : static bool
2607 2504 : _equalCompositeTypeStmt(const CompositeTypeStmt *a, const CompositeTypeStmt *b)
2608 : {
2609 2504 : COMPARE_NODE_FIELD(typevar);
2610 2504 : COMPARE_NODE_FIELD(coldeflist);
2611 :
2612 2504 : return true;
2613 : }
2614 :
2615 : static bool
2616 712 : _equalCreateEnumStmt(const CreateEnumStmt *a, const CreateEnumStmt *b)
2617 : {
2618 712 : COMPARE_NODE_FIELD(typeName);
2619 712 : COMPARE_NODE_FIELD(vals);
2620 :
2621 712 : return true;
2622 : }
2623 :
2624 : static bool
2625 528 : _equalCreateRangeStmt(const CreateRangeStmt *a, const CreateRangeStmt *b)
2626 : {
2627 528 : COMPARE_NODE_FIELD(typeName);
2628 528 : COMPARE_NODE_FIELD(params);
2629 :
2630 528 : return true;
2631 : }
2632 :
2633 : static bool
2634 1528 : _equalAlterEnumStmt(const AlterEnumStmt *a, const AlterEnumStmt *b)
2635 : {
2636 1528 : COMPARE_NODE_FIELD(typeName);
2637 1528 : COMPARE_STRING_FIELD(oldVal);
2638 1528 : COMPARE_STRING_FIELD(newVal);
2639 1528 : COMPARE_STRING_FIELD(newValNeighbor);
2640 1528 : COMPARE_SCALAR_FIELD(newValIsAfter);
2641 1528 : COMPARE_SCALAR_FIELD(skipIfNewValExists);
2642 :
2643 1528 : return true;
2644 : }
2645 :
2646 : static bool
2647 45152 : _equalViewStmt(const ViewStmt *a, const ViewStmt *b)
2648 : {
2649 45152 : COMPARE_NODE_FIELD(view);
2650 45152 : COMPARE_NODE_FIELD(aliases);
2651 45152 : COMPARE_NODE_FIELD(query);
2652 45152 : COMPARE_SCALAR_FIELD(replace);
2653 45152 : COMPARE_NODE_FIELD(options);
2654 45152 : COMPARE_SCALAR_FIELD(withCheckOption);
2655 :
2656 45152 : return true;
2657 : }
2658 :
2659 : static bool
2660 232 : _equalLoadStmt(const LoadStmt *a, const LoadStmt *b)
2661 : {
2662 232 : COMPARE_STRING_FIELD(filename);
2663 :
2664 232 : return true;
2665 : }
2666 :
2667 : static bool
2668 2232 : _equalCreatedbStmt(const CreatedbStmt *a, const CreatedbStmt *b)
2669 : {
2670 2232 : COMPARE_STRING_FIELD(dbname);
2671 2232 : COMPARE_NODE_FIELD(options);
2672 :
2673 2232 : return true;
2674 : }
2675 :
2676 : static bool
2677 112 : _equalAlterDatabaseStmt(const AlterDatabaseStmt *a, const AlterDatabaseStmt *b)
2678 : {
2679 112 : COMPARE_STRING_FIELD(dbname);
2680 112 : COMPARE_NODE_FIELD(options);
2681 :
2682 112 : return true;
2683 : }
2684 :
2685 : static bool
2686 8 : _equalAlterDatabaseRefreshCollStmt(const AlterDatabaseRefreshCollStmt *a, const AlterDatabaseRefreshCollStmt *b)
2687 : {
2688 8 : COMPARE_STRING_FIELD(dbname);
2689 :
2690 8 : return true;
2691 : }
2692 :
2693 : static bool
2694 4128 : _equalAlterDatabaseSetStmt(const AlterDatabaseSetStmt *a, const AlterDatabaseSetStmt *b)
2695 : {
2696 4128 : COMPARE_STRING_FIELD(dbname);
2697 4128 : COMPARE_NODE_FIELD(setstmt);
2698 :
2699 4128 : return true;
2700 : }
2701 :
2702 : static bool
2703 344 : _equalDropdbStmt(const DropdbStmt *a, const DropdbStmt *b)
2704 : {
2705 344 : COMPARE_STRING_FIELD(dbname);
2706 344 : COMPARE_SCALAR_FIELD(missing_ok);
2707 344 : COMPARE_NODE_FIELD(options);
2708 :
2709 344 : return true;
2710 : }
2711 :
2712 : static bool
2713 616 : _equalAlterSystemStmt(const AlterSystemStmt *a, const AlterSystemStmt *b)
2714 : {
2715 616 : COMPARE_NODE_FIELD(setstmt);
2716 :
2717 616 : return true;
2718 : }
2719 :
2720 : static bool
2721 816 : _equalClusterStmt(const ClusterStmt *a, const ClusterStmt *b)
2722 : {
2723 816 : COMPARE_NODE_FIELD(relation);
2724 816 : COMPARE_STRING_FIELD(indexname);
2725 816 : COMPARE_NODE_FIELD(params);
2726 :
2727 816 : return true;
2728 : }
2729 :
2730 : static bool
2731 37372 : _equalVacuumStmt(const VacuumStmt *a, const VacuumStmt *b)
2732 : {
2733 37372 : COMPARE_NODE_FIELD(options);
2734 37372 : COMPARE_NODE_FIELD(rels);
2735 37372 : COMPARE_SCALAR_FIELD(is_vacuumcmd);
2736 :
2737 37372 : return true;
2738 : }
2739 :
2740 : static bool
2741 37012 : _equalVacuumRelation(const VacuumRelation *a, const VacuumRelation *b)
2742 : {
2743 37012 : COMPARE_NODE_FIELD(relation);
2744 37012 : COMPARE_SCALAR_FIELD(oid);
2745 37012 : COMPARE_NODE_FIELD(va_cols);
2746 :
2747 37012 : return true;
2748 : }
2749 :
2750 : static bool
2751 66856 : _equalExplainStmt(const ExplainStmt *a, const ExplainStmt *b)
2752 : {
2753 66856 : COMPARE_NODE_FIELD(query);
2754 66856 : COMPARE_NODE_FIELD(options);
2755 :
2756 66856 : return true;
2757 : }
2758 :
2759 : static bool
2760 7132 : _equalCreateTableAsStmt(const CreateTableAsStmt *a, const CreateTableAsStmt *b)
2761 : {
2762 7132 : COMPARE_NODE_FIELD(query);
2763 7132 : COMPARE_NODE_FIELD(into);
2764 7132 : COMPARE_SCALAR_FIELD(objtype);
2765 7132 : COMPARE_SCALAR_FIELD(is_select_into);
2766 7132 : COMPARE_SCALAR_FIELD(if_not_exists);
2767 :
2768 7132 : return true;
2769 : }
2770 :
2771 : static bool
2772 912 : _equalRefreshMatViewStmt(const RefreshMatViewStmt *a, const RefreshMatViewStmt *b)
2773 : {
2774 912 : COMPARE_SCALAR_FIELD(concurrent);
2775 912 : COMPARE_SCALAR_FIELD(skipData);
2776 912 : COMPARE_NODE_FIELD(relation);
2777 :
2778 912 : return true;
2779 : }
2780 :
2781 : static bool
2782 672 : _equalCheckPointStmt(const CheckPointStmt *a, const CheckPointStmt *b)
2783 : {
2784 :
2785 672 : return true;
2786 : }
2787 :
2788 : static bool
2789 120 : _equalDiscardStmt(const DiscardStmt *a, const DiscardStmt *b)
2790 : {
2791 120 : COMPARE_SCALAR_FIELD(target);
2792 :
2793 120 : return true;
2794 : }
2795 :
2796 : static bool
2797 3952 : _equalLockStmt(const LockStmt *a, const LockStmt *b)
2798 : {
2799 3952 : COMPARE_NODE_FIELD(relations);
2800 3952 : COMPARE_SCALAR_FIELD(mode);
2801 3952 : COMPARE_SCALAR_FIELD(nowait);
2802 :
2803 3952 : return true;
2804 : }
2805 :
2806 : static bool
2807 404 : _equalConstraintsSetStmt(const ConstraintsSetStmt *a, const ConstraintsSetStmt *b)
2808 : {
2809 404 : COMPARE_NODE_FIELD(constraints);
2810 404 : COMPARE_SCALAR_FIELD(deferred);
2811 :
2812 404 : return true;
2813 : }
2814 :
2815 : static bool
2816 3296 : _equalReindexStmt(const ReindexStmt *a, const ReindexStmt *b)
2817 : {
2818 3296 : COMPARE_SCALAR_FIELD(kind);
2819 3296 : COMPARE_NODE_FIELD(relation);
2820 3296 : COMPARE_STRING_FIELD(name);
2821 3296 : COMPARE_NODE_FIELD(params);
2822 :
2823 3296 : return true;
2824 : }
2825 :
2826 : static bool
2827 256 : _equalCreateConversionStmt(const CreateConversionStmt *a, const CreateConversionStmt *b)
2828 : {
2829 256 : COMPARE_NODE_FIELD(conversion_name);
2830 256 : COMPARE_STRING_FIELD(for_encoding_name);
2831 256 : COMPARE_STRING_FIELD(to_encoding_name);
2832 256 : COMPARE_NODE_FIELD(func_name);
2833 256 : COMPARE_SCALAR_FIELD(def);
2834 :
2835 256 : return true;
2836 : }
2837 :
2838 : static bool
2839 1080 : _equalCreateCastStmt(const CreateCastStmt *a, const CreateCastStmt *b)
2840 : {
2841 1080 : COMPARE_NODE_FIELD(sourcetype);
2842 1080 : COMPARE_NODE_FIELD(targettype);
2843 1080 : COMPARE_NODE_FIELD(func);
2844 1080 : COMPARE_SCALAR_FIELD(context);
2845 1080 : COMPARE_SCALAR_FIELD(inout);
2846 :
2847 1080 : return true;
2848 : }
2849 :
2850 : static bool
2851 200 : _equalCreateTransformStmt(const CreateTransformStmt *a, const CreateTransformStmt *b)
2852 : {
2853 200 : COMPARE_SCALAR_FIELD(replace);
2854 200 : COMPARE_NODE_FIELD(type_name);
2855 200 : COMPARE_STRING_FIELD(lang);
2856 200 : COMPARE_NODE_FIELD(fromsql);
2857 200 : COMPARE_NODE_FIELD(tosql);
2858 :
2859 200 : return true;
2860 : }
2861 :
2862 : static bool
2863 6456 : _equalPrepareStmt(const PrepareStmt *a, const PrepareStmt *b)
2864 : {
2865 6456 : COMPARE_STRING_FIELD(name);
2866 6456 : COMPARE_NODE_FIELD(argtypes);
2867 6456 : COMPARE_NODE_FIELD(query);
2868 :
2869 6456 : return true;
2870 : }
2871 :
2872 : static bool
2873 45728 : _equalExecuteStmt(const ExecuteStmt *a, const ExecuteStmt *b)
2874 : {
2875 45728 : COMPARE_STRING_FIELD(name);
2876 45728 : COMPARE_NODE_FIELD(params);
2877 :
2878 45728 : return true;
2879 : }
2880 :
2881 : static bool
2882 16136 : _equalDeallocateStmt(const DeallocateStmt *a, const DeallocateStmt *b)
2883 : {
2884 16136 : COMPARE_STRING_FIELD(name);
2885 16136 : COMPARE_SCALAR_FIELD(isall);
2886 : COMPARE_LOCATION_FIELD(location);
2887 :
2888 16136 : return true;
2889 : }
2890 :
2891 : static bool
2892 576 : _equalDropOwnedStmt(const DropOwnedStmt *a, const DropOwnedStmt *b)
2893 : {
2894 576 : COMPARE_NODE_FIELD(roles);
2895 576 : COMPARE_SCALAR_FIELD(behavior);
2896 :
2897 576 : return true;
2898 : }
2899 :
2900 : static bool
2901 152 : _equalReassignOwnedStmt(const ReassignOwnedStmt *a, const ReassignOwnedStmt *b)
2902 : {
2903 152 : COMPARE_NODE_FIELD(roles);
2904 152 : COMPARE_NODE_FIELD(newrole);
2905 :
2906 152 : return true;
2907 : }
2908 :
2909 : static bool
2910 160 : _equalAlterTSDictionaryStmt(const AlterTSDictionaryStmt *a, const AlterTSDictionaryStmt *b)
2911 : {
2912 160 : COMPARE_NODE_FIELD(dictname);
2913 160 : COMPARE_NODE_FIELD(options);
2914 :
2915 160 : return true;
2916 : }
2917 :
2918 : static bool
2919 20928 : _equalAlterTSConfigurationStmt(const AlterTSConfigurationStmt *a, const AlterTSConfigurationStmt *b)
2920 : {
2921 20928 : COMPARE_SCALAR_FIELD(kind);
2922 20928 : COMPARE_NODE_FIELD(cfgname);
2923 20928 : COMPARE_NODE_FIELD(tokentype);
2924 20928 : COMPARE_NODE_FIELD(dicts);
2925 20928 : COMPARE_SCALAR_FIELD(override);
2926 20928 : COMPARE_SCALAR_FIELD(replace);
2927 20928 : COMPARE_SCALAR_FIELD(missing_ok);
2928 :
2929 20928 : return true;
2930 : }
2931 :
2932 : static bool
2933 5016 : _equalPublicationTable(const PublicationTable *a, const PublicationTable *b)
2934 : {
2935 5016 : COMPARE_NODE_FIELD(relation);
2936 5016 : COMPARE_NODE_FIELD(whereClause);
2937 5016 : COMPARE_NODE_FIELD(columns);
2938 :
2939 5016 : return true;
2940 : }
2941 :
2942 : static bool
2943 6440 : _equalPublicationObjSpec(const PublicationObjSpec *a, const PublicationObjSpec *b)
2944 : {
2945 6440 : COMPARE_SCALAR_FIELD(pubobjtype);
2946 6440 : COMPARE_STRING_FIELD(name);
2947 6440 : COMPARE_NODE_FIELD(pubtable);
2948 : COMPARE_LOCATION_FIELD(location);
2949 :
2950 6440 : return true;
2951 : }
2952 :
2953 : static bool
2954 2656 : _equalCreatePublicationStmt(const CreatePublicationStmt *a, const CreatePublicationStmt *b)
2955 : {
2956 2656 : COMPARE_STRING_FIELD(pubname);
2957 2656 : COMPARE_NODE_FIELD(options);
2958 2656 : COMPARE_NODE_FIELD(pubobjects);
2959 2656 : COMPARE_SCALAR_FIELD(for_all_tables);
2960 :
2961 2656 : return true;
2962 : }
2963 :
2964 : static bool
2965 4048 : _equalAlterPublicationStmt(const AlterPublicationStmt *a, const AlterPublicationStmt *b)
2966 : {
2967 4048 : COMPARE_STRING_FIELD(pubname);
2968 4048 : COMPARE_NODE_FIELD(options);
2969 4048 : COMPARE_NODE_FIELD(pubobjects);
2970 4048 : COMPARE_SCALAR_FIELD(for_all_tables);
2971 4048 : COMPARE_SCALAR_FIELD(action);
2972 :
2973 4048 : return true;
2974 : }
2975 :
2976 : static bool
2977 1472 : _equalCreateSubscriptionStmt(const CreateSubscriptionStmt *a, const CreateSubscriptionStmt *b)
2978 : {
2979 1472 : COMPARE_STRING_FIELD(subname);
2980 1472 : COMPARE_STRING_FIELD(conninfo);
2981 1472 : COMPARE_NODE_FIELD(publication);
2982 1472 : COMPARE_NODE_FIELD(options);
2983 :
2984 1472 : return true;
2985 : }
2986 :
2987 : static bool
2988 1724 : _equalAlterSubscriptionStmt(const AlterSubscriptionStmt *a, const AlterSubscriptionStmt *b)
2989 : {
2990 1724 : COMPARE_SCALAR_FIELD(kind);
2991 1724 : COMPARE_STRING_FIELD(subname);
2992 1724 : COMPARE_STRING_FIELD(conninfo);
2993 1724 : COMPARE_NODE_FIELD(publication);
2994 1724 : COMPARE_NODE_FIELD(options);
2995 :
2996 1724 : return true;
2997 : }
2998 :
2999 : static bool
3000 656 : _equalDropSubscriptionStmt(const DropSubscriptionStmt *a, const DropSubscriptionStmt *b)
3001 : {
3002 656 : COMPARE_STRING_FIELD(subname);
3003 656 : COMPARE_SCALAR_FIELD(missing_ok);
3004 656 : COMPARE_SCALAR_FIELD(behavior);
3005 :
3006 656 : return true;
3007 : }
3008 :
3009 : static bool
3010 0 : _equalPathKey(const PathKey *a, const PathKey *b)
3011 : {
3012 0 : COMPARE_SCALAR_FIELD(pk_eclass);
3013 0 : COMPARE_SCALAR_FIELD(pk_opfamily);
3014 0 : COMPARE_SCALAR_FIELD(pk_strategy);
3015 0 : COMPARE_SCALAR_FIELD(pk_nulls_first);
3016 :
3017 0 : return true;
3018 : }
3019 :
3020 : static bool
3021 0 : _equalRestrictInfo(const RestrictInfo *a, const RestrictInfo *b)
3022 : {
3023 0 : COMPARE_NODE_FIELD(clause);
3024 0 : COMPARE_SCALAR_FIELD(is_pushed_down);
3025 0 : COMPARE_SCALAR_FIELD(has_clone);
3026 0 : COMPARE_SCALAR_FIELD(is_clone);
3027 0 : COMPARE_SCALAR_FIELD(security_level);
3028 0 : COMPARE_BITMAPSET_FIELD(required_relids);
3029 0 : COMPARE_BITMAPSET_FIELD(incompatible_relids);
3030 0 : COMPARE_BITMAPSET_FIELD(outer_relids);
3031 0 : COMPARE_SCALAR_FIELD(rinfo_serial);
3032 :
3033 0 : return true;
3034 : }
3035 :
3036 : static bool
3037 966 : _equalPlaceHolderVar(const PlaceHolderVar *a, const PlaceHolderVar *b)
3038 : {
3039 966 : COMPARE_BITMAPSET_FIELD(phnullingrels);
3040 954 : COMPARE_SCALAR_FIELD(phid);
3041 750 : COMPARE_SCALAR_FIELD(phlevelsup);
3042 :
3043 750 : return true;
3044 : }
3045 :
3046 : static bool
3047 0 : _equalSpecialJoinInfo(const SpecialJoinInfo *a, const SpecialJoinInfo *b)
3048 : {
3049 0 : COMPARE_BITMAPSET_FIELD(min_lefthand);
3050 0 : COMPARE_BITMAPSET_FIELD(min_righthand);
3051 0 : COMPARE_BITMAPSET_FIELD(syn_lefthand);
3052 0 : COMPARE_BITMAPSET_FIELD(syn_righthand);
3053 0 : COMPARE_SCALAR_FIELD(jointype);
3054 0 : COMPARE_SCALAR_FIELD(ojrelid);
3055 0 : COMPARE_BITMAPSET_FIELD(commute_above_l);
3056 0 : COMPARE_BITMAPSET_FIELD(commute_above_r);
3057 0 : COMPARE_BITMAPSET_FIELD(commute_below_l);
3058 0 : COMPARE_BITMAPSET_FIELD(commute_below_r);
3059 0 : COMPARE_SCALAR_FIELD(lhs_strict);
3060 0 : COMPARE_SCALAR_FIELD(semi_can_btree);
3061 0 : COMPARE_SCALAR_FIELD(semi_can_hash);
3062 0 : COMPARE_NODE_FIELD(semi_operators);
3063 0 : COMPARE_NODE_FIELD(semi_rhs_exprs);
3064 :
3065 0 : return true;
3066 : }
3067 :
3068 : static bool
3069 0 : _equalAppendRelInfo(const AppendRelInfo *a, const AppendRelInfo *b)
3070 : {
3071 0 : COMPARE_SCALAR_FIELD(parent_relid);
3072 0 : COMPARE_SCALAR_FIELD(child_relid);
3073 0 : COMPARE_SCALAR_FIELD(parent_reltype);
3074 0 : COMPARE_SCALAR_FIELD(child_reltype);
3075 0 : COMPARE_NODE_FIELD(translated_vars);
3076 0 : COMPARE_SCALAR_FIELD(num_child_cols);
3077 0 : COMPARE_POINTER_FIELD(parent_colnos, a->num_child_cols * sizeof(AttrNumber));
3078 0 : COMPARE_SCALAR_FIELD(parent_reloid);
3079 :
3080 0 : return true;
3081 : }
3082 :
3083 : static bool
3084 0 : _equalPlaceHolderInfo(const PlaceHolderInfo *a, const PlaceHolderInfo *b)
3085 : {
3086 0 : COMPARE_SCALAR_FIELD(phid);
3087 0 : COMPARE_NODE_FIELD(ph_var);
3088 0 : COMPARE_BITMAPSET_FIELD(ph_eval_at);
3089 0 : COMPARE_BITMAPSET_FIELD(ph_lateral);
3090 0 : COMPARE_BITMAPSET_FIELD(ph_needed);
3091 0 : COMPARE_SCALAR_FIELD(ph_width);
3092 :
3093 0 : return true;
3094 : }
3095 :
3096 : static bool
3097 897352 : _equalInteger(const Integer *a, const Integer *b)
3098 : {
3099 897352 : COMPARE_SCALAR_FIELD(ival);
3100 :
3101 897352 : return true;
3102 : }
3103 :
3104 : static bool
3105 21912 : _equalFloat(const Float *a, const Float *b)
3106 : {
3107 21912 : COMPARE_STRING_FIELD(fval);
3108 :
3109 21912 : return true;
3110 : }
3111 :
3112 : static bool
3113 153972 : _equalBoolean(const Boolean *a, const Boolean *b)
3114 : {
3115 153972 : COMPARE_SCALAR_FIELD(boolval);
3116 :
3117 153972 : return true;
3118 : }
3119 :
3120 : static bool
3121 25952578 : _equalString(const String *a, const String *b)
3122 : {
3123 25952578 : COMPARE_STRING_FIELD(sval);
3124 :
3125 25951428 : return true;
3126 : }
3127 :
3128 : static bool
3129 8088 : _equalBitString(const BitString *a, const BitString *b)
3130 : {
3131 8088 : COMPARE_STRING_FIELD(bsval);
3132 :
3133 8088 : return true;
3134 : }
|