diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2017-06-21 14:39:04 -0400 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2017-06-21 14:39:04 -0400 |
commit | e3860ffa4dd0dad0dd9eea4be9cc1412373a8c89 (patch) | |
tree | 8dc7df95c340803546152724fbc17aee4b8527f9 /src/interfaces/ecpg/test | |
parent | 8ff6d4ec7840b0af56f1207073f44b7f2afae96d (diff) | |
download | postgresql-e3860ffa4dd0dad0dd9eea4be9cc1412373a8c89.tar.gz postgresql-e3860ffa4dd0dad0dd9eea4be9cc1412373a8c89.zip |
Initial pgindent run with pg_bsd_indent version 2.0.
The new indent version includes numerous fixes thanks to Piotr Stefaniak.
The main changes visible in this commit are:
* Nicer formatting of function-pointer declarations.
* No longer unexpectedly removes spaces in expressions using casts,
sizeof, or offsetof.
* No longer wants to add a space in "struct structname *varname", as
well as some similar cases for const- or volatile-qualified pointers.
* Declarations using PG_USED_FOR_ASSERTS_ONLY are formatted more nicely.
* Fixes bug where comments following declarations were sometimes placed
with no space separating them from the code.
* Fixes some odd decisions for comments following case labels.
* Fixes some cases where comments following code were indented to less
than the expected column 33.
On the less good side, it now tends to put more whitespace around typedef
names that are not listed in typedefs.list. This might encourage us to
put more effort into typedef name collection; it's not really a bug in
indent itself.
There are more changes coming after this round, having to do with comment
indentation and alignment of lines appearing within parentheses. I wanted
to limit the size of the diffs to something that could be reviewed without
one's eyes completely glazing over, so it seemed better to split up the
changes as much as practical.
Discussion: https://postgr.es/m/E1dAmxK-0006EE-1r@gemulon.postgresql.org
Discussion: https://postgr.es/m/30527.1495162840@sss.pgh.pa.us
Diffstat (limited to 'src/interfaces/ecpg/test')
16 files changed, 19 insertions, 19 deletions
diff --git a/src/interfaces/ecpg/test/expected/compat_informix-test_informix2.c b/src/interfaces/ecpg/test/expected/compat_informix-test_informix2.c index 4476130689c..98246f47345 100644 --- a/src/interfaces/ecpg/test/expected/compat_informix-test_informix2.c +++ b/src/interfaces/ecpg/test/expected/compat_informix-test_informix2.c @@ -29,7 +29,7 @@ #define SQLERRMC_LEN 150 #ifdef __cplusplus -extern "C" +extern "C" { #endif diff --git a/src/interfaces/ecpg/test/expected/preproc-init.c b/src/interfaces/ecpg/test/expected/preproc-init.c index 9e410ff1558..6ca8d559014 100644 --- a/src/interfaces/ecpg/test/expected/preproc-init.c +++ b/src/interfaces/ecpg/test/expected/preproc-init.c @@ -23,7 +23,7 @@ #define SQLERRMC_LEN 150 #ifdef __cplusplus -extern "C" +extern "C" { #endif diff --git a/src/interfaces/ecpg/test/expected/preproc-outofscope.c b/src/interfaces/ecpg/test/expected/preproc-outofscope.c index 348e8433286..70809c450d0 100644 --- a/src/interfaces/ecpg/test/expected/preproc-outofscope.c +++ b/src/interfaces/ecpg/test/expected/preproc-outofscope.c @@ -62,7 +62,7 @@ typedef struct } decimal; #ifdef __cplusplus -extern "C" +extern "C" { #endif diff --git a/src/interfaces/ecpg/test/expected/sql-array.c b/src/interfaces/ecpg/test/expected/sql-array.c index 9128741dd34..4b0a0418f73 100644 --- a/src/interfaces/ecpg/test/expected/sql-array.c +++ b/src/interfaces/ecpg/test/expected/sql-array.c @@ -36,7 +36,7 @@ #define SQLERRMC_LEN 150 #ifdef __cplusplus -extern "C" +extern "C" { #endif diff --git a/src/interfaces/ecpg/test/expected/sql-code100.c b/src/interfaces/ecpg/test/expected/sql-code100.c index 3c8fea62169..4338f7ed2d3 100644 --- a/src/interfaces/ecpg/test/expected/sql-code100.c +++ b/src/interfaces/ecpg/test/expected/sql-code100.c @@ -23,7 +23,7 @@ #define SQLERRMC_LEN 150 #ifdef __cplusplus -extern "C" +extern "C" { #endif diff --git a/src/interfaces/ecpg/test/expected/sql-copystdout.c b/src/interfaces/ecpg/test/expected/sql-copystdout.c index 62db9c17718..a1e75958731 100644 --- a/src/interfaces/ecpg/test/expected/sql-copystdout.c +++ b/src/interfaces/ecpg/test/expected/sql-copystdout.c @@ -25,7 +25,7 @@ #define SQLERRMC_LEN 150 #ifdef __cplusplus -extern "C" +extern "C" { #endif diff --git a/src/interfaces/ecpg/test/expected/sql-define.c b/src/interfaces/ecpg/test/expected/sql-define.c index ad6e317aac5..9c9931f4438 100644 --- a/src/interfaces/ecpg/test/expected/sql-define.c +++ b/src/interfaces/ecpg/test/expected/sql-define.c @@ -23,7 +23,7 @@ #define SQLERRMC_LEN 150 #ifdef __cplusplus -extern "C" +extern "C" { #endif diff --git a/src/interfaces/ecpg/test/expected/sql-dynalloc.c b/src/interfaces/ecpg/test/expected/sql-dynalloc.c index c78e13a3f6e..d2051e6996a 100644 --- a/src/interfaces/ecpg/test/expected/sql-dynalloc.c +++ b/src/interfaces/ecpg/test/expected/sql-dynalloc.c @@ -24,7 +24,7 @@ #define SQLERRMC_LEN 150 #ifdef __cplusplus -extern "C" +extern "C" { #endif diff --git a/src/interfaces/ecpg/test/expected/sql-dynalloc2.c b/src/interfaces/ecpg/test/expected/sql-dynalloc2.c index 9f74a0c5f9e..2d25149cbbc 100644 --- a/src/interfaces/ecpg/test/expected/sql-dynalloc2.c +++ b/src/interfaces/ecpg/test/expected/sql-dynalloc2.c @@ -24,7 +24,7 @@ #define SQLERRMC_LEN 150 #ifdef __cplusplus -extern "C" +extern "C" { #endif diff --git a/src/interfaces/ecpg/test/expected/sql-dyntest.c b/src/interfaces/ecpg/test/expected/sql-dyntest.c index 2cbc196009c..ea0d859bd7e 100644 --- a/src/interfaces/ecpg/test/expected/sql-dyntest.c +++ b/src/interfaces/ecpg/test/expected/sql-dyntest.c @@ -77,7 +77,7 @@ enum #define SQLERRMC_LEN 150 #ifdef __cplusplus -extern "C" +extern "C" { #endif diff --git a/src/interfaces/ecpg/test/expected/sql-indicators.c b/src/interfaces/ecpg/test/expected/sql-indicators.c index 6c8cffc2490..454fba0dba8 100644 --- a/src/interfaces/ecpg/test/expected/sql-indicators.c +++ b/src/interfaces/ecpg/test/expected/sql-indicators.c @@ -25,7 +25,7 @@ #define SQLERRMC_LEN 150 #ifdef __cplusplus -extern "C" +extern "C" { #endif diff --git a/src/interfaces/ecpg/test/expected/sql-sqlda.c b/src/interfaces/ecpg/test/expected/sql-sqlda.c index b470b04a6ae..b6c35ab1a3a 100644 --- a/src/interfaces/ecpg/test/expected/sql-sqlda.c +++ b/src/interfaces/ecpg/test/expected/sql-sqlda.c @@ -84,7 +84,7 @@ typedef struct } decimal; #ifdef __cplusplus -extern "C" +extern "C" { #endif diff --git a/src/interfaces/ecpg/test/expected/thread-alloc.c b/src/interfaces/ecpg/test/expected/thread-alloc.c index 49f1cd19c4f..57ef2bcc63b 100644 --- a/src/interfaces/ecpg/test/expected/thread-alloc.c +++ b/src/interfaces/ecpg/test/expected/thread-alloc.c @@ -46,7 +46,7 @@ main(void) #define SQLERRMC_LEN 150 #ifdef __cplusplus -extern "C" +extern "C" { #endif diff --git a/src/interfaces/ecpg/test/expected/thread-descriptor.c b/src/interfaces/ecpg/test/expected/thread-descriptor.c index e2be89dec04..50a7a31da43 100644 --- a/src/interfaces/ecpg/test/expected/thread-descriptor.c +++ b/src/interfaces/ecpg/test/expected/thread-descriptor.c @@ -37,7 +37,7 @@ #define SQLERRMC_LEN 150 #ifdef __cplusplus -extern "C" +extern "C" { #endif diff --git a/src/interfaces/ecpg/test/expected/thread-prep.c b/src/interfaces/ecpg/test/expected/thread-prep.c index 4d06b90b984..382e2148799 100644 --- a/src/interfaces/ecpg/test/expected/thread-prep.c +++ b/src/interfaces/ecpg/test/expected/thread-prep.c @@ -46,7 +46,7 @@ main(void) #define SQLERRMC_LEN 150 #ifdef __cplusplus -extern "C" +extern "C" { #endif diff --git a/src/interfaces/ecpg/test/regression.h b/src/interfaces/ecpg/test/regression.h index 4aa13b6fb29..6b7fba1bfd3 100644 --- a/src/interfaces/ecpg/test/regression.h +++ b/src/interfaces/ecpg/test/regression.h @@ -1,5 +1,5 @@ -exec sql define REGRESSDB1 ecpg1_regression; -exec sql define REGRESSDB2 ecpg2_regression; +exec sql define REGRESSDB1 ecpg1_regression; +exec sql define REGRESSDB2 ecpg2_regression; -exec sql define REGRESSUSER1 regress_ecpg_user1; -exec sql define REGRESSUSER2 regress_ecpg_user2; +exec sql define REGRESSUSER1 regress_ecpg_user1; +exec sql define REGRESSUSER2 regress_ecpg_user2; |