]> granicus.if.org Git - postgresql/commit
Restrict vertical tightness to parentheses in Perl code
authorAndrew Dunstan <andrew@dunslane.net>
Wed, 9 May 2018 14:14:46 +0000 (10:14 -0400)
committerAndrew Dunstan <andrew@dunslane.net>
Wed, 9 May 2018 14:14:46 +0000 (10:14 -0400)
commit35361ee78890ce5b559a710c8fa2fdfa843eb280
tree22a5a33c4e327f6260f85e1bf36f54759da7f2be
parent286bb240e1c8e279efa2d805c7f700abfb771925
Restrict vertical tightness to parentheses in Perl code

The vertical tightness settings collapse vertical whitespace between
opening and closing brackets (parentheses, square brakets and braces).
This can make data structures in particular harder to read, and is not
very consistent with our style in non-Perl code. This patch restricts
that setting to parentheses only, and reformats all the perl code
accordingly. Not applying this to parentheses has some unfortunate
effects, so the consensus is to keep the setting for parentheses and not
for the others.

The diff for this patch does highlight some places where structures
should have trailing commas. They can be added manually, as there is no
automatic tool to do so.

Discussion: https://postgr.es/m/a2f2b87c-56be-c070-bfc0-36288b4b41c1@2ndQuadrant.com
46 files changed:
src/backend/catalog/Catalog.pm
src/backend/utils/Gen_fmgrtab.pl
src/backend/utils/mb/Unicode/UCS_to_BIG5.pl
src/backend/utils/mb/Unicode/UCS_to_EUC_CN.pl
src/backend/utils/mb/Unicode/UCS_to_EUC_JIS_2004.pl
src/backend/utils/mb/Unicode/UCS_to_EUC_JP.pl
src/backend/utils/mb/Unicode/UCS_to_EUC_KR.pl
src/backend/utils/mb/Unicode/UCS_to_EUC_TW.pl
src/backend/utils/mb/Unicode/UCS_to_GB18030.pl
src/backend/utils/mb/Unicode/UCS_to_JOHAB.pl
src/backend/utils/mb/Unicode/UCS_to_SHIFT_JIS_2004.pl
src/backend/utils/mb/Unicode/UCS_to_SJIS.pl
src/backend/utils/mb/Unicode/UCS_to_UHC.pl
src/backend/utils/mb/Unicode/convutils.pm
src/bin/pg_archivecleanup/t/010_pg_archivecleanup.pl
src/bin/pg_basebackup/t/010_pg_basebackup.pl
src/bin/pg_basebackup/t/020_pg_receivewal.pl
src/bin/pg_basebackup/t/030_pg_recvlogical.pl
src/bin/pg_controldata/t/001_pg_controldata.pl
src/bin/pg_ctl/t/001_start_stop.pl
src/bin/pg_dump/t/002_pg_dump.pl
src/bin/pg_dump/t/010_dump_connstr.pl
src/bin/pg_resetwal/t/002_corrupted.pl
src/bin/pg_rewind/RewindTest.pm
src/bin/pg_rewind/t/003_extrafiles.pl
src/bin/pgbench/t/001_pgbench_with_server.pl
src/bin/pgbench/t/002_pgbench_no_server.pl
src/bin/psql/create_help.pl
src/test/kerberos/t/001_auth.pl
src/test/modules/test_pg_dump/t/001_base.pl
src/test/perl/PostgresNode.pm
src/test/perl/TestLib.pm
src/test/recovery/t/006_logical_decoding.pl
src/test/recovery/t/011_crash_recovery.pl
src/test/recovery/t/013_crash_restart.pl
src/test/ssl/ServerSetup.pm
src/tools/git_changelog
src/tools/msvc/Install.pm
src/tools/msvc/MSBuildProject.pm
src/tools/msvc/Mkvcbuild.pm
src/tools/msvc/Project.pm
src/tools/msvc/Solution.pm
src/tools/msvc/VCBuildProject.pm
src/tools/pgindent/perltidyrc
src/tools/pgindent/pgindent
src/tools/win32tzlist.pl