From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | James Coleman <jtc331(at)gmail(dot)com> |
Cc: | pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: pgindent (probably my missing something obvious) |
Date: | 2023-07-04 02:04:21 |
Message-ID: | 475710.1688436261@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
James Coleman <jtc331(at)gmail(dot)com> writes:
> My heuristic for what pgindent changes must be wrong. The long
> function calls (and 'if' conditions) seem obviously out of place to my
> eyes with the surrounding code. Does that mean the surrounding code
> was just hand-prettified?
pgindent won't usually editorialize on line breaks within C
statements. (It *will* re-flow comment text, if the comment block
isn't at the left margin.) It seems to feel free to play with
horizontal whitespace, but not to add or remove newlines within a
statement. I do know that it will move curly braces around to meet
formatting rules, but I've not seen it do similar changes within a
function call or if-condition. So it's up to you to break the lines
in a reasonable way.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Ibrar Ahmed | 2023-07-04 02:27:19 | Re: Commitfest manager for July |
Previous Message | James Coleman | 2023-07-04 01:41:10 | Re: pgindent (probably my missing something obvious) |