]> git.ipfire.org Git - thirdparty/postgresql.git/commitdiff
Document some structures in attribute_stats.c
authorMichael Paquier <michael@paquier.xyz>
Thu, 6 Nov 2025 07:22:12 +0000 (16:22 +0900)
committerMichael Paquier <michael@paquier.xyz>
Thu, 6 Nov 2025 07:22:12 +0000 (16:22 +0900)
Like relation_stats.c, these structures are used to track the argument
number, names and types of pg_restore_attribute_stats() and
pg_clear_attribute_stats().

Extracted from a larger patch by the same author, reworded by me for
consistency with relation_stats.c.

Author: Corey Huinker <corey.huinker@gmail.com>
Discussion: https://postgr.es/m/CADkLM=dpz3KFnqP-dgJ-zvRvtjsa8UZv8wDAQdqho=qN3kX0Zg@mail.gmail.com

src/backend/statistics/attribute_stats.c

index 401bf571f27aeb4cc8fb8043f17ab2e89d31a2df..ef4d768feab7e5192f4ae329fccadaaf09d9537c 100644 (file)
 #define DEFAULT_AVG_WIDTH      Int32GetDatum(0) /* unknown */
 #define DEFAULT_N_DISTINCT     Float4GetDatum(0.0)     /* unknown */
 
+/*
+ * Positional argument numbers, names, and types for
+ * attribute_statistics_update() and pg_restore_attribute_stats().
+ */
+
 enum attribute_stats_argnum
 {
        ATTRELSCHEMA_ARG = 0,
@@ -82,6 +87,11 @@ static struct StatsArgInfo attarginfo[] =
        [NUM_ATTRIBUTE_STATS_ARGS] = {0}
 };
 
+/*
+ * Positional argument numbers, names, and types for
+ * pg_clear_attribute_stats().
+ */
+
 enum clear_attribute_stats_argnum
 {
        C_ATTRELSCHEMA_ARG = 0,