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 1kdeCS-0008Am-Q1 for pgsql-hackers@arkaria.postgresql.org; Fri, 13 Nov 2020 18:53:32 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1kdeCR-000332-NB for pgsql-hackers@arkaria.postgresql.org; Fri, 13 Nov 2020 18:53:31 +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 1kdeCR-00032v-G6 for pgsql-hackers@lists.postgresql.org; Fri, 13 Nov 2020 18:53:31 +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 1kdeCP-0004BR-AB for pgsql-hackers@lists.postgresql.org; Fri, 13 Nov 2020 18:53:30 +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 0ADIrRqt393227; Fri, 13 Nov 2020 13:53:27 -0500 From: Tom Lane To: Jacob Champion cc: pgsql-hackers@lists.postgresql.org, Nikhil Benesch Subject: Re: [PATCH] Support negative indexes in split_part In-reply-to: <160503709681.7362.10221272161043601074.pgcf@coridan.postgresql.org> References: <160503709681.7362.10221272161043601074.pgcf@coridan.postgresql.org> Comments: In-reply-to Jacob Champion message dated "Tue, 10 Nov 2020 19:38:16 +0000" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <393225.1605293607.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Fri, 13 Nov 2020 13:53:27 -0500 Message-ID: <393226.1605293607@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Jacob Champion writes: > Patch looks good to me. Seems like a useful feature, and I agree that th= e two-pass implementation makes the change very easy to review. LGTM too. I made a couple of cosmetic improvements and pushed it. > Quick note on test coverage: gcov marks the "needle not found" branch (t= he one marked `/* special case if fldsep not found at all */`) as being co= mpletely uncovered. I don't think that needs to gate this patch; it looks = like it was uncovered before this feature was added. We seem to be trying for full test coverage of this function now, so I added a test case for that branch too. > Doc builds are currently failing due to what appears to be an xmllint fa= ilure: Unrelated, but see https://www.postgresql.org/message-id/flat/E2EE6B76-2D96-408A-B961-CAE47D1= A86F0%40yesql.se regards, tom lane