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 1jjWWs-0005K0-MO for pgsql-hackers@arkaria.postgresql.org; Thu, 11 Jun 2020 23:22:38 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jjWWq-0001Lx-DE for pgsql-hackers@arkaria.postgresql.org; Thu, 11 Jun 2020 23:22:36 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jjWWq-0001Lq-6c for pgsql-hackers@lists.postgresql.org; Thu, 11 Jun 2020 23:22:36 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jjWWo-0000nk-3f for pgsql-hackers@lists.postgresql.org; Thu, 11 Jun 2020 23:22:35 +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 05BNMWOD582553 for ; Thu, 11 Jun 2020 19:22:32 -0400 From: Tom Lane To: pgsql-hackers@lists.postgresql.org Subject: exp() versus the POSIX standard MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <582551.1591917752.1@sss.pgh.pa.us> Date: Thu, 11 Jun 2020 19:22:32 -0400 Message-ID: <582552.1591917752@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk The POSIX standard says this about the exp(3) function: If x is -Inf, +0 shall be returned. At least on my Linux box, our version does no such thing: regression=# select exp('-inf'::float8); ERROR: value out of range: underflow Does anyone disagree that that's a bug? Should we back-patch a fix, or just change it in HEAD? Given the lack of user complaints, I lean a bit towards the latter, but am not sure. regards, tom lane