| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | Pierre Forstmann <pierre(dot)forstmann(at)gmail(dot)com> |
| Cc: | pierre(at)senellart(dot)com, pgsql-bugs(at)lists(dot)postgresql(dot)org |
| Subject: | Re: [patch] BUG #19558: User-defined prefix operators "|" and "->" no longer parse in 19beta2 (SQL/PGQ grammar change) |
| Date: | 2026-07-18 17:03:31 |
| Message-ID: | 125921.1784394211@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-bugs |
Pierre Forstmann <pierre(dot)forstmann(at)gmail(dot)com> writes:
> Le 18/07/2026 à 17:42, Tom Lane a écrit :
>> Why are you promoting these to UMINUS binding precedence?
>> AFAICS they would have had Op precedence before v19
>> (and still do, as binary operators).
> No good reason: I have fixed my mistake in patch v002.
OK. You don't need the explicit %prec specs, because these operators
already have the same precedence as Op:
%left Op OPERATOR RIGHT_ARROW '|' /* multi-character ops and user-defined operators */
and a bison rule takes the precedence of its rightmost terminal
symbol by default. More importantly, you missed adding the
same productions to b_expr, so that there would have been contexts
where these symbols still didn't work like they used to.
I fixed both those things and pushed it. Thanks for the
report and the patch!
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Tom Lane | 2026-07-18 18:11:11 | Re: BUG #19553: Wrong results from nested LEFT JOINs over an empty subquery (regression since v16) |
| Previous Message | Pierre Forstmann | 2026-07-18 16:01:48 | Re: [patch] BUG #19558: User-defined prefix operators "|" and "->" no longer parse in 19beta2 (SQL/PGQ grammar change) |