From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | pgsql-committers(at)postgresql(dot)org |
Subject: | pgsql: Fix YA unwanted behavioral difference with operator_precedence_w |
Date: | 2017-02-15 19:44:33 |
Message-ID: | E1ce5VB-0005NW-Hr@gemulon.postgresql.org |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Fix YA unwanted behavioral difference with operator_precedence_warning.
Jeff Janes noted that the error cursor position shown for some errors
would vary when operator_precedence_warning is turned on. We'd prefer
that option to have no undocumented effects, so this isn't desirable.
To fix, make sure that an AEXPR_PAREN node has the same exprLocation
as its child node.
(Note: it would be a little cheaper to use @2 here instead of an
exprLocation call, but there are cases where that wouldn't produce
the identical answer, so don't do it like that.)
Back-patch to 9.5 where this feature was introduced.
Discussion: https://postgr.es/m/CAMkU=1ykK+VhhcQ4Ky8KBo9FoaUJH3f3rDQB8TkTXi-ZsBRUkQ@mail.gmail.com
Branch
------
REL9_5_STABLE
Details
-------
http://git.postgresql.org/pg/commitdiff/2b47e29f2081f7b2bbe99d240bdd08f63438357e
Modified Files
--------------
src/backend/parser/gram.y | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2017-02-15 20:23:26 | pgsql: Fix tab completion for "ALTER SYSTEM SET variable ...". |
Previous Message | Robert Haas | 2017-02-15 18:56:43 | pgsql: Add optimizer and executor support for parallel index scans. |