public inbox for [email protected]
help / color / mirror / Atom feedFrom: Andrew Dunstan <[email protected]>
To: Tom Lane <[email protected]>
To: Akshay Joshi <[email protected]>
Cc: Ashutosh Bapat <[email protected]>
Cc: pgsql-hackers <[email protected]>
Subject: Re: [PATCH] pgindent truncates last line of files missing a trailing newline
Date: Fri, 27 Mar 2026 15:08:22 -0400
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <CANxoLDfca8O5SkeDxB_j6SVNXd+pNKaDmVmEW+2yyicdU8fy0w@mail.gmail.com>
<[email protected]>
<[email protected]>
<CAExHW5uSuG9qcGd=o6o6TiwWUKE4ie7K7nmgKzDzUKxrQ9rYDw@mail.gmail.com>
<CANxoLDdbhQbap5vd3=01ad67EGbGNKDsvZdYVT3KRUiy-onYqA@mail.gmail.com>
<[email protected]>
On 2026-03-26 Th 12:29 PM, Tom Lane wrote:
> Akshay Joshi<[email protected]> writes:
>> I have addressed the review comments from Andrew.
>> Attached is the v2 patch, ready for review.
> I'm not sure I want to expend the brain cells to figure out whether
> this is a correct/complete patch. If pg_bsd_indent were less of an
> undercommented spaghetti-code nightmare, maybe fixing it here would
> be reasonable. But as things stand, why don't we just fix this in
> the perl wrapper, as attached?
Well, I thought we were trying to reduce the fixups we did in pgindent.
However, I take your point about the ugly nature of the pg_bsd_indent
code. So I'm ok with this fix, which is quite straightforward.
>
> (In any case, I'm not in favor of adding a test case, because that
> would require putting a trailing-newline-less .c file into our tree.
> At best there would be a permanent hazard of something "fixing"
> the file.)
>
>
fair point.
cheers
andrew
--
Andrew Dunstan
EDB:https://www.enterprisedb.com
view thread (7+ messages) latest in thread
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected], [email protected], [email protected]
Subject: Re: [PATCH] pgindent truncates last line of files missing a trailing newline
In-Reply-To: <[email protected]>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox