From: Michael Paquier <michael@paquier.xyz>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-committers@lists.postgresql.org
Subject: Re: pgsql: Make all ereport() calls within gram.y provide error locations.
Date: Fri, 1 Nov 2024 10:56:50 +0900
Message-ID: <ZyQ1YgvaQw85F-Jm@paquier.xyz> (raw)
In-Reply-To: <E1t6bUA-003L1a-OS@gemulon.postgresql.org>
References: <E1t6bUA-003L1a-OS@gemulon.postgresql.org>
Hi Tom,
On Thu, Oct 31, 2024 at 08:09:38PM +0000, Tom Lane wrote:
> Make all ereport() calls within gram.y provide error locations.
>
> This patch responds to a comment that I (tgl) made in the
> discussion leading up to 774171c4f, that really all errors
> occurring during raw parsing should provide error cursors.
> Syntax errors reported by Bison will have one, and most of
> the handwritten ereport's in gram.y already provide one,
> but there were a few stragglers.
>
> (It is not claimed that this handles every failure reachable
> during raw parsing --- out-of-memory is an obvious exception.
> But this makes a good start on cases that are likely to occur.)
>
> While we're at it, clean up the reported positions for errors
> associated with LIMIT/OFFSET clauses. Previously we were
> relying on applying exprLocation() to the contained expressions,
> but that leads to slightly odd cursor placement, e.g.
The tests of sepgsql need a refresh:
https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=rhinoceros&dt=2024-10-31%2020%3A52%3A13
Thanks,
--
Michael
Attachments:
signature.asc (application/pgp-signature, 832B) download
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: pgsql-committers@postgresql.org
Cc: michael@paquier.xyz, tgl@sss.pgh.pa.us, pgsql-committers@lists.postgresql.org
Subject: Re: pgsql: Make all ereport() calls within gram.y provide error locations.
In-Reply-To: <ZyQ1YgvaQw85F-Jm@paquier.xyz>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox