pgindent run prior to branching v12.
authorTom Lane
Mon, 1 Jul 2019 16:37:52 +0000 (12:37 -0400)
committerTom Lane
Mon, 1 Jul 2019 16:37:52 +0000 (12:37 -0400)
pgperltidy and reformat-dat-files too, though the latter didn't
find anything to change.

15 files changed:
contrib/postgres_fdw/postgres_fdw.h
src/backend/commands/indexcmds.c
src/backend/commands/tablecmds.c
src/backend/commands/tablespace.c
src/backend/executor/nodeIndexonlyscan.c
src/backend/executor/nodeModifyTable.c
src/backend/partitioning/partbounds.c
src/backend/utils/adt/pg_lsn.c
src/backend/utils/cache/syscache.c
src/backend/utils/misc/guc.c
src/bin/initdb/findtimezone.c
src/include/catalog/pg_statistic_ext_data.h
src/tools/msvc/Mkvcbuild.pm
src/tools/pgindent/README
src/tools/pgindent/typedefs.list

index 35545e1831daa0d4308d2fc95bbeb36c3ef6fd5d..6acb7dcf6cd283b40e4ac5ec64d9eb6dc0e4097c 100644 (file)
@@ -64,6 +64,7 @@ typedef struct PgFdwRelationInfo
    int         width;
    Cost        startup_cost;
    Cost        total_cost;
+
    /*
     * Estimated number of rows fetched from the foreign server, and costs
     * excluding costs for transferring those rows from the foreign server.
index 579b99895488aa85128b87ffe2cc59a098db211d..6fa5738bbfb51924680e03cb9b32d1a2bf39c25c 100644 (file)
@@ -1085,9 +1085,9 @@ DefineIndex(Oid relationId,
                childrel = table_open(childRelid, lockmode);
 
                /*
-                * Don't try to create indexes on foreign tables, though.
-                * Skip those if a regular index, or fail if trying to create
-                * constraint index.
+                * Don't try to create indexes on foreign tables, though. Skip
+                * those if a regular index, or fail if trying to create a
+                * constraint index.
                 */
                if (childrel->rd_rel->relkind == RELKIND_FOREIGN_TABLE)
                {
@@ -1097,7 +1097,7 @@ DefineIndex(Oid relationId,
                                 errmsg("cannot create unique index on partitioned table \"%s\"",
                                        RelationGetRelationName(rel)),
                                 errdetail("Table \"%s\" contains partitions that are foreign tables.",
-                                       RelationGetRelationName(rel))));
+                                          RelationGetRelationName(rel))));
 
                    table_close(childrel, lockmode);
                    continue;
index fd67d2a841378e039502a544b6405d0dcababcb9..3aee2d82ce50bcafd79c44ff83a6c0dc5ffc083c 100644 (file)
@@ -1077,7 +1077,7 @@ DefineRelation(CreateStmt *stmt, char relkind, Oid ownerId,
                             errmsg("cannot create foreign partition of partitioned table \"%s\"",
                                    RelationGetRelationName(parent)),
                             errdetail("Table \"%s\" contains indexes that are unique.",
-                                   RelationGetRelationName(parent))));
+                                      RelationGetRelationName(parent))));
                else
                {
                    index_close(idxRel, AccessShareLock);
@@ -15682,6 +15682,7 @@ ATExecAttachPartition(List **wqueue, Relation rel, PartitionCmd *cmd)
        defaultrel = table_open(defaultPartOid, NoLock);
        defPartConstraint =
            get_proposed_default_constraint(partBoundConstraint);
+
        /*
         * Map the Vars in the constraint expression from rel's attnos to
         * defaultrel's.
index 502736be1aa0188938918ccac2f8cd54941cb31d..84efb414d8c5b8f7de379d49ccbba3ac1150a5ba 100644 (file)
@@ -1211,8 +1211,8 @@ check_temp_tablespaces(char **newval, void **extra, GucSource source)
    /*
     * If we aren't inside a transaction, or connected to a database, we
     * cannot do the catalog accesses necessary to verify the name.  Must
-    * accept the value on faith.
-    * Fortunately, there's then also no need to pass the data to fd.c.
+    * accept the value on faith. Fortunately, there's then also no need to
+    * pass the data to fd.c.
     */
    if (IsTransactionState() && MyDatabaseId != InvalidOid)
    {
index f0f8fa210ba6baf93c28e4f11e8a8ae66745962e..652a9afc752859e162f7f1ba43117651d202d14c 100644 (file)
@@ -528,9 +528,8 @@ ExecInitIndexOnlyScan(IndexOnlyScan *node, EState *estate, int eflags)
                          &TTSOpsVirtual);
 
    /*
-    * We need another slot, in a format that's suitable for the table AM,
-    * for when we need to fetch a tuple from the table for rechecking
-    * visibility.
+    * We need another slot, in a format that's suitable for the table AM, for
+    * when we need to fetch a tuple from the table for rechecking visibility.
     */
    indexstate->ioss_TableSlot =
        ExecAllocTableSlot(&estate->es_tupleTable,
index 24ed3718effd4444c88799f17b0666db77edcb06..d8b695d897f815708e9f4b5ba6d15cadf9b11491 100644 (file)
@@ -2317,8 +2317,8 @@ ExecInitModifyTable(ModifyTable *node, EState *estate, int eflags)
     * indexes for insertion of new index entries.  Note we *must* set
     * estate->es_result_relation_info correctly while we initialize each
     * sub-plan; external modules such as FDWs may depend on that (see
-    * contrib/postgres_fdw/postgres_fdw.c: postgresBeginDirectModify()
-    * as one example).
+    * contrib/postgres_fdw/postgres_fdw.c: postgresBeginDirectModify() as one
+    * example).
     */
    saved_resultRelInfo = estate->es_result_relation_info;
 
index f3c9236ad56f2f2b9fbd94eaf03a9b10d6531292..13d576c37942a606f1d92ae01ebd5389576cf657 100644 (file)
@@ -1237,13 +1237,14 @@ check_default_partition_contents(Relation parent, Relation default_rel,
        : get_qual_for_range(parent, new_spec, false);
    def_part_constraints =
        get_proposed_default_constraint(new_part_constraints);
+
    /*
     * Map the Vars in the constraint expression from parent's attnos to
     * default_rel's.
     */
    def_part_constraints =
-           map_partition_varattnos(def_part_constraints, 1, default_rel,
-                                   parent, NULL);
+       map_partition_varattnos(def_part_constraints, 1, default_rel,
+                               parent, NULL);
 
    /*
     * If the existing constraints on the default partition imply that it will
index 2d4b4bf3d8a025c180c888e20752678504dd8487..4c329a8d8fe84e0ba72ccf7b420aededd0b9643f 100644 (file)
@@ -61,7 +61,7 @@ pg_lsn_in(PG_FUNCTION_ARGS)
 {
    char       *str = PG_GETARG_CSTRING(0);
    XLogRecPtr  result;
-   bool have_error = false;
+   bool        have_error = false;
 
    result = pg_lsn_in_internal(str, &have_error);
    if (have_error)
index 99976468e5c10db4b16c82ce7dee7f3373502b2f..16297a52a1906a42582cbfdebe2da25cbc51dfa5 100644 (file)
@@ -728,7 +728,7 @@ static const struct cachedesc cacheinfo[] = {
        },
        32
    },
-   {StatisticExtDataRelationId, /* STATEXTDATASTXOID */
+   {StatisticExtDataRelationId,    /* STATEXTDATASTXOID */
        StatisticExtDataStxoidIndexId,
        1,
        {
index 92c4fee8f8b404d613220ae61fb6da5dcd4c7de6..631f16f5fe77098945d5bd4928a79ca46b138542 100644 (file)
@@ -11615,7 +11615,7 @@ check_recovery_target_time(char **newval, void **extra, GucSource source)
                dterr = DecodeDateTime(field, ftype, nf, &dtype, tm, &fsec, &tz);
            if (dterr != 0)
                return false;
-           if (dtype !=  DTK_DATE)
+           if (dtype != DTK_DATE)
                return false;
 
            if (tm2timestamp(tm, fsec, &tz, ×tamp) != 0)
index f91fd3115e63c0cf1d7d7b99cf58aa78ecdfbdfc..a5c9c9ee51139cbfd18ea6c05584f0ec9f5a8b55 100644 (file)
@@ -699,8 +699,9 @@ scan_available_timezones(char *tzdir, char *tzdirsub, struct tztry *tt,
            else if (score == *bestscore)
            {
                /* Consider how to break a tie */
-               int     namepref = (zone_name_pref(tzdirsub) -
-                                   zone_name_pref(bestzonename));
+               int         namepref = (zone_name_pref(tzdirsub) -
+                                       zone_name_pref(bestzonename));
+
                if (namepref > 0 ||
                    (namepref == 0 &&
                     (strlen(tzdirsub) < strlen(bestzonename) ||
index 5da9bc8ae2cf03e3a34f207c114a1ce22de86188..952883e2d3e8313eb80277226fdbdf41ac1b44fb 100644 (file)
@@ -34,9 +34,9 @@ CATALOG(pg_statistic_ext_data,3429,StatisticExtDataRelationId)
 
 #ifdef CATALOG_VARLEN          /* variable-length fields start here */
 
-   pg_ndistinct stxdndistinct; /* ndistinct coefficients (serialized) */
+   pg_ndistinct stxdndistinct; /* ndistinct coefficients (serialized) */
    pg_dependencies stxddependencies;   /* dependencies (serialized) */
-   pg_mcv_list stxdmcv;            /* MCV (serialized) */
+   pg_mcv_list stxdmcv;        /* MCV (serialized) */
 
 #endif
 
@@ -47,6 +47,6 @@ CATALOG(pg_statistic_ext_data,3429,StatisticExtDataRelationId)
  *     the format of pg_statistic_ext_data relation.
  * ----------------
  */
-typedef FormData_pg_statistic_ext_data *Form_pg_statistic_ext_data;
+typedef FormData_pg_statistic_ext_data * Form_pg_statistic_ext_data;
 
 #endif                         /* PG_STATISTIC_EXT_DATA_H */
index 973691c3de061f97bdf1ef09c95370a4eb616109..6f928234eec072e0a7510657048b32bc2275d5c0 100644 (file)
@@ -42,12 +42,12 @@ my $contrib_extrasource = {
    'seg'  => [ 'contrib/seg/segscan.l',   'contrib/seg/segparse.y' ],
 };
 my @contrib_excludes = (
-   'commit_ts',       'hstore_plperl',
-   'hstore_plpython', 'intagg',
-   'jsonb_plperl',    'jsonb_plpython',
-   'ltree_plpython',  'pgcrypto',
-   'sepgsql',         'brin',
-   'test_extensions', 'test_pg_dump',
+   'commit_ts',        'hstore_plperl',
+   'hstore_plpython',  'intagg',
+   'jsonb_plperl',     'jsonb_plpython',
+   'ltree_plpython',   'pgcrypto',
+   'sepgsql',          'brin',
+   'test_extensions',  'test_pg_dump',
    'snapshot_too_old', 'unsafe_tests');
 
 # Set of variables for frontend modules
index 044b380fed81a1a76d443562ade6d8c509ed10ac..00bffcf005ad74da557761852786babd62b12571 100644 (file)
@@ -50,6 +50,7 @@ DOING THE INDENT RUN:
 
 5) Reformat the bootstrap catalog data files:
 
+   ./configure     # "make" will not work in an unconfigured tree
    cd src/include/catalog
    make reformat-dat-files
    cd ../../..
index bdcbc8d15e09e2d955c3d9c4966f73ab16a62bc5..8cc033eb131b5a170ce942c3863605f930477664 100644 (file)
@@ -729,7 +729,6 @@ FormData_pg_sequence_data
 FormData_pg_shdepend
 FormData_pg_statistic
 FormData_pg_statistic_ext
-FormData_pg_statistic_ext_data
 FormData_pg_subscription
 FormData_pg_subscription_rel
 FormData_pg_tablespace
@@ -787,7 +786,6 @@ Form_pg_sequence_data
 Form_pg_shdepend
 Form_pg_statistic
 Form_pg_statistic_ext
-Form_pg_statistic_ext_data
 Form_pg_subscription
 Form_pg_subscription_rel
 Form_pg_tablespace