aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2022-12-17 10:31:25 -0500
committerTom Lane <tgl@sss.pgh.pa.us>2022-12-17 10:31:25 -0500
commit0efecb5518c914a45d9f294adebc2948f5882f2e (patch)
treebf134306f11982a0f6b2b8f74475753ebfd97dcc
parent935277b24172979e8244a5399906c358e4176b49 (diff)
downloadpostgresql-0efecb5518c914a45d9f294adebc2948f5882f2e.tar.gz
postgresql-0efecb5518c914a45d9f294adebc2948f5882f2e.zip
Doc: update pg_list.h header comments to include XidLists.
I realize that the XidList infrastructure is rather incomplete, but failing to mention it in adjacent comments takes that a bit too far.
-rw-r--r--src/include/nodes/pg_list.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/include/nodes/pg_list.h b/src/include/nodes/pg_list.h
index dc991626ba0..57eb8458dcf 100644
--- a/src/include/nodes/pg_list.h
+++ b/src/include/nodes/pg_list.h
@@ -15,16 +15,18 @@
* Non-empty lists have a header, which will not be relocated as long as the
* list remains non-empty, and an expansible data array.
*
- * We support three types of lists:
+ * We support four types of lists:
*
* T_List: lists of pointers
* (in practice usually pointers to Nodes, but not always;
* declared as "void *" to minimize casting annoyances)
* T_IntList: lists of integers
* T_OidList: lists of Oids
+ * T_XidList: lists of TransactionIds
+ * (the XidList infrastructure is less complete than the other cases)
*
- * (At the moment, ints and Oids are the same size, but they may not
- * always be so; try to be careful to maintain the distinction.)
+ * (At the moment, ints, Oids, and XIDs are the same size, but they may not
+ * always be so; be careful to use the appropriate list type for your data.)
*
*
* Portions Copyright (c) 1996-2022, PostgreSQL Global Development Group
@@ -50,7 +52,7 @@ typedef union ListCell
typedef struct List
{
- NodeTag type; /* T_List, T_IntList, or T_OidList */
+ NodeTag type; /* T_List, T_IntList, T_OidList, or T_XidList */
int length; /* number of elements currently present */
int max_length; /* allocated length of elements[] */
ListCell *elements; /* re-allocatable array of cells */