pg.ddx.io pgsql-committers@postgresql.org mailing list archivehelp / color / mirror / Atom feed
pgsql: Change various Gin*Is* macros to return 0/1. 6+ messages / 1 participants [nested] [flat]
* pgsql: Change various Gin*Is* macros to return 0/1. @ 2016-03-27 15:50 Andres Freund <andres@anarazel.de> 0 siblings, 0 replies; 6+ messages in thread From: Andres Freund @ 2016-03-27 15:50 UTC (permalink / raw) To: pgsql-committers Change various Gin*Is* macros to return 0/1. Returning the direct result of bit arithmetic, in a macro intended to be used in a boolean manner, can be problematic if the return value is stored in a variable of type 'bool'. If bool is implemented using C99's _Bool, that can lead to comparison failures if the variable is then compared again with the expression (see ginStepRight() for an example that fails), as _Bool forces the result to be 0/1. That happens in some configurations of newer MSVC compilers. It's also problematic when storing the result of such an expression in a narrower type. Several gin macros have been declared in that style since gin's initial commit in 8a3631f8d86. There's a lot more macros like this, but this is the only one causing regression test failures; and I don't want to commit and backpatch a larger patch with lots of conflicts just before the next set of minor releases. Discussion: 20150811154237.GD17575@awork2.anarazel.de Backpatch: All supported branches Branch ------ master Details ------- http://git.postgresql.org/pg/commitdiff/af4472bcb88ab36b9abbe7fd5858e570a65a2d1a Modified Files -------------- src/include/access/gin_private.h | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers ^ permalink raw reply [nested|flat] 6+ messages in thread
* pgsql: Change various Gin*Is* macros to return 0/1. @ 2016-03-27 15:50 Andres Freund <andres@anarazel.de> 0 siblings, 0 replies; 6+ messages in thread From: Andres Freund @ 2016-03-27 15:50 UTC (permalink / raw) To: pgsql-committers Change various Gin*Is* macros to return 0/1. Returning the direct result of bit arithmetic, in a macro intended to be used in a boolean manner, can be problematic if the return value is stored in a variable of type 'bool'. If bool is implemented using C99's _Bool, that can lead to comparison failures if the variable is then compared again with the expression (see ginStepRight() for an example that fails), as _Bool forces the result to be 0/1. That happens in some configurations of newer MSVC compilers. It's also problematic when storing the result of such an expression in a narrower type. Several gin macros have been declared in that style since gin's initial commit in 8a3631f8d86. There's a lot more macros like this, but this is the only one causing regression test failures; and I don't want to commit and backpatch a larger patch with lots of conflicts just before the next set of minor releases. Discussion: 20150811154237.GD17575@awork2.anarazel.de Backpatch: All supported branches Branch ------ REL9_5_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/ec8a30ef2a2b5cf4221231a324d1bd3310fe8f2c Modified Files -------------- src/include/access/gin_private.h | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers ^ permalink raw reply [nested|flat] 6+ messages in thread
* pgsql: Change various Gin*Is* macros to return 0/1. @ 2016-03-27 15:50 Andres Freund <andres@anarazel.de> 0 siblings, 0 replies; 6+ messages in thread From: Andres Freund @ 2016-03-27 15:50 UTC (permalink / raw) To: pgsql-committers Change various Gin*Is* macros to return 0/1. Returning the direct result of bit arithmetic, in a macro intended to be used in a boolean manner, can be problematic if the return value is stored in a variable of type 'bool'. If bool is implemented using C99's _Bool, that can lead to comparison failures if the variable is then compared again with the expression (see ginStepRight() for an example that fails), as _Bool forces the result to be 0/1. That happens in some configurations of newer MSVC compilers. It's also problematic when storing the result of such an expression in a narrower type. Several gin macros have been declared in that style since gin's initial commit in 8a3631f8d86. There's a lot more macros like this, but this is the only one causing regression test failures; and I don't want to commit and backpatch a larger patch with lots of conflicts just before the next set of minor releases. Discussion: 20150811154237.GD17575@awork2.anarazel.de Backpatch: All supported branches Branch ------ REL9_4_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/6faea0169082b4218588e575c3db8b26458664df Modified Files -------------- src/include/access/gin_private.h | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers ^ permalink raw reply [nested|flat] 6+ messages in thread
* pgsql: Change various Gin*Is* macros to return 0/1. @ 2016-03-27 15:51 Andres Freund <andres@anarazel.de> 0 siblings, 0 replies; 6+ messages in thread From: Andres Freund @ 2016-03-27 15:51 UTC (permalink / raw) To: pgsql-committers Change various Gin*Is* macros to return 0/1. Returning the direct result of bit arithmetic, in a macro intended to be used in a boolean manner, can be problematic if the return value is stored in a variable of type 'bool'. If bool is implemented using C99's _Bool, that can lead to comparison failures if the variable is then compared again with the expression (see ginStepRight() for an example that fails), as _Bool forces the result to be 0/1. That happens in some configurations of newer MSVC compilers. It's also problematic when storing the result of such an expression in a narrower type. Several gin macros have been declared in that style since gin's initial commit in 8a3631f8d86. There's a lot more macros like this, but this is the only one causing regression test failures; and I don't want to commit and backpatch a larger patch with lots of conflicts just before the next set of minor releases. Discussion: 20150811154237.GD17575@awork2.anarazel.de Backpatch: All supported branches Branch ------ REL9_3_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/65a8a3f9f60b174d6a614dbe96169b18cf7a5366 Modified Files -------------- src/include/access/gin_private.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers ^ permalink raw reply [nested|flat] 6+ messages in thread
* pgsql: Change various Gin*Is* macros to return 0/1. @ 2016-03-27 15:51 Andres Freund <andres@anarazel.de> 0 siblings, 0 replies; 6+ messages in thread From: Andres Freund @ 2016-03-27 15:51 UTC (permalink / raw) To: pgsql-committers Change various Gin*Is* macros to return 0/1. Returning the direct result of bit arithmetic, in a macro intended to be used in a boolean manner, can be problematic if the return value is stored in a variable of type 'bool'. If bool is implemented using C99's _Bool, that can lead to comparison failures if the variable is then compared again with the expression (see ginStepRight() for an example that fails), as _Bool forces the result to be 0/1. That happens in some configurations of newer MSVC compilers. It's also problematic when storing the result of such an expression in a narrower type. Several gin macros have been declared in that style since gin's initial commit in 8a3631f8d86. There's a lot more macros like this, but this is the only one causing regression test failures; and I don't want to commit and backpatch a larger patch with lots of conflicts just before the next set of minor releases. Discussion: 20150811154237.GD17575@awork2.anarazel.de Backpatch: All supported branches Branch ------ REL9_2_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/290cc21de484da610090d5f62b98fd55e9f70ac7 Modified Files -------------- src/include/access/gin_private.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers ^ permalink raw reply [nested|flat] 6+ messages in thread
* pgsql: Change various Gin*Is* macros to return 0/1. @ 2016-03-27 15:51 Andres Freund <andres@anarazel.de> 0 siblings, 0 replies; 6+ messages in thread From: Andres Freund @ 2016-03-27 15:51 UTC (permalink / raw) To: pgsql-committers Change various Gin*Is* macros to return 0/1. Returning the direct result of bit arithmetic, in a macro intended to be used in a boolean manner, can be problematic if the return value is stored in a variable of type 'bool'. If bool is implemented using C99's _Bool, that can lead to comparison failures if the variable is then compared again with the expression (see ginStepRight() for an example that fails), as _Bool forces the result to be 0/1. That happens in some configurations of newer MSVC compilers. It's also problematic when storing the result of such an expression in a narrower type. Several gin macros have been declared in that style since gin's initial commit in 8a3631f8d86. There's a lot more macros like this, but this is the only one causing regression test failures; and I don't want to commit and backpatch a larger patch with lots of conflicts just before the next set of minor releases. Discussion: 20150811154237.GD17575@awork2.anarazel.de Backpatch: All supported branches Branch ------ REL9_1_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/598e2c55ebbbb292c4f79c4acdc8567bf18ef9be Modified Files -------------- src/include/access/gin_private.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers ^ permalink raw reply [nested|flat] 6+ messages in thread
end of thread, other threads:[~2016-03-27 15:51 UTC | newest] Thread overview: 6+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2016-03-27 15:50 pgsql: Change various Gin*Is* macros to return 0/1. Andres Freund <andres@anarazel.de> 2016-03-27 15:50 pgsql: Change various Gin*Is* macros to return 0/1. Andres Freund <andres@anarazel.de> 2016-03-27 15:50 pgsql: Change various Gin*Is* macros to return 0/1. Andres Freund <andres@anarazel.de> 2016-03-27 15:51 pgsql: Change various Gin*Is* macros to return 0/1. Andres Freund <andres@anarazel.de> 2016-03-27 15:51 pgsql: Change various Gin*Is* macros to return 0/1. Andres Freund <andres@anarazel.de> 2016-03-27 15:51 pgsql: Change various Gin*Is* macros to return 0/1. Andres Freund <andres@anarazel.de>
This inbox is served by DDX for PostgreSQL; see mirroring instructions for how to clone and mirror all data and code used for this inbox