Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kuQ1l-00047g-78 for pgsql-committers@arkaria.postgresql.org; Wed, 30 Dec 2020 01:11:49 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1kuQ1h-0006Op-T8 for pgsql-committers@arkaria.postgresql.org; Wed, 30 Dec 2020 01:11:45 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kuQ1h-0006O2-NX for pgsql-committers@lists.postgresql.org; Wed, 30 Dec 2020 01:11:45 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kuQ1c-0005ii-FA; Wed, 30 Dec 2020 01:11:44 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 0BU1BdSQ2246044; Tue, 29 Dec 2020 20:11:39 -0500 From: Tom Lane To: Alexander Korotkov cc: pgsql-committers@lists.postgresql.org Subject: Re: pgsql: Multirange datatypes In-reply-to: References: Comments: In-reply-to Alexander Korotkov message dated "Sun, 20 Dec 2020 04:21:16 +0000" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <2246042.1609290699.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Tue, 29 Dec 2020 20:11:39 -0500 Message-ID: <2246043.1609290699@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Alexander Korotkov writes: > Multirange datatypes Multiple buildfarm members are issuing similar warnings about multirangetypes.c: calliphoridae | 2020-12-29 23:10:11 | /home/andres/build/buildfarm-callip= horidae/HEAD/pgsql.build/../pgsql/src/backend/utils/adt/multirangetypes.c:= 218:37: warning: suggest braces around empty body in an 'else' statement [= -Wempty-body] calliphoridae | 2020-12-29 23:10:11 | /home/andres/build/buildfarm-callip= horidae/HEAD/pgsql.build/../pgsql/src/backend/utils/adt/multirangetypes.c:= 236:37: warning: suggest braces around empty body in an 'else' statement [= -Wempty-body] These are evidently unhappy with code like if ... ... } else /* include it in range_str */ ; So apparently preferred style is more like else { /* include it in range_str */ } I don't particularly care for the wording of this comment, either: it looks like it's describing an action that's about to be taken, only there's no action there. Could it say something more like "we already included it in range_str", or "we'll include it in range_str below the switch", or whatever's appropriate? regards, tom lane