pgsql: Don't use !! but != 0/NULL to force boolean evaluation.
pgsql: Don't use !! but != 0/NULL to force boolean evaluation.
От:
Andres Freund <andres@anarazel.de>
Дата:
Don't use !! but != 0/NULL to force boolean evaluation. I introduced several uses of !! to force bit arithmetic to be boolean, but per discussion the project prefers != 0/NULL. Discussion: CA+TgmoZP5KakLGP6B4vUjgMBUW0woq_dJYi0paOz-My0Hwt_vQ@mail.gmail.com Branch ------ master Details ------- http://git.postgresql.org/pg/commitdiff/1a7a43672bf2939dda93a27d498349e7a4aa3c14 Modified Files -------------- contrib/sepgsql/uavc.c | 2 +- src/backend/access/transam/xact.c | 3 ++- src/backend/replication/logical/reorderbuffer.c | 2 +- src/backend/storage/lmgr/lwlock.c | 12 ++++++------ src/include/access/xact.h | 4 ++-- 5 files changed, 12 insertions(+), 11 deletions(-)