Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dB6wM-00073e-MP for pgsql-hackers@arkaria.postgresql.org; Wed, 17 May 2017 21:57:06 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1dB6wM-0003LI-0I for pgsql-hackers@arkaria.postgresql.org; Wed, 17 May 2017 21:57:06 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dB6uq-0000gj-J3 for pgsql-hackers@postgresql.org; Wed, 17 May 2017 21:55:32 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dB6um-0004XQ-Vf for pgsql-hackers@postgresql.org; Wed, 17 May 2017 21:55:31 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id v4HLtP74012244; Wed, 17 May 2017 17:55:25 -0400 From: Tom Lane To: Alvaro Herrera cc: Piotr Stefaniak , Peter Eisentraut , "pgsql-hackers@postgresql.org" Subject: Re: [COMMITTERS] pgsql: Preventive maintenance in advance of pgindent run. In-reply-to: <20170517211347.6g2bbx2fsjffd2sz@alvherre.pgsql> References: <20170517211347.6g2bbx2fsjffd2sz@alvherre.pgsql> Comments: In-reply-to Alvaro Herrera message dated "Wed, 17 May 2017 17:13:47 -0400" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <12242.1495058125.1@sss.pgh.pa.us> Date: Wed, 17 May 2017 17:55:25 -0400 Message-ID: <12243.1495058125@sss.pgh.pa.us> X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org Alvaro Herrera writes: > Piotr Stefaniak wrote: >> If I remember correctly, it tries to right-align string literals to >> whatever -l ("Maximum length of an output line") was set to. > Yeah, it does that (for error messages too). Piotr's version seems to at least do this more consistently than the old version; for instance I notice this diff from Bruce's run: @@ -1864,8 +1864,8 @@ describeOneTableDetails(const char *schemaname, if (verbose) printfPQExpBuffer(&buf, "SELECT inhparent::pg_catalog.regclass," - " pg_get_expr(c.relpartbound, inhrelid)," - " pg_get_partition_constraintdef(inhrelid)" + " pg_get_expr(c.relpartbound, inhrelid)," + " pg_get_partition_constraintdef(inhrelid)" " FROM pg_catalog.pg_class c" " JOIN pg_catalog.pg_inherits" " ON c.oid = inhrelid" (Again, untabified for clarity.) However, it didn't do anything to any of the horribly-formatted queries in pg_dump.c, so it's mostly following the same rule as before. > I'm not sure what's the behavior we do want. One choice is that the > continuation string opening quote should line up with the opening quote > in the previous line. So for instance: Yeah, I'd vote for that one too. If you want to line things up with a function call paren, you can always start the whole literal on a fresh line, as in the above example. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers