Re: pl/python refactoring - Mailing list pgsql-hackers

From Tom Lane
Subject Re: pl/python refactoring
Date
Msg-id 21644.1295457600@sss.pgh.pa.us
Whole thread Raw
In response to Re: pl/python refactoring  (Alvaro Herrera <alvherre@commandprompt.com>)
List pgsql-hackers
Alvaro Herrera <alvherre@commandprompt.com> writes:
> Excerpts from Peter Eisentraut's message of mar ene 18 19:22:50 -0300 2011:
>> #16: This is probably pointless because pgindent will reformat this.

> pgindent used to remove useless braces around single-statement blocks,
> but this behavior was removed years ago because it'd break formatting
> around PG_TRY blocks.

Yeah.  FWIW, I concur with Jan that this is a readability improvement.
A comment and a statement always look like two statements to me ---
and the fact that pgindent insists on inserting a blank line in front
of the comment in this scenario does even more to mangle the visual
impression of what the "if" controls.  +1 for the braces.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: Replication logging
Next
From: Tom Lane
Date:
Subject: Re: pg_basebackup for streaming base backups